Skip to content

Commit

Permalink
Merge pull request cakephp#5710 from WrDX/WrDX-patch-security-useopenssl
Browse files Browse the repository at this point in the history
Added notes regarding Security.useOpenSsl
  • Loading branch information
markstory authored Apr 12, 2018
2 parents efba9ac + 928f250 commit f808915
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions en/core-utility-libraries/security.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ The `security library <https://api.cakephp.org/2.x/class-Security.html>`_
handles basic security measures such as providing methods for
hashing and encrypting data.

.. warning::
The encryption features offered by Security rely on the deprecated
``mcrypt`` extension. If you are using PHP>=7.1 you will need to install
``mcrypt`` via PECL.
.. note::
By default the encryption features offered by Security rely on the deprecated
``mcrypt`` extension.
This behaviour can be changed by setting ``Security.useOpenSsl``.
If you are using the default behaviour using PHP>=7.1 you will need to
install ``mcrypt`` via PECL.

Security API
============
Expand Down Expand Up @@ -79,6 +81,9 @@ Security API

.. versionadded:: 2.5

.. versionadded:: 2.10.8
Set ``Security.useOpenSsl`` to use OpenSSL instead of the deprecated ``mcrpyt`` extension.

.. php:staticmethod:: decrypt($cipher, $key, $hmacSalt = null)
:param string $cipher: The ciphertext to decrypt.
Expand All @@ -101,6 +106,9 @@ Security API

.. versionadded:: 2.5

.. versionadded:: 2.10.8
Set ``Security.useOpenSsl`` to use OpenSSL instead of the deprecated ``mcrpyt`` extension.

.. php:staticmethod:: hash( $string, $type = NULL, $salt = false )
:rtype: string
Expand Down

0 comments on commit f808915

Please sign in to comment.