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

Dynamically register algorithms to lookup as they get loaded #607

Merged
merged 1 commit into from
Sep 8, 2024

Conversation

anakinj
Copy link
Member

@anakinj anakinj commented Jul 30, 2024

Description

Dynamically generate the list of supported algorithms as implementations are loaded. This will allow replacing and extending the algorithm from outside of this gem.

Initial use-case would be to move the rbnacl related algorithms to a gem with an explicit dependency to the 3rd party crypto libs. More of that work can be looked at over here

Checklist

Before the PR can be merged be sure the following are checked:

  • There are tests for the fix or feature added/changed
  • A description of the changes and a reference to the PR has been added to CHANGELOG.md. More details in the CONTRIBUTING.md

@anakinj anakinj marked this pull request as ready for review August 1, 2024 19:41
@anakinj anakinj changed the title Dynamically build algorithm to implementation hash Dynamically register algorithms available Aug 1, 2024
@anakinj anakinj changed the title Dynamically register algorithms available Dynamically register algorithms to lookup as they get loaded Aug 3, 2024
@anakinj anakinj marked this pull request as draft August 17, 2024 16:31
lib/jwt/jwa.rb Outdated Show resolved Hide resolved
lib/jwt/jwa/ecdsa.rb Outdated Show resolved Hide resolved
@anakinj anakinj marked this pull request as ready for review August 27, 2024 18:59
lib/jwt/jwa/ecdsa.rb Show resolved Hide resolved
lib/jwt/jwa/ecdsa.rb Show resolved Hide resolved
lib/jwt/jwa/ecdsa.rb Show resolved Hide resolved
lib/jwt/jwa/ps.rb Outdated Show resolved Hide resolved
lib/jwt/jwa/signing_algorithm.rb Show resolved Hide resolved
lib/jwt/jwa/signing_algorithm.rb Outdated Show resolved Hide resolved
lib/jwt/jwa/unsupported.rb Outdated Show resolved Hide resolved
spec/jwt/jwt_spec.rb Show resolved Hide resolved
Co-authored-by: Matteo Pierro <pierromatteo@gmail.com>
MatteoPierro

This comment was marked as resolved.

Copy link
Contributor

@MatteoPierro MatteoPierro left a comment

Choose a reason for hiding this comment

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

LGTM

@anakinj anakinj merged commit 3a4f611 into jwt:main Sep 8, 2024
34 checks 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