Documentation ¶
Overview ¶
This package implements PKCS#7 padding to byte slices. Padding works by calculating the amount of needed padding and repeating that number to fill in the rest of the slice up to the block size. This way, in order to unpad the slice, you check the value held in the last slot and then remove that many bytes from the end.
By defniition, PKCS#7 only padds for block sizes between 1 and 255 inclusive. If the supplied byte slice is a multiple of the block size, N, an extra N amount of bytes is appended all of value N.
Please review the tests for this package for examples.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.