From 8415ff4b0c911ae34c893dd6837109bad8eb3329 Mon Sep 17 00:00:00 2001 From: Andrew Whitehead Date: Tue, 30 Jan 2024 14:30:18 -0800 Subject: [PATCH] add cached BBS v1 context Signed-off-by: Andrew Whitehead --- .../vc/ld_proofs/document_downloader.py | 1 + .../ld_proofs/resources/bbs-v1-context.jsonld | 129 ++++++++++++++++++ 2 files changed, 130 insertions(+) create mode 100644 aries_cloudagent/vc/ld_proofs/resources/bbs-v1-context.jsonld diff --git a/aries_cloudagent/vc/ld_proofs/document_downloader.py b/aries_cloudagent/vc/ld_proofs/document_downloader.py index 2a4a794a34..a465522eff 100644 --- a/aries_cloudagent/vc/ld_proofs/document_downloader.py +++ b/aries_cloudagent/vc/ld_proofs/document_downloader.py @@ -43,6 +43,7 @@ class StaticCacheJsonLdDownloader: "https://w3id.org/security/v1": "security-v1-context.jsonld", "https://w3id.org/security/v2": "security-v2-context.jsonld", "https://w3id.org/security/suites/ed25519-2020/v1": "ed25519-2020-context.jsonld", + "https://w3id.org/security/bbs/v1": "bbs-v1-context.jsonld", } def __init__( diff --git a/aries_cloudagent/vc/ld_proofs/resources/bbs-v1-context.jsonld b/aries_cloudagent/vc/ld_proofs/resources/bbs-v1-context.jsonld new file mode 100644 index 0000000000..738c2baef8 --- /dev/null +++ b/aries_cloudagent/vc/ld_proofs/resources/bbs-v1-context.jsonld @@ -0,0 +1,129 @@ +{ + "@context": { + "@version": 1.1, + "id": "@id", + "type": "@type", + "BbsBlsSignature2020": { + "@id": "https://w3id.org/security#BbsBlsSignature2020", + "@context": { + "@version": 1.1, + "@protected": true, + "id": "@id", + "type": "@type", + "challenge": "https://w3id.org/security#challenge", + "created": { + "@id": "http://purl.org/dc/terms/created", + "@type": "http://www.w3.org/2001/XMLSchema#dateTime" + }, + "domain": "https://w3id.org/security#domain", + "proofValue": "https://w3id.org/security#proofValue", + "nonce": "https://w3id.org/security#nonce", + "proofPurpose": { + "@id": "https://w3id.org/security#proofPurpose", + "@type": "@vocab", + "@context": { + "@version": 1.1, + "@protected": true, + "id": "@id", + "type": "@type", + "assertionMethod": { + "@id": "https://w3id.org/security#assertionMethod", + "@type": "@id", + "@container": "@set" + }, + "authentication": { + "@id": "https://w3id.org/security#authenticationMethod", + "@type": "@id", + "@container": "@set" + } + } + }, + "verificationMethod": { + "@id": "https://w3id.org/security#verificationMethod", + "@type": "@id" + } + } + }, + "BbsBlsSignatureProof2020": { + "@id": "https://w3id.org/security#BbsBlsSignatureProof2020", + "@context": { + "@version": 1.1, + "@protected": true, + "id": "@id", + "type": "@type", + + "challenge": "https://w3id.org/security#challenge", + "created": { + "@id": "http://purl.org/dc/terms/created", + "@type": "http://www.w3.org/2001/XMLSchema#dateTime" + }, + "domain": "https://w3id.org/security#domain", + "nonce": "https://w3id.org/security#nonce", + "proofPurpose": { + "@id": "https://w3id.org/security#proofPurpose", + "@type": "@vocab", + "@context": { + "@version": 1.1, + "@protected": true, + "id": "@id", + "type": "@type", + "sec": "https://w3id.org/security#", + "assertionMethod": { + "@id": "https://w3id.org/security#assertionMethod", + "@type": "@id", + "@container": "@set" + }, + "authentication": { + "@id": "https://w3id.org/security#authenticationMethod", + "@type": "@id", + "@container": "@set" + } + } + }, + "proofValue": "https://w3id.org/security#proofValue", + "verificationMethod": { + "@id": "https://w3id.org/security#verificationMethod", + "@type": "@id" + } + } + }, + "Bls12381G1Key2020": { + "@id": "https://w3id.org/security#Bls12381G1Key2020", + "@context": { + "@protected": true, + "id": "@id", + "type": "@type", + "controller": { + "@id": "https://w3id.org/security#controller", + "@type": "@id" + }, + "revoked": { + "@id": "https://w3id.org/security#revoked", + "@type": "http://www.w3.org/2001/XMLSchema#dateTime" + }, + "publicKeyBase58": { + "@id": "https://w3id.org/security#publicKeyBase58" + } + } + }, + "Bls12381G2Key2020": { + "@id": "https://w3id.org/security#Bls12381G2Key2020", + "@context": { + "@protected": true, + "id": "@id", + "type": "@type", + "controller": { + "@id": "https://w3id.org/security#controller", + "@type": "@id" + }, + "revoked": { + "@id": "https://w3id.org/security#revoked", + "@type": "http://www.w3.org/2001/XMLSchema#dateTime" + }, + "publicKeyBase58": { + "@id": "https://w3id.org/security#publicKeyBase58" + } + } + } + } +}