Add crypto-inventory: a cryptographic inventory of source code as a CycloneDX 1.6 CBOM, with linear cost on hostile input; PKI DER messages in English

This commit is contained in:
Aere Network committed 2026-09-29 17:42:36 +03:00
1 parent 7d814d1bb8
commit 0f081f0847
49 files changed
+4342 -33

No files matched your search

+1 -1
View File
@@ -243,7 +243,7 @@ function parseExtensions(seqEl, what) {
export function parseCert(der) {
const top = D.parse(der);
D.expect(top, D.TAG.SEQUENCE, 'certificat');
D.expect(top, D.TAG.SEQUENCE, 'certificate');
const [tbsEl, algEl, sigEl, ...rest] = D.children(top);
if (rest.length || !sigEl) throw new PkiError('DER', 'a certificate has exactly three parts');
const t = D.children(D.expect(tbsEl, D.TAG.SEQUENCE, 'tbsCertificate'));