Documentation ¶
Index ¶
- func AesDecrypt(key, text []byte) ([]byte, error)
- func AesEncrypt(key, plain []byte) ([]byte, error)
- func EciesDecrypt(raw []byte, ciphertext []byte) ([]byte, error)
- func EciesEncrypt(raw []byte, plain []byte) ([]byte, error)
- func GenerateKey(len int) []byte
- func PEMtoCertificate(raw []byte) (*x509.Certificate, error)
- func PEMtoPrivateKey(raw []byte, pwd []byte) (interface{}, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AesDecrypt ¶
func AesEncrypt ¶
func GenerateKey ¶
func PEMtoCertificate ¶
func PEMtoCertificate(raw []byte) (*x509.Certificate, error)
PEMtoCertificate converts pem to x509
func PEMtoPrivateKey ¶
PEMtoPrivateKey unmarshals a pem to private key
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.