Skip to content

Commit 5d4fa02

Browse files
authored
Merge pull request #10 from digitalcredentials/jc-update-security-document-loader
2 parents 2da6036 + 30a4acb commit 5d4fa02

File tree

3 files changed

+63
-8
lines changed

3 files changed

+63
-8
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# isomorphic-lib-template Changelog
22

3-
## 0.0.1 - TBD
3+
## 1.0.0 - TBD
44

55
### Added
66

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@digitalcredentials/verifier-core",
33
"description": "For verifying Verifiable Credentials in the browser, Node.js, and React Native.",
4-
"version": "1.0.0-beta.6",
4+
"version": "1.0.0-beta.7",
55
"scripts": {
66
"build-esm": "tsc -p tsconfig.esm.json",
77
"build-types": "tsc -p tsconfig.types.json",
@@ -31,7 +31,7 @@
3131
"@digitalcredentials/eddsa-rdfc-2022-cryptosuite": "^1.3.0",
3232
"@digitalcredentials/issuer-registry-client": "^3.2.0-beta.5",
3333
"@digitalcredentials/jsonld-signatures": "^12.0.1",
34-
"@digitalcredentials/security-document-loader": "^7.0.0",
34+
"@digitalcredentials/security-document-loader": "^8.0.0",
3535
"@digitalcredentials/vc": "^10.0.0",
3636
"@digitalcredentials/vc-bitstring-status-list": "^1.0.0"
3737
},

test/Verify.experimentation.spec.ts

Lines changed: 60 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,65 @@ import { verifyCredential } from '../src/Verify.js'
33
import { knownDIDRegistries } from '../src/test-fixtures/knownDidRegistries.js';
44
const { expect } = chai;
55

6-
/* This is just here for convenience, as an easy way to try things
7-
during development
6+
/* This file is just here for convenience, as an easy way to try things
7+
during development, with a few credentials already setup.
88
*/
99

10+
const v1oidfNostatusNoexpiryEd25519Signature2020 = {
11+
"@context": [
12+
"https://www.w3.org/2018/credentials/v1",
13+
"https://purl.imsglobal.org/spec/ob/v3p0/context-3.0.3.json",
14+
"https://w3id.org/security/suites/ed25519-2020/v1"
15+
],
16+
"id": "urn:uuid:2fe53dc9-b2ec-4939-9b2c-0d00f6663b6c",
17+
"issuanceDate": "2025-01-09T15:06:31Z",
18+
"type": [
19+
"VerifiableCredential",
20+
"OpenBadgeCredential"
21+
],
22+
"name": "DCC Test Credential",
23+
"issuer": {
24+
"type": [
25+
"Profile"
26+
],
27+
"id": "did:web:digitalcredentials.github.io:vc-test-fixtures:dids:oidf",
28+
"name": "Digital Credentials Consortium Test Issuer",
29+
"url": "https://dcconsortium.org",
30+
"image": "https://user-images.githubusercontent.com/752326/230469660-8f80d264-eccf-4edd-8e50-ea634d407778.png"
31+
},
32+
"credentialSubject": {
33+
"type": [
34+
"AchievementSubject"
35+
],
36+
"achievement": {
37+
"id": "urn:uuid:bd6d9316-f7ae-4073-a1e5-2f7f5bd22922",
38+
"type": [
39+
"Achievement"
40+
],
41+
"achievementType": "Diploma",
42+
"name": "Badge",
43+
"description": "This is a sample credential issued by the Digital Credentials Consortium to demonstrate the functionality of Verifiable Credentials for wallets and verifiers.",
44+
"criteria": {
45+
"type": "Criteria",
46+
"narrative": "This credential was issued to a student that demonstrated proficiency in the Python programming language that occurred from **February 17, 2023** to **June 12, 2023**."
47+
},
48+
"image": {
49+
"id": "https://user-images.githubusercontent.com/752326/214947713-15826a3a-b5ac-4fba-8d4a-884b60cb7157.png",
50+
"type": "Image"
51+
}
52+
},
53+
"name": "Jane Doe"
54+
},
55+
"proof": {
56+
"type": "Ed25519Signature2020",
57+
"created": "2025-05-08T16:04:18Z",
58+
"verificationMethod": "did:web:digitalcredentials.github.io:vc-test-fixtures:dids:oidf#z6MkjXe1vZvPRqFuc9nRBtZ3e1Y9XKDFSbjFAfzLfW2bD6cZ",
59+
"proofPurpose": "assertionMethod",
60+
"proofValue": "z3LWc7BqiGRmP2ZnWvXeoVFgmHAcbNsDidMdnP9nnqw5kgNSUzTFVw5nM5dUnzdUTdNHy4SbHYdL9yp6apFVv16oV"
61+
}
62+
} as any
63+
64+
1065
const didWebCredential = {
1166
"type": [
1267
"VerifiableCredential",
@@ -116,12 +171,12 @@ const didKeyCredential = {
116171

117172

118173
describe('tests to experiment during development work', () => {
119-
it.skip('returns oidf data', async () => {
174+
it('tests', async () => {
120175
// change this however you like to test things, or more likely,
121176
// change the VC that is passed in.
122177
const result = await verifyCredential({ credential: didKeyCredential, knownDIDRegistries })
123-
console.log(JSON.stringify(result, null, 2))
124-
expect(true).to.equal(true)
178+
// console.log(JSON.stringify(result, null, 2))
179+
expect(result.errors).to.not.exist
125180
})
126181
})
127182

0 commit comments

Comments
 (0)