1/// <reference types="node" /> 2import * as sigstore from '../types/sigstore'; 3import { ASN1Obj } from '../util/asn1'; 4import { x509AuthorityKeyIDExtension, x509BasicConstraintsExtension, x509Extension, x509KeyUsageExtension, x509SCTExtension, x509SubjectAlternativeNameExtension, x509SubjectKeyIDExtension } from './ext'; 5interface SCTVerificationResult { 6 verified: boolean; 7 logID: Buffer; 8} 9export declare class x509Certificate { 10 root: ASN1Obj; 11 constructor(asn1: ASN1Obj); 12 static parse(cert: Buffer | string): x509Certificate; 13 get tbsCertificate(): ASN1Obj; 14 get version(): string; 15 get notBefore(): Date; 16 get notAfter(): Date; 17 get issuer(): Buffer; 18 get subject(): Buffer; 19 get publicKey(): Buffer; 20 get signatureAlgorithm(): string; 21 get signatureValue(): Buffer; 22 get extensions(): ASN1Obj[]; 23 get extKeyUsage(): x509KeyUsageExtension | undefined; 24 get extBasicConstraints(): x509BasicConstraintsExtension | undefined; 25 get extSubjectAltName(): x509SubjectAlternativeNameExtension | undefined; 26 get extAuthorityKeyID(): x509AuthorityKeyIDExtension | undefined; 27 get extSubjectKeyID(): x509SubjectKeyIDExtension | undefined; 28 get extSCT(): x509SCTExtension | undefined; 29 get isCA(): boolean; 30 extension(oid: string): x509Extension | undefined; 31 verify(issuerCertificate?: x509Certificate): boolean; 32 validForDate(date: Date): boolean; 33 equals(other: x509Certificate): boolean; 34 verifySCTs(issuer: x509Certificate, logs: sigstore.TransparencyLogInstance[]): SCTVerificationResult[]; 35 private clone; 36 private findExtension; 37 private checkRecognizedExtensions; 38 private get tbsCertificateObj(); 39 private get signatureAlgorithmObj(); 40 private get signatureValueObj(); 41 private get versionObj(); 42 private get issuerObj(); 43 private get validityObj(); 44 private get subjectObj(); 45 private get subjectPublicKeyInfoObj(); 46 private get extensionsObj(); 47} 48export {}; 49