PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Sunday, January 16, 2022

[FIXED] undefined method Cake\Utility\Security::cipher()

 January 16, 2022     cakephp, encryption     No comments   

Issue

I am trying to create users management modal. I am using this code

      $encryptKey = 'ab12333way2code';
      $secret = Security::cipher('StringToEncrypt', $encryptKey);

But it's showing the following Fatal error

enter image description here


Solution

The method has been removed in CakePHP 3.0

Security::cipher() has been removed. It is insecure and promoted bad cryptographic practices. You should use Security::encrypt() instead.

https://book.cakephp.org/3.0/en/appendices/3-0-migration-guide.html#security



Answered By - jbe
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home
View mobile version

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing