fix: make proof_types_supported
requirement optional
#84
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of change
Prior to this PR, the Wallet always expects the Credential Issuer to supply the
proof_types_supported
parameter to the Credential Configuration in its Credential Issuer Metadata. However,proof_types_supported
is an optional field hence why this fix was needed.In this update, the Wallet will choose its own preferred signing algorithm to sign the Proof if there is no
proof_types_supported
parameter present in the Credential Issuer Metadata. Only when there is aproof_types_supported
parameter present AND the Wallet can not match it to its own supported signing algorithm it will throw an error.If the Wallet can make a match, then it will use the matching signing algorithm to sign the Proof as usual.
Links to any relevant issues
https://openid.net/specs/openid-4-verifiable-credential-issuance-1_0-13.html#section-7.2-2.2.1
How the change has been tested
Added four unit tests:
Definition of Done checklist
Add an
x
to the boxes that are relevant to your changes.