View Full Version : encrypt in lm formula ?
qwe010
2nd October 2008, 19:53
hello
in php i can encrypt in md5 formula
but how i can encrypt in lm/des/md4 formula
any idea ?
qwe010
4th October 2008, 23:42
up for help
Ben
5th October 2008, 12:52
to hash or one-way-encrypt data with other algorithms than md5 either see crypt() (http://de.php.net/manual/en/function.crypt.php) or use sha1() (http://de.php.net/manual/en/function.sha1.php).
for real en/decryption check gnupg implementation in php (http://de.php.net/manual/en/book.gnupg.php)
you may also check http://pear.php.net for other usefull things here.
qwe010
8th October 2008, 07:57
thanks Ben
but what about sha265 ?
Ben
8th October 2008, 10:29
i don't know. I can't search more in the www than you can ;) (google would guide you to usercomments like the following).
Source: http://us2.php.net/sha1
Note that the sha1 algorithm has been compromised and is no longer being used by government agencies.
As of PHP 5.1.2 a new set of hashing functions are available.
http://www.php.net/manual/en/function.hash.php
The new function hash() supports a new range of hashing methods.
echo hash('sha256', 'The quick brown fox jumped over the lazy dog.');
It is recommended that developers start to future proof their applications by using the stronger sha-2, hashing methods such as sha256, sha384, sha512 or better.
As of PHP 5.1.2 hash_algos() returns an array of system specific or registered hashing algorithms methods that are available to PHP.
print_r(hash_algos());
Btw are you looking for something specific? As you mentioned some (hasing) algorithms above, but not sha256 but even the much weaker md4...
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.