-
Notifications
You must be signed in to change notification settings - Fork 276
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] Signers apply EIP-155 even for EIP-{1559,2718} transactions #144
Comments
I can send a PR for a direct fix if useful, but this comment made me think that there are more changes coming that might preempt a direct fix. |
the "correct" fix here is to change the |
🤔 I'm not 100% sure, but from looking at the code, if Perhaps we should avoid applying EIP-155 in the first place. For example, the |
I'm saying that the txn should ensure the signature is in the format that it accepts at the time it is joined with the siganture.
That's a bug, thanks. fixed in 497 |
Component
signers
What version of Alloy are you on?
No response
Operating System
None
Describe the bug
Signers::sign_transaction and SignerSync::sign_transaction_sync should not apply EIP-155 when the signer's chain_id is None. Indeed, this is the expected behavior according to Signer's docstring, but EIP-155 is applied anyway if the chain ID is found on the transaction instead.
Ref:
alloy/crates/signer/src/signer.rs
Line 87 in 2ee7b8b
EIP-{1559,2718} always embed a chain ID value but they're not compatible with EIP-155. Thus, they get an EIP-155 signature when they shouldn't.
The text was updated successfully, but these errors were encountered: