File tree Expand file tree Collapse file tree 1 file changed +29
-2
lines changed Expand file tree Collapse file tree 1 file changed +29
-2
lines changed Original file line number Diff line number Diff line change 8
8
issueCloned
9
9
} from 'data-integrity-test-suite-assertion' ;
10
10
import { createInitialVc , endpointCheck } from '../helpers.js' ;
11
+ import { getMultiKey } from '../vc-generator/key-gen.js' ;
12
+ import { getSuites } from './helpers.js' ;
11
13
import { localVerifier } from '../vc-verifier/index.js' ;
12
14
13
15
export function commonAlgorithms ( {
@@ -188,12 +190,37 @@ async function _setup({
188
190
selectivePointers,
189
191
suiteName,
190
192
keyType
193
+ } ) {
194
+ // stub suite canonize via Proxy cryptosuite.canonize and set safe to false
195
+ const credentials = new Map ( ) ;
196
+ const keyPair = await getMultiKey ( { keyType} ) ;
197
+ const signer = keyPair . signer ( ) ;
198
+ const _credential = structuredClone ( credential ) ;
199
+ _credential . issuer = keyPair . controller ;
200
+ const { invalidCreated} = generators ?. dates ;
201
+ credentials . set ( 'invalidCreated' , await issueCloned ( invalidCreated ( {
202
+ credential : structuredClone ( _credential ) ,
203
+ ...getSuites ( {
204
+ signer,
205
+ suiteName,
206
+ selectivePointers,
207
+ mandatoryPointers
208
+ } )
209
+ } ) ) ) ;
210
+ return credentials ;
211
+ }
212
+
213
+ async function _generateNoTypeCryptosuite ( {
214
+ signer,
215
+ credential,
216
+ mandatoryPointers,
217
+ selectivePointers
191
218
} ) {
192
219
const {
193
220
invalidProofType,
194
221
invalidCryptosuite
195
222
} = generators ?. mandatory ;
196
- const credentials = new Map ( ) ;
197
- const { invalidCreated} = generators ?. dates ;
223
+ const noType = invalidProofType ( {
198
224
225
+ } ) ;
199
226
}
You can’t perform that action at this time.
0 commit comments