Documentation
¶
Index ¶
- type EncryptedMessage
- type EncryptionScheme
- type PREEncryptedMessage
- type PREEncryptionScheme
- func (pre *PREEncryptionScheme) Decrypt(encMsg *EncryptedMessage) ([]byte, error)
- func (pre *PREEncryptionScheme) Encrypt(data []byte) (*EncryptedMessage, error)
- func (pre *PREEncryptionScheme) GetEncryptedKey() string
- func (pre *PREEncryptionScheme) GetPublicKey() (string, error)
- func (pre *PREEncryptionScheme) GetReGenKey(encPublicKey string, tag string) (string, error)
- func (pre *PREEncryptionScheme) InitForDecryption(tag string, encryptedKey string) error
- func (pre *PREEncryptionScheme) InitForEncryption(tag string)
- func (pre *PREEncryptionScheme) Initialize(mnemonic string) error
- func (pre *PREEncryptionScheme) SymDec(group kyber.Group, ctx []byte, keyhash []byte) ([]byte, error)
- func (pre *PREEncryptionScheme) SymEnc(group kyber.Group, message []byte, keyhash []byte) ([]byte, error)
- type ReKey
- type ReKeyBytes
- type Suite
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EncryptedMessage ¶
type EncryptionScheme ¶
type EncryptionScheme interface {
Initialize(mnemonic string) error
InitForEncryption(tag string)
InitForDecryption(tag string, encryptedKey string) error
Encrypt(data []byte) (*EncryptedMessage, error)
Decrypt(*EncryptedMessage) ([]byte, error)
GetEncryptedKey() string
GetReGenKey(encPublicKey string, tag string) (string, error)
GetPublicKey() (string, error)
}
func NewEncryptionScheme ¶
func NewEncryptionScheme() EncryptionScheme
type PREEncryptedMessage ¶
type PREEncryptedMessage struct {
EncryptedKey kyber.Point `json:"-"`
EncryptedData []byte
MessageChecksum []byte
OverallChecksum []byte
TagA []byte
}
func (*PREEncryptedMessage) MarshalJSON ¶
func (u *PREEncryptedMessage) MarshalJSON() ([]byte, error)
type PREEncryptionScheme ¶
type PREEncryptionScheme struct {
PublicKey kyber.Point
PrivateKey kyber.Scalar
SuiteObj Suite
Tag []byte
T kyber.Point
Ht kyber.Point
EncryptedKey kyber.Point
}
func (*PREEncryptionScheme) Decrypt ¶
func (pre *PREEncryptionScheme) Decrypt(encMsg *EncryptedMessage) ([]byte, error)
func (*PREEncryptionScheme) Encrypt ¶
func (pre *PREEncryptionScheme) Encrypt(data []byte) (*EncryptedMessage, error)
func (*PREEncryptionScheme) GetEncryptedKey ¶
func (pre *PREEncryptionScheme) GetEncryptedKey() string
func (*PREEncryptionScheme) GetPublicKey ¶
func (pre *PREEncryptionScheme) GetPublicKey() (string, error)
func (*PREEncryptionScheme) GetReGenKey ¶
func (pre *PREEncryptionScheme) GetReGenKey(encPublicKey string, tag string) (string, error)
func (*PREEncryptionScheme) InitForDecryption ¶
func (pre *PREEncryptionScheme) InitForDecryption(tag string, encryptedKey string) error
func (*PREEncryptionScheme) InitForEncryption ¶
func (pre *PREEncryptionScheme) InitForEncryption(tag string)
func (*PREEncryptionScheme) Initialize ¶
func (pre *PREEncryptionScheme) Initialize(mnemonic string) error
type ReKeyBytes ¶
Click to show internal directories.
Click to hide internal directories.