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

feat: create kb jwt when present all #129

Merged

Conversation

lukasjhan
Copy link
Member

In present method, when presentationKeys is undefined, then present all disclosures. but in this case kbjwt is not created.
I fixed it to create kbjwt.

Signed-off-by: Lukas.J.Han <lukas.j.han@gmail.com>
@@ -146,17 +146,19 @@ export class SDJwtInstance<ExtendedPayload extends SdJwtPayload> {
kb?: KBOptions;
},
): Promise<SDJWTCompact> {
if (!presentationKeys) return encodedSDJwt;
Copy link
Member Author

Choose a reason for hiding this comment

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

Due to the early return, kbjwt is not created.

Copy link

codecov bot commented Mar 3, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.39%. Comparing base (5906908) to head (e7a9830).

Additional details and impacted files
@@           Coverage Diff           @@
##             next     #129   +/-   ##
=======================================
  Coverage   97.38%   97.39%           
=======================================
  Files          23       23           
  Lines        1876     1878    +2     
  Branches      272      272           
=======================================
+ Hits         1827     1829    +2     
  Misses         49       49           

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

@cre8
Copy link
Contributor

cre8 commented Mar 3, 2024

Good point, since the key binding has nothing to do with the selective disclosure, but with the holder binding.

@lukasjhan lukasjhan merged commit c65744c into openwallet-foundation-labs:next Mar 3, 2024
10 checks passed
cre8 pushed a commit to cre8/sd-jwt-js that referenced this pull request Mar 8, 2024
Signed-off-by: Lukas.J.Han <lukas.j.han@gmail.com>
Signed-off-by: Mirko Mollik <mirko.mollik@fit.fraunhofer.de>
cre8 pushed a commit that referenced this pull request Mar 8, 2024
Signed-off-by: Lukas.J.Han <lukas.j.han@gmail.com>
Signed-off-by: Mirko Mollik <mirko.mollik@fit.fraunhofer.de>
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

2 participants