package
0.0.0-20240315150211-d9e980b5aa70
Repository: https://github.com/netsec-ethz/fpki.git
Documentation: pkg.go.dev

# Functions

No description provided by the author
CertificateFromFile uses a CertReader to read just one certificate.
No description provided by the author
No description provided by the author
DeserializeCertificates takes a stream of bytes that contains a sequence of certificates in ASN.1 DER form, and returns the original sequence of certificates.
ExtractCertDomains: get domain from cert: {Common Name, SANs}.
ExtractExpirations simply returns all expiration times in order.
ExtractNames returns a list of lists of names.
No description provided by the author
LoadCertsAndChainsFromCSV returns a ready to insert-in-DB collection of the leaf certificate payload, its ID, its parent ID, and its names, for each certificate and its ancestry chain.
LoadPoliciesFromRaw can load RPCs, SPs, RCSRs, PCRevocations, SPRTs, and PSRs from their serialized form.
No description provided by the author
No description provided by the author
No description provided by the author
NewTimeOfDay constructs a TimeOfDayWrap from the arguments.
ParseDuration parses a string into a time.Duration, assuming that a year always has 365d, a week always has 7d, and a day always has 24h.
ParseTimeOfDay returns a time.Time constructed from strings such as 15:35:55 or 15:55:55.123456.
No description provided by the author
No description provided by the author
No description provided by the author
Pow returns x raised to n.
No description provided by the author
No description provided by the author
RSAKeyFromFile loads an RSA private key from file in PEM format.
No description provided by the author
No description provided by the author
No description provided by the author
RunWhen executes the function at the specified time.Time.
No description provided by the author
SerializeCertificates serializes a sequence of certificates into their ASN.1 DER form.
SetSignalHandler builds a context that gets cancelled in case of receiving one of the signals passed as arguments.
ToTypedSlice expects a slice as input and returns a slice whose elements are converted to the required type one by one, and another slice with the remaining elements that couldn't be converted.
No description provided by the author
ToType returns the passed object as the specified type, or error.
ToTypedSlice expects a slice (or error is returned).
UnfoldCert takes a certificate with its trust chain and returns a ready-to-insert-in-DB collection of IDs and payloads for the certificate and its ancestry.
UnfoldCerts takes a slice of certificates and chains with the same length, and returns all certificates once, without duplicates, and the ID of the parent in the trust chain, or nil if the certificate is root.

# Constants

No description provided by the author
No description provided by the author

# Structs

No description provided by the author
No description provided by the author
DurationWrap is a wrapper to enable marshalling and unmarshalling of durations with the custom format.
No description provided by the author
TimeOfDayWrap is a wrapper to enable marshalling and unmarshalling of durations with the custom format.