Add (inactive) encryption on 2FAccount controller

This commit is contained in:
Bubka 2020-01-21 21:31:28 +01:00
parent 7fca9cdf3c
commit c044dcd6c6
2 changed files with 34 additions and 1 deletions

View File

@ -4,6 +4,7 @@
use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Facades\Storage;
use Illuminate\Contracts\Encryption\DecryptException;
class TwoFAccount extends Model
{
@ -40,4 +41,35 @@ public function getIconAttribute($value)
return $value;
}
/**
* Set the user's first name.
*
* @param string $value
* @return void
*/
// public function setUriAttribute($value)
// {
// $this->attributes['uri'] = encrypt($value);
// }
/**
* Get the user's first name.
*
* @param string $value
* @return string
*/
// public function getUriAttribute($value)
// {
// try {
// return decrypt($value);
// } catch (DecryptException $e) {
// return null;
// }
// }
}

View File

@ -22,6 +22,7 @@
'response' => [
'no_valid_totp' => 'No valid TOTP resource in this QR code',
],
'something_wrong_with_server' => 'Something is wrong with your server'
'something_wrong_with_server' => 'Something is wrong with your server',,
'Unable_to_decrypt_uri' => 'Unable to decrypt uri',
];