API index

Every documented primitive, grouped by namespace page — 349 primitives. Generated from the same source comments that build the rest of this site.

Constants

PrimitiveSinceStatus
C.TIME.days(n) -> milliseconds0.1.0stable
C.BYTES.mib(n) -> bytes0.1.0stable

Errors

PrimitiveSinceStatus
new PkiError(message, code)0.1.0stable
pki.errors.defineClass(name, opts?) -> constructor0.1.0stable

ASN.1 / DER

PrimitiveSinceStatus
pki.asn1.decode(bytes, opts?) -> node0.1.0stable
pki.asn1.read.oid(node) -> "1.2.840.113549.1.1.11"0.1.15stable
pki.asn1.encode(classBits, constructed, tagNumber, content) -> Buffer0.1.0stable
pki.asn1.build.sequence([ ...tlvBuffers ]) -> Buffer0.1.0stable

CBOR (deterministic)

PrimitiveSinceStatus
pki.cbor.decode(bytes, opts?) -> node0.1.27stable
pki.cbor.read.uint(node) -> 0n0.1.27stable
pki.cbor.read.nint(node) -> -1n0.1.27stable
pki.cbor.read.int(node) -> -1n0.1.27stable
pki.cbor.read.byteString(node) -> Buffer0.1.27stable
pki.cbor.read.textString(node) -> "text"0.1.27stable
pki.cbor.read.array(node) -> [node, ...]0.1.27stable
pki.cbor.read.map(node) -> [[keyNode, valueNode], ...]0.1.27stable
pki.cbor.read.mapGet(node, key) -> valueNode | null0.2.20stable
pki.cbor.read.boolean(node) -> false0.1.27stable
pki.cbor.read.nullValue(node) -> null0.1.27stable
pki.cbor.read.undefinedValue(node) -> undefined0.1.27stable
pki.cbor.read.float(node) -> 1.50.1.27stable
pki.cbor.read.biguint(node) -> 18446744073709551616n0.1.27stable
pki.cbor.read.time(node) -> Date0.1.27stable
pki.cbor.read.oid(node) -> "2.5.4.3"0.1.27stable

Object Identifiers

PrimitiveSinceStatus
pki.oid.name(dotted) -> string | undefined0.1.0stable
pki.oid.register(dotted, name) -> void0.1.0stable
pki.oid.registerFamily(base, members) -> void0.1.2stable
pki.oid.paramsMustBeAbsent(dotted) -> boolean0.1.21stable

WebCrypto

PrimitiveSinceStatus
new pki.webcrypto.CryptoKey(type, extractable, algorithm, usages, handle)0.1.0stable
await pki.webcrypto.subtle.exportKey(format, key)0.1.0stable
pki.webcrypto.getRandomValues(typedArray) / pki.webcrypto.subtle0.1.0stable

CMC

PrimitiveSinceStatus
pki.cmc.verify(response, sent?) -> Promise<verdict>0.4.16stable
pki.cmc.build(spec, signer, opts?) -> Promise<Buffer|string>0.4.16stable
pki.schema.cmc.parsePkiData(der, caps?) -> parsed0.4.16stable
pki.schema.cmc.parsePkiResponse(der, caps?) -> parsed0.4.16stable
pki.schema.cmc.parse(input, caps?) -> parsed0.4.16stable

Possession statements

PrimitiveSinceStatus
pki.possession.parse(value) -> { signer, certificate }0.8.44stable
pki.possession.verifyRequest(request, opts) -> Promise<verdict>0.8.44stable

PKCS#11 URI

PrimitiveSinceStatus
pki.pkcs11.parseUri(uri) -> parsed0.8.7stable
pki.pkcs11.formatUri(record) -> string0.8.7stable

CMS DigestedData

PrimitiveSinceStatus
pki.cms.digest(content, opts?) -> Promise<Buffer|string>0.8.1stable
pki.cms.verifyDigest(input, opts?) -> Promise<verdict>0.8.1stable

Service identity (RFC 9525)

PrimitiveSinceStatus
pki.identity.match(cert, references, opts?) -> verdict0.8.8stable

Certification path validation (RFC 5280 6)

PrimitiveSinceStatus
pki.path.validate(path, opts) -> Promise<result>0.1.16stable
pki.path.crlChecker(crls, opts?) -> RevocationChecker0.1.16stable
pki.path.ocspChecker(responses) -> RevocationChecker0.1.32stable
pki.path.verifyOcspResponse(response, cert, issuerCert, time, opts?) -> Promise<{ valid, status, responderAuthorized, signatureValid, matched, nonceMatched, thisUpdate, nextUpdate, revocationReason?, revocationTime?, reason }>0.2.22stable
pki.path.anchorFromCert(cert) -> { name, publicKey, algorithm, parameters, subjectDer }stable
pki.path.build(leaf, opts) -> Promise<{ valid, path, trustAnchor, result, candidatesConsidered, aiaFetches }>0.3.7stable

Trust-store ingestion

PrimitiveSinceStatus
pki.trust.parseCertdata(text) -> { anchors }0.2.0stable
pki.trust.parseCcadbCsv(text) -> { anchors }0.2.0stable
pki.trust.anchor(entry, opts?) -> trustAnchor0.2.0stable
pki.trust.parseTrustAnchorList(input, opts?) -> { anchors }0.8.13stable
pki.trust.discoversBundles(platform) -> boolean0.8.15stable
pki.trust.systemAnchors(opts?) -> { anchors, source, path, skipped }0.8.15stable

JOSE (JWS / JWK)

PrimitiveSinceStatus
pki.jose.base64url.encode(bytes) -> string0.1.25stable
pki.jose.base64url.decode(text) -> Buffer0.1.25stable
pki.jose.parseJson(input) -> value0.1.25stable
pki.jose.assertPublicJwk(jwk) -> jwk0.1.25stable
pki.jose.verify(jws, opts) -> Promise<{ header, payload, keySource }>0.1.25stable
pki.jose.sign(opts) -> Promise<{ protected, payload, signature }>0.1.25stable
pki.jose.thumbprint(jwk) -> Promise<string>0.1.25stable
pki.jose.sigAlgs() -> Array<{alg,kty,crv,hash,saltLength}>0.5.3stable

ACME

PrimitiveSinceStatus
pki.acme.assertTransition(kind, from, to) -> void0.1.25stable
pki.acme.validateProblem(obj) -> obj0.1.25stable
pki.acme.validate(kind, obj) -> obj0.1.25stable
pki.acme.identify(obj) -> string0.1.25stable
pki.acme.keyAuthorization(token, accountJwk) -> Promise<string>0.1.25stable
pki.acme.http01(token, accountJwk) -> Promise<{ path, body }>0.1.25stable
pki.acme.dns01(token, accountJwk, domain) -> Promise<{ name, value }>0.1.25stable
pki.acme.tlsAlpn01Extension(token, accountJwk) -> Promise<Buffer>0.1.25stable
pki.acme.verifyTlsAlpn01(certDer, token, accountJwk, identifier) -> Promise<void>0.1.25stable
pki.acme.postAsGet(opts) -> Promise<object>0.1.25stable
pki.acme.newAccount(opts) -> Promise<object>0.1.25stable
pki.acme.externalAccountBinding(opts) -> Promise<object>0.1.25stable
pki.acme.newOrder(opts) -> Promise<object>0.1.25stable
pki.acme.newAuthz(opts) -> flattened JWS0.3.29stable
pki.acme.finalize(opts) -> Promise<object>0.1.25stable
pki.acme.challengeResponse(opts) -> Promise<object>0.1.25stable
pki.acme.deactivate(opts) -> Promise<object>0.1.25stable
pki.acme.updateAccount(opts) -> Promise<object>0.6.4stable
pki.acme.revokeCert(opts) -> Promise<object>0.1.25stable
pki.acme.keyChange(opts) -> Promise<object>0.1.25stable
pki.acme.ariCertId(certDer) -> string0.1.25stable
pki.acme.parseAriCertId(certId) -> { keyIdentifier, serial }0.1.25stable
pki.acme.validateRenewalInfo(obj) -> obj0.1.25stable
pki.acme.client(directoryUrl, opts) -> client0.3.18stable

HPKE

PrimitiveSinceStatus
pki.hpke.setupS(suiteIds, recipientPublicKey, opts?) -> { enc, context, sharedSecret }0.2.2stable
pki.hpke.setupR(suiteIds, enc, recipientPrivateKey, opts?) -> context0.2.2stable
pki.hpke.seal(suiteIds, recipientPublicKey, opts, aad, pt) -> { enc, ct }0.2.2stable
pki.hpke.open(suiteIds, enc, recipientPrivateKey, opts, aad, ct) -> pt0.2.2stable
pki.hpke.deriveKeyPair(kemId, ikm) -> { publicKey, privateKey }0.8.45stable
pki.hpke.generateKeyPair(kemId) -> { publicKey, privateKey }0.8.45stable
pki.hpke.encap(kemId, recipientPublicKey) -> { enc, sharedSecret }0.8.45stable
pki.hpke.decap(kemId, enc, recipientPrivateKey) -> sharedSecret0.8.45stable

Composite ML-KEM

PrimitiveSinceStatus
pki.kem.decapsulate(privateKey, ciphertext) -> Promise<Buffer>0.6.6stable
pki.kem.encapsulate(publicKey) -> Promise<{ sharedSecret: Buffer, ciphertext: Buffer }>0.6.6stable

Transport

PrimitiveSinceStatus
pki.transport.https(defaults?) -> transport0.3.16stable
pki.transport.peerChain(request, defaults?) -> Promise<channel>0.8.32stable

OCSP

PrimitiveSinceStatus
pki.ocsp.buildRequest(query, opts?) -> Buffer | string0.2.22stable
pki.ocsp.sign(responseData, responder, opts?) -> Promise<Buffer | string>0.2.22stable
pki.ocsp.buildErrorResponse(status) -> Buffer0.2.22stable
pki.ocsp.verify(response, opts) -> Promise<{ valid, status, responderAuthorized, signatureValid, matched, thisUpdate, nextUpdate, revocationReason?, revocationTime?, nonceMatched?, reason }>0.2.22stable
pki.ocsp.verifyRequest(request, opts?) -> Promise<{ valid, signed, signatureValid, requestorNamed, signerCert, signerCerts, certs, signerSubject, requestorName, requestList, requestExtensions, version, reason }>0.6.0stable
pki.ocsp.httpRequest(der, responderUrl, opts?) -> { method, url, headers, body }0.8.8stable
pki.schema.ocsp.parseRequest(input, caps?) -> ocspRequest0.1.11stable
pki.schema.ocsp.parseResponse(input, caps?) -> ocspResponse0.1.11stable
pki.schema.ocsp.pemDecode(text, label?) -> Buffer0.1.11stable
pki.schema.ocsp.pemEncode(der, label?) -> string0.1.23stable

Schema

PrimitiveSinceStatus
pki.schema.all() -> string[]0.1.7stable
pki.schema.parse(input, caps?) -> parsed0.1.7stable
pki.schema.detectFormat(input) -> string | null0.3.8stable
pki.schema.pem.decodeBundle(text, opts) -> [{ index, offset, label, der }]0.8.8stable
pki.schema.pem.encodeBundle(objects) -> string0.8.8stable

Schema engine

PrimitiveSinceStatus
pki.schema.engine.walk(schema, node, ctx) -> value0.1.7stable
pki.schema.engine.encode(schema, value, ctx) -> Buffer0.1.17stable
pki.schema.engine.embeddedDer(schema, bytes, ctx, opts?) -> value0.1.18stable

C509

PrimitiveSinceStatus
pki.schema.c509.parse(bytes, caps?) -> { certificateType, serialNumber, serialNumberHex, ... }0.2.30stable
pki.schema.c509.encode(input[, opts]) -> Buffer0.3.4stable

X.509

PrimitiveSinceStatus
pki.schema.x509.pemDecode(text, label?) -> Buffer0.1.7stable
pki.schema.x509.pemEncode(der, label) -> string0.1.7stable
pki.schema.x509.parse(input, caps?) -> certificate0.1.7stable
pki.schema.x509.decodeExtensions(certOrBytes, opts?) -> rows0.8.11stable
pki.schema.x509.decodeExtension(ext, opts?) -> row0.8.11stable
pki.x509.sign(spec, issuer, opts?) -> Promise<Buffer|string>0.3.0stable
pki.x509.randomSerial() -> BigInt0.7.12stable
pki.x509.extension(name, value, opts?) -> Buffer0.7.33stable
pki.x509.parseDn(dn) -> { rdns, dn, bytes }0.8.2stable

PKCS#8

PrimitiveSinceStatus
pki.schema.pkcs8.parse(input, caps?) -> privateKey0.1.9stable
pki.schema.pkcs8.parseEncrypted(input, caps?) -> encrypted0.1.9stable
pki.schema.pkcs8.pemDecode(text, label?) -> Buffer0.1.9stable
pki.schema.pkcs8.pemEncode(der, label?) -> string0.1.9stable

PKCS#1

PrimitiveSinceStatus
pki.schema.pkcs1.parse(input, opts) -> key0.8.8stable
pki.schema.pkcs1.parsePublic(input, opts) -> key0.8.8stable
pki.schema.pkcs1.encode(key) -> Buffer0.8.8stable
pki.schema.pkcs1.encodePublic(key) -> Buffer0.8.8stable

SEC1

PrimitiveSinceStatus
pki.schema.sec1.parse(input, opts) -> key0.8.8stable
pki.schema.sec1.encode(key) -> Buffer0.8.8stable

TSP

PrimitiveSinceStatus
pki.schema.tsp.parseRequest(input, caps?) -> timeStampReq0.2.19stable
pki.schema.tsp.parseTstInfo(input, caps?) -> tstInfo0.1.13stable
pki.schema.tsp.parse(input, caps?) -> timeStampResp0.1.13stable
pki.schema.tsp.parseToken(input, caps?) -> tstInfo0.1.13stable
pki.schema.tsp.pemDecode(text, label?) -> Buffer0.1.13stable
pki.schema.tsp.pemEncode(der, label) -> string0.1.23stable
pki.tsp.sign(messageImprint, tsa, opts) -> Promise<Buffer|string>0.2.15stable
pki.tsp.request(messageImprint, opts) -> Buffer|string0.2.19stable
pki.tsp.parseRequest(input) -> timeStampReq0.2.19stable
pki.tsp.response(token, opts) -> Buffer|string0.2.19stable
pki.tsp.parseResponse(input) -> timeStampResp0.2.19stable
pki.tsp.verify(token, data, opts) -> Promise<result>0.2.19stable

Trust anchors

PrimitiveSinceStatus
pki.schema.trustanchor.parse(input, caps?) -> trustAnchorList0.8.13stable
pki.schema.trustanchor.parseInfo(input, caps?) -> trustAnchorInfo0.8.13stable
pki.schema.trustanchor.pemDecode(text, label?) -> Buffer0.8.13stable
pki.schema.trustanchor.pemEncode(der, label?) -> string0.8.13stable

S/MIME (ESS)

PrimitiveSinceStatus
pki.schema.smime.parseSigningCertificate(der, caps?) -> { certs, policies }0.1.22stable
pki.schema.smime.parseSigningCertificateV2(der) -> { certs, policies }0.1.22stable
pki.schema.smime.parseSmimeCapabilities(der, caps?) -> { capabilities }0.1.22stable
pki.schema.smime.buildSigningCertificateV2(certs, opts?) -> Buffer0.8.52stable
pki.schema.smime.decodeAttribute(attr) -> { kind, ... }0.1.22stable
pki.smime.sign(content, signers, opts?) -> Promise<Buffer>0.2.25stable
pki.smime.verify(message, opts?) -> Promise<{ valid, trusted, signers, form, content, micalg, sender, protectedHeaders, headerProtection }>0.2.25stable
pki.smime.encrypt(content, recipients, opts?) -> Promise<Buffer>0.2.26stable
pki.smime.decrypt(message, keyMaterial, opts?) -> Promise<{ content, smimeType, authenticated, recipientType, recipientIndex, contentEncryptionAlgorithm, protectedHeaders, headerProtection }>0.2.26stable
pki.smime.compress(content, opts?) -> Promise<Buffer>0.2.27stable
pki.smime.decompress(message, opts?) -> Promise<{ content, contentType, contentTypeName, compressionAlgorithm }>0.2.27stable
pki.smime.buildCertsOnly(certs, opts?) -> Buffer0.6.3stable

CSR Attributes

PrimitiveSinceStatus
pki.schema.csrattrs.parse(der, caps?) -> { items }0.1.24stable

EST

PrimitiveSinceStatus
pki.est.transferDecode(body) -> Buffer0.1.24stable
pki.est.transferEncode(der) -> string0.1.24stable
pki.est.parseCertsOnly(der) -> { certificates, crls }0.1.24stable
pki.est.classifyResponse(status, headers, body, opts?) -> verdict0.1.24stable
pki.est.paths(baseUrl, opts?) -> { cacerts, simpleenroll, ... }0.1.24stable
pki.est.challengePasswordFromTlsUnique(channelBinding) -> Buffer0.6.31stable
pki.est.fullcmc(baseUrl, request, opts?) -> Promise<verdict | { retry, retryAfterSeconds }>0.4.16stable
pki.est.cacerts(baseUrl, opts?) -> Promise<{ certificates, crls } | { retry, retryAfterSeconds }>0.3.16stable
pki.est.simpleenroll(baseUrl, csr | builder, opts?) -> Promise<{ certificate, chain, certificates } | { retry, retryAfterSeconds }>0.3.16stable
pki.est.simplereenroll(baseUrl, csr | builder, opts?) -> Promise<{ certificate, chain, certificates } | { retry, retryAfterSeconds }>0.3.16stable
pki.est.serverkeygen(baseUrl, csr, opts?) -> Promise<{ certificates, privateKey } | { certificates, encryptedKey } | { retry, retryAfterSeconds, retryAfterDate }>0.3.28stable
pki.est.csrattrs(baseUrl, opts?) -> Promise<{ available: true, attrs, plan } | { available: false, attrs: null }>0.3.28stable

SCEP

PrimitiveSinceStatus
pki.scep.build(spec) -> Promise<Buffer>0.6.2stable
pki.scep.parse(bytes, opts?) -> Promise<verdict>0.6.2stable
pki.scep.parseCapabilities(text) -> { AES?, "SHA-256"?, POSTPKIOperation?, ... }0.6.7stable
pki.scep.getCACaps(baseUrl, opts?) -> Promise<capabilities>0.6.7stable
pki.scep.getCACert(baseUrl, opts?) -> Promise<{ caCertificate, certificates }>0.6.7stable
pki.scep.getNextCACert(baseUrl, opts) -> Promise<{ certificates }>0.6.14stable
pki.scep.enroll(baseUrl, opts) -> Promise<{ status, certificate?, certificates?, transactionId }>0.6.7stable
pki.scep.renew(baseUrl, opts) -> Promise<{ status, certificate?, certificates?, transactionId }>0.6.7stable
pki.scep.getCert(baseUrl, opts) -> Promise<{ certificate, certificates, transactionId }>0.6.17stable
pki.scep.getCrl(baseUrl, opts) -> Promise<{ crl, crls, transactionId }>0.6.17stable

Stateful hash-based

PrimitiveSinceStatus
pki.shbs.verify(publicKey, message, signature) -> boolean0.2.1stable
pki.shbs.verifyLms(publicKey, message, signature) -> boolean0.2.1stable

Attribute certificates

PrimitiveSinceStatus
pki.attrcert.sign(spec, issuer, opts?) -> Promise<Buffer|string>0.3.2stable
pki.attrcert.verify(ac, issuer, opts) -> Promise<{ valid, verified, signatureValid, validityChecked, targetingChecked, revocationChecked, noRevAvail, holderBindingChecked, issuerPathChecked, holder, issuer, attributes, extensions, notBefore, notAfter, serialNumberHex, reason }>0.5.15stable
pki.schema.attrcert.parse(input, caps?) -> attributeCertificate0.1.14stable
pki.schema.attrcert.pemDecode(text, label?) -> Buffer0.1.14stable
pki.schema.attrcert.pemEncode(der, label?) -> string0.1.23stable
pki.schema.attrcert.decodeExtensions(acOrBytes, opts?) -> rows0.8.11stable
pki.schema.attrcert.decodeExtension(ext, opts?) -> row0.8.11stable

Certificate management protocol messages

PrimitiveSinceStatus
pki.cmp.build(message, opts?) -> Promise<Buffer|string>0.3.5stable
pki.cmp.transfer(url, message, opts?) -> Promise<{ response, responseBytes, status, contentType, tls }>0.3.19stable
pki.cmp.wellKnownUrl(base, opts?) -> string0.3.19stable
pki.schema.cmp.parse(input, caps?) -> pkiMessage0.1.19stable
pki.schema.cmp.pemDecode(text, label?) -> Buffer0.1.19stable
pki.schema.cmp.pemEncode(der, label?) -> string0.1.19stable

CRLs

PrimitiveSinceStatus
pki.crl.sign(spec, issuer, opts?) -> Promise<Buffer|string>0.3.9stable
pki.crl.verify(crl, issuer) -> Promise<{ valid, issuerMaySign, signatureValid, issuer, code?, reason? }>0.3.9stable
pki.crl.isRevoked(crl, serialNumber, opts?) -> entry | null0.3.9stable
pki.schema.crl.parse(input, caps?) -> crl0.1.7stable
pki.schema.crl.pemDecode(text, label?) -> Buffer0.1.7stable
pki.schema.crl.pemEncode(der, label?) -> string0.1.23stable
pki.schema.crl.decodeExtensions(crlOrBytes, opts?) -> rows0.8.11stable
pki.schema.crl.decodeExtension(ext, opts) -> row0.8.11stable

Certificate request messages

PrimitiveSinceStatus
pki.crmf.build(spec, key?, opts?) -> Promise<Buffer|string>0.3.3stable
pki.crmf.buildCertTemplate(template) -> Buffer0.3.5stable
pki.crmf.verifyPop(messages) -> Promise<{ valid, verified, messages: [{ valid, verified, method, cryptographicallyVerified, certReqId, subject, subjectBound, publicKey, reason }] }>0.5.14stable
pki.schema.crmf.parse(input, caps?) -> certReqMessages0.1.17stable
pki.schema.crmf.pemDecode(text, label?) -> Buffer0.1.17stable
pki.schema.crmf.pemEncode(der, label) -> string0.1.23stable
pki.schema.crmf.decodeExtensions(messagesOrBytes, opts?) -> rows0.8.11stable
pki.schema.crmf.decodeExtension(ext, opts?) -> row0.8.11stable

Certification requests

PrimitiveSinceStatus
pki.csr.sign(spec, key, opts?) -> Promise<Buffer|string>0.3.1stable
pki.csr.verify(request) -> Promise<{ valid, verified, subject, subjectPublicKeyInfo, attributes, certificationRequestInfoBytes }>0.5.13stable
pki.schema.csr.parse(input, caps?) -> csr0.1.8stable
pki.schema.csr.pemDecode(text, label?) -> Buffer0.1.8stable
pki.schema.csr.pemEncode(der, label?) -> string0.1.8stable
pki.schema.csr.decodeExtensions(csrOrBytes, opts?) -> rows0.8.11stable
pki.schema.csr.decodeExtension(ext, opts?) -> row0.8.11stable

Keys

PrimitiveSinceStatus
pki.key.encrypt(privateKey, password, opts?) -> Promise<Buffer|string>0.3.10stable
pki.key.decrypt(encrypted, password, opts?) -> Promise<Buffer|string>0.3.10stable
pki.key.export(key, opts?) -> Promise<Buffer|string>0.3.10stable
pki.key.import(input, opts?) -> Promise<CryptoKey>0.3.10stable
pki.key.generate(algorithm, opts?) -> Promise<{ privateKey, publicKey }>0.3.10stable
pki.key.publicFromPrivate(privateKey, opts?) -> Promise<Buffer|string>0.3.10stable

PKCS#12

PrimitiveSinceStatus
pki.pkcs12.build(spec, opts?) -> Promise<Buffer|string>0.3.11stable
pki.pkcs12.verifyMac(pfx, password, opts?) -> Promise<{ valid, macAlgorithm, macAlgorithmName, iterationCount }>0.3.11stable
pki.pkcs12.open(pfx, password, opts?) -> Promise<OpenResult>0.3.12stable
pki.schema.pkcs12.parse(input, caps?) -> pfx0.1.18stable
pki.schema.pkcs12.pemDecode(text, label?) -> Buffer0.1.18stable
pki.schema.pkcs12.pemEncode(der, label?) -> string0.1.18stable
PrimitiveSinceStatus
pki.relatedCert.requestSignedData(spec) -> Buffer0.8.42stable
pki.relatedCert.certificateHash(certificate, digestAlgorithm?) -> { hashAlgorithm, hashValue }0.8.42stable
pki.relatedCert.matchesCertificate(relatedCertificate, certificate) -> boolean0.8.42stable
pki.relatedCert.verifyRequest(requesterCertificate, certificate, opts?) -> Promise<boolean>0.8.42stable

Alternative signatures

PrimitiveSinceStatus
pki.altSig.signedData(structure) -> Buffer0.8.43stable
pki.altSig.subjectAltPublicKey(certificate) -> Buffer0.8.43stable
pki.altSig.verify(structure, issuerAltPublicKey, opts?) -> Promise<boolean>0.8.43stable

Sigstore

PrimitiveSinceStatus
pki.sigstore.pae(payloadType, payloadBytes) -> Buffer0.2.3stable
pki.sigstore.parseBundle(input) -> bundle0.2.3stable
pki.sigstore.verifyBundle(bundle, opts) -> Promise<result>0.2.3stable

Inspect

PrimitiveSinceStatus
pki.inspect.certificate(input) -> string0.2.4stable
pki.inspect.crl(input) -> string0.3.8stable
pki.inspect.csr(input) -> string0.3.8stable
pki.inspect.cms(input) -> string0.3.8stable
pki.inspect.pkcs8(input) -> string0.8.29stable
pki.inspect.pkcs12(input) -> string0.8.29stable
pki.inspect.crmf(input) -> string0.8.29stable
pki.inspect.cmp(input) -> string0.8.29stable
pki.inspect.csrattrs(input) -> string0.8.29stable
pki.inspect.trustanchor(input) -> string0.8.29stable
pki.inspect.ocspRequest(input) -> string0.8.29stable
pki.inspect.ocspResponse(input) -> string0.8.29stable
pki.inspect.tsp(input) -> string0.8.29stable
pki.inspect.attrcert(input) -> string0.8.29stable
pki.inspect.asn1(input, opts?) -> string0.8.31stable
pki.inspect.any(input) -> string0.3.8stable

Lint

PrimitiveSinceStatus
pki.lint.certificate(input, opts?) -> LintReport0.2.10stable
pki.lint.crl(pem | der | parsed, opts?) -> LintReport0.7.9stable
pki.lint.csr(pem | der | parsed, opts?) -> LintReport0.8.16stable
pki.lint.ocsp(pem | der | parsed, opts?) -> LintReport0.7.26stable
pki.lint.cms(pem | der | parsed, opts?) -> LintReport0.8.26stable
pki.lint.tsp(pem | der, opts?) -> LintReport0.8.26stable
pki.lint.attrcert(pem | der, opts?) -> LintReport0.8.26stable
pki.lint.rules(profile?, artifact?) -> [{id, severity, source, citation}]0.2.10stable
pki.lint.profiles() -> [string]0.2.10stable

CT

PrimitiveSinceStatus
pki.ct.parseSctList(extValue) -> { scts, unknownScts, all }0.1.20stable
pki.ct.reconstructSignedData(entry, sct) -> Buffer0.1.20stable
pki.ct.verifySct(entry, sct, logPublicKey) -> Promise<boolean>0.2.12stable
pki.ct.encodeSctList(scts) -> Buffer0.2.24stable
pki.ct.signSct(entry, logKey, opts?) -> Promise<sct>0.2.24stable
pki.ct.parseLogList(json, opts?) -> { logs, byLogId, version, timestamp }0.2.28stable
pki.ct.verifySctWithLogList(entry, sct, logList, opts?) -> Promise<{ valid, logId, logIdHex, operator, logState, timestamp }>0.2.28stable
pki.ct.verifySctList(entry, list, logList, opts?) -> Promise<verdict>0.6.1stable
pki.ct.x509CertEntry(cert, issuer) -> { entryType, tbsCertificate, issuerKeyHash }0.6.1stable
pki.ct.verifyLogListSignature(json, signature, publicKey) -> Promise<boolean>0.2.29stable
pki.ct.sthSignedData(sth) -> Buffer0.8.40stable
pki.ct.verifySth(sth, logKey) -> Promise<boolean>0.8.40stable
pki.ct.getSth(opts) -> Promise<{ treeSize, timestamp, rootHash, signature, raw }>0.8.40stable
pki.ct.getProofByHash(opts) -> Promise<{ leafIndex, auditPath, verified }>0.8.40stable
pki.ct.getSthConsistency(opts) -> Promise<{ consistency, verified }>0.8.40stable
pki.ct.getEntries(opts) -> Promise<{ entries, requested, truncated }>0.8.40stable
pki.ct.getRoots(opts) -> Promise<{ certificates }>0.8.40stable
pki.ct.addChain(opts) -> Promise<{ sct, verified }>0.8.40stable
pki.ct.addPreChain(opts) -> Promise<{ sct, verified }>0.8.40stable
pki.ct.fetchLogList(opts) -> Promise<{ logs, byLogId, version, timestamp, raw, status, contentType, tls }>0.3.21stable

TLS

PrimitiveSinceStatus
pki.tls.decompressCertificate(bytes, opts?) -> { algorithm, algorithmName, uncompressedLength, certificateMessage, certificate }0.4.3stable
pki.tls.parseCertificateMessage(bytes, opts?) -> { certificateRequestContext, entries }0.4.3stable
pki.tls.compressCertificate(certificateMessage, opts?) -> Buffer0.4.3stable

Merkle

PrimitiveSinceStatus
pki.merkle.leafHash(entry) -> Buffer0.1.28stable
pki.merkle.nodeHash(left, right) -> Buffer0.1.28stable
pki.merkle.emptyRootHash() -> Buffer0.1.28stable
pki.merkle.verifyInclusion(opts) -> boolean0.1.28stable
pki.merkle.verifyConsistency(opts) -> boolean0.1.28stable
pki.merkle.root(leafHashes) -> Buffer0.8.34stable
pki.merkle.inclusionProof(opts) -> Buffer[]0.8.34stable
pki.merkle.consistencyProof(opts) -> Buffer[]0.8.34stable

Tlog

PrimitiveSinceStatus
pki.tlog.keyId(keyName, publicKey) -> Buffer0.8.33stable
pki.tlog.parseNote(input) -> { text, signedBytes, signatures }0.8.33stable
pki.tlog.verifyNote(input, keys) -> Promise<{ verified, signers, note }>0.8.33stable
pki.tlog.parseCheckpoint(input) -> { origin, treeSize, rootHash, extensions, note }0.8.33stable
pki.tlog.verifyCheckpoint(input, keys, opts?) -> Promise<{ verified, signers, checkpoint }>0.8.33stable
pki.tlog.parseVkey(text) -> { name, keyId, signatureType, publicKey }0.8.37stable
pki.tlog.tilePath(level, index, width?) -> string0.8.33stable
pki.tlog.entryBundlePath(index, width?) -> string0.8.33stable
pki.tlog.checkpointPath() -> string0.8.33stable
pki.tlog.parseTilePath(path) -> { level, index, width }0.8.33stable
pki.tlog.parseTile(bytes, opts?) -> Buffer[]0.8.33stable
pki.tlog.parseEntryBundle(bytes) -> Buffer[]0.8.33stable
pki.tlog.tileWidth(treeSize, level, index) -> number | null0.8.36stable
pki.tlog.inclusionProof(opts) -> Promise<Buffer[]>0.8.36stable

TUF

PrimitiveSinceStatus
pki.tuf.canonicalJson(value) -> Buffer0.8.41stable
pki.tuf.keyId(key) -> string0.8.41stable
pki.tuf.parseMetadata(input) -> { type, specVersion, version, expires, signed, signatures, signedBytes }0.8.41stable
pki.tuf.checkExpiry(metadata, now) -> true0.8.41stable
pki.tuf.verifySignatures(opts) -> Promise<{ verified, keyIds, threshold }>0.8.41stable
pki.tuf.updateRoot(opts) -> Promise<{ root, version, updated, walked }>0.8.41stable

Trust anchor lists

PrimitiveSinceStatus
pki.trustanchor.build(spec, opts?) -> Buffer | string0.8.13stable

WebAuthn

PrimitiveSinceStatus
pki.webauthn.parseCoseKey(bytes) -> object0.5.2stable
pki.webauthn.parseAttestationObject(bytes) -> { fmt, attStmt, authData, authDataBytes }0.2.5stable
pki.webauthn.verify(attestationObject, clientDataHash?, opts?) -> Promise<{ valid, attestationVerified, fmt, attestationType, trustPath, anchoredTo, aaguid, credentialId, credentialPublicKey, credentialPublicKeyBytes, signCount, flags, rpIdHash, extensions, bindingChecked, clientData }>0.2.5stable
pki.webauthn.verifyMetadataBlob(blob, opts) -> Promise<{ no, legalHeader, nextUpdate, stale, allowStale, rollbackChecked, previousNo, entries, byAaguid, byKeyIdentifier, statusPolicy, rejectUnknownStatus }>0.4.11stable
pki.webauthn.metadataFor(metadata, identifier) -> entry | null0.4.11stable
pki.webauthn.metadataAnchors(entry, opts?) -> [certificate]0.4.11stable
pki.webauthn.parseClientData(bytes, opts?) -> { type, challenge, origin, crossOrigin, topOrigin, checked }0.5.0stable
pki.webauthn.parseAuthenticatorData(bytes) -> { rpIdHash, flags, signCount, aaguid, credentialId, credentialPublicKey, credentialPublicKeyBytes, extensions }0.5.0stable
pki.webauthn.verifyAssertion(input) -> Promise<{ valid, signatureVerified, signCount, signCountChecked, flags, rpIdHash, extensions, bindingChecked, clientData }>0.5.0stable

CMS

PrimitiveSinceStatus
pki.cms.verify(input, opts?) -> Promise<{ valid, trusted, eContentType, eContent, signers }>0.2.14stable
pki.cms.sign(content, signers, opts?) -> Promise<Buffer|string>0.2.15stable
pki.cms.countersign(cms, signers, opts?) -> Promise<Buffer|string>0.3.13stable
pki.cms.encrypt(content, recipients, opts?) -> Promise<Buffer | string>0.2.23stable
pki.cms.authenticate(content, recipients, opts?) -> Promise<Buffer | string>0.3.14stable
pki.cms.decrypt(input, keyMaterial, opts?) -> Promise<{ content, contentType, contentTypeName, recipientType, recipientIndex, contentEncryptionAlgorithm, authenticated, authenticatedBy, originAuthenticated, originatorInfo }>0.2.23stable
pki.cms.compress(content, opts?) -> Promise<Buffer | string>0.2.27stable
pki.cms.decompress(input, opts?) -> Promise<{ content, contentType, contentTypeName, compressionAlgorithm }>0.2.27stable
pki.cms.certsOnly(certs, opts?) -> Buffer | string0.6.3stable
pki.cms.parseCertsOnly(input, opts?) -> { certificates, crls }0.6.3stable
pki.cms.isCertsOnly(input) -> boolean0.6.3stable
pki.schema.cms.parse(input, caps?) -> content0.1.10stable
pki.schema.cms.pemDecode(text, label?) -> Buffer0.1.10stable
pki.schema.cms.pemEncode(der, label?) -> string0.1.10stable