crypto-inventory 0.3.0: glob imports resolved, libcrux and spqr, libsignal KEM key pairs; control-plane: a key agreement or client-side TLS called by the application itself is not routed to the TLS gateway (planner 35/35, B1 negative control 4/4)

This commit is contained in:
Aere Network committed 2026-10-18 05:59:35 +03:00
1 parent f2f6217b4c
commit f971fa9e28
11 files changed
+161 -30

No files matched your search

+14
View File
@@ -19,6 +19,11 @@ const inventory = [
{ ref: 'algorithm:mlkem', assetType: 'algorithm', name: 'ML-KEM-768', primitive: 'kem', quantumVulnerable: false },
{ ref: 'algorithm:mldsa', assetType: 'algorithm', name: 'ML-DSA-65', primitive: 'signature', quantumVulnerable: false },
{ ref: 'algorithm:aes', assetType: 'algorithm', name: 'AES-256-GCM', primitive: 'ae', quantumVulnerable: false },
// 2026-10-18 (Avano): criptografie chemata de aplicatie, cu limbajul si API-ul din inventarul real; si un ECDH din configuratia TLS a codului
{ ref: 'cod:x25519:rust', assetType: 'algorithm', name: 'X25519', primitive: 'key-agree', quantumVulnerable: true, language: 'rust', api: 'StaticSecret::random_from_rng', location: 'src/ratchet.rs:10' },
{ ref: 'cod:ed25519:rust', assetType: 'algorithm', name: 'Ed25519', primitive: 'signature', quantumVulnerable: true, language: 'rust', api: 'SigningKey::generate', location: 'src/sign.rs:5' },
{ ref: 'cod:tls:go', assetType: 'algorithm', name: 'ECDH-secp256r1', primitive: 'key-agree', quantumVulnerable: true, language: 'go', api: 'tls.Config.CurvePreferences', protocolType: undefined, location: 'main.go:30' },
{ ref: 'cod:tls-client:rust', assetType: 'algorithm', name: 'X25519', primitive: 'key-agree', quantumVulnerable: true, language: 'rust', api: 'rustls::crypto::ring::default_provider', location: 'src/http.rs:12' },
];
// 2026-09-27: constatarile de scanare se DERIVA din sursa scanerului (readiness-service.mjs, apelurile lui add(id, severitate,
// titlu)), nu se scriu de mana. Fixtura veche folosea id-uri inventate ('tls-kex-classical', 'tls12-enabled'), deci proba era verde
@@ -49,6 +54,15 @@ cer('certificatul WebPKI public e BLOCAT (niciun CA public PQ), nu se pretinde a
cer('scanarea: schimbul de cheie clasic e in plan, auto prin gateway', byRef['tls-kex:client.exemplu.com'] && byRef['tls-kex:client.exemplu.com'].product === 'gateway');
cer('scanarea: TLS 1.2 e in plan, manual (config)', byRef['tls-conf:client.exemplu.com:tls12-accepted'] && byRef['tls-conf:client.exemplu.com:tls12-accepted'].method === 'manual');
// 2026-10-18 (Avano): criptografia chemata de aplicatie nu se repara cu gateway-ul sau cu PKI-ul; cea din configuratia TLS, da
const xc = byRef['cod:x25519:rust'], ec = byRef['cod:ed25519:rust'], tc = byRef['cod:tls:go'];
cer('X25519 chemat din cod (ratchet) -> manual, in cod, tinta hibrida cu ML-KEM-768, fara gateway', xc && xc.method === 'manual' && !xc.product && /ML-KEM-768/.test(xc.target) && /gateway in front cannot/.test(xc.how) && /StaticSecret/.test(xc.how));
cer('Ed25519 pe date de aplicatie -> PKI emite cheia hibrida, iar how spune ca aplicatia trebuie sa o adopte (schimbare de cod)', ec && ec.product === 'pki' && /ML-DSA/.test(ec.target) && /code change/.test(ec.how) && /call site/.test(ec.how));
cer('CONTROL: ECDH din configuratia TLS a codului ramane auto prin gateway', tc && tc.product === 'gateway' && tc.method === 'auto-aere');
cer('HNDL ramane si in cod: X25519 HIGH, Ed25519 MEDIUM', xc && ec && xc.urgency === 'HIGH' && ec.urgency === 'MEDIUM');
const cl = byRef['cod:tls-client:rust'];
cer('TLS de client din cod (rustls ring provider) -> manual, furnizorul hibrid in client, fara gateway', cl && cl.method === 'manual' && !cl.product && /X25519MLKEM768/.test(cl.target) && /aws-lc-rs/.test(cl.how) && /does not change what this client offers/.test(cl.how));
// controale negative: ce NU trebuie sa fie in plan
cer('CONTROL: ML-KEM (deja PQ) NU e in plan', !byRef['algorithm:mlkem']);
cer('CONTROL: ML-DSA (deja PQ) NU e in plan', !byRef['algorithm:mldsa']);