Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConvertPemToPrivateKey ¶
func ConvertPemToPrivateKey(skPem string) (*rsa.PrivateKey, error)
ConvertPemToPrivateKey return rsa private key from secret key
func DecodeKey ¶
func DecodeKey(sk *rsa.PrivateKey, hashBase64 string) (string, error)
DecodeKey with secret key (base64) and hash (base64), return the encrypted key string
func ExtractPublicKey ¶
func ExtractPublicKey(sk *rsa.PrivateKey) (string, error)
ExtractPublicKey get public key from private key and return []byte represent the public key
func GenerateKeys ¶
GenerateKeys using rsa random generate keys and return []byte bas64
func PrivateKeyToByte ¶
func PrivateKeyToByte(sk *rsa.PrivateKey) []byte
PrivateKeyToByte converts privateKey to []byte
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.