Documentation
¶
Index ¶
- type APP
- type PEMBase64
- func (my *PEMBase64) GeneratePemPrivateKey() (*PEMBase64, error)
- func (my *PEMBase64) GeneratePemPublicKey() (*PEMBase64, error)
- func (my *PEMBase64) GetBase64PrivateKey() string
- func (my *PEMBase64) GetBase64PublicKey() string
- func (my *PEMBase64) GetPemPrivateKey() []byte
- func (my *PEMBase64) GetPemPublicKey() []byte
- func (*PEMBase64) New() *PEMBase64
- func (my *PEMBase64) SetBase64PrivateKye(base64PrivateKey string) *PEMBase64
- func (my *PEMBase64) SetBase64PublicKey(base64PublicKey string) *PEMBase64
- type RSA
- func (my *RSA) DecryptByBase64(base64PrivateKey string, cipherText []byte) ([]byte, error)
- func (my *RSA) DecryptByPem(pemPrivateKey []byte, cipherText []byte) ([]byte, error)
- func (my *RSA) Demo()
- func (*RSA) DemoDecryptRsa(base64Encrypted string) string
- func (*RSA) DemoEncryptRsa(unEncrypt []byte) string
- func (my *RSA) EncryptByBase64(base64PublicKey string, plainText []byte) ([]byte, error)
- func (my *RSA) EncryptByPem(pemPublicKey []byte, plainText []byte) ([]byte, error)
- func (*RSA) New() *RSA
- type UnEncrypt
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PEMBase64 ¶ added in v1.66.1
type PEMBase64 struct {
// contains filtered or unexported fields
}
func (*PEMBase64) GeneratePemPrivateKey ¶ added in v1.66.1
GeneratePemPrivateKey 生成pem密钥
func (*PEMBase64) GeneratePemPublicKey ¶ added in v1.66.1
func (*PEMBase64) GetBase64PrivateKey ¶ added in v1.66.1
func (*PEMBase64) GetBase64PublicKey ¶ added in v1.66.1
func (*PEMBase64) GetPemPrivateKey ¶ added in v1.66.1
GetPemPrivateKey 获取pem私钥
func (*PEMBase64) GetPemPublicKey ¶ added in v1.66.1
func (*PEMBase64) SetBase64PrivateKye ¶ added in v1.66.1
func (*PEMBase64) SetBase64PublicKey ¶ added in v1.66.1
type RSA ¶ added in v1.66.1
type RSA struct{}
func (*RSA) DecryptByBase64 ¶ added in v1.66.1
DecryptByBase64 通过base64私钥解密
func (*RSA) DecryptByPem ¶ added in v1.66.1
DecryptByPem 使用PEM私钥进行RSA解密
func (*RSA) DemoDecryptRsa ¶ added in v1.66.1
func (*RSA) DemoEncryptRsa ¶ added in v1.66.1
func (*RSA) EncryptByBase64 ¶ added in v1.66.1
EncryptByBase64 通过base64公钥加密
func (*RSA) EncryptByPem ¶ added in v1.66.1
EncryptByPem 通过pem公钥加密
Click to show internal directories.
Click to hide internal directories.