Combine warnings

This commit is contained in:
Chris Ward 2019-04-05 14:43:57 +02:00
parent f8b126e153
commit 26d6305a43

View File

@ -186,15 +186,13 @@ Mathematical and Cryptographic Functions
For further details, read `example usage <https://ethereum.stackexchange.com/q/1777/222>`_.
.. note::
Since `EIP-2 <http://eips.ethereum.org/EIPS/eip-2#specification>`_, all transaction signatures with an ``s`` value
greater than ``secp256k1n/2`` are considered invalid.
.. warning::
If you use ``ecrecover``, be aware that a valid signature can be turned into a different valid signature without requiring
knowledge of the corresponding private key. This is usually not a problem unless you require signatures to be unique or
knowledge of the corresponding private key. Since `EIP-2 <http://eips.ethereum.org/EIPS/eip-2#specification>`_, all transaction signatures with an ``s`` value
greater than ``secp256k1n/2`` are considered invalid.
This is usually not a problem unless you require signatures to be unique or
use them to identify items. OpenZeppelin have a `ECDSA helper library <https://docs.openzeppelin.org/docs/cryptography_ecdsa>`_ that you can use as a wrapper for ``ecrecover`` without this issue.
.. note::