Re[2]: [PHP] recent encrpyt decrypt code... (problems)

2002-10-05 Thread Tom Rogers

Hi,

Sunday, October 6, 2002, 4:20:40 AM, you wrote:
JB here is the URL that will give you the php compile info on my website
JB (phpinfo)

Looks identical to mine as far as mcrypt is concerned.
Try changing the $key = to this:

$key = 'test';


 As it looks like the key is getting truncated to 0


-- 
regards,
Tom


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re[2]: [PHP] recent encrpyt decrypt code... (problems)

2002-10-05 Thread Tom Rogers

Hi,

Sunday, October 6, 2002, 7:32:11 AM, you wrote:
JB ok - that made things work...  here is the output.  it looks like it is
JB still encrypting it.  what would the resolution be for this, or can I set
JB the key to anything I want?

Ok I have got to the bottom of it :)
You changed the name of the class but did not change the name of the
constructor so the key was never getting set.
So change
class encrypt_decrypt
{
var $secret;
function encrypt_class(){
$this-secret = 'this is a very long key, even too long for the 
cipher';
}

to:
class encrypt_decrypt{
var $secret;
function encrypt_decrypt(){
$this-secret = 'this is a very long key, even too long for the 
cipher';

}




-- 
regards,
Tom


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: Re[2]: [PHP] recent encrpyt decrypt code... (problems)

2002-10-05 Thread Jeff Bluemel

ok Tom - that worked...

thanks for your help and assistance...  I never would have figured this out
without the help.

Jeff

Tom Rogers [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 Hi,

 Sunday, October 6, 2002, 7:32:11 AM, you wrote:
 JB ok - that made things work...  here is the output.  it looks like it
is
 JB still encrypting it.  what would the resolution be for this, or can I
set
 JB the key to anything I want?

 Ok I have got to the bottom of it :)
 You changed the name of the class but did not change the name of the
 constructor so the key was never getting set.
 So change
 class encrypt_decrypt
 {
 var $secret;
 function encrypt_class(){
 $this-secret = 'this is a very long key, even too long
for the cipher';
 }

 to:
 class encrypt_decrypt{
 var $secret;
 function encrypt_decrypt(){
 $this-secret = 'this is a very long key, even too long
for the cipher';

 }




 --
 regards,
 Tom




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re[2]: [PHP] recent encrpyt decrypt code... (problems)

2002-10-04 Thread Tom Rogers

Hi,

Saturday, October 5, 2002, 4:10:03 AM, you wrote:
JB I had not downloaded mcrypt, but I download it (which required a later
JB version of mhash so I downloaded, and installed it too).  I compiled
JB everything with the instrucitons you listed, and I am still getttng the same
JB error messages.

I just recompiled using the latest versions of libmcrypt - mcrypt -
mhash and it still works ok. I don't use dynamic loading of php it is
built into apache statically.
What version of PHP/apache are you using? .. I use 4.2.3

-- 
regards,
Tom


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php