• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Got an error "Decrypting: authentication failed" while using Encryption service

#3
(09-25-2020, 09:19 AM)paulbalandan Wrote: In your editCategory function, you setup two instances of the encryption config.

$config = config('Encryption'); // the shared instance
$configuration = new \Config\Encryption(); // the other instance

Yet, you passed to the encrypter is the "other" instance. This causes the wrong starter key to be used in your decryption. You need to manipulate the shared instance.

Then in both editCategory and updateCategory, you don't really need two instances of the same config file. Just use the shared config instance across your code.

Thanks for your advice.
Reply


Messages In This Thread
RE: Got an error "Decrypting: authentication failed" while using Encryption service - by nileshsanyal - 09-27-2020, 12:50 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.