@sphereon/ssi-sdk.siopv2-oid4vp-op-auth 0.32.1-feature.VDX.341.56 → 0.32.1-feature.new.develop.273
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent/DidAuthSiopOpAuthenticator.d.ts +5 -5
- package/dist/agent/DidAuthSiopOpAuthenticator.d.ts.map +1 -1
- package/dist/agent/DidAuthSiopOpAuthenticator.js +85 -64
- package/dist/agent/DidAuthSiopOpAuthenticator.js.map +1 -1
- package/dist/services/Siopv2MachineService.d.ts +4 -3
- package/dist/services/Siopv2MachineService.d.ts.map +1 -1
- package/dist/services/Siopv2MachineService.js +24 -16
- package/dist/services/Siopv2MachineService.js.map +1 -1
- package/dist/session/OID4VP.d.ts +4 -4
- package/dist/session/OID4VP.d.ts.map +1 -1
- package/dist/session/OID4VP.js.map +1 -1
- package/dist/session/OpSession.d.ts.map +1 -1
- package/dist/session/OpSession.js +3 -3
- package/dist/session/OpSession.js.map +1 -1
- package/dist/types/IDidAuthSiopOpAuthenticator.d.ts +12 -8
- package/dist/types/IDidAuthSiopOpAuthenticator.d.ts.map +1 -1
- package/dist/types/IDidAuthSiopOpAuthenticator.js.map +1 -1
- package/dist/types/machine/index.d.ts +1 -0
- package/dist/types/machine/index.d.ts.map +1 -1
- package/dist/types/machine/index.js.map +1 -1
- package/dist/types/siop-service/index.d.ts +20 -5
- package/dist/types/siop-service/index.d.ts.map +1 -1
- package/dist/types/siop-service/index.js.map +1 -1
- package/dist/utils/CredentialUtils.d.ts.map +1 -1
- package/dist/utils/CredentialUtils.js.map +1 -1
- package/dist/utils/dcql.d.ts +2 -2
- package/dist/utils/dcql.d.ts.map +1 -1
- package/dist/utils/dcql.js.map +1 -1
- package/package.json +22 -22
- package/src/agent/DidAuthSiopOpAuthenticator.ts +108 -90
- package/src/services/Siopv2MachineService.ts +20 -11
- package/src/session/OID4VP.ts +6 -6
- package/src/session/OpSession.ts +8 -6
- package/src/types/IDidAuthSiopOpAuthenticator.ts +21 -9
- package/src/types/machine/index.ts +1 -0
- package/src/types/siop-service/index.ts +23 -5
- package/src/utils/CredentialUtils.ts +2 -2
- package/src/utils/dcql.ts +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CredentialMapper,
|
|
1
|
+
import { CredentialMapper, HasherSync, ICredential, IVerifiableCredential, OriginalVerifiableCredential } from '@sphereon/ssi-types'
|
|
2
2
|
import { VerifiableCredential } from '@veramo/core'
|
|
3
3
|
import { UniqueDigitalCredential } from '@sphereon/ssi-sdk.credential-store'
|
|
4
4
|
|
|
@@ -58,7 +58,7 @@ export const getOriginalVerifiableCredential = (credential: InputCredential): Or
|
|
|
58
58
|
return getCredentialFromProofOrWrapped(credential)
|
|
59
59
|
}
|
|
60
60
|
|
|
61
|
-
const getCredentialFromProofOrWrapped = (cred: any, hasher?:
|
|
61
|
+
const getCredentialFromProofOrWrapped = (cred: any, hasher?: HasherSync): OriginalVerifiableCredential => {
|
|
62
62
|
if (typeof cred === 'object' && 'proof' in cred && 'jwt' in cred.proof && CredentialMapper.isSdJwtEncoded(cred.proof.jwt)) {
|
|
63
63
|
return cred.proof.jwt
|
|
64
64
|
}
|
package/src/utils/dcql.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { UniqueDigitalCredential } from '@sphereon/ssi-sdk.credential-store'
|
|
2
2
|
import { DcqlCredential, DcqlSdJwtVcCredential, DcqlW3cVcCredential } from 'dcql'
|
|
3
|
-
import { CredentialMapper,
|
|
3
|
+
import { CredentialMapper, HasherSync, OriginalVerifiableCredential } from '@sphereon/ssi-types'
|
|
4
4
|
import { isUniqueDigitalCredential } from './CredentialUtils'
|
|
5
5
|
|
|
6
|
-
export function convertToDcqlCredentials(credential: UniqueDigitalCredential | OriginalVerifiableCredential, hasher?:
|
|
6
|
+
export function convertToDcqlCredentials(credential: UniqueDigitalCredential | OriginalVerifiableCredential, hasher?: HasherSync): DcqlCredential {
|
|
7
7
|
let payload
|
|
8
8
|
if (isUniqueDigitalCredential(credential)) {
|
|
9
9
|
if (!credential.originalVerifiableCredential) {
|