problem with mcrypt_generic_deinit function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have a problem with this function.
When I execute via web the script: 


<?php
  $llave = "esta es una llave secre";
  $entrada = "Encontrémonos a las 9 en punto en el lugar secre."; 

  $td = mcrypt_module_open('tripledes', '', 'ofb', '');
  $iv = mcrypt_create_iv (mcrypt_enc_get_iv_size($td), MCRYPT_RAND);
  mcrypt_generic_init($td, $llave, $iv);
  $datos_cifrados = mcrypt_generic($td, $entrada);
  echo $datos_cifrados;
  mcrypt_generic_deinit($td);
  mcrypt_module_close($td);
?> 

I get the following: 

3`ZïeYS lyZøW».c¿º&#190;óÇY»ÞÐ" &#8221;4&#189;ôUr-Ì¿°&#732;¯h 

Fatal error: Call to undefined function: mcrypt_generic_deinit() in 
/path/script.php on line 10 

The first line on the www client is the third line on the script: 
"Encontrémonos a las 9 en punto en el lugar secre", but encrypted. 

If I comment line 10 the script run succesfully. 

The server is a debian woody with apache and php-mcrypt module. 

The function mcrypt_generic_deinit is necessary or is posible to use mcrypt 
without this function? 

Could somebody help me with this. 

Thanks in advance.

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux