![]() |
AnCH Framework
0.1
Another C++ Hack Framework
|
Zero padding implementation. More...
#include <zeroPadding.hpp>
Static Public Member Functions | |
static void | pad (uint8_t *data, std::size_t len, std::size_t expLen) |
static std::size_t | length (uint8_t *data, std::size_t len) |
Zero padding implementation.
Add 0x00 until the end of the block.
Zero padding may not be reversible when data to pad ends with 0x00 (end of string).
|
static |
Unpad data
data | the data to unpad |
len | the block length |
|
static |
Pad data
data | the data to pad |
len | the data length |
expLen | the expected length |