Re: [PHP] Re: Problem decrypting data stored in MySQL text field using mcrypt?

2004-01-28 Thread Terence
Why not use the AES_ENCRYPT and AES_DECRYPT functions?

from the MySQL manual:

AES_ENCRYPT() and AES_DECRYPT() were added in version 4.0.2, and can be
considered the most cryptographically secure encryption functions currently
available in MySQL.

SELECT AES_ENCRTPY('my_password_is_easy', 'secretword')
->?"¤»5Ë#TӝAò=WN¤/¿w>øÓpñe¬1d\m,

SELECT AES_ENCRTPY(my_column, 'secretword')
->my_password_is_easy



- Original Message - 
From: "Murray @ PlanetThoughtful.org" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 29, 2004 2:31 PM
Subject: RE: [PHP] Re: Problem decrypting data stored in MySQL text field
using mcrypt?


Hi Jas,

Not really -- I can't help thinking there's something about retrieving the
encrypted value from the MySQL text field that makes the end result
un-decryptable...

I was hoping that someone could provide me with a working example that
encrypts a value, stores in a MySQL table, then retrieves the value from the
table, decrypts it and returns the same text as the original plaintext...

But, thank you very, very much for going out of your way to help, all the
same...

Much warmth,

Murray
http://www.planetthoughtful.org
Building a thoughtful planet,
One quirky comment at a time.



-Original Message-
From: Jas [mailto:[EMAIL PROTECTED]
Sent: Monday, 26 January 2004 4:48 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Re: Problem decrypting data stored in MySQL text field using
mcrypt?


Jas wrote:

[ Here there be snippage ]

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

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



RE: [PHP] Re: Problem decrypting data stored in MySQL text field using mcrypt?

2004-01-28 Thread Murray @ PlanetThoughtful.org
Hi Jas,

Not really -- I can't help thinking there's something about retrieving the
encrypted value from the MySQL text field that makes the end result
un-decryptable...

I was hoping that someone could provide me with a working example that
encrypts a value, stores in a MySQL table, then retrieves the value from the
table, decrypts it and returns the same text as the original plaintext...

But, thank you very, very much for going out of your way to help, all the
same...

Much warmth,

Murray
http://www.planetthoughtful.org
Building a thoughtful planet,
One quirky comment at a time.



-Original Message-
From: Jas [mailto:[EMAIL PROTECTED] 
Sent: Monday, 26 January 2004 4:48 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Re: Problem decrypting data stored in MySQL text field using
mcrypt?


Jas wrote:

[ Here there be snippage ]

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