openssl_encrypt_crash.phpt 312 B

123456789101112
  1. --TEST--
  2. openssl_encrypt() crash with old OpenSSL
  3. --EXTENSIONS--
  4. openssl
  5. --FILE--
  6. <?php
  7. openssl_encrypt('', 'AES-128-CBC', 'foo');
  8. var_dump("done");
  9. ?>
  10. --EXPECTF--
  11. Warning: openssl_encrypt(): Using an empty Initialization Vector (iv) is potentially insecure and not recommended in %s on line %d
  12. string(4) "done"