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

Use proper claim types in JSON-RPC replay tool #6936

Merged
merged 2 commits into from May 22, 2024
Merged

Conversation

emlautarom1
Copy link
Contributor

Changes

  • Use the proper Claim type when building a JWT token in Kute.

Types of changes

What types of changes does your code introduce?

  • Bugfix (a non-breaking change that fixes an issue)
  • New feature (a non-breaking change that adds functionality)
  • Breaking change (a change that causes existing functionality not to work as expected)
  • Optimization
  • Refactoring
  • Documentation update
  • Build-related changes
  • Other: Description

Testing

Requires testing

  • Yes
  • No

If yes, did you write tests?

  • Yes
  • No

Notes on testing

Tested against a running Reth (TODO: document which version is being used)

Documentation

Requires documentation update

  • Yes
  • No

Requires explanation in Release Notes

  • Yes
  • No

Copy link
Contributor

@marcindsobczak marcindsobczak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if int or uint, probably both are fine. We were testing with uint master...fix/jwt_iat_type

@emlautarom1
Copy link
Contributor Author

Not sure if int or uint, probably both are fine. We were testing with uint master...fix/jwt_iat_type

With ClaimValueTypes.UInteger64 Reth rejects the Authorization header since the iat claim is stored as a string. To debug this, run Kute and break before making the HTTP request, extract the Bearer token and paste it here: https://jwt.io/.

If you use ClaimValueTypes.Integer64 the iat claim is stored as an integer which Reth can deserialize.

@MarekM25 MarekM25 merged commit 485fd8a into master May 22, 2024
67 checks passed
@MarekM25 MarekM25 deleted the fix/jwt-claim-iat-type branch May 22, 2024 10:29
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.

None yet

4 participants