[Gambas-user] Crypt/Decrypt

nando nando_f at ...951...
Thu Jan 19 17:12:45 CET 2006


MD5 isn't used to decrypt.
It's used to encrypt...one way only.
For security and passwords: ** Do NOT ** compare decrypted secrets.
Always compare encrypted secrets.
When you make databases with passwords, you do not want to know
passwords...store them encrypted and process with them encrypted.
When passwords are forgotten, reset them to something.
-Fernando



---------- Original Message -----------
From: Rohnny Stormo <rohnny at ...1248...>
To: Gambas Users Listserver <gambas-user at lists.sourceforge.net>
Sent: Thu, 19 Jan 2006 16:41:59 +0100
Subject: [Gambas-user] Crypt/Decrypt

> How to crypt and decrypt a string with gambas2.
> 
> I have found md5(password, prefix) as string  and des(password, prefix)
>  as string Tried to use it twice but without any luck. If there is not 
> decryption the modules are useless except for MD5 and Check When 
> Encrypt/Decrypt are ok, you may save password to local file more secure
> 
> The class should include
> Md5(string) as string
> CheckMD5(md5String) as boolean
> EnCrypt(key, string) as string
> DeCrypt(key, EnCryptString) as string
> 
> Or if it more crypt types can be used it  could be like this
> EnCrypt(key,string, gb.crypt.???) as string
> DeCrypt(key,string, gb.crypt.???) as string
> 
> Example of usage.
> a1b2c3d4e5f6=Encrypt("MyPassword","Hello",gb.crypt.des)
> Hello = DeCrypt("MyPassword","a1b2c3d4e5f6",gb.crypt.des)
> 
> -- 
> -----------------------------------------
> Gambas brings Basic to Linux.
> My Gambas Community http://forum.stormweb.no
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc. Do you grep through log 
> files for problems?  Stop!  Download the new AJAX search engine that makes
> searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
> http://sel.as-
> us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
------- End of Original Message -------





More information about the User mailing list