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

Secret JWK k values larger than HMAC-SHA minimums #909

Merged
merged 2 commits into from
Jan 28, 2024
Merged

Commits on Jan 28, 2024

  1. - Ensured Secret JWK 'k' byte arrays for HMAC-SHA algorithms can be l…

    …arger than the identified HS* algorithm. This is allowed per https://datatracker.ietf.org/doc/html/rfc7518#section-3.2: "A key of the same size as the hash output ... _or larger_ MUST be used with this algorithm"
    
    - Ensured that, when using the JwkBuilder, Secret JWK 'alg' values would automatically be set to 'HS256', 'HS384', or 'HS512' if the specified Java SecretKey algorithm name equals a JCA standard name (HmacSHA256, HmacSHA384, etc) or JCA standard HMAC-SHA OID.
    
    Fixes #901.
    lhazlewood committed Jan 28, 2024
    Configuration menu
    Copy the full SHA
    d9c030e View commit details
    Browse the repository at this point in the history
  2. - Ensured Secret JWK 'k' byte arrays for HMAC-SHA algorithms can be l…

    …arger than the identified HS* algorithm. This is allowed per https://datatracker.ietf.org/doc/html/rfc7518#section-3.2: "A key of the same size as the hash output ... _or larger_ MUST be used with this algorithm"
    
    - Ensured that, when using the JwkBuilder, Secret JWK 'alg' values would automatically be set to 'HS256', 'HS384', or 'HS512' if the specified Java SecretKey algorithm name equals a JCA standard name (HmacSHA256, HmacSHA384, etc) or JCA standard HMAC-SHA OID.
    - Updated CHANGELOG.md accordingly.
    lhazlewood committed Jan 28, 2024
    Configuration menu
    Copy the full SHA
    6ac5cc7 View commit details
    Browse the repository at this point in the history