@veramo/credential-ld 3.1.1-next.10

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.
Files changed (67) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +6 -0
  3. package/build/action-handler.d.ts +28 -0
  4. package/build/action-handler.d.ts.map +1 -0
  5. package/build/action-handler.js +155 -0
  6. package/build/action-handler.js.map +1 -0
  7. package/build/index.d.ts +15 -0
  8. package/build/index.d.ts.map +1 -0
  9. package/build/index.js +31 -0
  10. package/build/index.js.map +1 -0
  11. package/build/ld-context-loader.d.ts +16 -0
  12. package/build/ld-context-loader.d.ts.map +1 -0
  13. package/build/ld-context-loader.js +40 -0
  14. package/build/ld-context-loader.js.map +1 -0
  15. package/build/ld-credential-module.d.ts +25 -0
  16. package/build/ld-credential-module.d.ts.map +1 -0
  17. package/build/ld-credential-module.js +148 -0
  18. package/build/ld-credential-module.js.map +1 -0
  19. package/build/ld-default-contexts.d.ts +6 -0
  20. package/build/ld-default-contexts.d.ts.map +1 -0
  21. package/build/ld-default-contexts.js +60 -0
  22. package/build/ld-default-contexts.js.map +1 -0
  23. package/build/ld-suite-loader.d.ts +15 -0
  24. package/build/ld-suite-loader.d.ts.map +1 -0
  25. package/build/ld-suite-loader.js +28 -0
  26. package/build/ld-suite-loader.js.map +1 -0
  27. package/build/ld-suites.d.ts +13 -0
  28. package/build/ld-suites.d.ts.map +1 -0
  29. package/build/ld-suites.js +15 -0
  30. package/build/ld-suites.js.map +1 -0
  31. package/build/suites/EcdsaSecp256k1RecoverySignature2020.d.ts +11 -0
  32. package/build/suites/EcdsaSecp256k1RecoverySignature2020.d.ts.map +1 -0
  33. package/build/suites/EcdsaSecp256k1RecoverySignature2020.js +100 -0
  34. package/build/suites/EcdsaSecp256k1RecoverySignature2020.js.map +1 -0
  35. package/build/suites/Ed25519Signature2018.d.ts +11 -0
  36. package/build/suites/Ed25519Signature2018.d.ts.map +1 -0
  37. package/build/suites/Ed25519Signature2018.js +92 -0
  38. package/build/suites/Ed25519Signature2018.js.map +1 -0
  39. package/build/tsdoc-metadata.json +11 -0
  40. package/build/types.d.ts +174 -0
  41. package/build/types.d.ts.map +1 -0
  42. package/build/types.js +3 -0
  43. package/build/types.js.map +1 -0
  44. package/contexts/X25519KeyAgreementKey2019.jsonld +26 -0
  45. package/contexts/did_v0.11.jsonld +58 -0
  46. package/contexts/ed25519-signature-2018-v1.jsonld +91 -0
  47. package/contexts/kyc-v1.jsonld +8 -0
  48. package/contexts/lds-ecdsa-secp256k1-recovery2020-0.0.jsonld +60 -0
  49. package/contexts/profile-v1.jsonld +8 -0
  50. package/contexts/security_context_v1.jsonld +58 -0
  51. package/contexts/socialmedia-v1.jsonld +7 -0
  52. package/contexts/transmute_v1.jsonld +21 -0
  53. package/contexts/w3_2018_credentials_v1.jsonld +237 -0
  54. package/package.json +51 -0
  55. package/plugin.schema.json +398 -0
  56. package/src/__tests__/context.loader.test.ts +39 -0
  57. package/src/__tests__/issue-verify-flow.test.ts +84 -0
  58. package/src/action-handler.ts +229 -0
  59. package/src/index.ts +14 -0
  60. package/src/ld-context-loader.ts +30 -0
  61. package/src/ld-credential-module.ts +170 -0
  62. package/src/ld-default-contexts.ts +30 -0
  63. package/src/ld-suite-loader.ts +29 -0
  64. package/src/ld-suites.ts +45 -0
  65. package/src/suites/EcdsaSecp256k1RecoverySignature2020.ts +83 -0
  66. package/src/suites/Ed25519Signature2018.ts +75 -0
  67. package/src/types.ts +208 -0
@@ -0,0 +1,174 @@
1
+ import { CredentialPayload, IAgentContext, IDIDManager, IKeyManager, IPluginMethodMap, IResolver, PresentationPayload, VerifiableCredential, VerifiablePresentation } from '@veramo/core';
2
+ /**
3
+ * The interface definition for a plugin that can issue and verify Verifiable Credentials and Presentations
4
+ * that use JSON-LD format.
5
+ *
6
+ * @remarks Please see {@link https://www.w3.org/TR/vc-data-model | W3C Verifiable Credentials data model}
7
+ *
8
+ * @beta This API is likely to change without a BREAKING CHANGE notice
9
+ */
10
+ export interface ICredentialIssuerLD extends IPluginMethodMap {
11
+ /**
12
+ * Creates a Verifiable Presentation.
13
+ * The payload, signer and format are chosen based on the `args` parameter.
14
+ *
15
+ * @param args - Arguments necessary to create the Presentation.
16
+ * @param context - This reserved param is automatically added and handled by the framework, *do not override*
17
+ *
18
+ * @returns - a promise that resolves to the {@link @veramo/core#VerifiablePresentation} that was requested or rejects with an error
19
+ * if there was a problem with the input or while getting the key to sign
20
+ *
21
+ * @remarks Please see {@link https://www.w3.org/TR/vc-data-model/#presentations | Verifiable Presentation data model }
22
+ *
23
+ * @beta This API is likely to change without a BREAKING CHANGE notice
24
+ */
25
+ createVerifiablePresentationLD(args: ICreateVerifiablePresentationLDArgs, context: IRequiredContext): Promise<VerifiablePresentation>;
26
+ /**
27
+ * Creates a Verifiable Credential.
28
+ * The payload, signer and format are chosen based on the `args` parameter.
29
+ *
30
+ * @param args - Arguments necessary to create the Presentation.
31
+ * @param context - This reserved param is automatically added and handled by the framework, *do not override*
32
+ *
33
+ * @returns - a promise that resolves to the {@link @veramo/core#VerifiableCredential} that was requested or rejects with an error
34
+ * if there was a problem with the input or while getting the key to sign
35
+ *
36
+ * @remarks Please see {@link https://www.w3.org/TR/vc-data-model/#credentials | Verifiable Credential data model}
37
+ *
38
+ * @beta This API is likely to change without a BREAKING CHANGE notice
39
+ */
40
+ createVerifiableCredentialLD(args: ICreateVerifiableCredentialLDArgs, context: IRequiredContext): Promise<VerifiableCredential>;
41
+ /**
42
+ * Verifies a Verifiable Credential JWT or LDS Format.
43
+ *
44
+ * @param args - Arguments necessary to verify a VerifiableCredential
45
+ * @param context - This reserved param is automatically added and handled by the framework, *do not override*
46
+ *
47
+ * @returns - a promise that resolves to the boolean true on successful verification or rejects on error
48
+ *
49
+ * @remarks Please see {@link https://www.w3.org/TR/vc-data-model/#credentials | Verifiable Credential data model}
50
+ *
51
+ * @beta This API is likely to change without a BREAKING CHANGE notice
52
+ */
53
+ verifyCredentialLD(args: IVerifyCredentialLDArgs, context: IRequiredContext): Promise<boolean>;
54
+ /**
55
+ * Verifies a Verifiable Presentation JWT or LDS Format.
56
+ *
57
+ * @param args - Arguments necessary to verify a VerifiableCredential
58
+ * @param context - This reserved param is automatically added and handled by the framework, *do not override*
59
+ *
60
+ * @returns - a promise that resolves to the boolean true on successful verification or rejects on error
61
+ *
62
+ * @remarks Please see {@link https://www.w3.org/TR/vc-data-model/#presentations | Verifiable Credential data model}
63
+ *
64
+ * @beta This API is likely to change without a BREAKING CHANGE notice
65
+ */
66
+ verifyPresentationLD(args: IVerifyPresentationLDArgs, context: IRequiredContext): Promise<boolean>;
67
+ }
68
+ /**
69
+ * Encapsulates the parameters required to create a
70
+ * {@link https://www.w3.org/TR/vc-data-model/#presentations | W3C Verifiable Presentation}
71
+ *
72
+ * @beta This API is likely to change without a BREAKING CHANGE notice
73
+ */
74
+ export interface ICreateVerifiablePresentationLDArgs {
75
+ /**
76
+ * The json payload of the Presentation according to the
77
+ * {@link https://www.w3.org/TR/vc-data-model/#presentations | canonical model}.
78
+ *
79
+ * The signer of the Presentation is chosen based on the `holder` property
80
+ * of the `presentation`
81
+ *
82
+ * '@context', 'type' and 'issuanceDate' will be added automatically if omitted
83
+ */
84
+ presentation: PresentationPayload;
85
+ /**
86
+ * Optional (only JWT) string challenge parameter to add to the verifiable presentation.
87
+ */
88
+ challenge?: string;
89
+ /**
90
+ * Optional string domain parameter to add to the verifiable presentation.
91
+ */
92
+ domain?: string;
93
+ /**
94
+ * Optional. The key handle ({@link IKey#kid}) from the internal database.
95
+ */
96
+ keyRef?: string;
97
+ }
98
+ /**
99
+ * Encapsulates the parameters required to create a
100
+ * {@link https://www.w3.org/TR/vc-data-model/#credentials | W3C Verifiable Credential}
101
+ *
102
+ * @beta This API is likely to change without a BREAKING CHANGE notice
103
+ */
104
+ export interface ICreateVerifiableCredentialLDArgs {
105
+ /**
106
+ * The json payload of the Credential according to the
107
+ * {@link https://www.w3.org/TR/vc-data-model/#credentials | canonical model}
108
+ *
109
+ * The signer of the Credential is chosen based on the `issuer.id` property
110
+ * of the `credential`
111
+ *
112
+ * '@context', 'type' and 'issuanceDate' will be added automatically if omitted
113
+ */
114
+ credential: CredentialPayload;
115
+ /**
116
+ * Optional. The key handle ({@link IKey#kid}) from the internal database.
117
+ */
118
+ keyRef?: string;
119
+ }
120
+ /**
121
+ * Encapsulates the parameters required to verify a
122
+ * {@link https://www.w3.org/TR/vc-data-model/#credentials | W3C Verifiable Credential}
123
+ *
124
+ * @beta This API is likely to change without a BREAKING CHANGE notice
125
+ */
126
+ export interface IVerifyCredentialLDArgs {
127
+ /**
128
+ * The json payload of the Credential according to the
129
+ * {@link https://www.w3.org/TR/vc-data-model/#credentials | canonical model}
130
+ *
131
+ * The signer of the Credential is chosen based on the `issuer.id` property
132
+ * of the `credential`
133
+ *
134
+ */
135
+ credential: VerifiableCredential;
136
+ }
137
+ /**
138
+ * Encapsulates the parameters required to verify a
139
+ * {@link https://www.w3.org/TR/vc-data-model/#presentations | W3C Verifiable Presentation}
140
+ *
141
+ * @beta This API is likely to change without a BREAKING CHANGE notice
142
+ */
143
+ export interface IVerifyPresentationLDArgs {
144
+ /**
145
+ * The json payload of the Credential according to the
146
+ * {@link https://www.w3.org/TR/vc-data-model/#credentials | canonical model}
147
+ *
148
+ * The signer of the Credential is chosen based on the `issuer.id` property
149
+ * of the `credential`
150
+ *
151
+ */
152
+ presentation: VerifiablePresentation;
153
+ /**
154
+ * Optional (only for JWT) string challenge parameter to verify the verifiable presentation against
155
+ */
156
+ challenge?: string;
157
+ /**
158
+ * Optional (only for JWT) string domain parameter to verify the verifiable presentation against
159
+ */
160
+ domain?: string;
161
+ }
162
+ /**
163
+ * Represents the requirements that this plugin has.
164
+ * The agent that is using this plugin is expected to provide these methods.
165
+ *
166
+ * This interface can be used for static type checks, to make sure your application is properly initialized.
167
+ *
168
+ * @beta This API is likely to change without a BREAKING CHANGE notice
169
+ */
170
+ export declare type IRequiredContext = IAgentContext<IResolver & Pick<IDIDManager, 'didManagerGet'> & Pick<IKeyManager, 'keyManagerGet' | 'keyManagerSign'>>;
171
+ export declare type ContextDoc = {
172
+ '@context': Record<string, any>;
173
+ };
174
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,aAAa,EACb,WAAW,EAEX,WAAW,EACX,gBAAgB,EAChB,SAAS,EACT,mBAAmB,EACnB,oBAAoB,EACpB,sBAAsB,EACvB,MAAM,cAAc,CAAA;AAErB;;;;;;;GAOG;AACH,MAAM,WAAW,mBAAoB,SAAQ,gBAAgB;IAC3D;;;;;;;;;;;;;OAaG;IACH,8BAA8B,CAC5B,IAAI,EAAE,mCAAmC,EACzC,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,sBAAsB,CAAC,CAAA;IAElC;;;;;;;;;;;;;OAaG;IACH,4BAA4B,CAC1B,IAAI,EAAE,iCAAiC,EACvC,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,oBAAoB,CAAC,CAAA;IAEhC;;;;;;;;;;;OAWG;IACH,kBAAkB,CAAC,IAAI,EAAE,uBAAuB,EAAE,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;IAE9F;;;;;;;;;;;OAWG;IACH,oBAAoB,CAAC,IAAI,EAAE,yBAAyB,EAAE,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;CACnG;AAED;;;;;GAKG;AACH,MAAM,WAAW,mCAAmC;IAClD;;;;;;;;OAQG;IACH,YAAY,EAAE,mBAAmB,CAAA;IAEjC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAElB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IAEf;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;AAED;;;;;GAKG;AACH,MAAM,WAAW,iCAAiC;IAChD;;;;;;;;OAQG;IACH,UAAU,EAAE,iBAAiB,CAAA;IAE7B;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;AAED;;;;;GAKG;AACH,MAAM,WAAW,uBAAuB;IACtC;;;;;;;OAOG;IACH,UAAU,EAAE,oBAAoB,CAAA;CACjC;AAED;;;;;GAKG;AACH,MAAM,WAAW,yBAAyB;IACxC;;;;;;;OAOG;IACH,YAAY,EAAE,sBAAsB,CAAA;IAEpC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAElB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;AAED;;;;;;;GAOG;AACH,oBAAY,gBAAgB,GAAG,aAAa,CAC1C,SAAS,GAAG,IAAI,CAAC,WAAW,EAAE,eAAe,CAAC,GAAG,IAAI,CAAC,WAAW,EAAE,eAAe,GAAG,gBAAgB,CAAC,CACvG,CAAA;AAED,oBAAY,UAAU,GAAG;IACvB,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;CAChC,CAAA"}
package/build/types.js ADDED
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":""}
@@ -0,0 +1,26 @@
1
+ {
2
+ "@context": {
3
+ "id": "@id",
4
+ "type": "@type",
5
+ "@protected": true,
6
+ "X25519KeyAgreementKey2019": {
7
+ "@id": "https://w3id.org/security#X25519KeyAgreementKey2019",
8
+ "@context": {
9
+ "@protected": true,
10
+ "id": "@id",
11
+ "type": "@type",
12
+ "controller": {
13
+ "@id": "https://w3id.org/security#controller",
14
+ "@type": "@id"
15
+ },
16
+ "revoked": {
17
+ "@id": "https://w3id.org/security#revoked",
18
+ "@type": "http://www.w3.org/2001/XMLSchema#dateTime"
19
+ },
20
+ "publicKeyBase58": {
21
+ "@id": "https://w3id.org/security#publicKeyBase58"
22
+ }
23
+ }
24
+ }
25
+ }
26
+ }
@@ -0,0 +1,58 @@
1
+ {
2
+ "@context": {
3
+ "@version": 1.1,
4
+ "id": "@id",
5
+ "type": "@type",
6
+
7
+ "dc": "http://purl.org/dc/terms/",
8
+ "schema": "http://schema.org/",
9
+ "sec": "https://w3id.org/security#",
10
+ "didv": "https://w3id.org/did#",
11
+ "xsd": "http://www.w3.org/2001/XMLSchema#",
12
+
13
+ "EcdsaSecp256k1Signature2019": "sec:EcdsaSecp256k1Signature2019",
14
+ "EcdsaSecp256k1VerificationKey2019": "sec:EcdsaSecp256k1VerificationKey2019",
15
+ "Ed25519Signature2018": "sec:Ed25519Signature2018",
16
+ "Ed25519VerificationKey2018": "sec:Ed25519VerificationKey2018",
17
+ "RsaSignature2018": "sec:RsaSignature2018",
18
+ "RsaVerificationKey2018": "sec:RsaVerificationKey2018",
19
+ "SchnorrSecp256k1Signature2019": "sec:SchnorrSecp256k1Signature2019",
20
+ "SchnorrSecp256k1VerificationKey2019": "sec:SchnorrSecp256k1VerificationKey2019",
21
+ "ServiceEndpointProxyService": "didv:ServiceEndpointProxyService",
22
+
23
+ "allowedAction": "sec:allowedAction",
24
+ "assertionMethod": {"@id": "sec:assertionMethod", "@type": "@id", "@container": "@set"},
25
+ "authentication": {"@id": "sec:authenticationMethod", "@type": "@id", "@container": "@set"},
26
+ "capability": {"@id": "sec:capability", "@type": "@id"},
27
+ "capabilityAction": "sec:capabilityAction",
28
+ "capabilityChain": {"@id": "sec:capabilityChain", "@type": "@id", "@container": "@list"},
29
+ "capabilityDelegation": {"@id": "sec:capabilityDelegationMethod", "@type": "@id", "@container": "@set"},
30
+ "capabilityInvocation": {"@id": "sec:capabilityInvocationMethod", "@type": "@id", "@container": "@set"},
31
+ "capabilityStatusList": {"@id": "sec:capabilityStatusList", "@type": "@id"},
32
+ "canonicalizationAlgorithm": "sec:canonicalizationAlgorithm",
33
+ "caveat": {"@id": "sec:caveat", "@type": "@id", "@container": "@set"},
34
+ "challenge": "sec:challenge",
35
+ "controller": {"@id": "sec:controller", "@type": "@id"},
36
+ "created": {"@id": "dc:created", "@type": "xsd:dateTime"},
37
+ "creator": {"@id": "dc:creator", "@type": "@id"},
38
+ "delegator": {"@id": "sec:delegator", "@type": "@id"},
39
+ "domain": "sec:domain",
40
+ "expirationDate": {"@id": "sec:expiration", "@type": "xsd:dateTime"},
41
+ "invocationTarget": {"@id": "sec:invocationTarget", "@type": "@id"},
42
+ "invoker": {"@id": "sec:invoker", "@type": "@id"},
43
+ "jws": "sec:jws",
44
+ "keyAgreement": {"@id": "sec:keyAgreementMethod", "@type": "@id", "@container": "@set"},
45
+ "nonce": "sec:nonce",
46
+ "owner": {"@id": "sec:owner", "@type": "@id"},
47
+ "proof": {"@id": "sec:proof", "@type": "@id", "@container": "@graph"},
48
+ "proofPurpose": {"@id": "sec:proofPurpose", "@type": "@vocab"},
49
+ "proofValue": "sec:proofValue",
50
+ "publicKey": {"@id": "sec:publicKey", "@type": "@id", "@container": "@set"},
51
+ "publicKeyBase58": "sec:publicKeyBase58",
52
+ "publicKeyPem": "sec:publicKeyPem",
53
+ "revoked": {"@id": "sec:revoked", "@type": "xsd:dateTime"},
54
+ "service": {"@id": "didv:service", "@type": "@id", "@container": "@set"},
55
+ "serviceEndpoint": {"@id": "didv:serviceEndpoint", "@type": "@id"},
56
+ "verificationMethod": {"@id": "sec:verificationMethod", "@type": "@id"}
57
+ }
58
+ }
@@ -0,0 +1,91 @@
1
+ {
2
+ "@context": {
3
+ "id": "@id",
4
+ "type": "@type",
5
+ "@protected": true,
6
+ "proof": {
7
+ "@id": "https://w3id.org/security#proof",
8
+ "@type": "@id",
9
+ "@container": "@graph"
10
+ },
11
+ "Ed25519VerificationKey2018": {
12
+ "@id": "https://w3id.org/security#Ed25519VerificationKey2018",
13
+ "@context": {
14
+ "@protected": true,
15
+ "id": "@id",
16
+ "type": "@type",
17
+ "controller": {
18
+ "@id": "https://w3id.org/security#controller",
19
+ "@type": "@id"
20
+ },
21
+ "revoked": {
22
+ "@id": "https://w3id.org/security#revoked",
23
+ "@type": "http://www.w3.org/2001/XMLSchema#dateTime"
24
+ },
25
+ "publicKeyBase58": {
26
+ "@id": "https://w3id.org/security#publicKeyBase58"
27
+ }
28
+ }
29
+ },
30
+ "Ed25519Signature2018": {
31
+ "@id": "https://w3id.org/security#Ed25519Signature2018",
32
+ "@context": {
33
+ "@protected": true,
34
+ "id": "@id",
35
+ "type": "@type",
36
+ "challenge": "https://w3id.org/security#challenge",
37
+ "created": {
38
+ "@id": "http://purl.org/dc/terms/created",
39
+ "@type": "http://www.w3.org/2001/XMLSchema#dateTime"
40
+ },
41
+ "domain": "https://w3id.org/security#domain",
42
+ "expires": {
43
+ "@id": "https://w3id.org/security#expiration",
44
+ "@type": "http://www.w3.org/2001/XMLSchema#dateTime"
45
+ },
46
+ "nonce": "https://w3id.org/security#nonce",
47
+ "proofPurpose": {
48
+ "@id": "https://w3id.org/security#proofPurpose",
49
+ "@type": "@vocab",
50
+ "@context": {
51
+ "@protected": true,
52
+ "id": "@id",
53
+ "type": "@type",
54
+ "assertionMethod": {
55
+ "@id": "https://w3id.org/security#assertionMethod",
56
+ "@type": "@id",
57
+ "@container": "@set"
58
+ },
59
+ "authentication": {
60
+ "@id": "https://w3id.org/security#authenticationMethod",
61
+ "@type": "@id",
62
+ "@container": "@set"
63
+ },
64
+ "capabilityInvocation": {
65
+ "@id": "https://w3id.org/security#capabilityInvocationMethod",
66
+ "@type": "@id",
67
+ "@container": "@set"
68
+ },
69
+ "capabilityDelegation": {
70
+ "@id": "https://w3id.org/security#capabilityDelegationMethod",
71
+ "@type": "@id",
72
+ "@container": "@set"
73
+ },
74
+ "keyAgreement": {
75
+ "@id": "https://w3id.org/security#keyAgreementMethod",
76
+ "@type": "@id",
77
+ "@container": "@set"
78
+ }
79
+ }
80
+ },
81
+ "jws": {
82
+ "@id": "https://w3id.org/security#jws"
83
+ },
84
+ "verificationMethod": {
85
+ "@id": "https://w3id.org/security#verificationMethod",
86
+ "@type": "@id"
87
+ }
88
+ }
89
+ }
90
+ }
91
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "@context": {
3
+ "@version": 1.1,
4
+ "@protected": true,
5
+ "VerifiableKyc": "https://veramo.io/contexts/kyc#VerifiableKyc",
6
+ "name": "https://schema.org/name"
7
+ }
8
+ }
@@ -0,0 +1,60 @@
1
+ {
2
+ "@context": {
3
+ "@version": 1.1,
4
+ "id": "@id",
5
+ "type": "@type",
6
+ "esrs2020": "https://identity.foundation/EcdsaSecp256k1RecoverySignature2020#",
7
+
8
+ "EcdsaSecp256k1RecoverySignature2020": {
9
+ "@id": "https://w3id.org/security#EcdsaSecp256k1RecoverySignature2020",
10
+ "@context": {
11
+ "@version": 1.1,
12
+ "@protected": true,
13
+
14
+ "id": "@id",
15
+ "type": "@type",
16
+
17
+ "sec": "https://w3id.org/security#",
18
+ "xsd": "http://www.w3.org/2001/XMLSchema#",
19
+
20
+ "challenge": "sec:challenge",
21
+ "created": {"@id": "http://purl.org/dc/terms/created", "@type": "xsd:dateTime"},
22
+ "domain": "sec:domain",
23
+ "expires": {"@id": "sec:expiration", "@type": "xsd:dateTime"},
24
+ "jws": "sec:jws",
25
+ "nonce": "sec:nonce",
26
+ "proofPurpose": {
27
+ "@id": "sec:proofPurpose",
28
+ "@type": "@vocab",
29
+ "@context": {
30
+ "@version": 1.1,
31
+ "@protected": true,
32
+
33
+ "id": "@id",
34
+ "type": "@type",
35
+
36
+ "sec": "https://w3id.org/security#",
37
+
38
+ "assertionMethod": {"@id": "sec:assertionMethod", "@type": "@id", "@container": "@set"},
39
+ "authentication": {"@id": "sec:authenticationMethod", "@type": "@id", "@container": "@set"}
40
+ }
41
+ },
42
+ "proofValue": "sec:proofValue",
43
+ "verificationMethod": {"@id": "sec:verificationMethod", "@type": "@id"}
44
+ }
45
+ },
46
+
47
+ "EcdsaSecp256k1RecoveryMethod2020": "esrs2020:EcdsaSecp256k1RecoveryMethod2020",
48
+ "publicKeyJwk": {
49
+ "@id": "esrs2020:publicKeyJwk",
50
+ "@type": "@json"
51
+ },
52
+ "privateKeyJwk": {
53
+ "@id": "esrs2020:privateKeyJwk",
54
+ "@type": "@json"
55
+ },
56
+ "publicKeyHex": "esrs2020:publicKeyHex",
57
+ "privateKeyHex": "esrs2020:privateKeyHex",
58
+ "ethereumAddress": "esrs2020:ethereumAddress"
59
+ }
60
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "@context": {
3
+ "@version": 1.1,
4
+ "@protected": true,
5
+ "Profile": "https://veramo.io/contexts/profile#Profile",
6
+ "name": "https://schema.org/name"
7
+ }
8
+ }
@@ -0,0 +1,58 @@
1
+ {
2
+ "@context": {
3
+ "@protected": true,
4
+ "id": "@id",
5
+ "type": "@type",
6
+
7
+ "alsoKnownAs": {
8
+ "@id": "https://www.w3.org/ns/activitystreams#alsoKnownAs",
9
+ "@type": "@id"
10
+ },
11
+ "assertionMethod": {
12
+ "@id": "https://w3id.org/security#assertionMethod",
13
+ "@type": "@id",
14
+ "@container": "@set"
15
+ },
16
+ "authentication": {
17
+ "@id": "https://w3id.org/security#authenticationMethod",
18
+ "@type": "@id",
19
+ "@container": "@set"
20
+ },
21
+ "capabilityDelegation": {
22
+ "@id": "https://w3id.org/security#capabilityDelegationMethod",
23
+ "@type": "@id",
24
+ "@container": "@set"
25
+ },
26
+ "capabilityInvocation": {
27
+ "@id": "https://w3id.org/security#capabilityInvocationMethod",
28
+ "@type": "@id",
29
+ "@container": "@set"
30
+ },
31
+ "controller": {
32
+ "@id": "https://w3id.org/security#controller",
33
+ "@type": "@id"
34
+ },
35
+ "keyAgreement": {
36
+ "@id": "https://w3id.org/security#keyAgreementMethod",
37
+ "@type": "@id",
38
+ "@container": "@set"
39
+ },
40
+ "service": {
41
+ "@id": "https://www.w3.org/ns/did#service",
42
+ "@type": "@id",
43
+ "@context": {
44
+ "@protected": true,
45
+ "id": "@id",
46
+ "type": "@type",
47
+ "serviceEndpoint": {
48
+ "@id": "https://www.w3.org/ns/did#serviceEndpoint",
49
+ "@type": "@id"
50
+ }
51
+ }
52
+ },
53
+ "verificationMethod": {
54
+ "@id": "https://w3id.org/security#verificationMethod",
55
+ "@type": "@id"
56
+ }
57
+ }
58
+ }
@@ -0,0 +1,7 @@
1
+ {
2
+ "@context": {
3
+ "@version": 1.1,
4
+ "@protected": true,
5
+ "VerifableSocialMediaPosting": "https://veramo.io/contexts/socialmedia#VerifableSocialMediaPosting"
6
+ }
7
+ }
@@ -0,0 +1,21 @@
1
+ {
2
+ "@context": [
3
+ {
4
+ "@version": 1.1
5
+ },
6
+ "https://www.w3.org/ns/did/v1",
7
+ {
8
+ "JsonWebKey2020": "https://w3id.org/security#JsonWebKey2020",
9
+ "Ed25519VerificationKey2018": "https://w3id.org/security#Ed25519VerificationKey2018",
10
+ "X25519KeyAgreementKey2019": "https://w3id.org/security#X25519KeyAgreementKey2019",
11
+
12
+ "publicKeyJwk": {
13
+ "@id": "https://w3id.org/security#publicKeyJwk",
14
+ "@type": "@json"
15
+ },
16
+ "publicKeyBase58": {
17
+ "@id": "https://w3id.org/security#publicKeyBase58"
18
+ }
19
+ }
20
+ ]
21
+ }