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

Fixed mapping of SHA1 on algToJWKAlg #168

Closed
wants to merge 2 commits into from

Conversation

bobgrey
Copy link

@bobgrey bobgrey commented Mar 29, 2024

Issue identified using the FIDO Conformance Tools v1.7.19 ("tpm" attestation for SHA-1).

The error returned by crypto lib is:
JWK "alg" does not match the requested algorithm

It expects RS1, not RS256.

Reference crypto:

...
const kHashNames = {
  sha1: {
    [kHashContextNode]: 'sha1',
    [kHashContextWebCrypto]: 'SHA-1',
    [kHashContextJwkRsa]: 'RS1',
    [kHashContextJwkRsaPss]: 'PS1',
    [kHashContextJwkRsaOaep]: 'RSA-OAEP',
    [kHashContextJwkHmac]: 'HS1',
  },

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.86%. Comparing base (ba30d26) to head (337d6b7).

❗ Current head 337d6b7 differs from pull request most recent head e05ef27. Consider uploading reports for the commit e05ef27 to get more accurate results

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #168   +/-   ##
=======================================
  Coverage   92.86%   92.86%           
=======================================
  Files          16       16           
  Lines        6027     6027           
=======================================
  Hits         5597     5597           
  Misses        430      430           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@bobgrey bobgrey closed this Mar 29, 2024
@Hexagon
Copy link
Member

Hexagon commented Apr 5, 2024

@bobgrey Have not looked into the issue, but why did you close this? Is the fix still valid?

@bobgrey
Copy link
Author

bobgrey commented Apr 19, 2024

@Hexagon Yes, it's still valid. I accidentally closed it due to additional unnecessary commits in my fork that altered the PR.

@JamesCullum
Copy link
Member

Do you want to recreate it then?

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