ante

package
v2.11.0-rc0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 14, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildPrePostTransactionHookMsg

func BuildPrePostTransactionHookMsg(tx sdk.Tx, isPreTx bool) ([]byte, error)

TODO: to refactor

func BuildPreTransactionHookMsg

func BuildPreTransactionHookMsg(tx sdk.Tx) ([]byte, error)

func GetMultiSigSignBytes

func GetMultiSigSignBytes(multiPK multisig.PubKey, sig *signing.MultiSignatureData, signerData authsigning.SignerData, handler authsigning.SignModeHandler, tx sdk.Tx) (signersBytes [][]byte, err error)

func GetSignBytesArr

func GetSignBytesArr(pubKey cryptotypes.PubKey, signerData authsigning.SignerData, sigData signing.SignatureData, handler authsigning.SignModeHandler, tx sdk.Tx) (signersBytes [][]byte, err error)

func GetSignerAddrStrings

func GetSignerAddrStrings(pubKey cryptotypes.PubKey) ([]string, error)

Types

type PreTransactionHookDecorator

type PreTransactionHookDecorator struct {
	// contains filtered or unexported fields
}

func (PreTransactionHookDecorator) AnteHandle

func (pth PreTransactionHookDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler) (sdk.Context, error)

type SmartAccountAuthDecorator

type SmartAccountAuthDecorator struct {
	// contains filtered or unexported fields
}

SmartAccountAuthDecorator does authentication for smart accounts

func NewSmartAccountAuthDecorator

func NewSmartAccountAuthDecorator(
	sak SmartAccountKeeper,
	wk WasmKeeper,
	ak authante.AccountKeeper,
	sigGasConsumer func(meter sdk.GasMeter, sig signing.SignatureV2, params authtypes.Params) error,
	signModeHandler authsigning.SignModeHandler,
) SmartAccountAuthDecorator

func (SmartAccountAuthDecorator) AnteHandle

func (sad SmartAccountAuthDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler) (sdk.Context, error)

AnteHandle checks if the tx provides sufficient fee to cover the required fee from the fee market.

func (SmartAccountAuthDecorator) CustomAuthVerify

func (sad SmartAccountAuthDecorator) CustomAuthVerify(
	ctx sdk.Context,
	authMsgs []*types.AuthorizationMsg,
	senders []string,
	account string,
	signatures,
	signedBytes [][]byte,
	data []byte,
) (bool, error)

func (SmartAccountAuthDecorator) GetParamsForCustomAuthVerification

func (sad SmartAccountAuthDecorator) GetParamsForCustomAuthVerification(
	ctx sdk.Context,
	sigTx authsigning.SigVerifiableTx,
	account sdk.AccAddress,
) (
	senderAddrs []string,
	signatureBzs [][]byte,
	signedBzs [][]byte,
	err error,
)

type SmartAccountKeeper

type SmartAccountKeeper interface {
	GetSetting(ctx sdk.Context, ownerAddr string) (*smartaccounttypes.Setting, error)
}

type WasmKeeper

type WasmKeeper interface {
	Sudo(ctx sdk.Context, contractAddress sdk.AccAddress, msg []byte) ([]byte, error)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL