package certdb
import "github.com/cloudflare/cfssl/certdb"
Index ¶
Types ¶
type Accessor ¶
type Accessor interface { InsertCertificate(cr CertificateRecord) error GetCertificate(serial, aki string) ([]CertificateRecord, error) GetUnexpiredCertificates() ([]CertificateRecord, error) GetRevokedAndUnexpiredCertificates() ([]CertificateRecord, error) GetRevokedAndUnexpiredCertificatesByLabel(label string) ([]CertificateRecord, error) RevokeCertificate(serial, aki string, reasonCode int) error InsertOCSP(rr OCSPRecord) error GetOCSP(serial, aki string) ([]OCSPRecord, error) GetUnexpiredOCSPs() ([]OCSPRecord, error) UpdateOCSP(serial, aki, body string, expiry time.Time) error UpsertOCSP(serial, aki, body string, expiry time.Time) error }
Accessor abstracts the CRUD of certdb objects from a DB.
type CertificateRecord ¶
type CertificateRecord struct { Serial string `db:"serial_number"` AKI string `db:"authority_key_identifier"` CALabel string `db:"ca_label"` Status string `db:"status"` Reason int `db:"reason"` Expiry time.Time `db:"expiry"` RevokedAt time.Time `db:"revoked_at"` PEM string `db:"pem"` }
CertificateRecord encodes a certificate and its metadata that will be recorded in a database.
type OCSPRecord ¶
type OCSPRecord struct { Serial string `db:"serial_number"` AKI string `db:"authority_key_identifier"` Body string `db:"body"` Expiry time.Time `db:"expiry"` }
OCSPRecord encodes a OCSP response body and its metadata that will be recorded in a database.
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
certdb/dbconf | |
certdb/ocspstapling | Package ocspstapling implements OCSP stapling of Signed Certificate Timestamps (SCTs) into OCSP responses in a database. |
certdb/sql | |
certdb/testdb |
- Version
- v1.4.0-rc1
- Published
- Oct 30, 2019
- Platform
- js/wasm
- Imports
- 1 packages
- Last checked
- 1 minute ago –
Tools for package owners.