@sphereon/ssi-sdk.credential-store 0.32.1-next.54 → 0.33.1-feature.vcdm2.4
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/CredentialStore.js +118 -155
- package/dist/agent/CredentialStore.js.map +1 -1
- package/dist/index.js +8 -32
- package/dist/index.js.map +1 -1
- package/dist/ssi-sdk.credential-store.d.ts +2 -2
- package/dist/tsdoc-metadata.json +1 -1
- package/dist/types/ICredentialStore.d.ts +2 -2
- package/dist/types/ICredentialStore.d.ts.map +1 -1
- package/dist/types/ICredentialStore.js +3 -6
- package/dist/types/ICredentialStore.js.map +1 -1
- package/dist/types/claims.js +1 -2
- package/dist/utils/filters.js +11 -17
- package/dist/utils/filters.js.map +1 -1
- package/package.json +7 -7
- package/plugin.schema.json +28 -13
- package/src/types/ICredentialStore.ts +2 -2
|
@@ -1,21 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.CredentialStore = exports.credentialStoreMethods = void 0;
|
|
13
|
-
const ssi_sdk_data_store_1 = require("@sphereon/ssi-sdk.data-store");
|
|
14
|
-
const ssi_sdk_core_1 = require("@sphereon/ssi-sdk.core");
|
|
15
|
-
const index_1 = require("../index");
|
|
16
|
-
const filters_1 = require("../utils/filters");
|
|
1
|
+
import { DocumentType, parseRawDocument, } from '@sphereon/ssi-sdk.data-store';
|
|
2
|
+
import { shaHasher as defaultHasher } from '@sphereon/ssi-sdk.core';
|
|
3
|
+
import { schema, logger } from '../index';
|
|
4
|
+
import { credentialIdOrHashFilter } from '../utils/filters';
|
|
17
5
|
// Exposing the methods here for any REST implementation
|
|
18
|
-
|
|
6
|
+
export const credentialStoreMethods = [
|
|
19
7
|
'crsAddCredential',
|
|
20
8
|
'crsUpdateCredentialState',
|
|
21
9
|
'crsGetCredential',
|
|
@@ -30,161 +18,140 @@ exports.credentialStoreMethods = [
|
|
|
30
18
|
/**
|
|
31
19
|
* {@inheritDoc ICRManager}
|
|
32
20
|
*/
|
|
33
|
-
class CredentialStore {
|
|
21
|
+
export class CredentialStore {
|
|
22
|
+
schema = schema.ICredentialStore;
|
|
23
|
+
methods = {
|
|
24
|
+
crsAddCredential: this.crsAddCredential.bind(this),
|
|
25
|
+
crsUpdateCredentialState: this.crsUpdateCredentialState.bind(this),
|
|
26
|
+
crsGetCredential: this.crsGetCredential.bind(this),
|
|
27
|
+
crsGetCredentials: this.crsGetCredentials.bind(this),
|
|
28
|
+
crsGetUniqueCredentialByIdOrHash: this.crsGetUniqueCredentialByIdOrHash.bind(this),
|
|
29
|
+
crsGetUniqueCredentials: this.crsGetUniqueCredentials.bind(this),
|
|
30
|
+
crsDeleteCredential: this.crsDeleteCredential.bind(this),
|
|
31
|
+
crsDeleteCredentials: this.crsDeleteCredentials.bind(this),
|
|
32
|
+
crsGetCredentialsByClaims: this.crsGetCredentialsByClaims.bind(this),
|
|
33
|
+
crsGetCredentialsByClaimsCount: this.crsGetCredentialsByClaimsCount.bind(this),
|
|
34
|
+
};
|
|
35
|
+
store;
|
|
34
36
|
constructor(options) {
|
|
35
|
-
this.schema = index_1.schema.ICredentialStore;
|
|
36
|
-
this.methods = {
|
|
37
|
-
crsAddCredential: this.crsAddCredential.bind(this),
|
|
38
|
-
crsUpdateCredentialState: this.crsUpdateCredentialState.bind(this),
|
|
39
|
-
crsGetCredential: this.crsGetCredential.bind(this),
|
|
40
|
-
crsGetCredentials: this.crsGetCredentials.bind(this),
|
|
41
|
-
crsGetUniqueCredentialByIdOrHash: this.crsGetUniqueCredentialByIdOrHash.bind(this),
|
|
42
|
-
crsGetUniqueCredentials: this.crsGetUniqueCredentials.bind(this),
|
|
43
|
-
crsDeleteCredential: this.crsDeleteCredential.bind(this),
|
|
44
|
-
crsDeleteCredentials: this.crsDeleteCredentials.bind(this),
|
|
45
|
-
crsGetCredentialsByClaims: this.crsGetCredentialsByClaims.bind(this),
|
|
46
|
-
crsGetCredentialsByClaimsCount: this.crsGetCredentialsByClaimsCount.bind(this),
|
|
47
|
-
};
|
|
48
37
|
this.store = options.store;
|
|
49
38
|
}
|
|
50
39
|
/** {@inheritDoc ICredentialStore.crsAddCredential} */
|
|
51
|
-
crsAddCredential(args) {
|
|
52
|
-
return
|
|
53
|
-
var _a, _b;
|
|
54
|
-
return yield this.store.addCredential(Object.assign(Object.assign({}, args.credential), { opts: Object.assign(Object.assign({}, args.opts), { hasher: (_b = (_a = args.opts) === null || _a === void 0 ? void 0 : _a.hasher) !== null && _b !== void 0 ? _b : ssi_sdk_core_1.shaHasher }) }));
|
|
55
|
-
});
|
|
40
|
+
async crsAddCredential(args) {
|
|
41
|
+
return await this.store.addCredential({ ...args.credential, opts: { ...args.opts, hasher: args.opts?.hasher ?? defaultHasher } });
|
|
56
42
|
}
|
|
57
43
|
/** {@inheritDoc ICredentialStore.crsUpdateCredentialState} */
|
|
58
|
-
crsUpdateCredentialState(args) {
|
|
59
|
-
return
|
|
60
|
-
return yield this.store.updateCredentialState(args);
|
|
61
|
-
});
|
|
44
|
+
async crsUpdateCredentialState(args) {
|
|
45
|
+
return await this.store.updateCredentialState(args);
|
|
62
46
|
}
|
|
63
47
|
/** {@inheritDoc ICredentialStore.crsGetCredential} */
|
|
64
|
-
crsGetCredential(args) {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
return this.store.getCredential({ id });
|
|
68
|
-
});
|
|
48
|
+
async crsGetCredential(args) {
|
|
49
|
+
const { id } = args;
|
|
50
|
+
return this.store.getCredential({ id });
|
|
69
51
|
}
|
|
70
52
|
/** {@inheritDoc ICredentialStore.crsGetCredentials} */
|
|
71
|
-
crsGetCredentials(args) {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
return credentials.data;
|
|
76
|
-
});
|
|
53
|
+
async crsGetCredentials(args) {
|
|
54
|
+
const { filter } = args;
|
|
55
|
+
const credentials = await this.store.getCredentials({ filter });
|
|
56
|
+
return credentials.data;
|
|
77
57
|
}
|
|
78
58
|
/** {@inheritDoc ICredentialStore.crsGetUniqueCredentialByIdOrHash} */
|
|
79
|
-
crsGetUniqueCredentialByIdOrHash(args) {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
return this.toUniqueCredentials(credentials)[0];
|
|
89
|
-
});
|
|
59
|
+
async crsGetUniqueCredentialByIdOrHash(args) {
|
|
60
|
+
const credentials = await this.crsGetCredentials({ filter: credentialIdOrHashFilter(args.credentialRole, args.idOrHash) });
|
|
61
|
+
if (credentials.length === 0) {
|
|
62
|
+
return undefined;
|
|
63
|
+
}
|
|
64
|
+
else if (credentials.length > 1) {
|
|
65
|
+
logger.warning('Duplicate credentials detected in crsGetUniqueCredentialByIdOrHash', args);
|
|
66
|
+
}
|
|
67
|
+
return this.toUniqueCredentials(credentials)[0];
|
|
90
68
|
}
|
|
91
69
|
/** {@inheritDoc ICredentialStore.crsGetUniqueCredentials} */
|
|
92
|
-
crsGetUniqueCredentials(args) {
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
return this.toUniqueCredentials(credentials);
|
|
96
|
-
});
|
|
70
|
+
async crsGetUniqueCredentials(args) {
|
|
71
|
+
const credentials = await this.crsGetCredentials(args);
|
|
72
|
+
return this.toUniqueCredentials(credentials);
|
|
97
73
|
}
|
|
98
74
|
/** {@inheritDoc ICredentialStore.crsDeleteCredential} */
|
|
99
|
-
crsDeleteCredential(args) {
|
|
100
|
-
return
|
|
101
|
-
return this.store.removeCredential(args);
|
|
102
|
-
});
|
|
75
|
+
async crsDeleteCredential(args) {
|
|
76
|
+
return this.store.removeCredential(args);
|
|
103
77
|
}
|
|
104
78
|
/** {@inheritDoc ICredentialStore.crsDeleteCredentials} */
|
|
105
|
-
crsDeleteCredentials(args) {
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
count++;
|
|
113
|
-
}
|
|
79
|
+
async crsDeleteCredentials(args) {
|
|
80
|
+
const credentials = await this.crsGetCredentials(args);
|
|
81
|
+
let count = 0;
|
|
82
|
+
for (const credential of credentials) {
|
|
83
|
+
const result = await this.store.removeCredential({ id: credential.id });
|
|
84
|
+
if (result) {
|
|
85
|
+
count++;
|
|
114
86
|
}
|
|
115
|
-
|
|
116
|
-
|
|
87
|
+
}
|
|
88
|
+
return count;
|
|
117
89
|
}
|
|
118
90
|
/**
|
|
119
91
|
* Returns a list of UniqueDigitalCredentials that match the given filter based on the claims they contain.
|
|
120
92
|
* @param args
|
|
121
93
|
*/
|
|
122
|
-
crsGetCredentialsByClaims(args) {
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
94
|
+
async crsGetCredentialsByClaims(args) {
|
|
95
|
+
const digitalCredentials = await this.crsGetUniqueCredentials({
|
|
96
|
+
filter: [
|
|
97
|
+
// TODO SDK-25 Implement param for documentType & support VP filtering below
|
|
98
|
+
{
|
|
99
|
+
documentType: DocumentType.VC,
|
|
100
|
+
credentialRole: args.credentialRole,
|
|
101
|
+
tenantId: args.tenantId,
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
documentType: DocumentType.C,
|
|
105
|
+
credentialRole: args.credentialRole,
|
|
106
|
+
tenantId: args.tenantId,
|
|
107
|
+
},
|
|
108
|
+
],
|
|
109
|
+
});
|
|
110
|
+
// This a copy of how Veramo did this. TODO Use GraphQL in the future?
|
|
111
|
+
return digitalCredentials.filter((uniqueVC) => {
|
|
112
|
+
if (!uniqueVC.uniformVerifiableCredential) {
|
|
113
|
+
return false;
|
|
114
|
+
}
|
|
115
|
+
const credential = uniqueVC.uniformVerifiableCredential;
|
|
116
|
+
return (args.filter.where?.every((whereClause) => {
|
|
117
|
+
const value = this.getValueFromCredential(credential, whereClause.column);
|
|
118
|
+
if (value === undefined) {
|
|
119
|
+
return whereClause.op === 'IsNull';
|
|
144
120
|
}
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
case 'IsNull':
|
|
170
|
-
return value === null || value === undefined;
|
|
171
|
-
case 'Equal':
|
|
172
|
-
default:
|
|
173
|
-
return value === ((_j = whereClause.value) === null || _j === void 0 ? void 0 : _j[0]);
|
|
174
|
-
}
|
|
175
|
-
})) !== null && _b !== void 0 ? _b : true);
|
|
176
|
-
});
|
|
121
|
+
switch (whereClause.op) {
|
|
122
|
+
case 'In':
|
|
123
|
+
return whereClause.value?.includes(value);
|
|
124
|
+
case 'Like':
|
|
125
|
+
return typeof value === 'string' && value.includes(whereClause.value?.[0] || '');
|
|
126
|
+
case 'Between':
|
|
127
|
+
return value >= (whereClause.value?.[0] || '') && value <= (whereClause.value?.[1] || '');
|
|
128
|
+
case 'LessThan':
|
|
129
|
+
return value < (whereClause.value?.[0] || '');
|
|
130
|
+
case 'LessThanOrEqual':
|
|
131
|
+
return value <= (whereClause.value?.[0] || '');
|
|
132
|
+
case 'MoreThan':
|
|
133
|
+
return value > (whereClause.value?.[0] || '');
|
|
134
|
+
case 'MoreThanOrEqual':
|
|
135
|
+
return value >= (whereClause.value?.[0] || '');
|
|
136
|
+
case 'Any':
|
|
137
|
+
return Array.isArray(value) && value.some((v) => whereClause.value?.includes(v));
|
|
138
|
+
case 'IsNull':
|
|
139
|
+
return value === null || value === undefined;
|
|
140
|
+
case 'Equal':
|
|
141
|
+
default:
|
|
142
|
+
return value === whereClause.value?.[0];
|
|
143
|
+
}
|
|
144
|
+
}) ?? true);
|
|
177
145
|
});
|
|
178
146
|
}
|
|
179
147
|
getValueFromCredential(credential, column) {
|
|
180
|
-
var _a, _b, _c, _d;
|
|
181
148
|
switch (column) {
|
|
182
149
|
case 'context':
|
|
183
150
|
return credential['@context'];
|
|
184
151
|
case 'credentialType':
|
|
185
152
|
return credential.type;
|
|
186
153
|
case 'type':
|
|
187
|
-
return Array.isArray(credential.credentialSubject) ?
|
|
154
|
+
return Array.isArray(credential.credentialSubject) ? credential.credentialSubject[0]?.type : credential.credentialSubject?.type;
|
|
188
155
|
case 'value':
|
|
189
156
|
return JSON.stringify(credential.credentialSubject);
|
|
190
157
|
case 'isObj':
|
|
@@ -194,7 +161,7 @@ class CredentialStore {
|
|
|
194
161
|
case 'issuer':
|
|
195
162
|
return typeof credential.issuer === 'string' ? credential.issuer : credential.issuer.id;
|
|
196
163
|
case 'subject':
|
|
197
|
-
return Array.isArray(credential.credentialSubject) ?
|
|
164
|
+
return Array.isArray(credential.credentialSubject) ? credential.credentialSubject[0]?.id : credential.credentialSubject?.id;
|
|
198
165
|
case 'expirationDate':
|
|
199
166
|
return credential.expirationDate;
|
|
200
167
|
case 'issuanceDate':
|
|
@@ -207,40 +174,37 @@ class CredentialStore {
|
|
|
207
174
|
* Returns a count of UniqueDigitalCredentials that match the given filter based on the claims they contain.
|
|
208
175
|
* @param args
|
|
209
176
|
*/
|
|
210
|
-
crsGetCredentialsByClaimsCount(args) {
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
return credentialsByClaims.length; // FIXME ?
|
|
214
|
-
});
|
|
177
|
+
async crsGetCredentialsByClaimsCount(args) {
|
|
178
|
+
const credentialsByClaims = await this.crsGetCredentialsByClaims(args);
|
|
179
|
+
return credentialsByClaims.length; // FIXME ?
|
|
215
180
|
}
|
|
216
181
|
secureParse(original) {
|
|
217
|
-
return
|
|
182
|
+
return parseRawDocument(original);
|
|
218
183
|
}
|
|
219
184
|
toUniqueCredentials(credentials) {
|
|
220
185
|
return Object.values(credentials.reduce((accumulator, credential) => {
|
|
221
|
-
var _a, _b, _c, _d;
|
|
222
186
|
const uniqueCredential = {
|
|
223
187
|
hash: credential.hash,
|
|
224
188
|
digitalCredential: credential,
|
|
225
189
|
};
|
|
226
190
|
switch (credential.documentType) {
|
|
227
|
-
case
|
|
191
|
+
case DocumentType.VC:
|
|
228
192
|
uniqueCredential.originalVerifiableCredential = this.secureParse(credential.rawDocument);
|
|
229
193
|
uniqueCredential.uniformVerifiableCredential = this.secureParse(credential.uniformDocument);
|
|
230
|
-
uniqueCredential.id =
|
|
194
|
+
uniqueCredential.id = uniqueCredential.uniformVerifiableCredential?.id;
|
|
231
195
|
break;
|
|
232
|
-
case
|
|
196
|
+
case DocumentType.VP:
|
|
233
197
|
uniqueCredential.originalVerifiablePresentation = this.secureParse(credential.rawDocument);
|
|
234
198
|
uniqueCredential.uniformVerifiablePresentation = this.secureParse(credential.uniformDocument);
|
|
235
|
-
uniqueCredential.id =
|
|
199
|
+
uniqueCredential.id = uniqueCredential.uniformVerifiablePresentation?.id;
|
|
236
200
|
break;
|
|
237
|
-
case
|
|
201
|
+
case DocumentType.P:
|
|
238
202
|
uniqueCredential.originalPresentation = this.secureParse(credential.rawDocument);
|
|
239
|
-
uniqueCredential.id =
|
|
203
|
+
uniqueCredential.id = uniqueCredential.originalPresentation?.id;
|
|
240
204
|
break;
|
|
241
|
-
case
|
|
205
|
+
case DocumentType.C:
|
|
242
206
|
uniqueCredential.originalCredential = this.secureParse(credential.rawDocument);
|
|
243
|
-
uniqueCredential.id =
|
|
207
|
+
uniqueCredential.id = uniqueCredential.originalCredential?.id;
|
|
244
208
|
break;
|
|
245
209
|
// TODO CBOR support
|
|
246
210
|
}
|
|
@@ -249,5 +213,4 @@ class CredentialStore {
|
|
|
249
213
|
}, {}));
|
|
250
214
|
}
|
|
251
215
|
}
|
|
252
|
-
exports.CredentialStore = CredentialStore;
|
|
253
216
|
//# sourceMappingURL=CredentialStore.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CredentialStore.js","sourceRoot":"","sources":["../../src/agent/CredentialStore.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CredentialStore.js","sourceRoot":"","sources":["../../src/agent/CredentialStore.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,YAAY,EACZ,gBAAgB,GACjB,MAAM,8BAA8B,CAAA;AACrC,OAAO,EAAE,SAAS,IAAI,aAAa,EAAE,MAAM,wBAAwB,CAAA;AAGnE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AACzC,OAAO,EAAE,wBAAwB,EAAE,MAAM,kBAAkB,CAAA;AAe3D,wDAAwD;AACxD,MAAM,CAAC,MAAM,sBAAsB,GAAkB;IACnD,kBAAkB;IAClB,0BAA0B;IAC1B,kBAAkB;IAClB,mBAAmB;IACnB,qBAAqB;IACrB,sBAAsB;IACtB,yBAAyB;IACzB,kCAAkC;IAClC,2BAA2B;IAC3B,gCAAgC;CACjC,CAAA;AAED;;GAEG;AACH,MAAM,OAAO,eAAe;IACjB,MAAM,GAAG,MAAM,CAAC,gBAAgB,CAAA;IAChC,OAAO,GAAqB;QACnC,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,IA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,WAAW,CAAC,CAAA;oBAC1F,gBAAgB,CAAC,6BAA6B,GAAG,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC,eAAe,CAAC,CAAA;oBAC7F,gBAAgB,CAAC,EAAE,GAAG,gBAAgB,CAAC,6BAA6B,EAAE,EAAE,CAAA;oBACxE,MAAK;gBACP,KAAK,YAAY,CAAC,CAAC;oBACjB,gBAAgB,CAAC,oBAAoB,GAAG,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC,WAAW,CAAC,CAAA;oBAChF,gBAAgB,CAAC,EAAE,GAAG,gBAAgB,CAAC,oBAAoB,EAAE,EAAE,CAAA;oBAC/D,MAAK;gBACP,KAAK,YAAY,CAAC,CAAC;oBACjB,gBAAgB,CAAC,kBAAkB,GAAG,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC,WAAW,CAAC,CAAA;oBAC9E,gBAAgB,CAAC,EAAE,GAAG,gBAAgB,CAAC,kBAAkB,EAAE,EAAE,CAAA;oBAC7D,MAAK;gBACP,oBAAoB;YACtB,CAAC;YACD,WAAW,CAAC,UAAU,CAAC,IAAI,CAAC,GAAG,gBAAgB,CAAA;YAC/C,OAAO,WAAW,CAAA;QACpB,CAAC,EACD,EAA6C,CAC9C,CACF,CAAA;IACH,CAAC;CACF"}
|
package/dist/index.js
CHANGED
|
@@ -1,37 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.DocumentType = exports.CredentialDocumentFormat = exports.CredentialCorrelationType = exports.CredentialStateType = exports.CredentialRole = exports.credentialStoreMethods = exports.CredentialStore = exports.logger = exports.schema = void 0;
|
|
18
|
-
const ssi_types_1 = require("@sphereon/ssi-types");
|
|
1
|
+
import { Loggers } from '@sphereon/ssi-types';
|
|
19
2
|
/**
|
|
20
3
|
* @public
|
|
21
4
|
*/
|
|
22
5
|
const schema = require('../plugin.schema.json');
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
Object.defineProperty(exports, "CredentialStateType", { enumerable: true, get: function () { return ssi_sdk_data_store_1.CredentialStateType; } });
|
|
31
|
-
Object.defineProperty(exports, "CredentialCorrelationType", { enumerable: true, get: function () { return ssi_sdk_data_store_1.CredentialCorrelationType; } });
|
|
32
|
-
Object.defineProperty(exports, "CredentialDocumentFormat", { enumerable: true, get: function () { return ssi_sdk_data_store_1.CredentialDocumentFormat; } });
|
|
33
|
-
Object.defineProperty(exports, "DocumentType", { enumerable: true, get: function () { return ssi_sdk_data_store_1.DocumentType; } });
|
|
34
|
-
__exportStar(require("./types/ICredentialStore"), exports);
|
|
35
|
-
__exportStar(require("./types/claims"), exports);
|
|
36
|
-
__exportStar(require("./utils/filters"), exports);
|
|
6
|
+
export { schema };
|
|
7
|
+
export const logger = Loggers.DEFAULT.get('sphereon:credential-store');
|
|
8
|
+
export { CredentialStore, credentialStoreMethods } from './agent/CredentialStore';
|
|
9
|
+
export { CredentialRole, CredentialStateType, CredentialCorrelationType, CredentialDocumentFormat, DocumentType, } from '@sphereon/ssi-sdk.data-store';
|
|
10
|
+
export * from './types/ICredentialStore';
|
|
11
|
+
export * from './types/claims';
|
|
12
|
+
export * from './utils/filters';
|
|
37
13
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAE7C;;GAEG;AACH,MAAM,MAAM,GAAG,OAAO,CAAC,uBAAuB,CAAC,CAAA;AAC/C,OAAO,EAAE,MAAM,EAAE,CAAA;AAEjB,MAAM,CAAC,MAAM,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,2BAA2B,CAAC,CAAA;AAEtE,OAAO,EAAE,eAAe,EAAE,sBAAsB,EAAE,MAAM,yBAAyB,CAAA;AACjF,OAAO,EACL,cAAc,EACd,mBAAmB,EACnB,yBAAyB,EACzB,wBAAwB,EACxB,YAAY,GAGb,MAAM,8BAA8B,CAAA;AACrC,cAAc,0BAA0B,CAAA;AACxC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,iBAAiB,CAAA"}
|
|
@@ -6,7 +6,7 @@ import { CredentialStateType } from '@sphereon/ssi-sdk.data-store';
|
|
|
6
6
|
import { DigitalCredential } from '@sphereon/ssi-sdk.data-store';
|
|
7
7
|
import { DocumentType as DocumentType_2 } from '@sphereon/ssi-sdk.data-store';
|
|
8
8
|
import { FindDigitalCredentialArgs } from '@sphereon/ssi-sdk.data-store';
|
|
9
|
-
import {
|
|
9
|
+
import { HasherSync } from '@sphereon/ssi-types';
|
|
10
10
|
import { IAgentContext } from '@veramo/core';
|
|
11
11
|
import { IAgentPlugin } from '@veramo/core';
|
|
12
12
|
import { ICredential } from '@sphereon/ssi-types';
|
|
@@ -24,7 +24,7 @@ export declare type AddCredentialArgs = {
|
|
|
24
24
|
credential: AddDigitalCredential;
|
|
25
25
|
opts?: {
|
|
26
26
|
maxTimeSkewInMS?: number;
|
|
27
|
-
hasher?:
|
|
27
|
+
hasher?: HasherSync;
|
|
28
28
|
};
|
|
29
29
|
};
|
|
30
30
|
|
package/dist/tsdoc-metadata.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CredentialRole, DigitalCredential, FindDigitalCredentialArgs, NonPersistedDigitalCredential, UpdateCredentialStateArgs } from '@sphereon/ssi-sdk.data-store';
|
|
2
|
-
import {
|
|
2
|
+
import { HasherSync, ICredential, IPresentation, IVerifiableCredential, IVerifiablePresentation, OriginalVerifiableCredential, OriginalVerifiablePresentation } from '@sphereon/ssi-types';
|
|
3
3
|
import { IAgentContext, IPluginMethodMap } from '@veramo/core';
|
|
4
4
|
import { FindClaimsArgs } from './claims';
|
|
5
5
|
export type { UpdateCredentialStateArgs };
|
|
@@ -87,7 +87,7 @@ export type AddCredentialArgs = {
|
|
|
87
87
|
credential: AddDigitalCredential;
|
|
88
88
|
opts?: {
|
|
89
89
|
maxTimeSkewInMS?: number;
|
|
90
|
-
hasher?:
|
|
90
|
+
hasher?: HasherSync;
|
|
91
91
|
};
|
|
92
92
|
};
|
|
93
93
|
export interface UniqueDigitalCredential {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ICredentialStore.d.ts","sourceRoot":"","sources":["../../src/types/ICredentialStore.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EACd,iBAAiB,EACjB,yBAAyB,EACzB,6BAA6B,EAC7B,yBAAyB,EAC1B,MAAM,8BAA8B,CAAA;AACrC,OAAO,EACL,
|
|
1
|
+
{"version":3,"file":"ICredentialStore.d.ts","sourceRoot":"","sources":["../../src/types/ICredentialStore.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EACd,iBAAiB,EACjB,yBAAyB,EACzB,6BAA6B,EAC7B,yBAAyB,EAC1B,MAAM,8BAA8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E,MAAM,CAAA;IACX,iBAAiB,EAAE,iBAAiB,CAAA;IAEpC,4BAA4B,CAAC,EAAE,4BAA4B,CAAA;IAC3D,8BAA8B,CAAC,EAAE,8BAA8B,CAAA;IAC/D,kBAAkB,CAAC,EAAE,WAAW,CAAA;IAChC,oBAAoB,CAAC,EAAE,aAAa,CAAA;IACpC,2BAA2B,CAAC,EAAE,qBAAqB,CAAA;IACnD,6BAA6B,CAAC,EAAE,uBAAuB,CAAA;CACxD;AAED,MAAM,MAAM,+BAA+B,GAAG,uBAAuB,GAAG,SAAS,CAAA;AAEjF,MAAM,MAAM,eAAe,GAAG,aAAa,CAAC,KAAK,CAAC,CAAA"}
|
|
@@ -1,13 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.contextHasCredentialStore = contextHasCredentialStore;
|
|
4
|
-
const ssi_sdk_agent_config_1 = require("@sphereon/ssi-sdk.agent-config");
|
|
1
|
+
import { contextHasPlugin } from '@sphereon/ssi-sdk.agent-config';
|
|
5
2
|
/**
|
|
6
3
|
*
|
|
7
4
|
* @param context
|
|
8
5
|
* @internal
|
|
9
6
|
*/
|
|
10
|
-
function contextHasCredentialStore(context) {
|
|
11
|
-
return
|
|
7
|
+
export function contextHasCredentialStore(context) {
|
|
8
|
+
return contextHasPlugin(context, 'crsGetCredential');
|
|
12
9
|
}
|
|
13
10
|
//# sourceMappingURL=ICredentialStore.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ICredentialStore.js","sourceRoot":"","sources":["../../src/types/ICredentialStore.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ICredentialStore.js","sourceRoot":"","sources":["../../src/types/ICredentialStore.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAA;AAoFjE;;;;GAIG;AACH,MAAM,UAAU,yBAAyB,CAAC,OAAwC;IAChF,OAAO,gBAAgB,CAAC,OAAO,EAAE,kBAAkB,CAAC,CAAA;AACtD,CAAC"}
|
package/dist/types/claims.js
CHANGED
package/dist/utils/filters.js
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
exports.mergeFilter = exports.verifiableCredentialForRoleFilter = exports.credentialIdOrHashFilter = void 0;
|
|
4
|
-
const ssi_sdk_data_store_1 = require("@sphereon/ssi-sdk.data-store");
|
|
5
|
-
const uuid_1 = require("uuid");
|
|
1
|
+
import { DocumentType } from '@sphereon/ssi-sdk.data-store';
|
|
2
|
+
import { validate as uuidValidate } from 'uuid';
|
|
6
3
|
/**
|
|
7
4
|
* Creates a filter to find a digital credential by its ID or hash.
|
|
8
5
|
*
|
|
@@ -10,7 +7,7 @@ const uuid_1 = require("uuid");
|
|
|
10
7
|
* @param idOrHash - The ID or hash of the credential to search for.
|
|
11
8
|
* @returns A FindDigitalCredentialArgs array for filtering by ID or hash.
|
|
12
9
|
*/
|
|
13
|
-
const credentialIdOrHashFilter = (credentialRole, idOrHash) => {
|
|
10
|
+
export const credentialIdOrHashFilter = (credentialRole, idOrHash) => {
|
|
14
11
|
const filter = [
|
|
15
12
|
{
|
|
16
13
|
hash: idOrHash,
|
|
@@ -21,7 +18,7 @@ const credentialIdOrHashFilter = (credentialRole, idOrHash) => {
|
|
|
21
18
|
credentialRole,
|
|
22
19
|
},
|
|
23
20
|
];
|
|
24
|
-
if ((
|
|
21
|
+
if (uuidValidate(idOrHash)) {
|
|
25
22
|
filter.push({
|
|
26
23
|
id: idOrHash,
|
|
27
24
|
credentialRole,
|
|
@@ -29,7 +26,6 @@ const credentialIdOrHashFilter = (credentialRole, idOrHash) => {
|
|
|
29
26
|
}
|
|
30
27
|
return filter;
|
|
31
28
|
};
|
|
32
|
-
exports.credentialIdOrHashFilter = credentialIdOrHashFilter;
|
|
33
29
|
/**
|
|
34
30
|
* Creates a filter for verifiable credentials with a specific role.
|
|
35
31
|
*
|
|
@@ -37,19 +33,18 @@ exports.credentialIdOrHashFilter = credentialIdOrHashFilter;
|
|
|
37
33
|
* @param withFilter - Optional additional filter criteria.
|
|
38
34
|
* @returns A FindDigitalCredentialArgs array for filtering verifiable credentials by role.
|
|
39
35
|
*/
|
|
40
|
-
const verifiableCredentialForRoleFilter = (credentialRole, withFilter) => {
|
|
36
|
+
export const verifiableCredentialForRoleFilter = (credentialRole, withFilter) => {
|
|
41
37
|
const filter = [
|
|
42
38
|
{
|
|
43
|
-
documentType:
|
|
39
|
+
documentType: DocumentType.VC,
|
|
44
40
|
credentialRole: credentialRole,
|
|
45
41
|
},
|
|
46
42
|
];
|
|
47
43
|
if (withFilter !== undefined) {
|
|
48
|
-
return
|
|
44
|
+
return mergeFilter(withFilter, filter);
|
|
49
45
|
}
|
|
50
46
|
return filter;
|
|
51
47
|
};
|
|
52
|
-
exports.verifiableCredentialForRoleFilter = verifiableCredentialForRoleFilter;
|
|
53
48
|
/**
|
|
54
49
|
* Merges two FindDigitalCredentialArgs arrays into a single array.
|
|
55
50
|
*
|
|
@@ -67,18 +62,18 @@ exports.verifiableCredentialForRoleFilter = verifiableCredentialForRoleFilter;
|
|
|
67
62
|
* const mergedFilter = mergeFilter(filter1, filter2);
|
|
68
63
|
* // Result: [{ documentType: DocumentType.VP }, { credentialRole: CredentialRole.ISSUER, hash: 'abc123' }]
|
|
69
64
|
*/
|
|
70
|
-
const mergeFilter = (filter1, filter2) => {
|
|
65
|
+
export const mergeFilter = (filter1, filter2) => {
|
|
71
66
|
const mergedFilter = [];
|
|
72
67
|
const mergedMap = new Map();
|
|
73
68
|
filter1.forEach((obj, index) => {
|
|
74
|
-
mergedMap.set(index,
|
|
69
|
+
mergedMap.set(index, { ...obj });
|
|
75
70
|
});
|
|
76
71
|
filter2.forEach((obj, index) => {
|
|
77
72
|
if (mergedMap.has(index)) {
|
|
78
|
-
mergedMap.set(index,
|
|
73
|
+
mergedMap.set(index, { ...mergedMap.get(index), ...obj });
|
|
79
74
|
}
|
|
80
75
|
else {
|
|
81
|
-
mergedMap.set(index,
|
|
76
|
+
mergedMap.set(index, { ...obj });
|
|
82
77
|
}
|
|
83
78
|
});
|
|
84
79
|
mergedMap.forEach((value) => {
|
|
@@ -86,5 +81,4 @@ const mergeFilter = (filter1, filter2) => {
|
|
|
86
81
|
});
|
|
87
82
|
return mergedFilter;
|
|
88
83
|
};
|
|
89
|
-
exports.mergeFilter = mergeFilter;
|
|
90
84
|
//# sourceMappingURL=filters.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filters.js","sourceRoot":"","sources":["../../src/utils/filters.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"filters.js","sourceRoot":"","sources":["../../src/utils/filters.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqC,YAAY,EAA6B,MAAM,8BAA8B,CAAA;AACzH,OAAO,EAAE,QAAQ,IAAI,YAAY,EAAE,MAAM,MAAM,CAAA;AAE/C;;;;;;GAMG;AAEH,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,cAA8B,EAAE,QAAgB,EAA6B,EAAE;IACtH,MAAM,MAAM,GAA8B;QACxC;YACE,IAAI,EAAE,QAAQ;YACd,cAAc;SACf;QACD;YACE,YAAY,EAAE,QAAQ;YACtB,cAAc;SACf;KACF,CAAA;IAED,IAAI,YAAY,CAAC,QAAQ,CAAC,EAAE,CAAC;QAC3B,MAAM,CAAC,IAAI,CAAC;YACV,EAAE,EAAE,QAAQ;YACZ,cAAc;SACf,CAAC,CAAA;IACJ,CAAC;IAED,OAAO,MAAM,CAAA;AACf,CAAC,CAAA;AAED;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,iCAAiC,GAAG,CAC/C,cAA8B,EAC9B,UAAsC,EACX,EAAE;IAC7B,MAAM,MAAM,GAAG;QACb;YACE,YAAY,EAAE,YAAY,CAAC,EAAE;YAC7B,cAAc,EAAE,cAAc;SAC/B;KACF,CAAA;IACD,IAAI,UAAU,KAAK,SAAS,EAAE,C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|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -17,16 +17,16 @@
|
|
|
17
17
|
"dependencies": {
|
|
18
18
|
"@sphereon/pex": "5.0.0-unstable.28",
|
|
19
19
|
"@sphereon/pex-models": "^2.3.2",
|
|
20
|
-
"@sphereon/ssi-sdk.core": "0.
|
|
21
|
-
"@sphereon/ssi-sdk.data-store": "0.
|
|
20
|
+
"@sphereon/ssi-sdk.core": "0.33.1-feature.vcdm2.4+9f634bdb",
|
|
21
|
+
"@sphereon/ssi-sdk.data-store": "0.33.1-feature.vcdm2.4+9f634bdb",
|
|
22
22
|
"cross-fetch": "^3.1.8",
|
|
23
23
|
"debug": "^4.3.4",
|
|
24
|
-
"typeorm": "^0.3.
|
|
24
|
+
"typeorm": "^0.3.21",
|
|
25
25
|
"uuid": "^9.0.1"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@sphereon/ssi-sdk.agent-config": "0.
|
|
29
|
-
"@sphereon/ssi-types": "0.
|
|
28
|
+
"@sphereon/ssi-sdk.agent-config": "0.33.1-feature.vcdm2.4+9f634bdb",
|
|
29
|
+
"@sphereon/ssi-types": "0.33.1-feature.vcdm2.4+9f634bdb",
|
|
30
30
|
"@types/uuid": "^9.0.8",
|
|
31
31
|
"@veramo/remote-client": "4.2.0",
|
|
32
32
|
"@veramo/remote-server": "4.2.0"
|
|
@@ -52,5 +52,5 @@
|
|
|
52
52
|
"Credential Manager"
|
|
53
53
|
],
|
|
54
54
|
"nx": {},
|
|
55
|
-
"gitHead": "
|
|
55
|
+
"gitHead": "9f634bdb714061141e277508c124b08d626f6036"
|
|
56
56
|
}
|
package/plugin.schema.json
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"type": "number"
|
|
16
16
|
},
|
|
17
17
|
"hasher": {
|
|
18
|
-
"$ref": "#/components/schemas/
|
|
18
|
+
"$ref": "#/components/schemas/HasherSync"
|
|
19
19
|
}
|
|
20
20
|
}
|
|
21
21
|
}
|
|
@@ -101,15 +101,30 @@
|
|
|
101
101
|
"issuerCorrelationId"
|
|
102
102
|
]
|
|
103
103
|
},
|
|
104
|
-
"
|
|
105
|
-
"$comment": "(data: string, alg: string) => Uint8Array",
|
|
104
|
+
"HasherSync": {
|
|
105
|
+
"$comment": "(data: string | ArrayBuffer, alg: string) => Uint8Array",
|
|
106
106
|
"type": "object",
|
|
107
107
|
"properties": {
|
|
108
108
|
"namedArgs": {
|
|
109
109
|
"type": "object",
|
|
110
110
|
"properties": {
|
|
111
111
|
"data": {
|
|
112
|
-
"
|
|
112
|
+
"anyOf": [
|
|
113
|
+
{
|
|
114
|
+
"type": "string"
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
"type": "object",
|
|
118
|
+
"properties": {
|
|
119
|
+
"byteLength": {
|
|
120
|
+
"type": "number"
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"required": [
|
|
124
|
+
"byteLength"
|
|
125
|
+
]
|
|
126
|
+
}
|
|
127
|
+
]
|
|
113
128
|
},
|
|
114
129
|
"alg": {
|
|
115
130
|
"type": "string"
|
|
@@ -1103,7 +1118,7 @@
|
|
|
1103
1118
|
"additionalProperties": {
|
|
1104
1119
|
"anyOf": [
|
|
1105
1120
|
{
|
|
1106
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1121
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1107
1122
|
},
|
|
1108
1123
|
{
|
|
1109
1124
|
"not": {}
|
|
@@ -1114,7 +1129,7 @@
|
|
|
1114
1129
|
{
|
|
1115
1130
|
"type": "array",
|
|
1116
1131
|
"items": {
|
|
1117
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1132
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1118
1133
|
}
|
|
1119
1134
|
}
|
|
1120
1135
|
]
|
|
@@ -1145,7 +1160,7 @@
|
|
|
1145
1160
|
"additionalProperties": {
|
|
1146
1161
|
"anyOf": [
|
|
1147
1162
|
{
|
|
1148
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1163
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1149
1164
|
},
|
|
1150
1165
|
{
|
|
1151
1166
|
"not": {}
|
|
@@ -1156,7 +1171,7 @@
|
|
|
1156
1171
|
{
|
|
1157
1172
|
"type": "array",
|
|
1158
1173
|
"items": {
|
|
1159
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1174
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1160
1175
|
}
|
|
1161
1176
|
}
|
|
1162
1177
|
]
|
|
@@ -1166,7 +1181,7 @@
|
|
|
1166
1181
|
}
|
|
1167
1182
|
]
|
|
1168
1183
|
},
|
|
1169
|
-
"alias-pes_sd-jwt-vc.d.ts-
|
|
1184
|
+
"alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006": {
|
|
1170
1185
|
"anyOf": [
|
|
1171
1186
|
{
|
|
1172
1187
|
"type": "string"
|
|
@@ -1182,7 +1197,7 @@
|
|
|
1182
1197
|
"additionalProperties": {
|
|
1183
1198
|
"anyOf": [
|
|
1184
1199
|
{
|
|
1185
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1200
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1186
1201
|
},
|
|
1187
1202
|
{
|
|
1188
1203
|
"not": {}
|
|
@@ -1193,7 +1208,7 @@
|
|
|
1193
1208
|
{
|
|
1194
1209
|
"type": "array",
|
|
1195
1210
|
"items": {
|
|
1196
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1211
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1197
1212
|
}
|
|
1198
1213
|
}
|
|
1199
1214
|
]
|
|
@@ -1265,7 +1280,7 @@
|
|
|
1265
1280
|
"additionalProperties": {
|
|
1266
1281
|
"anyOf": [
|
|
1267
1282
|
{
|
|
1268
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1283
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1269
1284
|
},
|
|
1270
1285
|
{
|
|
1271
1286
|
"not": {}
|
|
@@ -1276,7 +1291,7 @@
|
|
|
1276
1291
|
{
|
|
1277
1292
|
"type": "array",
|
|
1278
1293
|
"items": {
|
|
1279
|
-
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-
|
|
1294
|
+
"$ref": "#/components/schemas/alias-pes_sd-jwt-vc.d.ts-197-306-pes_sd-jwt-vc.d.ts-0-8006"
|
|
1280
1295
|
}
|
|
1281
1296
|
},
|
|
1282
1297
|
{
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
UpdateCredentialStateArgs,
|
|
8
8
|
} from '@sphereon/ssi-sdk.data-store'
|
|
9
9
|
import {
|
|
10
|
-
|
|
10
|
+
HasherSync,
|
|
11
11
|
ICredential,
|
|
12
12
|
IPresentation,
|
|
13
13
|
IVerifiableCredential,
|
|
@@ -121,7 +121,7 @@ export type AddDigitalCredential = Omit<
|
|
|
121
121
|
|
|
122
122
|
export type AddCredentialArgs = {
|
|
123
123
|
credential: AddDigitalCredential
|
|
124
|
-
opts?: { maxTimeSkewInMS?: number; hasher?:
|
|
124
|
+
opts?: { maxTimeSkewInMS?: number; hasher?: HasherSync }
|
|
125
125
|
}
|
|
126
126
|
|
|
127
127
|
export interface UniqueDigitalCredential {
|