Skip to content

Update test vectors for ERC-4361 erratum#1

Open
jwahdatehagh wants to merge 1 commit into
masterfrom
erc-4361-erratum
Open

Update test vectors for ERC-4361 erratum#1
jwahdatehagh wants to merge 1 commit into
masterfrom
erc-4361-erratum

Conversation

@jwahdatehagh
Copy link
Copy Markdown
Member

@jwahdatehagh jwahdatehagh commented Apr 24, 2026

Summary

Updates the canonical SIWE test vectors for the surviving behavior changes in signinwithethereum/ERCs#1.

Changes:

  • Reclassifies two userinfo@ domain vectors from positive to negative, matching the ERC-4361 erratum's exclusion of the RFC 3986 userinfo subcomponent from SIWE domain values.
  • Updates statement character vectors for the printable-ASCII widening: printable ASCII punctuation is now valid for statement, while LF and other controls remain excluded.

Vectors moved from vectors/parsing/parsing_positive.json to vectors/parsing/parsing_negative.json:

  • domain is RFC 3986 authority with userinfo (test@127.0.0.1)
  • domain is RFC 3986 authority with userinfo and port (test@127.0.0.1:8080)

Statement vector changes:

  • vectors/grammar/valid_chars.json now treats full printable ASCII (0x20 through 0x7E) as valid for statement.
  • Obsolete negative statement punctuation cases were removed from vectors/grammar/invalid_chars.json.

Coordination

This PR is held open pending resolution of the ERC-4361 erratum. Downstream SIWE libraries should consume this vector update when they implement the surviving parser changes: reject userinfo@ in domain and accept the widened statement character set.

Evidence

See the erratum evidence repository:

Reclassify userinfo@ domain messages as negative and update statement character vectors for the printable-ASCII widening.
@jwahdatehagh jwahdatehagh changed the title Reclassify userinfo@ domain vectors as negative (ERC-4361 erratum) Update test vectors for ERC-4361 erratum Apr 30, 2026
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.

1 participant