func GetCAPrivateKeyPEMTXT(store *liftca.Store, r *ht.Request) *ht.Answer { ca, answer := ObtainCA(store, r) if answer != nil { return answer } return ht.Read("text/plain", ca.PEMPrivateKey()) }
func GetCACertificatePEMTXT(store *liftca.Store, r *ht.Request) *ht.Answer { ca, answer := ObtainCA(store, r) if answer != nil { return answer } return ht.Read("text/plain", ca.PEMCertificate()) }
func GetCAPrivateKeyPEM(store *liftca.Store, r *ht.Request) *ht.Answer { ca, answer := ObtainCA(store, r) if answer != nil { return answer } return ht.Read("application/x-pem-file", ca.PEMPrivateKey()) }
func GetCAPrivateKeyCER(store *liftca.Store, r *ht.Request) *ht.Answer { ca, answer := ObtainCA(store, r) if answer != nil { return answer } return ht.Read("application/pkix-cert", ca.DERPrivateKey()) }
func GetCertificatePEM(store *liftca.Store, r *ht.Request) *ht.Answer { _, cert, answer := ObtainCAAndCert(store, r) if answer != nil { return answer } return ht.Read("application/x-pem-file", cert.PEMCertificate()) }
func GetCertificateCER(store *liftca.Store, r *ht.Request) *ht.Answer { _, cert, answer := ObtainCAAndCert(store, r) if answer != nil { return answer } return ht.Read("application/pkix-cert", cert.DERCertificate()) }
func GetCertificatePrivateKeyPEMTXT(store *liftca.Store, r *ht.Request) *ht.Answer { _, cert, answer := ObtainCAAndCert(store, r) if answer != nil { return answer } return ht.Read("text/plain", cert.PEMPrivateKey()) }
func GetCACRLPEMTXT(store *liftca.Store, r *ht.Request) *ht.Answer { ca, answer := ObtainCA(store, r) if answer != nil { return answer } revoked := store.GetRevokedChildren(ca.SerialNumber()) crl, err := ca.PEMCRL(revoked) if err != nil { return ht.Failure(err) } return ht.Read("text/plain", crl) }
func GetCACRLCER(store *liftca.Store, r *ht.Request) *ht.Answer { ca, answer := ObtainCA(store, r) if answer != nil { return answer } revoked := store.GetRevokedChildren(ca.SerialNumber()) crl, err := ca.DERCRL(revoked) if err != nil { return ht.Failure(err) } return ht.Read("application/pkix-crl", crl) }