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: relying-party creates SI token for VP query #3659

Conversation

paullatzelsperger
Copy link
Member

@paullatzelsperger paullatzelsperger commented Nov 25, 2023

What this PR changes/adds

This PR extends the IdentityAndTrustService and generates another SI token on the relying-party side
which is then used to execute the VP query against the counter-party's CredentialService (= presentation endpoint).

Why it does that

Complete the circle of the presentation flow

Further notes

  • Be aware that currently we need to parse the access_token to get the scope string. This is a workaround, until we can extract the scope from the verification context. This behaviour will change in subsequent developments and is only there for the immediate future. The related code has been marked accordingly.
  • the access_token constant was renamed to PRESENTATION_ACCESS_TOKEN_CLAIM and is now used everywhere
  • this PR also adds the temporary AudienceResolver object, which maps a DSP url to an audience, which can be used to resolve key material

Linked Issue(s)

Closes # <-- insert Issue number if one exists

Please be sure to take a look at the contributing guidelines and our etiquette for pull requests.

@paullatzelsperger paullatzelsperger added this to the Milestone 13 milestone Nov 25, 2023
@paullatzelsperger paullatzelsperger added dcp breaking-change Will require manual intervention for version update labels Nov 25, 2023
@paullatzelsperger paullatzelsperger added the enhancement New feature or request label Nov 25, 2023
@codecov-commenter
Copy link

codecov-commenter commented Nov 25, 2023

Codecov Report

Attention: 6 lines in your changes are missing coverage. Please review.

Comparison is base (1cf48c2) 71.79% compared to head (51023de) 71.81%.

Files Patch % Lines
...edc/iam/identitytrust/IdentityAndTrustService.java 87.09% 3 Missing and 1 partial ⚠️
...tytrust/validation/SelfIssuedIdTokenValidator.java 0.00% 1 Missing and 1 partial ⚠️

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

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3659      +/-   ##
==========================================
+ Coverage   71.79%   71.81%   +0.01%     
==========================================
  Files         917      917              
  Lines       18370    18395      +25     
  Branches     1042     1044       +2     
==========================================
+ Hits        13189    13210      +21     
- Misses       4724     4726       +2     
- Partials      457      459       +2     

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

Copy link
Contributor

@wolf4ood wolf4ood left a comment

Choose a reason for hiding this comment

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

LGTM

@paullatzelsperger paullatzelsperger merged commit a3ef0f1 into eclipse-edc:main Nov 26, 2023
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking-change Will require manual intervention for version update dcp enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants