Versions in this module Expand all Collapse all v1 v1.0.1 Nov 17, 2023 Changes in this version + const AddChainPath + const AddJSONPath + const AddPreChainPath + const GetEntriesPath + const GetEntryAndProofPath + const GetProofByHashPath + const GetRootsPath + const GetSTHConsistencyPath + const GetSTHPath + const TreeLeafPrefix + const TreeNodePrefix + var AllowVerificationWithNonCompliantKeys = false + func IsPreIssuer(issuer *x509.Certificate) bool + func LeafHashForLeaf(leaf *MerkleTreeLeaf) ([sha256.Size]byte, error) + func PublicKeyFromB64(b64PubKey string) (crypto.PublicKey, error) + func SerializeSCTSignatureInput(sct SignedCertificateTimestamp, entry LogEntry) ([]byte, error) + func SerializeSTHSignatureInput(sth SignedTreeHead) ([]byte, error) + func TimestampToTime(ts uint64) time.Time + type APIEndpoint string + const AddChainStr + const AddPreChainStr + const GetEntriesStr + const GetEntryAndProofStr + const GetProofByHashStr + const GetRootsStr + const GetSTHConsistencyStr + const GetSTHStr + type ASN1Cert struct + Data []byte + type AddChainRequest struct + Chain [][]byte + type AddChainResponse struct + Extensions string + ID []byte + SCTVersion Version + Signature []byte + Timestamp uint64 + func (r *AddChainResponse) ToSignedCertificateTimestamp() (*SignedCertificateTimestamp, error) + type AddJSONRequest struct + Data interface{} + type AuditPath []MerkleTreeNode + type CTExtensions []byte + type CertificateChain struct + Entries []ASN1Cert + type CertificateTimestamp struct + EntryType LogEntryType + Extensions CTExtensions + JSONEntry *JSONDataEntry + PrecertEntry *PreCert + SCTVersion Version + SignatureType SignatureType + Timestamp uint64 + X509Entry *ASN1Cert + type ConsistencyProof []MerkleTreeNode + type DigitallySigned tls.DigitallySigned + func (d *DigitallySigned) FromBase64String(b64 string) error + func (d *DigitallySigned) UnmarshalJSON(b []byte) error + func (d DigitallySigned) Base64String() (string, error) + func (d DigitallySigned) MarshalJSON() ([]byte, error) + type GetEntriesResponse struct + Entries []LeafEntry + type GetEntryAndProofResponse struct + AuditPath [][]byte + ExtraData []byte + LeafInput []byte + type GetProofByHashResponse struct + AuditPath [][]byte + LeafIndex int64 + type GetRootsResponse struct + Certificates []string + type GetSTHConsistencyResponse struct + Consistency [][]byte + type GetSTHResponse struct + SHA256RootHash []byte + Timestamp uint64 + TreeHeadSignature []byte + TreeSize uint64 + func (r *GetSTHResponse) ToSignedTreeHead() (*SignedTreeHead, error) + type JSONDataEntry struct + Data []byte + type LeafEntry struct + ExtraData []byte + LeafInput []byte + type LeafInput []byte + type LogEntry struct + Chain []ASN1Cert + Index int64 + JSONData []byte + Leaf MerkleTreeLeaf + Precert *Precertificate + X509Cert *x509.Certificate + func LogEntryFromLeaf(index int64, leaf *LeafEntry) (*LogEntry, error) + type LogEntryType tls.Enum + const PrecertLogEntryType + const X509LogEntryType + func (e LogEntryType) String() string + type LogID struct + KeyID [sha256.Size]byte + type MerkleLeafType tls.Enum + const TimestampedEntryLeafType + func (m MerkleLeafType) String() string + type MerkleTreeLeaf struct + LeafType MerkleLeafType + TimestampedEntry *TimestampedEntry + Version Version + func CreateX509MerkleTreeLeaf(cert ASN1Cert, timestamp uint64) *MerkleTreeLeaf + func MerkleTreeLeafForEmbeddedSCT(chain []*x509.Certificate, timestamp uint64) (*MerkleTreeLeaf, error) + func MerkleTreeLeafFromChain(chain []*x509.Certificate, etype LogEntryType, timestamp uint64) (*MerkleTreeLeaf, error) + func MerkleTreeLeafFromRawChain(rawChain []ASN1Cert, etype LogEntryType, timestamp uint64) (*MerkleTreeLeaf, error) + func (m *MerkleTreeLeaf) Precertificate() (*x509.Certificate, error) + func (m *MerkleTreeLeaf) X509Certificate() (*x509.Certificate, error) + type MerkleTreeNode []byte + type PreCert struct + IssuerKeyHash [sha256.Size]byte + TBSCertificate []byte + type PrecertChainEntry struct + CertificateChain []ASN1Cert + PreCertificate ASN1Cert + type Precertificate struct + IssuerKeyHash [sha256.Size]byte + Submitted ASN1Cert + TBSCertificate *x509.Certificate + type RawLogEntry struct + Cert ASN1Cert + Chain []ASN1Cert + Index int64 + Leaf MerkleTreeLeaf + func RawLogEntryFromLeaf(index int64, entry *LeafEntry) (*RawLogEntry, error) + func (rle *RawLogEntry) ToLogEntry() (*LogEntry, error) + type SHA256Hash [sha256.Size]byte + func PublicKeyFromPEM(b []byte) (crypto.PublicKey, SHA256Hash, []byte, error) + func (s *SHA256Hash) FromBase64String(b64 string) error + func (s *SHA256Hash) UnmarshalJSON(b []byte) error + func (s SHA256Hash) Base64String() string + func (s SHA256Hash) MarshalJSON() ([]byte, error) + type SignatureType tls.Enum + const CertificateTimestampSignatureType + const TreeHashSignatureType + func (st SignatureType) String() string + type SignatureVerifier struct + PubKey crypto.PublicKey + func NewSignatureVerifier(pk crypto.PublicKey) (*SignatureVerifier, error) + func (s SignatureVerifier) VerifySCTSignature(sct SignedCertificateTimestamp, entry LogEntry) error + func (s SignatureVerifier) VerifySTHSignature(sth SignedTreeHead) error + func (s SignatureVerifier) VerifySignature(data []byte, sig tls.DigitallySigned) error + type SignedCertificateTimestamp struct + Extensions CTExtensions + LogID LogID + SCTVersion Version + Signature DigitallySigned + Timestamp uint64 + func (s SignedCertificateTimestamp) String() string + type SignedTreeHead struct + LogID SHA256Hash + SHA256RootHash SHA256Hash + Timestamp uint64 + TreeHeadSignature DigitallySigned + TreeSize uint64 + Version Version + func (s SignedTreeHead) String() string + type TimestampedEntry struct + EntryType LogEntryType + Extensions CTExtensions + JSONEntry *JSONDataEntry + PrecertEntry *PreCert + Timestamp uint64 + X509Entry *ASN1Cert + type TreeHeadSignature struct + SHA256RootHash SHA256Hash + SignatureType SignatureType + Timestamp uint64 + TreeSize uint64 + Version Version + type Version tls.Enum + const V1 + func (v Version) String() string