diff --git a/tests/mcrypt_decrypt_error.phpt b/tests/mcrypt_decrypt_error.phpt deleted file mode 100644 index a4d7bf4..0000000 --- a/tests/mcrypt_decrypt_error.phpt +++ /dev/null @@ -1,55 +0,0 @@ ---TEST-- -Test mcrypt_decrypt() function : error conditions ---SKIPIF-- - ---FILE-- - -===DONE=== ---EXPECTF-- -*** Testing mcrypt_decrypt() : error conditions *** - --- Testing mcrypt_decrypt() function with more than expected no. of arguments -- - -Deprecated: Function mcrypt_decrypt() is deprecated in %s%emcrypt_decrypt_error.php on line 19 - -Warning: mcrypt_decrypt() expects at most 5 parameters, 6 given in %s on line %d -NULL - --- Testing mcrypt_decrypt() function with less than expected no. of arguments -- - -Deprecated: Function mcrypt_decrypt() is deprecated in %s%emcrypt_decrypt_error.php on line 26 - -Warning: mcrypt_decrypt() expects at least 4 parameters, 3 given in %s on line %d -NULL -===DONE=== diff --git a/tests/mcrypt_decrypt_variation1.phpt b/tests/mcrypt_decrypt_variation1.phpt deleted file mode 100644 index 63ec4f0..0000000 --- a/tests/mcrypt_decrypt_variation1.phpt +++ /dev/null @@ -1,255 +0,0 @@ ---TEST-- -Test mcrypt_decrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for cipher - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( mcrypt_decrypt($value, $key, $data, $mode, $iv) ); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_decrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 1-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---int -12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float .5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---int indexed array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---associative array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---nested arrays-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---uppercase NULL-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase null-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase true-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase false-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string DQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string SQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 1 to be string, object given, %s(%d) -NULL - ---undefined var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---unset var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---resource-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation1.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 1 to be string, resource given, %s(%d) -NULL -===DONE=== diff --git a/tests/mcrypt_decrypt_variation2.phpt b/tests/mcrypt_decrypt_variation2.phpt deleted file mode 100644 index b200df3..0000000 --- a/tests/mcrypt_decrypt_variation2.phpt +++ /dev/null @@ -1,255 +0,0 @@ ---TEST-- -Test mcrypt_decrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for key - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( bin2hex(mcrypt_decrypt($cipher, $value, $data, $mode, $iv))); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_decrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---int 1-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---int 12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---int -12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float 10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float -10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float .5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---empty array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---int indexed array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---associative array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---nested arrays-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---uppercase NULL-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---lowercase null-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---lowercase true-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---lowercase false-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---empty string DQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---empty string SQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 2 to be string, object given, %s(%d) -string(0) "" - ---undefined var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---unset var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---resource-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation2.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 2 to be string, resource given, %s(%d) -string(0) "" -===DONE=== diff --git a/tests/mcrypt_decrypt_variation3.phpt b/tests/mcrypt_decrypt_variation3.phpt deleted file mode 100644 index 9ae3054..0000000 --- a/tests/mcrypt_decrypt_variation3.phpt +++ /dev/null @@ -1,235 +0,0 @@ ---TEST-- -Test mcrypt_decrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for data - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump(bin2hex(mcrypt_decrypt($cipher, $key, $value, $mode, $iv))); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_decrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "52833a00168e547f" - ---int 1-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "82011a0a93098a13" - ---int 12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "e8b71c21b6acc162" - ---int -12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "db3c458e975563a8" - ---float 10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "6ee8764562f25913" - ---float -10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d63b39fd5f65678e" - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(32) "7712cc4828221be40672239d9c32e742" - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(32) "caa892cb5d28b53c2b75b1e0799427c3" - ---float .5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "99880c86884385d9" - ---empty array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---int indexed array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---associative array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---nested arrays-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---uppercase NULL-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---lowercase null-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---lowercase true-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "82011a0a93098a13" - ---lowercase false-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "82011a0a93098a13" - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---empty string DQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---empty string SQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(32) "46677e368bc07ef375bd580e0c4b2594" - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 3 to be string, object given, %s(%d) -string(0) "" - ---undefined var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---unset var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -string(16) "d27689f6fd9700f4" - ---resource-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation3.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 3 to be string, resource given, %s(%d) -string(0) "" -===DONE=== diff --git a/tests/mcrypt_decrypt_variation4.phpt b/tests/mcrypt_decrypt_variation4.phpt deleted file mode 100644 index 4cf6366..0000000 --- a/tests/mcrypt_decrypt_variation4.phpt +++ /dev/null @@ -1,255 +0,0 @@ ---TEST-- -Test mcrypt_decrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for mode - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( mcrypt_decrypt($cipher, $key, $data, $value, $iv) ); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_decrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 1-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---int -12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---float .5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---int indexed array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---associative array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---nested arrays-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---uppercase NULL-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase null-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase true-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase false-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string DQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string SQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 4 to be string, object given, %s(%d) -NULL - ---undefined var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---unset var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt(): Module initialization failed, %s(%d) -bool(false) - ---resource-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation4.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 4 to be string, resource given, %s(%d) -NULL -===DONE=== diff --git a/tests/mcrypt_decrypt_variation5.phpt b/tests/mcrypt_decrypt_variation5.phpt deleted file mode 100644 index b45ce7a..0000000 --- a/tests/mcrypt_decrypt_variation5.phpt +++ /dev/null @@ -1,255 +0,0 @@ ---TEST-- -Test mcrypt_decrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for iv - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump(bin2hex(mcrypt_decrypt($cipher, $key, $data, $mode, $value))); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_decrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---int 1-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---int 12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---int -12345-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float 10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float -10.5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float .5-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---empty array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---int indexed array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---associative array-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---nested arrays-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---uppercase NULL-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---lowercase null-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---lowercase true-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---lowercase false-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---empty string DQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---empty string SQ-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 5 to be string, object given, %s(%d) -string(0) "" - ---undefined var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---unset var-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---resource-- -Error: 8192 - Function mcrypt_decrypt() is deprecated, %s%emcrypt_decrypt_variation5.php(107) -Error: 2 - mcrypt_decrypt() expects parameter 5 to be string, resource given, %s(%d) -string(0) "" -===DONE=== diff --git a/tests/mcrypt_encrypt_error.phpt b/tests/mcrypt_encrypt_error.phpt deleted file mode 100644 index bbae095..0000000 --- a/tests/mcrypt_encrypt_error.phpt +++ /dev/null @@ -1,56 +0,0 @@ ---TEST-- -Test mcrypt_encrypt() function : error conditions ---SKIPIF-- - ---FILE-- - -===DONE=== ---EXPECTF-- -*** Testing mcrypt_encrypt() : error conditions *** - --- Testing mcrypt_encrypt() function with more than expected no. of arguments -- - -Deprecated: Function mcrypt_encrypt() is deprecated in %s%emcrypt_encrypt_error.php on line 19 - -Warning: mcrypt_encrypt() expects at most 5 parameters, 6 given in %s on line %d -NULL - --- Testing mcrypt_encrypt() function with less than expected no. of arguments -- - -Deprecated: Function mcrypt_encrypt() is deprecated in %s%emcrypt_encrypt_error.php on line 26 - -Warning: mcrypt_encrypt() expects at least 4 parameters, 3 given in %s on line %d -NULL -===DONE=== - diff --git a/tests/mcrypt_encrypt_variation1.phpt b/tests/mcrypt_encrypt_variation1.phpt deleted file mode 100644 index 1a03c05..0000000 --- a/tests/mcrypt_encrypt_variation1.phpt +++ /dev/null @@ -1,256 +0,0 @@ ---TEST-- -Test mcrypt_encrypt() function : usage variation - different types for cipher ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for cipher - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( mcrypt_encrypt($value, $key, $data, $mode, $iv) ); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_encrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 1-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---int -12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float .5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---int indexed array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---associative array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---nested arrays-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 1 to be string, array given, %s(%d) -NULL - ---uppercase NULL-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase null-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase true-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase false-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string DQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string SQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 1 to be string, object given, %s(%d) -NULL - ---undefined var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---unset var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---resource-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation1.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 1 to be string, resource given, %s(%d) -NULL -===DONE=== - diff --git a/tests/mcrypt_encrypt_variation2.phpt b/tests/mcrypt_encrypt_variation2.phpt deleted file mode 100644 index d6c0cb7..0000000 --- a/tests/mcrypt_encrypt_variation2.phpt +++ /dev/null @@ -1,256 +0,0 @@ ---TEST-- -Test mcrypt_encrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for key - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( bin2hex(mcrypt_encrypt($cipher, $value, $data, $mode, $iv) )); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_encrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---int 1-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---int 12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---int -12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float 10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float -10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---float .5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---empty array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---int indexed array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---associative array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---nested arrays-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 2 to be string, array given, %s(%d) -string(0) "" - ---uppercase NULL-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---lowercase null-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---lowercase true-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---lowercase false-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---empty string DQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---empty string SQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 2 to be string, object given, %s(%d) -string(0) "" - ---undefined var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---unset var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt(): Key of size %d not supported by this algorithm. Only keys of size 24 supported, %s(%d) -string(0) "" - ---resource-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation2.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 2 to be string, resource given, %s(%d) -string(0) "" -===DONE=== - diff --git a/tests/mcrypt_encrypt_variation3.phpt b/tests/mcrypt_encrypt_variation3.phpt deleted file mode 100644 index b538a48..0000000 --- a/tests/mcrypt_encrypt_variation3.phpt +++ /dev/null @@ -1,236 +0,0 @@ ---TEST-- -Test mcrypt_encrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for data - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( bin2hex(mcrypt_encrypt($cipher, $key, $value, $mode, $iv) )); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_encrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "51dc9cd9179b718b" - ---int 1-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "619c335f8c4f9cbf" - ---int 12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "b1258d67ab73de00" - ---int -12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "8eecf134443bd6b9" - ---float 10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "34b5750a793baff5" - ---float -10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "7a605f2aacc8a11d" - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(32) "74a0d7026ae586f476d4b17808851e86" - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(32) "bfb155997017986c01090afebd62c7ca" - ---float .5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "cc60ac201164b6c7" - ---empty array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---int indexed array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---associative array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---nested arrays-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 3 to be string, array given, %s(%d) -string(0) "" - ---uppercase NULL-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---lowercase null-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---lowercase true-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "619c335f8c4f9cbf" - ---lowercase false-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "619c335f8c4f9cbf" - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---empty string DQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---empty string SQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(32) "749c3b4d16731d98370128754b7c930f" - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 3 to be string, object given, %s(%d) -string(0) "" - ---undefined var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---unset var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -string(16) "6ece228c41457539" - ---resource-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation3.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 3 to be string, resource given, %s(%d) -string(0) "" -===DONE=== - diff --git a/tests/mcrypt_encrypt_variation4.phpt b/tests/mcrypt_encrypt_variation4.phpt deleted file mode 100644 index 21f9189..0000000 --- a/tests/mcrypt_encrypt_variation4.phpt +++ /dev/null @@ -1,255 +0,0 @@ ---TEST-- -Test mcrypt_encrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for mode - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( mcrypt_encrypt($cipher, $key, $data, $value, $iv) ); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_encrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 1-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---int 12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---int -12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---float .5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---int indexed array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---associative array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---nested arrays-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 4 to be string, array given, %s(%d) -NULL - ---uppercase NULL-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase null-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase true-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---lowercase false-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string DQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---empty string SQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 4 to be string, object given, %s(%d) -NULL - ---undefined var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---unset var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt(): Module initialization failed, %s(%d) -bool(false) - ---resource-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation4.php(107) -Error: 2 - mcrypt_encrypt() expects parameter 4 to be string, resource given, %s(%d) -NULL -===DONE=== diff --git a/tests/mcrypt_encrypt_variation5.phpt b/tests/mcrypt_encrypt_variation5.phpt deleted file mode 100644 index 3fa4785..0000000 --- a/tests/mcrypt_encrypt_variation5.phpt +++ /dev/null @@ -1,257 +0,0 @@ ---TEST-- -Test mcrypt_encrypt() function : usage variation ---SKIPIF-- - ---FILE-- - 1, 'two' => 2); - -//array of values to iterate over -$inputs = array( - - // int data - 'int 0' => 0, - 'int 1' => 1, - 'int 12345' => 12345, - 'int -12345' => -2345, - - // float data - 'float 10.5' => 10.5, - 'float -10.5' => -10.5, - 'float 12.3456789000e10' => 12.3456789000e10, - 'float -12.3456789000e10' => -12.3456789000e10, - 'float .5' => .5, - - // array data - 'empty array' => array(), - 'int indexed array' => $index_array, - 'associative array' => $assoc_array, - 'nested arrays' => array('foo', $index_array, $assoc_array), - - // null data - 'uppercase NULL' => NULL, - 'lowercase null' => null, - - // boolean data - 'lowercase true' => true, - 'lowercase false' =>false, - 'uppercase TRUE' =>TRUE, - 'uppercase FALSE' =>FALSE, - - // empty data - 'empty string DQ' => "", - 'empty string SQ' => '', - - // object data - 'instance of classWithToString' => new classWithToString(), - 'instance of classWithoutToString' => new classWithoutToString(), - - // undefined data - 'undefined var' => @$undefined_var, - - // unset data - 'unset var' => @$unset_var, - - // resource variable - 'resource' => $fp -); - -// loop through each element of the array for iv - -foreach($inputs as $valueType =>$value) { - echo "\n--$valueType--\n"; - var_dump( bin2hex(mcrypt_encrypt($cipher, $key, $data, $mode, $value))); -}; - -fclose($fp); - -?> -===DONE=== ---EXPECTF-- -*** Testing mcrypt_encrypt() : usage variation *** - ---int 0-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---int 1-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---int 12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---int -12345-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float 10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float -10.5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float 12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float -12.3456789000e10-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---float .5-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---empty array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---int indexed array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---associative array-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---nested arrays-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt() expects parameter 5 to be string, array given, %s(%d) -string(0) "" - ---uppercase NULL-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---lowercase null-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---lowercase true-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---lowercase false-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---uppercase TRUE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---uppercase FALSE-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---empty string DQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---empty string SQ-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---instance of classWithToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---instance of classWithoutToString-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt() expects parameter 5 to be string, object given, %s(%d) -string(0) "" - ---undefined var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---unset var-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt(): Received initialization vector of size %d, but size 8 is required for this encryption mode, %s(%d) -string(0) "" - ---resource-- -Error: 8192 - Function mcrypt_encrypt() is deprecated, %s%emcrypt_encrypt_variation5.php(108) -Error: 2 - mcrypt_encrypt() expects parameter 5 to be string, resource given, %s(%d) -string(0) "" -===DONE=== -