diff options
| author | Ilia Alshanetsky <iliaa@php.net> | 2005-11-30 23:51:25 +0000 |
|---|---|---|
| committer | Ilia Alshanetsky <iliaa@php.net> | 2005-11-30 23:51:25 +0000 |
| commit | ae07423bcd294e48e238644459bd99c297d1a8a2 (patch) | |
| tree | 3a54a2b0dcf6a120f3933daf9fe03f69f3b0e36f /ext/mcrypt/tests | |
| parent | 9c2183f6221943790683033a93fcdc57af84236a (diff) | |
| download | php-git-ae07423bcd294e48e238644459bd99c297d1a8a2.tar.gz | |
Fixed bug #35496 (Crash in mcrypt_generic()/mdecrypt_generic() without
proper init).
Diffstat (limited to 'ext/mcrypt/tests')
| -rw-r--r-- | ext/mcrypt/tests/bug35496.phpt | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/ext/mcrypt/tests/bug35496.phpt b/ext/mcrypt/tests/bug35496.phpt new file mode 100644 index 0000000000..9d94ba4ca9 --- /dev/null +++ b/ext/mcrypt/tests/bug35496.phpt @@ -0,0 +1,14 @@ +--TEST-- +Bug #35496 (Crash in mcrypt_generic()/mdecrypt_generic() without proper init). +--SKIPIF-- +<?php if (!extension_loaded("mcrypt")) print "skip"; ?> +--FILE-- +<?php +$td = mcrypt_module_open('rijndael-256', '', 'ofb', ''); +mcrypt_generic($td, "foobar"); +mdecrypt_generic($td, "baz"); +?> +--EXPECTF-- +Warning: mcrypt_generic(): Operation disallowed prior to mcrypt_generic_init(). in %s/bug35496.php on line 3 + +Warning: mdecrypt_generic(): Operation disallowed prior to mcrypt_generic_init(). in %s/bug35496.php on line 4 |
