PDA

View Full Version : encrypt database email records


pedroz
01-13-2007, 11:11 PM
I was wondering if it is possible to encrypt the email addresses of the database records because I do not want to provide it to my hosting company.

Any idea?

Thanks!

Attilitus
01-14-2007, 03:51 AM
Unfortunately, you cannot encrypt email addresses in the same manner as you can encrypt passwords.

Passwords are encrypted using MD5 hashing which is one way encoding that cannot be changed back. (When you enter in your password to login it gets MD5 hashed and then checked with the hash on file).

Email addresses cannot be used that way, as it needs to be in a "real" format of emailaddress @ emailaddressprovider.com. The best that you could do would be some kind of obstufication...

Why are you concerned that your host might want to steal your member's email addresses?

Dismounted
01-14-2007, 04:19 AM
You could always use base64. Pretty easily cracked but better than nothing.

Attilitus
01-14-2007, 04:31 AM
Yea... I hate to give a cop-out response like this, but if you don't trust your host to this extreme extent, perhaps you ought not be using them.

I mean... to suspect that your host might steal your member-bases emails is a little extreme. Especially because the emails would be non-opt-in addresses and would thus be worth very little if they planned to sell them.