Documentation ¶
Index ¶
Constants ¶
View Source
const Name = "ecc"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Encryptor ¶
type Encryptor struct {
// contains filtered or unexported fields
}
func NewEncryptor ¶
func NewEncryptor(opts ...EncryptorOption) *Encryptor
type EncryptorOption ¶
type EncryptorOption func(o *encryptorOptions)
func WithEncryptorPrivateKey ¶
func WithEncryptorPrivateKey(privateKey string) EncryptorOption
WithEncryptorPrivateKey 设置解密私钥
func WithEncryptorPublicKey ¶
func WithEncryptorPublicKey(publicKey string) EncryptorOption
WithEncryptorPublicKey 设置加密公钥
func WithEncryptorShareInfo ¶
func WithEncryptorShareInfo(s1, s2 string) EncryptorOption
WithEncryptorShareInfo 设置共享信息
type Key ¶
type Key struct {
// contains filtered or unexported fields
}
func (*Key) MarshalPrivateKey ¶
MarshalPrivateKey 编码私钥
func (*Key) MarshalPublicKey ¶
MarshalPublicKey 编码公钥
type Signer ¶
type Signer struct {
// contains filtered or unexported fields
}
func NewSigner ¶
func NewSigner(opts ...SignerOption) *Signer
type SignerOption ¶
type SignerOption func(o *signerOptions)
func WithSignerDelimiter ¶
func WithSignerDelimiter(delimiter string) SignerOption
WithSignerDelimiter 设置签名分割符
func WithSignerPrivateKey ¶
func WithSignerPrivateKey(privateKey string) SignerOption
WithSignerPrivateKey 设置解密私钥
func WithSignerPublicKey ¶
func WithSignerPublicKey(publicKey string) SignerOption
WithSignerPublicKey 设置验签公钥
Click to show internal directories.
Click to hide internal directories.