Skip to content
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

chore(EIP55): optional EIP55 validation #206

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Cali93
Copy link

@Cali93 Cali93 commented Jul 15, 2024

Context

The SIWE message constructor throws if the address isn't EIP55 compliant, which brakes the SIWE integration for users that use wallets such as Zerion.

In addition to that, it's not a hard requirement based on the EIP-4361 spec

address REQUIRED. The Ethereum address performing the signing. Its value SHOULD be conformant to mixed-case checksum address encoding specified in ERC-55 where applicable.

This provides flexibility to developers to decide whatever or not they want explicit EIP55 validation.

The option defaults to true and is optional for backwards compatibility.

@chris13524
Copy link

I think it would be better if the option was removed, and instead it would validate like so:

  • If all lowercase, then pass
  • Otherwise must pass ERC-55

Reason being because different wallets will do it differently, and app developers shouldn't have to think about which one the wallet happens to use. Perhaps the flag could be used if the developer KNOWS that it needs to be ERC-55, but this is probably quite rare.

But does this require a major version bump since the behavior changes?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants