Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMixedKeys ¶
func NewRPC11Keys ¶
func NewRPC15Keys ¶
Types ¶
type API ¶
type API interface {
// Seal returns an authenticated and encrypted version of the supplied
// data. Seal appends the encrypted data to the supplied buf and the
// the returned slice points to the newly encrypted data that can be used
// as the argument to Open (it includes he MAC).
Seal(buf, data []byte) ([]byte, error)
// Open authenticates and decrypts a box produced by Seal and returns true
// on success. The decrypted data is appended to buf and the returned slice
// points to the newly decrypted data.
Open(buf, data []byte) ([]byte, bool)
// ChannelBinding Returns a byte slice that is unique for the the
// particular cipher (and the parties between which it is operating).
// Having both parties assert out of the band that they are indeed
// participating in a connection with that channel binding value is
// sufficient to authenticate the data received through the cipher.
ChannelBinding() []byte
// Overhead is the max difference between the plaintext and ciphertext sizes.
Overhead() int
}
API provides an API for testing ciphers used for encrypting messages sent by message pipe implementations. This interface is used solely for testing and is intended to allow for a single set of tests to be used for multiple cipher implementations in the future.
func NewMixedCiphers ¶
func NewRPC11Ciphers ¶
func NewRPC15Ciphers ¶
Click to show internal directories.
Click to hide internal directories.