Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
--TEST-- iconv_mime_decode_headers() charset parameter length checks (CVE-2007-4840) --EXT..
Decoded Output download
--TEST--
iconv_mime_decode_headers() charset parameter length checks (CVE-2007-4840)
--EXTENSIONS--
iconv
--FILE--
<?php
$a = str_repeat("/", 9000000);
var_dump(iconv_mime_decode_headers("a", 0, $a));
?>
--EXPECTF--
Warning: iconv_mime_decode_headers(): Encoding parameter exceeds the maximum allowed length of 64 characters in %s on line %d
bool(false)
Did this file decode correctly?
Original Code
--TEST--
iconv_mime_decode_headers() charset parameter length checks (CVE-2007-4840)
--EXTENSIONS--
iconv
--FILE--
<?php
$a = str_repeat("/", 9000000);
var_dump(iconv_mime_decode_headers("a", 0, $a));
?>
--EXPECTF--
Warning: iconv_mime_decode_headers(): Encoding parameter exceeds the maximum allowed length of 64 characters in %s on line %d
bool(false)
Function Calls
str_repeat | 1 |
Stats
MD5 | 70fb2bd098609543da4f6a7ce1f51e55 |
Eval Count | 0 |
Decode Time | 92 ms |