Documentation
¶
Index ¶
- func DecryptData(priKey *rsa.PrivateKey, data []byte) []byte
- func EncryptData(pubKey *rsa.PublicKey, data []byte) []byte
- func GenerateRsaKeyPair() *rsa.PrivateKey
- func GenerateRsaKeyPairPem() (priPem string, pubPem string, err error)
- func PemToPrivateKey(privateKeyPem string) (*rsa.PrivateKey, error)
- func PemToPublicKey(pubPem string) (*rsa.PublicKey, error)
- func PrivateKeyToPem(priKey *rsa.PrivateKey) string
- func PublicKeyToPem(pubKey *rsa.PublicKey) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecryptData ¶
func DecryptData(priKey *rsa.PrivateKey, data []byte) []byte
func GenerateRsaKeyPair ¶
func GenerateRsaKeyPair() *rsa.PrivateKey
func GenerateRsaKeyPairPem ¶
func PemToPrivateKey ¶
func PemToPrivateKey(privateKeyPem string) (*rsa.PrivateKey, error)
func PrivateKeyToPem ¶
func PrivateKeyToPem(priKey *rsa.PrivateKey) string
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.