> For the complete documentation index, see [llms.txt](https://docs.optimumsec.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.optimumsec.xyz/coding/use-cryptographic-libs.md).

# Use Cryptographic Libraries

In Solidity, verifying signatures is a crucial part of ensuring that only authorized parties can perform specific actions in a smart contract. Instead of writing custom signature verification logic, developers should rely on well-established [cryptography libraries](https://github.com/OpenZeppelin/openzeppelin-contracts/tree/master/contracts/utils/cryptography).

These libraries have been thoroughly tested and are less likely to contain critical bugs that could lead to exploits, such as unauthorized access or fraudulent transactions. Issues around `ecrecover`, like signature malleability or improper error handling, as well as potential integration bugs with ERC-1271 signatures, are also addressed by these libraries.
