From 4b661f7a540973133d67ec13c793aa8f816fd151 Mon Sep 17 00:00:00 2001 From: Philip Su Date: Mon, 29 Apr 2024 09:42:50 -0700 Subject: [PATCH 1/5] debug --- x/evm/ante/preprocess.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/evm/ante/preprocess.go b/x/evm/ante/preprocess.go index 15eb9aaa4a..678f837c59 100644 --- a/x/evm/ante/preprocess.go +++ b/x/evm/ante/preprocess.go @@ -358,7 +358,7 @@ func (p *EVMAddressDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bo } pk, err := btcec.ParsePubKey(acc.GetPubKey().Bytes(), btcec.S256()) if err != nil { - ctx.Logger().Error(fmt.Sprintf("failed to parse pubkey for %s", err)) + ctx.Logger().Error(fmt.Sprintf("failed to parse pubkey for %s", acc), "err", err) continue } evmAddr, err := pubkeyToEVMAddress(pk.SerializeUncompressed()) From 90118944187e6c91733df150152bbd478979a526 Mon Sep 17 00:00:00 2001 From: Philip Su Date: Mon, 29 Apr 2024 09:44:23 -0700 Subject: [PATCH 2/5] debug --- x/evm/ante/preprocess.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/evm/ante/preprocess.go b/x/evm/ante/preprocess.go index 678f837c59..a034183ee5 100644 --- a/x/evm/ante/preprocess.go +++ b/x/evm/ante/preprocess.go @@ -358,7 +358,7 @@ func (p *EVMAddressDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bo } pk, err := btcec.ParsePubKey(acc.GetPubKey().Bytes(), btcec.S256()) if err != nil { - ctx.Logger().Error(fmt.Sprintf("failed to parse pubkey for %s", acc), "err", err) + ctx.Logger().Error(fmt.Sprintf("failed to parse pubkey for %s", acc.GetPubKey()), "err", err) continue } evmAddr, err := pubkeyToEVMAddress(pk.SerializeUncompressed()) From b96fe5e1f1136379a412e11776c66ea76201b1d9 Mon Sep 17 00:00:00 2001 From: Philip Su Date: Mon, 29 Apr 2024 09:56:40 -0700 Subject: [PATCH 3/5] skip non-secp signatures fevm antehandler --- x/evm/ante/preprocess.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/evm/ante/preprocess.go b/x/evm/ante/preprocess.go index a034183ee5..18cb447b7c 100644 --- a/x/evm/ante/preprocess.go +++ b/x/evm/ante/preprocess.go @@ -358,7 +358,7 @@ func (p *EVMAddressDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bo } pk, err := btcec.ParsePubKey(acc.GetPubKey().Bytes(), btcec.S256()) if err != nil { - ctx.Logger().Error(fmt.Sprintf("failed to parse pubkey for %s", acc.GetPubKey()), "err", err) + ctx.Logger().Debug(fmt.Sprintf("failed to parse pubkey for %s, likely due to the fact that it isn't on secp256k1 curve", acc.GetPubKey()), "err", err) continue } evmAddr, err := pubkeyToEVMAddress(pk.SerializeUncompressed()) From 67f29e905938d62eed3b4429bd41a9f8fc777827 Mon Sep 17 00:00:00 2001 From: Philip Su Date: Mon, 29 Apr 2024 09:58:59 -0700 Subject: [PATCH 4/5] fix log --- x/evm/ante/preprocess.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/evm/ante/preprocess.go b/x/evm/ante/preprocess.go index 18cb447b7c..01d9d6f08c 100644 --- a/x/evm/ante/preprocess.go +++ b/x/evm/ante/preprocess.go @@ -358,7 +358,7 @@ func (p *EVMAddressDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bo } pk, err := btcec.ParsePubKey(acc.GetPubKey().Bytes(), btcec.S256()) if err != nil { - ctx.Logger().Debug(fmt.Sprintf("failed to parse pubkey for %s, likely due to the fact that it isn't on secp256k1 curve", acc.GetPubKey()), "err", err) + ctx.Logger().Debug(fmt.Sprintf("failed to parse pubkey for %s, likely due to the fact that it isn't on secp256k1 curve", "pubkey", acc.GetPubKey()), "err", err) continue } evmAddr, err := pubkeyToEVMAddress(pk.SerializeUncompressed()) From d71dd43dd4e24a1828a911c7e83609337b630803 Mon Sep 17 00:00:00 2001 From: Philip Su Date: Mon, 29 Apr 2024 10:24:28 -0700 Subject: [PATCH 5/5] fix log --- x/evm/ante/preprocess.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/evm/ante/preprocess.go b/x/evm/ante/preprocess.go index 01d9d6f08c..18cb447b7c 100644 --- a/x/evm/ante/preprocess.go +++ b/x/evm/ante/preprocess.go @@ -358,7 +358,7 @@ func (p *EVMAddressDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bo } pk, err := btcec.ParsePubKey(acc.GetPubKey().Bytes(), btcec.S256()) if err != nil { - ctx.Logger().Debug(fmt.Sprintf("failed to parse pubkey for %s, likely due to the fact that it isn't on secp256k1 curve", "pubkey", acc.GetPubKey()), "err", err) + ctx.Logger().Debug(fmt.Sprintf("failed to parse pubkey for %s, likely due to the fact that it isn't on secp256k1 curve", acc.GetPubKey()), "err", err) continue } evmAddr, err := pubkeyToEVMAddress(pk.SerializeUncompressed())