rsa

package
v1.0.45 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 5, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenRsaKey

func GenRsaKey(priKeyFileName string, pubKeyFileName string, bits int) error

func GenRsaKeyPKCS1 added in v1.0.11

func GenRsaKeyPKCS1(priKeyFileName string, pubKeyFileName string, bits int) error

func GenRsaKeyToString added in v1.0.21

func GenRsaKeyToString(bits int) (string, string, error)

func ReadRsaKeys

func ReadRsaKeys(priKeyFileName string, pubKeyFileName string) (error, []byte, []byte)

func ReadRsaPubKey

func ReadRsaPubKey(priKeyFileName string, pubKeyFileName string) (error, string)

func RsaDecrypt

func RsaDecrypt(ciphertext []byte, priKeyBytes []byte) ([]byte, error)

func RsaDecryptByDefaultKey

func RsaDecryptByDefaultKey(b64CipherText string, sumHext string) ([]byte, error)

func RsaDecryptByPkcs1 added in v1.0.22

func RsaDecryptByPkcs1(ciphertext []byte, priKeyBytes []byte) ([]byte, error)

func RsaEncrypt

func RsaEncrypt(origData []byte, publicKey []byte) ([]byte, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL