Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Basic Encryption 2

Status
Not open for further replies.

overyde

Programmer
Joined
May 27, 2003
Messages
226
Location
ZA
Hi,
I'm looking for some ideas on basic encryption. Nothing too hardcore. I was thinking along the lines of MD5 encryption. Is this a good one to use, are there better ones for use on a windows machine? How do I utilise it effectively.
 
How about;

$crypted = crypt($var, "MM");

That will use MM encryption (obviously).

Cheers

Andy
 
md5 is the best even banking companies depend on it...

Known is handfull, Unknown is worldfull
 
Just note that using the crypt function is a one way algorithm, so it's fine if you never wish to decypt a previously encrypted string.

'... and then it wouldn't compile?'
t_avatar.jpg
 
Actually that's not true. One way encryption is often for useful.

Say it's for passwords...

then someone submits a password, you encrypt it and store it.

Next time they submit the password, you encrypt and compare it to the stored encrypted version. If the encryptions match, it was the same password, if the encryptions do not match, it wasn't the same password. You have all the information you need... it's a simple true false. And this way if someone snags your password database, they still can't get in to your system so you have some extra security.

-Rob
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top