Date: 08/15/00
- Next message: Eric Jones: "Re: [PHP] ISPs geared toward PHP / mySQL"
- Previous message: Sam Masiello: "RE: [PHP] odd addition error<>?"
- In reply to: Sascha Schumann: "Re: [PHP] bug? php4 with libmcrypt-2.2.7"
- Next in thread: Sascha Schumann: "Re: [PHP] bug? php4 with libmcrypt-2.2.7"
- Reply: Sascha Schumann: "Re: [PHP] bug? php4 with libmcrypt-2.2.7"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
thank you so very much for replying back to my message. i really
appreciate the time/effort.
i'm not ready to move onto 4.0.2 until the people at PHP have confirmed
that it is a stable release... which, i guess, means that libmcrypt-2.4.*
is out of the equation.
if you guys have not had any problem with it, could i ask you to do a
simple test? please run the following script and lemme know what is the
output that you get?
<?php
{
$cipher = MCRYPT_3DES;
$key = "magic_key";
$input = "blahblah";
echo (mcrypt_get_cipher_name ($cipher)."<br>");
echo (mcrypt_get_block_size($cipher)."<br>");
$en_data = mcrypt_ecb ($cipher, $key, $input, MCRYPT_ENCRYPT);
echo "en_data:$en_data<br>";
$de_date = mcrypt_ecb ($cipher, $key, $en_data, MCRYPT_DECRYPT);
echo "de_data:$de_data<br>";
}
?>
my output is:
3des
8
en_data:?Id?h?? //this is not exactly what i see on the screen, i am
seeing non-ascii characters.
de_data:
----------------
remco chang
bountyquest.com
On Tue, 15 Aug 2000, Sascha Schumann wrote:
> On Tue, 15 Aug 2000, Remco Chang wrote:
>
> > i have been battling libmcrypt for the past 2 days and came with zilch so
> > far... i am about to raise the white flag and submit it to the bug list
> > unless someone here could convince me otherwise...
> >
> > there is very little support/documentation on how php talks to libmcrypt.
> > after going through the source code, i noticed that the functions listed
> > on the web page http://www.php.net/manual/ref.mcrypt.php are not all
> > implemented... the following are the only functions supported:
> > PHP_FE(mcrypt_ecb, NULL)
> > PHP_FE(mcrypt_cbc, NULL)
> > PHP_FE(mcrypt_cfb, NULL)
> > PHP_FE(mcrypt_ofb, NULL)
> > PHP_FE(mcrypt_get_cipher_name, NULL)
> > PHP_FE(mcrypt_get_block_size, NULL)
> > PHP_FE(mcrypt_get_key_size, NULL)
> > PHP_FE(mcrypt_create_iv, NULL)
> >
> > even then, mcrypt_ecb, cbc, cfb, ofb are not working correctly. instead
> > of returning srings, they return binary garbage. this is a huge problem
> > because the decrypt function takes a string as input. because of this, i
> > cannot go through the encrypt/decrypt process and get back the original
> > message that i wanted encrypted.
>
> Your analysis is completely wrong. Strings in PHP are 8-bit
> clean. The output of the encryption process almost always
> looks like "binary garbage" (if it would make sense to you,
> it would be a bad algorithm).
>
> PHP 4.0.2 supports libmcrypt 2.4.x and also adds some
> additional user-level functions. These are already documented
> in the manual (there should be a note about them being
> supported starting at 4.0.2. If not, please submit a
> documentation bug report).
>
> - Sascha
>
>
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe <email protected> For additional commands, e-mail: php-general-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: Eric Jones: "Re: [PHP] ISPs geared toward PHP / mySQL"
- Previous message: Sam Masiello: "RE: [PHP] odd addition error<>?"
- In reply to: Sascha Schumann: "Re: [PHP] bug? php4 with libmcrypt-2.2.7"
- Next in thread: Sascha Schumann: "Re: [PHP] bug? php4 with libmcrypt-2.2.7"
- Reply: Sascha Schumann: "Re: [PHP] bug? php4 with libmcrypt-2.2.7"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

