Documentation ¶
Overview ¶
Implements Block Modes. This package is intended for SPIs. The GCM mode is only available for ciphers with 128-bit block size.
Encoding = ( $ciphers.... ) + ( "/gcm" "/cbc" "/cfb" "/ctr" "/ofb" "/eax" )
Index ¶
Constants ¶
View Source
const ( GCM = iota CBC CFB CTR OFB EAX )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BlockCipher ¶
type BlockCipher struct { F MakeBlock Key int IV int // BlockSize for .RegisterVariants("..."), IV-size otherwise. Mode int }
func (*BlockCipher) Decrypt ¶
func (c *BlockCipher) Decrypt(b *ciphersuite2.Cipher_Buffer) (*format2.CipherObject, error)
func (*BlockCipher) Encrypt ¶
func (c *BlockCipher) Encrypt(b *ciphersuite2.Cipher_Buffer) (*format2.CipherObject, error)
func (*BlockCipher) Keybuf ¶
func (c *BlockCipher) Keybuf() *ciphersuite2.Cipher_Buffer
func (*BlockCipher) RegisterVariants ¶
func (c *BlockCipher) RegisterVariants(name string)
Click to show internal directories.
Click to hide internal directories.