From 514d48584df433b4bb9fe40103d4c2c395f8ca7d Mon Sep 17 00:00:00 2001 From: sherlock-admin4 <162441180+sherlock-admin4@users.noreply.github.com> Date: Thu, 28 Nov 2024 09:26:37 +0100 Subject: [PATCH] message --- DelegationSurrogate.sol | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 DelegationSurrogate.sol diff --git a/DelegationSurrogate.sol b/DelegationSurrogate.sol new file mode 100644 index 0000000..f14bd81 --- /dev/null +++ b/DelegationSurrogate.sol @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: AGPL-3.0-only +pragma solidity ^0.8.23; + +import {IERC20} from "openzeppelin/token/ERC20/IERC20.sol"; + +/// @title DelegationSurrogate +/// @author [ScopeLift](https://scopelift.co) +/// @notice A dead-simple contract whose only purpose is to hold ERC20 tokens which can always be +/// moved by the Surrogate's deployer. +abstract contract DelegationSurrogate { + /// @param _token The token that will be held by this surrogate. + constructor(IERC20 _token) { + _token.approve(msg.sender, type(uint256).max); + } +}