-
Notifications
You must be signed in to change notification settings - Fork 16
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
Feature/sphereon 1183 sd jwt confomance #174
Merged
sanderPostma
merged 4 commits into
develop
from
feature/SPHEREON-1183_sd-jwt-confomance
Nov 11, 2024
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
ac0d6a1
chore: SPHEREON-1183 support disclosure of entire sd-jwt groups which…
sanderPostma 98da6ec
chore: SPHEREON-1183 version bump
sanderPostma 3dff76f
chore: SPHEREON-1183 cleanup
sanderPostma 87da1d8
Merge remote-tracking branch 'origin/develop' into feature/SPHEREON-1…
sanderPostma File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{ | ||
"presentation_definition": { | ||
"id": "pid-sdjwt", | ||
"name": "Identity verification SD-JWT", | ||
"purpose": "We need to verify your identity information.", | ||
"format": { | ||
"vc+sd-jwt": { | ||
"sd-jwt_alg_values": [ | ||
"ES256", | ||
"ES384", | ||
"ES512", | ||
"EdDSA" | ||
] | ||
} | ||
}, | ||
"input_descriptors": [ | ||
{ | ||
"id": "6aa0ac61-6535-46c2-924d-65fccfe65f4f", | ||
"constraints": { | ||
"limit_disclosure": "required", | ||
"fields": [ | ||
{ | ||
"path": [ | ||
"$.place_of_birth" | ||
] | ||
}, | ||
{ | ||
"path": [ | ||
"$.given_name" | ||
] | ||
}, | ||
{ | ||
"path": [ | ||
"$.family_name" | ||
] | ||
}, | ||
{ | ||
"path": [ | ||
"$.address" | ||
] | ||
}, | ||
{ | ||
"path": [ | ||
"$.age_equal_or_over.18" | ||
] | ||
} | ||
] | ||
}, | ||
"name": "Identity", | ||
"purpose": "We need your identity information." | ||
} | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
eyJ4NWMiOlsiTUlJQ2REQ0NBaHVnQXdJQkFnSUJBakFLQmdncWhrak9QUVFEQWpDQmlERUxNQWtHQTFVRUJoTUNSRVV4RHpBTkJnTlZCQWNNQmtKbGNteHBiakVkTUJzR0ExVUVDZ3dVUW5WdVpHVnpaSEoxWTJ0bGNtVnBJRWR0WWtneEVUQVBCZ05WQkFzTUNGUWdRMU1nU1VSRk1UWXdOQVlEVlFRRERDMVRVRkpKVGtRZ1JuVnVhMlVnUlZWRVNTQlhZV3hzWlhRZ1VISnZkRzkwZVhCbElFbHpjM1ZwYm1jZ1EwRXdIaGNOTWpRd05UTXhNRGd4TXpFM1doY05NalV3TnpBMU1EZ3hNekUzV2pCc01Rc3dDUVlEVlFRR0V3SkVSVEVkTUJzR0ExVUVDZ3dVUW5WdVpHVnpaSEoxWTJ0bGNtVnBJRWR0WWtneENqQUlCZ05WQkFzTUFVa3hNakF3QmdOVkJBTU1LVk5RVWtsT1JDQkdkVzVyWlNCRlZ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FbEtKc2hWMlZycnZ3Zmgtd0RwandnIiwiYWdlX2luX3llYXJzIiw0MF0~WyJsTV9ULWxqQTRSV0NkUHozVTFyMEhBIiwiYmlydGhfZmFtaWx5X25hbWUiLCJHQUJMRVIiXQ~WyJFck93ZUlzVV9FU3NMREdxZmlYOElnIiwibmF0aW9uYWxpdGllcyIsWyJERSJdXQ~WyJXLS04bjRTT094dWVEVU9GalUyMVJ3IiwiMTIiLHRydWVd~WyJVaXdLS1MxSlNGdGl6NEF3QTBqenhnIiwiMTQiLHRydWVd~WyJha0x3aGd1S2lSaG5nQVdmZ01XOEhRIiwiMTYiLHRydWVd~WyJHYXVBaUc2ZW1CT0pJX1B5WE1YdDVBIiwiMTgiLHRydWVd~WyJiMGM5NHphbGMzZ0FwQkFzUllGX0ZnIiwiMjEiLHRydWVd~WyJwd25JYTdnb2xacjA5c3I5OGpteUdnIiwiNjUiLGZhbHNlXQ~WyJvdHpyeU1yYXc2NUY0SjkyVU1zWXF3IiwibG9jYWxpdHkiLCJCRVJMSU4iXQ~WyJ2WWt2RzBqVEpzb2QwVGJieHQyT2hRIiwibG9jYWxpdHkiLCJLw5ZMTiJd~WyJ2ZWJsRU1URmJVTUx3V0FqUzYza1pnIiwiY291bnRyeSIsIkRFIl0~WyJqZTJHMnU4RFlyN1UxSEh3YWFqa3ZRIiwicG9zdGFsX2NvZGUiLCI1MTE0NyJd~WyJVM0hKdEZHNm02NFBqYmg1ZTgxaVFRIiwic3RyZWV0X2FkZHJlc3MiLCJIRUlERVNUUkFTU0UgMTciXQ~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export type ClaimValue = string | number | boolean | { [key: string]: ClaimValue } | Array<ClaimValue>; |
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Curious, why do we need to handle nested objects? If a PD includes
$.address
and address is an object, then havingaddress: true
in the disclosure frame should be enough right?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@TimoGlastra
This is for the situation where a sd-jwt (not created by us) does not have a disclosure frame element on a group, but on the individual fields within a group. ie.
When the pd asks to disclose \$.electronicPassport.dataGroup1 instead of \$.electronicPassport.dataGroup1.* it should still disclose all disclosable fields & groups within the group.
(When you control PD or credential you can make it work by modifying either on or both, but we ran into an interoperability tests where you we do not.)
Also with the address example in the Funke PID, the @sd-jwt library (0.7.2) does not disclose anything when specifying address: true
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm okay, i think it's probably something that should be solved in @sd-jwt library then? As saying
address: true
is enough to know the whole address object and sub-disclosures should be resolved.It feels like a hack to me to solve it in this was
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Forking the @sd-jwt library which is not ours is also something we would like to avoid. When I have more time I can play around with the tests in the @sd-jwt library, but have plenty of other stuff on my plate atm.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For clarity, for this setup address: true does work:
But then you always disclose the whole address and just field passportNumberIdentifier won't work anymore.