ETH Price: $3,332.39 (+2.23%)
Gas: 2 Gwei

Contract

0x3D30B1aB88D487B0F3061F40De76845Bec3F1e94
 
Transaction Hash
Method
Block
From
To
Claim197472302024-04-27 14:21:4793 days ago1714227707IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.000539288.87072444
Claim193658192024-03-05 1:56:11146 days ago1709603771IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.0046209476.00984996
Claim188074992023-12-17 18:23:59225 days ago1702837439IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.0024590140.44827583
Claim186726672023-11-28 21:00:47244 days ago1701205247IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.002865547.13468676
Claim183862312023-10-19 18:40:59284 days ago1697740859IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.000699111.49961557
Claim183650222023-10-16 19:27:35287 days ago1697484455IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.0006269510.31272372
0x68747470139242832022-01-02 5:59:08939 days ago1641103148IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242822022-01-02 5:58:56939 days ago1641103136IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242822022-01-02 5:58:56939 days ago1641103136IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242822022-01-02 5:58:56939 days ago1641103136IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242822022-01-02 5:58:56939 days ago1641103136IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242822022-01-02 5:58:56939 days ago1641103136IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242812022-01-02 5:58:36939 days ago1641103116IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242812022-01-02 5:58:36939 days ago1641103116IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242812022-01-02 5:58:36939 days ago1641103116IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242812022-01-02 5:58:36939 days ago1641103116IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242812022-01-02 5:58:36939 days ago1641103116IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242812022-01-02 5:58:36939 days ago1641103116IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242812022-01-02 5:58:36939 days ago1641103116IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242802022-01-02 5:58:33939 days ago1641103113IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242792022-01-02 5:58:15939 days ago1641103095IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242792022-01-02 5:58:15939 days ago1641103095IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242792022-01-02 5:58:15939 days ago1641103095IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242792022-01-02 5:58:15939 days ago1641103095IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
0x68747470139242792022-01-02 5:58:15939 days ago1641103095IN
Uniswap Protocol: Treasury Vester 4
0 ETH0.001727476
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Similar Match Source Code
This contract matches the deployed Bytecode of the Source Code for Contract 0x4750c438...6C4286E1a
The constructor portion of the code might be different and could alter the actual behaviour of the contract

Contract Name:
TreasuryVester

Compiler Version
v0.5.16+commit.9c3226ce

Optimization Enabled:
Yes with 999999 runs

Other Settings:
default evmVersion, None license
/**
 *Submitted for verification at Etherscan.io on 2020-09-16
*/

pragma solidity ^0.5.16;

// From https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/math/Math.sol
// Subject to the MIT license.

/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, reverting on overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a, "SafeMath: addition overflow");

        return c;
    }

    /**
     * @dev Returns the addition of two unsigned integers, reverting with custom message on overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a, errorMessage);

        return c;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on underflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     * - Subtraction cannot underflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return sub(a, b, "SafeMath: subtraction underflow");
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on underflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     * - Subtraction cannot underflow.
     */
    function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b <= a, errorMessage);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b, "SafeMath: multiplication overflow");

        return c;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b, errorMessage);

        return c;
    }

    /**
     * @dev Returns the integer division of two unsigned integers.
     * Reverts on division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return div(a, b, "SafeMath: division by zero");
    }

    /**
     * @dev Returns the integer division of two unsigned integers.
     * Reverts with custom message on division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        // Solidity only automatically asserts when dividing by 0
        require(b > 0, errorMessage);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return mod(a, b, "SafeMath: modulo by zero");
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts with custom message when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b != 0, errorMessage);
        return a % b;
    }
}

contract TreasuryVester {
    using SafeMath for uint;

    address public uni;
    address public recipient;

    uint public vestingAmount;
    uint public vestingBegin;
    uint public vestingCliff;
    uint public vestingEnd;

    uint public lastUpdate;

    constructor(
        address uni_,
        address recipient_,
        uint vestingAmount_,
        uint vestingBegin_,
        uint vestingCliff_,
        uint vestingEnd_
    ) public {
        require(vestingBegin_ >= block.timestamp, 'TreasuryVester::constructor: vesting begin too early');
        require(vestingCliff_ >= vestingBegin_, 'TreasuryVester::constructor: cliff is too early');
        require(vestingEnd_ > vestingCliff_, 'TreasuryVester::constructor: end is too early');

        uni = uni_;
        recipient = recipient_;

        vestingAmount = vestingAmount_;
        vestingBegin = vestingBegin_;
        vestingCliff = vestingCliff_;
        vestingEnd = vestingEnd_;

        lastUpdate = vestingBegin;
    }

    function setRecipient(address recipient_) public {
        require(msg.sender == recipient, 'TreasuryVester::setRecipient: unauthorized');
        recipient = recipient_;
    }

    function claim() public {
        require(block.timestamp >= vestingCliff, 'TreasuryVester::claim: not time yet');
        uint amount;
        if (block.timestamp >= vestingEnd) {
            amount = IUni(uni).balanceOf(address(this));
        } else {
            amount = vestingAmount.mul(block.timestamp - lastUpdate).div(vestingEnd - vestingBegin);
            lastUpdate = block.timestamp;
        }
        IUni(uni).transfer(recipient, amount);
    }
}

interface IUni {
    function balanceOf(address account) external view returns (uint);
    function transfer(address dst, uint rawAmount) external returns (bool);
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"uni_","type":"address"},{"internalType":"address","name":"recipient_","type":"address"},{"internalType":"uint256","name":"vestingAmount_","type":"uint256"},{"internalType":"uint256","name":"vestingBegin_","type":"uint256"},{"internalType":"uint256","name":"vestingCliff_","type":"uint256"},{"internalType":"uint256","name":"vestingEnd_","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"constant":false,"inputs":[],"name":"claim","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"lastUpdate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"recipient","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"recipient_","type":"address"}],"name":"setRecipient","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"uni","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vestingAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vestingBegin","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vestingCliff","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vestingEnd","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"}]

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100a25760003560e01c806384a1931f11610076578063e29bc68b1161005b578063e29bc68b1461013f578063edc9af9514610147578063f3640e741461014f576100a2565b806384a1931f1461012f578063c046371114610137576100a2565b8062728f76146100a75780633bbed4a0146100c15780634e71d92d146100f657806366d003ac146100fe575b600080fd5b6100af610157565b60408051918252519081900360200190f35b6100f4600480360360208110156100d757600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661015d565b005b6100f4610214565b610106610405565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6100af610421565b6100af610427565b6100af61042d565b610106610433565b6100af61044f565b60025481565b60015473ffffffffffffffffffffffffffffffffffffffff1633146101cd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a8152602001806105cb602a913960400191505060405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60045442101561026f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806106166023913960400191505060405180910390fd5b6000600554421061031e57600054604080517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152905173ffffffffffffffffffffffffffffffffffffffff909216916370a0823191602480820192602092909190829003018186803b1580156102eb57600080fd5b505afa1580156102ff573d6000803e3d6000fd5b505050506040513d602081101561031557600080fd5b50519050610354565b61034d60035460055403610341600654420360025461045590919063ffffffff16565b9063ffffffff6104d116565b4260065590505b60008054600154604080517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9283166004820152602481018690529051919092169263a9059cbb92604480820193602093909283900390910190829087803b1580156103d657600080fd5b505af11580156103ea573d6000803e3d6000fd5b505050506040513d602081101561040057600080fd5b505050565b60015473ffffffffffffffffffffffffffffffffffffffff1681565b60055481565b60065481565b60035481565b60005473ffffffffffffffffffffffffffffffffffffffff1681565b60045481565b600082610464575060006104cb565b8282028284828161047157fe5b04146104c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806105f56021913960400191505060405180910390fd5b90505b92915050565b60006104c883836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250600081836105b4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610579578181015183820152602001610561565b50505050905090810190601f1680156105a65780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816105c057fe5b049594505050505056fe54726561737572795665737465723a3a736574526563697069656e743a20756e617574686f72697a6564536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7754726561737572795665737465723a3a636c61696d3a206e6f742074696d6520796574a265627a7a72315820b9382470bb8af267fe135bae65d43ec540b7eb889218f4b0851327c0eb2522cc64736f6c63430005100032

Deployed Bytecode Sourcemap

6600:1701:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6600:1701:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6721:25;;;:::i;:::-;;;;;;;;;;;;;;;;7641:179;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;7641:179:0;;;;:::i;:::-;;7828:470;;;:::i;6688:24::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;;6815:22;;;:::i;6846:::-;;;:::i;6753:24::-;;;:::i;6663:18::-;;;:::i;6784:24::-;;;:::i;6721:25::-;;;;:::o;7641:179::-;7723:9;;;;7709:10;:23;7701:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7790:9;:22;;;;;;;;;;;;;;;7641:179::o;7828:470::-;7890:12;;7871:15;:31;;7863:79;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7953:11;7998:10;;7979:15;:29;7975:268;;8039:3;;8034:34;;;;;;8062:4;8034:34;;;;;;8039:3;;;;;8034:19;;:34;;;;;;;;;;;;;;;8039:3;8034:34;;;5:2:-1;;;;30:1;27;20:12;5:2;8034:34:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8034:34:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;8034:34:0;;-1:-1:-1;7975:268:0;;;8110:78;8175:12;;8162:10;;:25;8110:47;8146:10;;8128:15;:28;8110:13;;:17;;:47;;;;:::i;:::-;:51;:78;:51;:78;:::i;:::-;8216:15;8203:10;:28;8101:87;-1:-1:-1;7975:268:0;8258:3;;;;8272:9;8253:37;;;;;;8258:3;8272:9;;;8253:37;;;;;;;;;;;;8258:3;;;;;8253:18;;:37;;;;;;;;;;;;;;;;;;8258:3;8253:37;;;5:2:-1;;;;30:1;27;20:12;5:2;8253:37:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8253:37:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;7828:470:0:o;6688:24::-;;;;;;:::o;6815:22::-;;;;:::o;6846:::-;;;;:::o;6753:24::-;;;;:::o;6663:18::-;;;;;;:::o;6784:24::-;;;;:::o;2740:471::-;2798:7;3043:6;3039:47;;-1:-1:-1;3073:1:0;3066:8;;3039:47;3110:5;;;3114:1;3110;:5;:1;3134:5;;;;;:10;3126:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3202:1;-1:-1:-1;2740:471:0;;;;;:::o;4398:132::-;4456:7;4483:39;4487:1;4490;4483:39;;;;;;;;;;;;;;;;;5104:7;5206:12;5199:5;5191:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;5191:28:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5230:9;5246:1;5242;:5;;;;;;;5018:345;-1:-1:-1;;;;;5018:345:0:o

Swarm Source

bzzr://b9382470bb8af267fe135bae65d43ec540b7eb889218f4b0851327c0eb2522cc

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.