Versions in this module Expand all Collapse all v1 v1.1.0 Apr 12, 2019 Changes in this version + const SecretTag + var ErrNotImplemented = errors.New("NOT YET IMPLEMENTED") + var RevocationReasonCodes = map[string]int + var URLRegex = regexp.MustCompile("(ldap|http)s*://(\\S+):(\\S+)@") + func B64Decode(str string) (buf []byte, err error) + func B64Encode(buf []byte) string + func BCCSPKeyRequestGenerate(req *csr.CertificateRequest, myCSP apicryptosuite.CryptoSuite) (apicryptosuite.Key, crypto.Signer, error) + func CreateToken(csp apicryptosuite.CryptoSuite, cert []byte, key apicryptosuite.Key, ...) (string, error) + func GenECDSAToken(csp apicryptosuite.CryptoSuite, cert []byte, key apicryptosuite.Key, ...) (string, error) + func GetEnrollmentIDFromPEM(cert []byte) (string, error) + func GetEnrollmentIDFromX509Certificate(cert *x509.Certificate) string + func GetMaskedURL(url string) string + func GetSerialAsHex(serial *big.Int) string + func GetSignerFromCert(cert *x509.Certificate, csp apicryptosuite.CryptoSuite) (apicryptosuite.Key, crypto.Signer, error) + func GetSignerFromSM2Cert(cert *sm2.Certificate, csp apicryptosuite.CryptoSuite) (apicryptosuite.Key, crypto.Signer, error) + func GetX509CertificateFromPEM(cert []byte) (*x509.Certificate, error) + func HTTPRequestToString(req *http.Request) string + func HTTPResponseToString(resp *http.Response) string + func ImportBCCSPKeyFromPEM(keyFile string, myCSP apicryptosuite.CryptoSuite, temporary bool) (apicryptosuite.Key, error) + func ImportBCCSPKeyFromPEMBytes(keyBuff []byte, myCSP apicryptosuite.CryptoSuite, temporary bool) (apicryptosuite.Key, error) + func LoadX509KeyPair(certFile, keyFile string, csp apicryptosuite.CryptoSuite) (*tls.Certificate, error) + func LoadX509KeyPairSM2(certFile, keyFile string, csp apicryptosuite.CryptoSuite) (*gtls.Certificate, error) + func MakeFileAbs(file, dir string) (string, error) + func Marshal(from interface{}, what string) ([]byte, error) + func ParseSm2Certificate2X509(sm2Cert *sm2.Certificate) *x509.Certificate + func ParseX509Certificate2Sm2(x509Cert *x509.Certificate) *sm2.Certificate + func ReadFile(file string) ([]byte, error) + func StructToString(si interface{}) string + type ECDSASignature struct + R *big.Int + S *big.Int