When I try as follows, the value gets stored encryted, but I cannot read it
as the getDecryptedUsername function returns false at the decrypt line:
protected function _setUsername($username)
{
$key = 'wt1U5MACWJFTXGenFoZoiLwQGrLgdbHA';
if(strlen($username) > 0)
{
$username = Security::encrypt($username, $key);
}
return($username);
}
protected function _getDecryptedUsername()
{
$key = 'wt1U5MACWJFTXGenFoZoiLwQGrLgdbHA';
$username = $this->_properties['username'];
if(strlen($username) > 0)
{
$username = Security::decrypt($username, $key);
}
return($username);
}
--
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup
We will soon be closing this Google Group. But don't worry, we have something
better coming. Stay tuned for an updated from the CakePHP Team soon.
Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
---
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.