Browsing index pages (3 articles)
↧
Figuring out the exact key created by PHP's mcrypt
A PHP application I'm maintaining uses Rijndael_256 with EBC_MODE encryption with mcrypt. Fun has it that the key isn't 256 bits long, but only 160. According to the mcrypt_encrypt documentation the...
View ArticleAnswer by HamZa for Figuring out the exact key created by PHP's mcrypt
'\0' means NULL, the hex value of it is 00 !So i tested 3 codes, and they returned all the same :)Let mcrypt_encrypt do the '\0' paddingAdded with PHP NULL valuesAdded with PHP converted 0 hex...
View ArticleAnswer by blahdiblah for Figuring out the exact key created by PHP's mcrypt
The issue isn't the key's padding, it's that you're using two different block sizes. In PHP, using MCRYPT_RIJNDAEL_256 uses a block size of... 256 bits. However, in perl using Crypt::Rijndael, they...
View Article
Browsing index pages (3 articles)