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

Allow to build JWT from JSON string #820

Merged
merged 1 commit into from
Aug 20, 2024

Conversation

sberyozkin
Copy link
Contributor

Fixes #813.

This PR adds another method to the JWT builder API to simplify signing JSON strings.
For example, I've that often enough, in a test I have a JSON string ready (or it may be coming from DB) but we only have Jwt.claims(Map), Jwt.claims(JsonObject) and Jwt.claims(String jsonFileLocation) start options - so I have to convert JSON String to JsonObject myself, which is not great.

MikeEdgar
MikeEdgar previously approved these changes Aug 20, 2024
Copy link
Member

@MikeEdgar MikeEdgar left a comment

Choose a reason for hiding this comment

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

👍

@sberyozkin
Copy link
Contributor Author

Thanks @MikeEdgar, I'll do a minor follow up PR to fix those doc typos in all other similar comments :-)

@MikeEdgar
Copy link
Member

I'll do a minor follow up PR to fix those doc typos in all other similar comments :-)

Thanks @sberyozkin, no big deal.

@sberyozkin sberyozkin merged commit 5cde65d into smallrye:main Aug 20, 2024
7 checks passed
@sberyozkin sberyozkin deleted the claims_json branch August 20, 2024 15:50
@sberyozkin sberyozkin added this to the 4.6.0 milestone Aug 20, 2024
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.

Add JWT build claimsJson method which accepts String
2 participants