{
    "Function": "isValidSignatureNow",
    "File": "contracts/openzeppelin-solidity/contracts/utils/cryptography/SignatureChecker.sol",
    "Parent Contracts": [],
    "High-Level Calls": [
        "ECDSA"
    ],
    "Internal Calls": [
        "abi.encodeWithSelector()",
        "abi.decode()"
    ],
    "Library Calls": [
        "tryRecover"
    ],
    "Low-Level Calls": [
        "staticcall"
    ],
    "Code": "function isValidSignatureNow(\n        address signer,\n        bytes32 hash,\n        bytes memory signature\n    ) internal view returns (bool) {\n        (address recovered, ECDSA.RecoverError error) = ECDSA.tryRecover(hash, signature);\n        if (error == ECDSA.RecoverError.NoError && recovered == signer) {\n            return true;\n        }\n\n        (bool success, bytes memory result) = signer.staticcall(\n            abi.encodeWithSelector(IERC1271.isValidSignature.selector, hash, signature)\n        );\n        return (success && result.length == 32 && abi.decode(result, (bytes4)) == IERC1271.isValidSignature.selector);\n    }"
}