Versions in this module Expand all Collapse all v0 v0.1.0 Jul 23, 2020 Changes in this version + var ErrMessageKeyUsed = errors.New("msg: message key has already been used") + var ErrNoKeyEntry = errors.New("msg: no KeyEntry found") + func CalcKey(senderIdentityHash string, recipientIdentityHash string, ...) string + func CalcStateKey(senderIdentityPub, recipientIdentityPub *[32]byte) string + func StateEqual(a, b *State) bool + type State struct + KeyInitSession bool + MaxRecipientCount uint64 + NextRecipientSessionPubSeen *uid.KeyEntry + NextSenderSessionPub *uid.KeyEntry + NymAddress string + RecipientTemp uid.KeyEntry + SenderMessageCount uint64 + SenderSessionCount uint64 + SenderSessionPub uid.KeyEntry + type Store interface + AddSessionKey func(hash, json, privKey string, cleanupTime uint64) error + CleanupSessionKeys func(t uint64) error + DelMessageKey func(sessionKey string, sender bool, msgIndex uint64) error + DelPrivSessionKey func(hash string) error + GetChainKey func(sessionKey string) (*[32]byte, error) + GetMessageKey func(sessionKey string, sender bool, msgIndex uint64) (*[64]byte, error) + GetPrivateKeyEntry func(pubKeyHash string) (*uid.KeyEntry, error) + GetPublicKeyEntry func(uidMsg *uid.Message) (*uid.KeyEntry, string, error) + GetRootKeyHash func(sessionKey string) (*[64]byte, error) + GetSessionKey func(hash string) (json, privKey string, err error) + GetSessionState func(sessionStateKey string) (*State, error) + HasSession func(sessionKey string) bool + NumMessageKeys func(sessionKey string) (uint64, error) + SetSessionState func(sessionStateKey string, sessionState *State) error + StoreSession func(sessionKey, rootKeyHash, chainKey string, send, recv []string) error