Documentation
¶
Overview ¶
Package padding implements common block cipher padding schemes.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Bit is the bit padding scheme. Bit bit // ISO10126 is the ISO/IEC 10126 padding scheme. ISO10126 iso10126 // ISO7816 is the ISO/IEC 7816-4 padding scheme. ISO7816 iso7816 // PKCS5 is the PKCS #5 padding scheme. PKCS5 pkcs5 // PKCS7 is the PKCS #7 padding scheme. PKCS7 pkcs7 // TBC is the trailing bit complement padding scheme. TBC tbc // X923 is the ANSI X9.23 padding scheme. X923 x923 // Zero is the zero padding scheme. Zero zero )
Functions ¶
func OverheadSize ¶
OverheadSize returns the padding length for length and blocksize.
Types ¶
type BlockSizeError ¶
type BlockSizeError int
BlockSizeError is returned when a padding block size is invalid.
func (BlockSizeError) Error ¶
func (i BlockSizeError) Error() string
type InvalidDataError ¶
type InvalidDataError int
InvalidDataError is returned when padded data is malformed.
func (InvalidDataError) Error ¶
func (i InvalidDataError) Error() string
Click to show internal directories.
Click to hide internal directories.