Documentation ¶
Index ¶
- func UnmarshallPublicKey(publicKey string) (kyber.Point, error)
- 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) GetEncryptedKeyPoint() string
- func (pre *PREEncryptionScheme) GetPrivateKey() (string, error)
- 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) InitForDecryptionWithPoint(tag, point string) error
- func (pre *PREEncryptionScheme) InitForEncryption(tag string)
- func (pre *PREEncryptionScheme) InitForEncryptionWithPoint(tag, point string) error
- func (pre *PREEncryptionScheme) Initialize(mnemonic string) ([]byte, error)
- func (pre *PREEncryptionScheme) InitializeWithPrivateKey(privateKey []byte) error
- func (pre *PREEncryptionScheme) ReDecrypt(D *ReEncryptedMessage) ([]byte, error)
- func (pre *PREEncryptionScheme) ReEncrypt(encMsg *EncryptedMessage, reGenKey string, clientPublicKey string) (*ReEncryptedMessage, 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 ReEncryptedMessage
- type ReKey
- type ReKeyBytes
- type Suite
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UnmarshallPublicKey ¶
Types ¶
type EncryptedMessage ¶
type EncryptionScheme ¶
type EncryptionScheme interface { Initialize(mnemonic string) ([]byte, error) InitializeWithPrivateKey(privateKey []byte) error InitForEncryption(tag string) InitForEncryptionWithPoint(tag, point string) error InitForDecryption(tag string, encryptedKey string) error InitForDecryptionWithPoint(tag, point string) error Encrypt(data []byte) (*EncryptedMessage, error) Decrypt(*EncryptedMessage) ([]byte, error) ReDecrypt(D *ReEncryptedMessage) ([]byte, error) GetEncryptedKey() string GetReGenKey(encPublicKey string, tag string) (string, error) ReEncrypt(encMsg *EncryptedMessage, reGenKey string, clientPublicKey string) (*ReEncryptedMessage, error) GetPublicKey() (string, error) GetPrivateKey() (string, error) GetEncryptedKeyPoint() string }
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) GetEncryptedKeyPoint ¶ added in v1.10.0
func (pre *PREEncryptionScheme) GetEncryptedKeyPoint() string
func (*PREEncryptionScheme) GetPrivateKey ¶
func (pre *PREEncryptionScheme) GetPrivateKey() (string, error)
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) InitForDecryptionWithPoint ¶ added in v1.10.0
func (pre *PREEncryptionScheme) InitForDecryptionWithPoint(tag, point string) error
func (*PREEncryptionScheme) InitForEncryption ¶
func (pre *PREEncryptionScheme) InitForEncryption(tag string)
func (*PREEncryptionScheme) InitForEncryptionWithPoint ¶ added in v1.10.0
func (pre *PREEncryptionScheme) InitForEncryptionWithPoint(tag, point string) error
func (*PREEncryptionScheme) Initialize ¶
func (pre *PREEncryptionScheme) Initialize(mnemonic string) ([]byte, error)
func (*PREEncryptionScheme) InitializeWithPrivateKey ¶ added in v1.2.88
func (pre *PREEncryptionScheme) InitializeWithPrivateKey(privateKey []byte) error
InitializeWithPrivateKey initialize with private key
func (*PREEncryptionScheme) ReDecrypt ¶
func (pre *PREEncryptionScheme) ReDecrypt(D *ReEncryptedMessage) ([]byte, error)
-----------------------------------------------ReDecryption-------------------------------------------------
func (*PREEncryptionScheme) ReEncrypt ¶
func (pre *PREEncryptionScheme) ReEncrypt(encMsg *EncryptedMessage, reGenKey string, clientPublicKey string) (*ReEncryptedMessage, error)
type ReEncryptedMessage ¶
func (*ReEncryptedMessage) Marshal ¶
func (reEncMsg *ReEncryptedMessage) Marshal() ([]byte, error)
func (*ReEncryptedMessage) Unmarshal ¶
func (reEncMsg *ReEncryptedMessage) Unmarshal(data []byte) error
type ReKey ¶
type ReKey struct { R1 kyber.Point R2 kyber.Point R3 kyber.Scalar }
func (*ReKey) MarshalJSON ¶
func (*ReKey) UnmarshalJSON ¶
type ReKeyBytes ¶
Click to show internal directories.
Click to hide internal directories.