mirror of
https://github.com/php/php-src.git
synced 2026-04-27 18:23:26 +02:00
bd59a23e0a
#- This is somewhat of a hack, and thus I will not merge it to HEAD, as # I've lots of other commits waiting for that.
20 lines
490 B
PHP
20 lines
490 B
PHP
--TEST--
|
|
Bug #21039
|
|
--SKIPIF--
|
|
<?php if (!extension_loaded("mcrypt")) print "skip"; ?>
|
|
--POST--
|
|
--GET--
|
|
--FILE--
|
|
<?php
|
|
error_reporting(E_ALL);
|
|
$nthash = "00000000000000000";
|
|
$challenge = "foo";
|
|
$td = mcrypt_module_open ('des', '', 'cbc', '');
|
|
$iv = mcrypt_create_iv (mcrypt_enc_get_iv_size ($td), MCRYPT_RAND);
|
|
$var = @mcrypt_generic_init ($td, substr($nthash, 0, 8));
|
|
$res = @mcrypt_generic ($td, $challenge);
|
|
print "I'm alive!\n";
|
|
?>
|
|
--EXPECT--
|
|
I'm alive!
|