MCPcopy Create free account
hub / github.com/f0ng/autoDecoder / pkcs5_pad

Method pkcs5_pad

testsql.php:93–96  ·  view source on GitHub ↗
($text, $blocksize)

Source from the content-addressed store, hash-verified

91 return $y;
92 }
93 function pkcs5_pad ($text, $blocksize) {
94 $pad = $blocksize - (strlen($text) % $blocksize);
95 return $text . str_repeat(chr($pad), $pad);
96 }
97 function pkcs5_unpad($text){
98 $pad = ord($text{strlen($text)-1});
99 if ($pad > strlen($text)) {

Callers 1

encryptMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected