Skip to content

Commit

Permalink
Merge branch 'feature/SPRIND-137' of github.com:Sphereon-Opensource/O…
Browse files Browse the repository at this point in the history
…ID4VC into feature/SPRIND-137
  • Loading branch information
Zoe Maas committed Dec 17, 2024
2 parents 1020b5b + 9b4bb1f commit 34ec540
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 20 deletions.
3 changes: 1 addition & 2 deletions packages/did-auth-siop-adapter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@
},
"devDependencies": {
"@types/jest": "^29.5.12",
"@types/jwt-decode": "^3.1.0",
"typescript": "5.4.5"
"typescript": "5.4.5"
},
"engines": {
"node": ">=18"
Expand Down
8 changes: 6 additions & 2 deletions packages/siop-oid4vp/lib/rp/RP.ts
Original file line number Diff line number Diff line change
Expand Up @@ -424,8 +424,12 @@ export class RP {
state,
nonce,
verification: mergeVerificationOpts(this._verifyResponseOptions, opts),
presentationDefinitions: opts?.presentationDefinitions ?? this._verifyResponseOptions.presentationDefinitions,
dcqlQuery: opts?.dcqlQuery ?? this._verifyResponseOptions.dcqlQuery,
...(opts?.presentationDefinitions && !opts?.dcqlQuery && {
presentationDefinitions: this._verifyResponseOptions.presentationDefinitions
}),
...(opts?.dcqlQuery && {
dcqlQuery: this._verifyResponseOptions.dcqlQuery
})
}
}

Expand Down
6 changes: 6 additions & 0 deletions packages/siop-oid4vp/lib/rp/RPBuilder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -241,10 +241,16 @@ export class RPBuilder {
},
true,
)
this._authorizationRequestPayload.presentation_definition = undefined
this._requestObjectPayload.presentation_definition = undefined
return this
}

withPresentationDefinition(definitionOpts: { definition: IPresentationDefinition; definitionUri?: string }, targets?: PropertyTargets): RPBuilder {
if(this._authorizationRequestPayload.dcql_query) {
return this
}

const { definition, definitionUri } = definitionOpts

if (this.getSupportedRequestVersion() < SupportedVersion.SIOPv2_D11) {
Expand Down
3 changes: 1 addition & 2 deletions packages/siop-oid4vp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@
"@transmute/ed25519-signature-2018": "^0.7.0-unstable.82",
"@types/debug": "^4.1.12",
"@types/jest": "^29.5.11",
"@types/jwt-decode": "^3.1.0",
"@types/language-tags": "^1.0.4",
"@types/language-tags": "^1.0.4",
"@types/qs": "^6.9.11",
"@typescript-eslint/eslint-plugin": "^5.52.0",
"@typescript-eslint/parser": "^5.52.0",
Expand Down
14 changes: 0 additions & 14 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 34ec540

Please sign in to comment.