@trustvc/trustvc 1.5.3 → 1.5.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/cjs/utils/fragment/index.js +33 -5
- package/dist/cjs/verify/fragments/document-status/w3cCredentialStatus.js +29 -2
- package/dist/esm/utils/fragment/index.js +35 -1
- package/dist/esm/verify/fragments/document-status/w3cCredentialStatus.js +29 -3
- package/dist/types/index.d.ts +2 -1
- package/dist/types/token-registry-v5/typedContractMethod.d.ts +1 -1
- package/dist/types/utils/fragment/index.d.ts +8 -1
- package/dist/types/utils/index.d.ts +3 -1
- package/dist/types/verify/fragments/document-status/w3cCredentialStatus.d.ts +15 -1
- package/package.json +2 -2
|
@@ -1,14 +1,42 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var tradetrustUtils = require('@tradetrust-tt/tradetrust-utils');
|
|
4
|
+
var ttVerify = require('@tradetrust-tt/tt-verify');
|
|
5
|
+
var w3cCredentialStatus = require('../../verify/fragments/document-status/w3cCredentialStatus');
|
|
4
6
|
|
|
7
|
+
var __defProp = Object.defineProperty;
|
|
8
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
9
|
+
const getW3CCredentialStatusFragment = ttVerify.utils.getFragmentByName(
|
|
10
|
+
"W3CCredentialStatus"
|
|
11
|
+
);
|
|
12
|
+
const w3cCredentialStatusRevoked = /* @__PURE__ */ __name((fragments) => {
|
|
13
|
+
const issuedFragment = getW3CCredentialStatusFragment(fragments);
|
|
14
|
+
return issuedFragment?.reason?.code === w3cCredentialStatus.W3CCredentialStatusCode.DOCUMENT_REVOKED || issuedFragment?.reason?.code === w3cCredentialStatus.W3CCredentialStatusCode.DOCUMENT_REVOKED_AND_SUSPENDED;
|
|
15
|
+
}, "w3cCredentialStatusRevoked");
|
|
16
|
+
const w3cCredentialStatusSuspended = /* @__PURE__ */ __name((fragments) => {
|
|
17
|
+
const issuedFragment = getW3CCredentialStatusFragment(fragments);
|
|
18
|
+
return issuedFragment?.reason?.code === w3cCredentialStatus.W3CCredentialStatusCode.DOCUMENT_SUSPENDED || issuedFragment?.reason?.code === w3cCredentialStatus.W3CCredentialStatusCode.DOCUMENT_REVOKED_AND_SUSPENDED;
|
|
19
|
+
}, "w3cCredentialStatusSuspended");
|
|
20
|
+
const errorMessageHandling = /* @__PURE__ */ __name((fragments) => {
|
|
21
|
+
const errors = [];
|
|
22
|
+
const isW3cFragments = fragments.some(
|
|
23
|
+
(f) => f.name.startsWith("W3C") || f.name === "TransferableRecords"
|
|
24
|
+
);
|
|
25
|
+
if (isW3cFragments) {
|
|
26
|
+
if (w3cCredentialStatusRevoked(fragments)) {
|
|
27
|
+
errors.push(tradetrustUtils.CONSTANTS.TYPES.REVOKED);
|
|
28
|
+
}
|
|
29
|
+
if (w3cCredentialStatusSuspended(fragments)) {
|
|
30
|
+
errors.push(tradetrustUtils.CONSTANTS.TYPES.SUSPENDED);
|
|
31
|
+
}
|
|
32
|
+
return errors;
|
|
33
|
+
} else return tradetrustUtils.errorMessageHandling(fragments);
|
|
34
|
+
}, "errorMessageHandling");
|
|
5
35
|
|
|
6
|
-
|
|
7
|
-
Object.defineProperty(exports, "errorMessageHandling", {
|
|
8
|
-
enumerable: true,
|
|
9
|
-
get: function () { return tradetrustUtils.errorMessageHandling; }
|
|
10
|
-
});
|
|
11
36
|
Object.defineProperty(exports, "interpretFragments", {
|
|
12
37
|
enumerable: true,
|
|
13
38
|
get: function () { return tradetrustUtils.interpretFragments; }
|
|
14
39
|
});
|
|
40
|
+
exports.errorMessageHandling = errorMessageHandling;
|
|
41
|
+
exports.w3cCredentialStatusRevoked = w3cCredentialStatusRevoked;
|
|
42
|
+
exports.w3cCredentialStatusSuspended = w3cCredentialStatusSuspended;
|
|
@@ -4,13 +4,28 @@ var w3cVc = require('@trustvc/w3c-vc');
|
|
|
4
4
|
|
|
5
5
|
var __defProp = Object.defineProperty;
|
|
6
6
|
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
7
|
+
var W3CCredentialStatusCode = /* @__PURE__ */ ((W3CCredentialStatusCode2) => {
|
|
8
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["SKIPPED"] = 0] = "SKIPPED";
|
|
9
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_NOT_ISSUED"] = 1] = "DOCUMENT_NOT_ISSUED";
|
|
10
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_REVOKED"] = 11] = "DOCUMENT_REVOKED";
|
|
11
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_SUSPENDED"] = 12] = "DOCUMENT_SUSPENDED";
|
|
12
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_REVOKED_AND_SUSPENDED"] = 101] = "DOCUMENT_REVOKED_AND_SUSPENDED";
|
|
13
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["STATUS_LIST_NOT_FOUND"] = 404] = "STATUS_LIST_NOT_FOUND";
|
|
14
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["INVALID_VALIDATION_METHOD"] = 8] = "INVALID_VALIDATION_METHOD";
|
|
15
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["UNRECOGNIZED_DOCUMENT"] = 9] = "UNRECOGNIZED_DOCUMENT";
|
|
16
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["SERVER_ERROR"] = 500] = "SERVER_ERROR";
|
|
17
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["UNEXPECTED_ERROR"] = 4] = "UNEXPECTED_ERROR";
|
|
18
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["INVALID_ARGUMENT"] = 6] = "INVALID_ARGUMENT";
|
|
19
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["INVALID_ISSUERS"] = 7] = "INVALID_ISSUERS";
|
|
20
|
+
return W3CCredentialStatusCode2;
|
|
21
|
+
})(W3CCredentialStatusCode || {});
|
|
7
22
|
const w3cCredentialStatus = {
|
|
8
23
|
skip: /* @__PURE__ */ __name(async () => {
|
|
9
24
|
return {
|
|
10
25
|
type: "DOCUMENT_STATUS",
|
|
11
26
|
name: "W3CCredentialStatus",
|
|
12
27
|
reason: {
|
|
13
|
-
code: 0
|
|
28
|
+
code: 0 /* SKIPPED */,
|
|
14
29
|
codeString: "SKIPPED",
|
|
15
30
|
message: `Document does not have a valid credentialStatus or type.`
|
|
16
31
|
},
|
|
@@ -35,11 +50,17 @@ const w3cCredentialStatus = {
|
|
|
35
50
|
(cs) => w3cVc.verifyCredentialStatus(cs, cs?.type, verifierOptions)
|
|
36
51
|
)
|
|
37
52
|
);
|
|
53
|
+
const purposes = verificationResult.map((item) => item.purpose);
|
|
54
|
+
const hasRevocation = purposes.includes("revocation");
|
|
55
|
+
const hasSuspension = purposes.includes("suspension");
|
|
56
|
+
const hasRevocationAndSuspension = hasRevocation && hasSuspension;
|
|
38
57
|
if (verificationResult.some((r) => r.error)) {
|
|
39
58
|
return {
|
|
40
59
|
type: "DOCUMENT_STATUS",
|
|
41
60
|
name: "W3CCredentialStatus",
|
|
42
61
|
reason: {
|
|
62
|
+
code: 4 /* UNEXPECTED_ERROR */,
|
|
63
|
+
codeString: "ERROR",
|
|
43
64
|
message: verificationResult.map((r) => r.error).join(", ")
|
|
44
65
|
},
|
|
45
66
|
data: verificationResult,
|
|
@@ -57,10 +78,16 @@ const w3cCredentialStatus = {
|
|
|
57
78
|
type: "DOCUMENT_STATUS",
|
|
58
79
|
name: "W3CCredentialStatus",
|
|
59
80
|
data: verificationResult,
|
|
60
|
-
status: "INVALID"
|
|
81
|
+
status: "INVALID",
|
|
82
|
+
reason: {
|
|
83
|
+
code: hasRevocationAndSuspension ? 101 /* DOCUMENT_REVOKED_AND_SUSPENDED */ : hasRevocation ? 11 /* DOCUMENT_REVOKED */ : 12 /* DOCUMENT_SUSPENDED */,
|
|
84
|
+
codeString: hasRevocationAndSuspension ? "REVOKED_AND_SUSPENDED" : hasRevocation ? "REVOKED" : "SUSPENDED",
|
|
85
|
+
message: hasRevocationAndSuspension ? "Document has been revoked and suspended." : hasRevocation ? "Document has been revoked." : "Document has been suspended."
|
|
86
|
+
}
|
|
61
87
|
};
|
|
62
88
|
}
|
|
63
89
|
}, "verify")
|
|
64
90
|
};
|
|
65
91
|
|
|
92
|
+
exports.W3CCredentialStatusCode = W3CCredentialStatusCode;
|
|
66
93
|
exports.w3cCredentialStatus = w3cCredentialStatus;
|
|
@@ -1 +1,35 @@
|
|
|
1
|
-
|
|
1
|
+
import { CONSTANTS, errorMessageHandling as errorMessageHandling$1 } from '@tradetrust-tt/tradetrust-utils';
|
|
2
|
+
export { interpretFragments } from '@tradetrust-tt/tradetrust-utils';
|
|
3
|
+
import { utils } from '@tradetrust-tt/tt-verify';
|
|
4
|
+
import { W3CCredentialStatusCode } from '../../verify/fragments/document-status/w3cCredentialStatus';
|
|
5
|
+
|
|
6
|
+
var __defProp = Object.defineProperty;
|
|
7
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
8
|
+
const getW3CCredentialStatusFragment = utils.getFragmentByName(
|
|
9
|
+
"W3CCredentialStatus"
|
|
10
|
+
);
|
|
11
|
+
const w3cCredentialStatusRevoked = /* @__PURE__ */ __name((fragments) => {
|
|
12
|
+
const issuedFragment = getW3CCredentialStatusFragment(fragments);
|
|
13
|
+
return issuedFragment?.reason?.code === W3CCredentialStatusCode.DOCUMENT_REVOKED || issuedFragment?.reason?.code === W3CCredentialStatusCode.DOCUMENT_REVOKED_AND_SUSPENDED;
|
|
14
|
+
}, "w3cCredentialStatusRevoked");
|
|
15
|
+
const w3cCredentialStatusSuspended = /* @__PURE__ */ __name((fragments) => {
|
|
16
|
+
const issuedFragment = getW3CCredentialStatusFragment(fragments);
|
|
17
|
+
return issuedFragment?.reason?.code === W3CCredentialStatusCode.DOCUMENT_SUSPENDED || issuedFragment?.reason?.code === W3CCredentialStatusCode.DOCUMENT_REVOKED_AND_SUSPENDED;
|
|
18
|
+
}, "w3cCredentialStatusSuspended");
|
|
19
|
+
const errorMessageHandling = /* @__PURE__ */ __name((fragments) => {
|
|
20
|
+
const errors = [];
|
|
21
|
+
const isW3cFragments = fragments.some(
|
|
22
|
+
(f) => f.name.startsWith("W3C") || f.name === "TransferableRecords"
|
|
23
|
+
);
|
|
24
|
+
if (isW3cFragments) {
|
|
25
|
+
if (w3cCredentialStatusRevoked(fragments)) {
|
|
26
|
+
errors.push(CONSTANTS.TYPES.REVOKED);
|
|
27
|
+
}
|
|
28
|
+
if (w3cCredentialStatusSuspended(fragments)) {
|
|
29
|
+
errors.push(CONSTANTS.TYPES.SUSPENDED);
|
|
30
|
+
}
|
|
31
|
+
return errors;
|
|
32
|
+
} else return errorMessageHandling$1(fragments);
|
|
33
|
+
}, "errorMessageHandling");
|
|
34
|
+
|
|
35
|
+
export { errorMessageHandling, w3cCredentialStatusRevoked, w3cCredentialStatusSuspended };
|
|
@@ -2,13 +2,28 @@ import { verifyCredentialStatus, isSignedDocument } from '@trustvc/w3c-vc';
|
|
|
2
2
|
|
|
3
3
|
var __defProp = Object.defineProperty;
|
|
4
4
|
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
5
|
+
var W3CCredentialStatusCode = /* @__PURE__ */ ((W3CCredentialStatusCode2) => {
|
|
6
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["SKIPPED"] = 0] = "SKIPPED";
|
|
7
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_NOT_ISSUED"] = 1] = "DOCUMENT_NOT_ISSUED";
|
|
8
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_REVOKED"] = 11] = "DOCUMENT_REVOKED";
|
|
9
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_SUSPENDED"] = 12] = "DOCUMENT_SUSPENDED";
|
|
10
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["DOCUMENT_REVOKED_AND_SUSPENDED"] = 101] = "DOCUMENT_REVOKED_AND_SUSPENDED";
|
|
11
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["STATUS_LIST_NOT_FOUND"] = 404] = "STATUS_LIST_NOT_FOUND";
|
|
12
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["INVALID_VALIDATION_METHOD"] = 8] = "INVALID_VALIDATION_METHOD";
|
|
13
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["UNRECOGNIZED_DOCUMENT"] = 9] = "UNRECOGNIZED_DOCUMENT";
|
|
14
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["SERVER_ERROR"] = 500] = "SERVER_ERROR";
|
|
15
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["UNEXPECTED_ERROR"] = 4] = "UNEXPECTED_ERROR";
|
|
16
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["INVALID_ARGUMENT"] = 6] = "INVALID_ARGUMENT";
|
|
17
|
+
W3CCredentialStatusCode2[W3CCredentialStatusCode2["INVALID_ISSUERS"] = 7] = "INVALID_ISSUERS";
|
|
18
|
+
return W3CCredentialStatusCode2;
|
|
19
|
+
})(W3CCredentialStatusCode || {});
|
|
5
20
|
const w3cCredentialStatus = {
|
|
6
21
|
skip: /* @__PURE__ */ __name(async () => {
|
|
7
22
|
return {
|
|
8
23
|
type: "DOCUMENT_STATUS",
|
|
9
24
|
name: "W3CCredentialStatus",
|
|
10
25
|
reason: {
|
|
11
|
-
code: 0
|
|
26
|
+
code: 0 /* SKIPPED */,
|
|
12
27
|
codeString: "SKIPPED",
|
|
13
28
|
message: `Document does not have a valid credentialStatus or type.`
|
|
14
29
|
},
|
|
@@ -33,11 +48,17 @@ const w3cCredentialStatus = {
|
|
|
33
48
|
(cs) => verifyCredentialStatus(cs, cs?.type, verifierOptions)
|
|
34
49
|
)
|
|
35
50
|
);
|
|
51
|
+
const purposes = verificationResult.map((item) => item.purpose);
|
|
52
|
+
const hasRevocation = purposes.includes("revocation");
|
|
53
|
+
const hasSuspension = purposes.includes("suspension");
|
|
54
|
+
const hasRevocationAndSuspension = hasRevocation && hasSuspension;
|
|
36
55
|
if (verificationResult.some((r) => r.error)) {
|
|
37
56
|
return {
|
|
38
57
|
type: "DOCUMENT_STATUS",
|
|
39
58
|
name: "W3CCredentialStatus",
|
|
40
59
|
reason: {
|
|
60
|
+
code: 4 /* UNEXPECTED_ERROR */,
|
|
61
|
+
codeString: "ERROR",
|
|
41
62
|
message: verificationResult.map((r) => r.error).join(", ")
|
|
42
63
|
},
|
|
43
64
|
data: verificationResult,
|
|
@@ -55,10 +76,15 @@ const w3cCredentialStatus = {
|
|
|
55
76
|
type: "DOCUMENT_STATUS",
|
|
56
77
|
name: "W3CCredentialStatus",
|
|
57
78
|
data: verificationResult,
|
|
58
|
-
status: "INVALID"
|
|
79
|
+
status: "INVALID",
|
|
80
|
+
reason: {
|
|
81
|
+
code: hasRevocationAndSuspension ? 101 /* DOCUMENT_REVOKED_AND_SUSPENDED */ : hasRevocation ? 11 /* DOCUMENT_REVOKED */ : 12 /* DOCUMENT_SUSPENDED */,
|
|
82
|
+
codeString: hasRevocationAndSuspension ? "REVOKED_AND_SUSPENDED" : hasRevocation ? "REVOKED" : "SUSPENDED",
|
|
83
|
+
message: hasRevocationAndSuspension ? "Document has been revoked and suspended." : hasRevocation ? "Document has been revoked." : "Document has been suspended."
|
|
84
|
+
}
|
|
59
85
|
};
|
|
60
86
|
}
|
|
61
87
|
}, "verify")
|
|
62
88
|
};
|
|
63
89
|
|
|
64
|
-
export { w3cCredentialStatus };
|
|
90
|
+
export { W3CCredentialStatusCode, w3cCredentialStatus };
|
package/dist/types/index.d.ts
CHANGED
|
@@ -35,10 +35,11 @@ export { RawVerifiableCredential, SignedVerifiableCredential, SigningResult, Ver
|
|
|
35
35
|
export { PrivateKeyPair } from '@trustvc/w3c-issuer';
|
|
36
36
|
export { i as vc } from './index-1ws_BWZW.js';
|
|
37
37
|
export { verifyW3CSignature } from './w3c/verify.js';
|
|
38
|
-
export {
|
|
38
|
+
export { errorMessageHandling, w3cCredentialStatusRevoked, w3cCredentialStatusSuspended } from './utils/fragment/index.js';
|
|
39
39
|
export * from '@tradetrust-tt/tradetrust-utils/constants/network';
|
|
40
40
|
export { generate12ByteNonce, generate32ByteKey, stringToUint8Array } from './utils/stringUtils/index.js';
|
|
41
41
|
export * from '@tradetrust-tt/tradetrust-utils/constants/supportedChains';
|
|
42
|
+
export { GasStationFeeData, GasStationFunction, calculateMaxFee, CONSTANTS as errorMessages, gasStation, interpretFragments, scaleBigNumber } from '@tradetrust-tt/tradetrust-utils';
|
|
42
43
|
export { WrappedOrSignedOpenAttestationDocument, getChainId, getTokenId, getTokenRegistryAddress, getTransferableRecordsCredentialStatus, isTransferableRecord } from './utils/documents/index.js';
|
|
43
44
|
export { AwsKmsSigner, AwsKmsSignerCredentials } from '@tradetrust-tt/ethers-aws-kms-signer';
|
|
44
45
|
export { CustomDnsResolver, IDNSQueryResponse, IDNSRecord, OpenAttestationDNSTextRecord, OpenAttestationDnsDidRecord, defaultDnsResolvers, getDnsDidRecords, getDocumentStoreRecords, parseDnsDidResults, parseDocumentStoreResults, parseOpenAttestationRecord, queryDns } from '@tradetrust-tt/dnsprove';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export { TypedContractMethod } from '@tradetrust-tt/token-registry-v5/contracts/common';
|
|
2
2
|
import '@trustvc/w3c-vc';
|
|
3
3
|
import '@trustvc/w3c-issuer';
|
|
4
|
-
import '@tradetrust-tt/tradetrust-utils';
|
|
5
4
|
import '@tradetrust-tt/tradetrust-utils/constants/network';
|
|
6
5
|
import '@tradetrust-tt/tradetrust-utils/constants/supportedChains';
|
|
6
|
+
import '@tradetrust-tt/tradetrust-utils';
|
|
7
7
|
import '@tradetrust-tt/ethers-aws-kms-signer';
|
|
8
8
|
import '@tradetrust-tt/dnsprove';
|
|
@@ -1 +1,8 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { interpretFragments } from '@tradetrust-tt/tradetrust-utils';
|
|
2
|
+
import { VerificationFragment } from '@tradetrust-tt/tt-verify';
|
|
3
|
+
|
|
4
|
+
declare const w3cCredentialStatusRevoked: (fragments: VerificationFragment[]) => boolean;
|
|
5
|
+
declare const w3cCredentialStatusSuspended: (fragments: VerificationFragment[]) => boolean;
|
|
6
|
+
declare const errorMessageHandling: (fragments: VerificationFragment[]) => string[];
|
|
7
|
+
|
|
8
|
+
export { errorMessageHandling, w3cCredentialStatusRevoked, w3cCredentialStatusSuspended };
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { errorMessageHandling, w3cCredentialStatusRevoked, w3cCredentialStatusSuspended } from './fragment/index.js';
|
|
2
2
|
export * from '@tradetrust-tt/tradetrust-utils/constants/network';
|
|
3
3
|
export { generate12ByteNonce, generate32ByteKey, stringToUint8Array } from './stringUtils/index.js';
|
|
4
4
|
export * from '@tradetrust-tt/tradetrust-utils/constants/supportedChains';
|
|
5
|
+
export { GasStationFeeData, GasStationFunction, calculateMaxFee, CONSTANTS as errorMessages, gasStation, interpretFragments, scaleBigNumber } from '@tradetrust-tt/tradetrust-utils';
|
|
5
6
|
export { WrappedOrSignedOpenAttestationDocument, getChainId, getTokenId, getTokenRegistryAddress, getTransferableRecordsCredentialStatus, isTransferableRecord } from './documents/index.js';
|
|
6
7
|
export { AwsKmsSigner, AwsKmsSignerCredentials } from '@tradetrust-tt/ethers-aws-kms-signer';
|
|
8
|
+
import '@tradetrust-tt/tt-verify';
|
|
7
9
|
import '@tradetrust-tt/tradetrust';
|
|
8
10
|
import '@trustvc/w3c-credential-status';
|
|
9
11
|
import '@trustvc/w3c-vc';
|
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
import { Verifier, VerificationFragment } from '@tradetrust-tt/tt-verify';
|
|
2
2
|
|
|
3
|
+
declare enum W3CCredentialStatusCode {
|
|
4
|
+
SKIPPED = 0,
|
|
5
|
+
DOCUMENT_NOT_ISSUED = 1,
|
|
6
|
+
DOCUMENT_REVOKED = 11,
|
|
7
|
+
DOCUMENT_SUSPENDED = 12,
|
|
8
|
+
DOCUMENT_REVOKED_AND_SUSPENDED = 101,
|
|
9
|
+
STATUS_LIST_NOT_FOUND = 404,
|
|
10
|
+
INVALID_VALIDATION_METHOD = 8,
|
|
11
|
+
UNRECOGNIZED_DOCUMENT = 9,
|
|
12
|
+
SERVER_ERROR = 500,
|
|
13
|
+
UNEXPECTED_ERROR = 4,
|
|
14
|
+
INVALID_ARGUMENT = 6,
|
|
15
|
+
INVALID_ISSUERS = 7
|
|
16
|
+
}
|
|
3
17
|
declare const w3cCredentialStatus: Verifier<VerificationFragment>;
|
|
4
18
|
|
|
5
|
-
export { w3cCredentialStatus };
|
|
19
|
+
export { W3CCredentialStatusCode, w3cCredentialStatus };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trustvc/trustvc",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.4",
|
|
4
4
|
"description": "TrustVC library",
|
|
5
5
|
"main": "dist/cjs/index.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|
|
@@ -115,7 +115,7 @@
|
|
|
115
115
|
"@tradetrust-tt/token-registry-v4": "npm:@tradetrust-tt/token-registry@^4.16.0",
|
|
116
116
|
"@tradetrust-tt/token-registry-v5": "npm:@tradetrust-tt/token-registry@^5.3.0",
|
|
117
117
|
"@tradetrust-tt/tradetrust": "^6.10.1",
|
|
118
|
-
"@tradetrust-tt/tradetrust-utils": "^2.3.
|
|
118
|
+
"@tradetrust-tt/tradetrust-utils": "^2.3.2",
|
|
119
119
|
"@tradetrust-tt/tt-verify": "^9.4.0",
|
|
120
120
|
"@trustvc/w3c-context": "^1.2.13",
|
|
121
121
|
"@trustvc/w3c-credential-status": "^1.2.12",
|