Ok So I Have Made 2 Encryption Functions.
This One Guarantees Safe Information But is it over doing it?
will this slow down the server load time?. :s
Second
Are Both Secure and is this useless code?
This One Guarantees Safe Information But is it over doing it?
will this slow down the server load time?. :s
PHP:
function encrypt($key) {
// Change Algorithm
if(count($key) < 12) {
$key = hash('sha256', $key);
} else {
$key = hash('gost', $key);
}
// Add Encrypted Key together
$key = $key.md5($key).str_ireplace('1', 'efx', $key);
// Return sha1 Encrypted .. Encrypted Key
return sha1($key);
}
Second
PHP:
function encrypt($key) {
return hash('gost', sha1($key));
}
Are Both Secure and is this useless code?