Skip to content

Commit

Permalink
Fix: Don't throw error if not a did:key identifier in kid header, ins…
Browse files Browse the repository at this point in the history
…tead at later point, this will be extended to resolve JWKs URI

Signed-off-by: George J Padayatti <[email protected]>
  • Loading branch information
georgepadayatti committed Oct 22, 2024
1 parent b301036 commit 9bb1f14
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sdjwt/pex.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,11 +296,11 @@ def verify_vp_token(vp_token: str):

key = None
if kid:
# FIXME: We only support signature verification using did:key
# This has to be extended for JWK by resolving JWKs URI
if kid.startswith("did:key"):
method_specific_identifier = kid.split("#")[1]
key = DIDKey.method_specific_identifier_to_jwk(method_specific_identifier)
else:
raise UnSupportedSignatureAlgorithmError("Failed to parse the key ID")
elif jwk:
key = jwk.JWK(**jwk_dict)
else:
Expand Down

0 comments on commit 9bb1f14

Please sign in to comment.