Optional
ca: typeof SELF_SIGNED | KeyCertReadonly
caReadonly
certReadonly
keyReadonly
nameThe file name of the certificate. The file is encoded as PEM.
The filename, or undefined if unknown.
Issuer DN string.
A string of the form '/C=US'.
The account name of the key, stored under KEYCHAIN_SERVICE in the OS-specific keychain. This corresponds to the file name that the key used to be stored in. This file should no longer exist after the upgrade procedure runs.
If known, the filename, otherwise undefined.
Certificate not valid after this date.
Date constructed from X509.
Certificate not valid before this date.
Date constructed from X509.
List of subjectAlternativeNames for the cert.
Array of {dns: 'hostname'} or {ip: 'address'} objects.
Serial number of the cert.
Hex string.
Subject name of the cert.
String of the form '/CN=localhost'.
Static
listGet all known certs in the given directory.
Options, most important is dir.
Logger.
Optional
ca: typeof SELF_SIGNED | KeyCertIf known, the CA, or SELF_SIGNED for CAs.
Static
listList all known keys.
Static
readRead the cert file and the key from the keychain.
Options. Most important is dir.
Base name of the files, escaped for use as filenames. No suffix or directory.
Logger.
Optional
ca: typeof SELF_SIGNED | KeyCertIf known, the CA. Use SELF_SIGNED for the CA.
KeyCert, or null if not found.
Delete this key, if it isn't temporary.
Optional
opts: Required<CommonCertOptions>Options, of which temp is the most important.
Optional
log: LoggerLogger.
Promise that completes when done deleting.
Verify the certificate with its issuer. If no CA, returns false.
True if valid.
Save the cert file and key, unless this is temporary.
Options, of which temp is the most important.
Logger.
Promise that completes when writing is done.
A certificate and its private key.