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

Add JWTAuthorizer Implementation. #36

Merged
merged 1 commit into from
Oct 22, 2024

Conversation

G8XSU
Copy link
Collaborator

@G8XSU G8XSU commented Oct 22, 2024

  • Add JWTAuthorizer Implementation.

@G8XSU G8XSU requested a review from jkczyz October 22, 2024 22:26
private final PublicKey publicKey;
private final JWTVerifier verifier;

public JwtAuthorizer(String pemFormatPublicKey) throws Exception {
Copy link

Choose a reason for hiding this comment

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

Consider linking to the RFC or other resource on what PEM format is.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

On some searching afaiu, there are multiple RFCs to specify that format but not a single one.
To avoid any further confusions, I gave a reference to OpenSSL docs and way to generate key pairs.

java/app/src/main/java/org/vss/auth/JwtAuthorizer.java Outdated Show resolved Hide resolved
java/app/src/main/java/org/vss/auth/JwtAuthorizer.java Outdated Show resolved Hide resolved
@G8XSU G8XSU requested a review from jkczyz October 22, 2024 23:12
Copy link

@jkczyz jkczyz left a comment

Choose a reason for hiding this comment

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

LGTM. Please squash.

java/app/src/main/java/org/vss/auth/JwtAuthorizer.java Outdated Show resolved Hide resolved
@G8XSU G8XSU force-pushed the java-jwt-authorizer branch from bd1a14c to 4d5cbd5 Compare October 22, 2024 23:24
@G8XSU
Copy link
Collaborator Author

G8XSU commented Oct 22, 2024

Addressed comments, squashed fixups.

@G8XSU G8XSU requested a review from jkczyz October 22, 2024 23:24
@G8XSU G8XSU merged commit e91d929 into lightningdevkit:main Oct 22, 2024
1 check passed
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