Replies: 2 comments 6 replies
-
Hello, are you using ethereumjs-tx? There is a field for the sender pub key and a function for the access: https://github.com/ethereumjs/ethereumjs-tx/blob/5c81b38/src/transaction.ts#L221 I can see that there is ecrecover just after: https://github.com/ethereumjs/ethereumjs-tx/blob/5c81b38/src/transaction.ts#L244 What do you mean by public address ? because I can see it's about encryption key, I am confused. |
Beta Was this translation helpful? Give feedback.
-
Hi, sorry, I meant deriving the sender pub key from the r, s and v values and original transaction. Yes, I am trying to use something similar that you have highlighted in your comments, but I'm unable to derive the right public key. I'm not sure if the recovery is failing because of the setting of V to 37/38, so I was wondering if this was something that anyone has tried before with a working example. |
Beta Was this translation helpful? Give feedback.
-
Hi, I understand that when signing a raw private transaction, we have to sign the transaction first before setting V to 37/38. Is it possible to derive the public key based off the signature (R, S, V) and rlp encoded raw transaction, i.e. via some sort of
ecrecover
method? If so, are there any examples on doing that?Thank you.
Beta Was this translation helpful? Give feedback.
All reactions