identity: the SD-JWT form of an AERE hybrid identity is judged on its ML-DSA-65 half by default, the Ed25519 half only on explicit request, and every verdict says postQuantum (rule sdjwt.hybrid-half); pq-pki: the signature algorithm a certificate or a revocation list declares must be its issuer key's (ALG_KEY, CRL_ALG_KEY); agents: an equivocation proof requires the agent's ML-DSA-65 key; pq-gateway: the status names the path to the backend and hybrid-only refuses a plain-HTTP backend; conformance 241 rules, 631 vectors

This commit is contained in:
Aere Network committed 2026-10-19 05:19:21 +03:00
1 parent 3ff21f7758
commit 0c8f1de3fd
122 files changed
+1205 -262

No files matched your search

+5 -2
View File
@@ -182,7 +182,9 @@ async function judeca(artifact, input, online) {
const vc = artifact === 'sdjwt-vc-presentation';
const M = await incarca(vc ? 'sdjwtvc' : 'sdjwt'); const RB = VERIFICATOARE.sdjwt.reguli, RV = VERIFICATOARE['sdjwt-vc'].reguli;
if (typeof input.now !== 'string') throw new Error('an SD-JWT presentation is judged on the verifier\'s clock: input.now (an RFC 3339 time) is required');
const o = { now: input.now }; for (const k of ['issuerKey', 'issuerAlg', 'audience', 'nonce', 'expectedIssuer', 'requireKeyBinding', 'requireExp', 'maxAgeS', 'expectedTyp', 'expectedVct', 'statusListJwt', 'statusListKey', 'statusListAlg', 'requireStatus']) if (input[k] !== undefined) o[k] = input[k];
// 2026-10-19 (AIP-25 C1): classicalHalf, which the verifier brings (the Ed25519 half of AERE keys judged on request), is passed too: a
// field this adapter does not name never reaches the verifier
const o = { now: input.now }; for (const k of ['issuerKey', 'issuerAlg', 'classicalHalf', 'audience', 'nonce', 'expectedIssuer', 'requireKeyBinding', 'requireExp', 'maxAgeS', 'expectedTyp', 'expectedVct', 'statusListJwt', 'statusListKey', 'statusListAlg', 'requireStatus']) if (input[k] !== undefined) o[k] = input[k];
const r = vc ? M.verifySdJwtVc(input.sdJwt, o) : M.verifySdJwt(input.sdJwt, o);
if (r.valid !== (r.rule == null)) throw new Error('the SD-JWT verifier refused without naming a rule');
if (!r.valid) {
@@ -190,7 +192,8 @@ async function judeca(artifact, input, online) {
pica(acc, m[1], m[0], r.reason); nemasurat(acc, m[1] === 'integrity' ? 'authenticity' : 'integrity', 'not-reached', 'the verifier stopped at its first refusal');
} else {
trece(acc, 'integrity', `no rule of the SD-JWT${vc ? ' VC' : ''} verifier refused: ${r.disclosed.length} disclosure(s) bound to the issuer-signed JWT${vc ? ', vct ' + r.vct : ''}`);
trece(acc, 'authenticity', `the issuer-signed JWT verifies (${r.alg}) with the issuer key the verifier gave` + (r.keyBinding ? `; the key binding JWT (${r.keyBinding.alg}) verifies with cnf.jwk for this audience and nonce` : '; no key binding (the verifier did not require one)'));
trece(acc, 'authenticity', `the issuer-signed JWT verifies (${r.alg}) with the issuer key the verifier gave` + (r.keyBinding ? `; the key binding JWT (${r.keyBinding.alg}) verifies with cnf.jwk for this audience and nonce` : '; no key binding (the verifier did not require one)')
+ (r.postQuantum === true ? '; every signature judged is post-quantum (ML-DSA-65)' : r.postQuantum === false ? '; NOT post-quantum: a signature judged is classical' : ''));
if (vc && r.status && r.status.present && !r.status.judged) nemasurat(acc, 'integrity', 'claim-not-checked', `the credential names a status (${r.status.mechanism}${r.status.uri ? ' at ' + r.status.uri : ''}) and no list was judged: the verifier waived it`);
}
for (const l of ['anchoring', 'finality']) nemasurat(acc, l, 'not-judged', 'an SD-JWT is anchored by notarizing an AIP-23 envelope of it, judged as the artifact `envelope`');