ReentrancyAttack.sol 318 B

123456789101112
  1. // SPDX-License-Identifier: MIT
  2. pragma solidity ^0.8.0;
  3. import "../utils/Context.sol";
  4. contract ReentrancyAttack is Context {
  5. function callSender(bytes4 data) public {
  6. (bool success, ) = _msgSender().call(abi.encodeWithSelector(data));
  7. require(success, "ReentrancyAttack: failed call");
  8. }
  9. }