Reputation: 4082
In one web application in CI, they used to save COOKIE data as an encrypted form and retrieve by decrypting it. Its was working fine since "GoDaddy" blocked "base64_encode" due to some security reasons ( Don't know why ). This is the error which I got
A PHP Error was encountered
Severity: Warning
Message: base64_decode() has been disabled for security reasons
Filename: models/extras.php
Line Number: 196
My encrypt and decrypt code as follows. Is there any alternate method for doing the same with out "base64_encode" ?
function encodeString($str){
for($i=0; $i<5;$i++)
{
$str=strrev(base64_encode($str)); //apply base64 first and then reverse the string
}
return $str;
}
function decodeString($str){
for($i=0; $i<5;$i++)
{
$str=base64_decode(strrev($str)); //apply base64 first and then reverse the string}
}
return $str;
}
Thanks in advance
Upvotes: 0
Views: 1928
Reputation: 1156
$data =array(
'password' => md5($this->input->post('password')),
);
Upvotes: 0
Reputation: 30488
In order to eliminate this error message you need to do ONE of the following things:
Upvotes: 1