je l'ai modifié et maintenant G ca..
Warning: The IV parameter must be as long as the blocksize in /home/genob/www/bonvivre/cryptage/cryptage.inc.php on line 10
ç@¯Ì].JaIÈ?]8k å)Ë?F?z¢|¥???y
Warning: The IV parameter must be as long as the blocksize in /home/genob/www/bonvivre/cryptage/cryptage.inc.php on line 17
ä\hU|?CTìíÏÈì???°ÀÁ"8?/*ù
et la modif est:
<?
// www.php.net/manual/en/function.mcrypt-encrypt.php
$iv = mcrypt_create_iv (mcrypt_get_iv_size (MCRYPT_RIJNDAEL_256, MCRYPT_MODE_ECB), MCRYPT_RAND);
$clef="Ceci est une clé secrète";
function encode($motdepasse)
{
$motdepasse_crypt = mcrypt_encrypt(MCRYPT_RIJNDAEL_256, $clef, $motdepasse, MCRYPT_MODE_ECB, $iv);
return $motdepasse_crypt;
}
function decode($motdepasse_crypt)
{
$motdepasse = mcrypt_ecb(MCRYPT_TripleDES, $clef, $motdepasse_crypt, MCRYPT_DECRYPT, $iv);
return $motdepasse;
}
?>
Message édité par chrono le 17-12-2002 à 02:23:26