diff --git a/ante/evm/05_signature_verification.go b/ante/evm/05_signature_verification.go index 1558d15d2..a845c75c5 100644 --- a/ante/evm/05_signature_verification.go +++ b/ante/evm/05_signature_verification.go @@ -49,7 +49,7 @@ func (esvd EthSigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, s return ctx, errorsmod.Wrapf(errortypes.ErrUnknownRequest, "invalid message type %T, expected %T", msg, (*evmtypes.MsgEthereumTx)(nil)) } - err := SignatureVerification(msgEthTx, signer, allowUnprotectedTxs) + err := SignatureVerification(msgEthTx, msgEthTx.AsTransaction(), signer, allowUnprotectedTxs) if err != nil { return ctx, err } @@ -64,10 +64,10 @@ func (esvd EthSigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, s // computed from the signature of the Ethereum transaction. func SignatureVerification( msg *evmtypes.MsgEthereumTx, + ethTx *ethtypes.Transaction, signer ethtypes.Signer, allowUnprotectedTxs bool, ) error { - ethTx := msg.AsTransaction() ethCfg := evmtypes.GetEthChainConfig() if !allowUnprotectedTxs { diff --git a/ante/evm/mono_decorator.go b/ante/evm/mono_decorator.go index 3971b071c..3277fbc76 100644 --- a/ante/evm/mono_decorator.go +++ b/ante/evm/mono_decorator.go @@ -1,9 +1,11 @@ package evm import ( + "math" "math/big" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/txpool" ethtypes "github.com/ethereum/go-ethereum/core/types" anteinterfaces "github.com/cosmos/evm/ante/interfaces" @@ -18,6 +20,12 @@ import ( txtypes "github.com/cosmos/cosmos-sdk/types/tx" ) +const AcceptedTxType = 0 | + 1<