ETH Price: $2,000.48 (-0.69%)

Contract

0x54e3cb7e3F6A1882d258b226BFf18Efd40B64E63
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Deposit203907392024-07-26 12:31:11244 days ago1721997071IN
0x54e3cb7e...d40B64E63
0 ETH0.007088912.39539636
Withdraw203900412024-07-26 10:10:59244 days ago1721988659IN
0x54e3cb7e...d40B64E63
0 ETH0.000295294.68964673
Deposit203900372024-07-26 10:10:11244 days ago1721988611IN
0x54e3cb7e...d40B64E63
0 ETH0.009333663.15391208
Withdraw200424202024-06-07 20:45:11292 days ago1717793111IN
0x54e3cb7e...d40B64E63
0 ETH0.0013303819.63182056
Withdraw198396002024-05-10 12:21:23321 days ago1715343683IN
0x54e3cb7e...d40B64E63
0 ETH0.000279794.12881603
Withdraw196399122024-04-12 13:45:47349 days ago1712929547IN
0x54e3cb7e...d40B64E63
0 ETH0.0020350230.02968529
Withdraw194398222024-03-15 10:42:47377 days ago1710499367IN
0x54e3cb7e...d40B64E63
0 ETH0.0020560740.58010653
Withdraw194398202024-03-15 10:42:23377 days ago1710499343IN
0x54e3cb7e...d40B64E63
0 ETH0.0022380233.02522797
Withdraw191416322024-02-02 15:34:35419 days ago1706888075IN
0x54e3cb7e...d40B64E63
0 ETH0.0016353124.13145491
Withdraw189119662024-01-01 10:22:23451 days ago1704104543IN
0x54e3cb7e...d40B64E63
0 ETH0.000673329.93589112
Withdraw186997132023-12-02 15:48:23481 days ago1701532103IN
0x54e3cb7e...d40B64E63
0 ETH0.001787735.28334129
Withdraw186997112023-12-02 15:47:59481 days ago1701532079IN
0x54e3cb7e...d40B64E63
0 ETH0.0018439536.39366581
Withdraw186997092023-12-02 15:47:35481 days ago1701532055IN
0x54e3cb7e...d40B64E63
0 ETH0.0018425236.36535208
Withdraw186997072023-12-02 15:47:11481 days ago1701532031IN
0x54e3cb7e...d40B64E63
0 ETH0.0018798337.10172812
Withdraw186997052023-12-02 15:46:47481 days ago1701532007IN
0x54e3cb7e...d40B64E63
0 ETH0.0026825139.58444416
Withdraw186994102023-12-02 14:47:23481 days ago1701528443IN
0x54e3cb7e...d40B64E63
0 ETH0.0025003836.8968332
Withdraw185419432023-11-10 13:48:35503 days ago1699624115IN
0x54e3cb7e...d40B64E63
0 ETH0.001909337.68345368
Withdraw185419412023-11-10 13:48:11503 days ago1699624091IN
0x54e3cb7e...d40B64E63
0 ETH0.0019509938.50616996
Withdraw185419392023-11-10 13:47:47503 days ago1699624067IN
0x54e3cb7e...d40B64E63
0 ETH0.0020671240.79823873
Withdraw185419372023-11-10 13:47:23503 days ago1699624043IN
0x54e3cb7e...d40B64E63
0 ETH0.0026036638.4209008
Withdraw182415282023-09-29 12:59:59545 days ago1695992399IN
0x54e3cb7e...d40B64E63
0 ETH0.0006294612.42359867
Withdraw182415262023-09-29 12:59:35545 days ago1695992375IN
0x54e3cb7e...d40B64E63
0 ETH0.0006116412.07186929
Withdraw182415242023-09-29 12:59:11545 days ago1695992351IN
0x54e3cb7e...d40B64E63
0 ETH0.0005824811.49642124
Withdraw182415222023-09-29 12:58:47545 days ago1695992327IN
0x54e3cb7e...d40B64E63
0 ETH0.000502579.91916642
Withdraw182415192023-09-29 12:58:11545 days ago1695992291IN
0x54e3cb7e...d40B64E63
0 ETH0.000445888.80023393
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
TimeLock

Compiler Version
v0.6.0+commit.26b70077

Optimization Enabled:
No with 200 runs

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

// contracts/OffshiftVesting.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.6.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}

contract TimeLock {
    IERC20 token;

    struct LockBoxStruct {
        address beneficiary;
        uint balance;
        uint releaseTime;
    }

    LockBoxStruct[] public lockBoxStructs; // This could be a mapping by address, but these numbered lockBoxes support possibility of multiple tranches per address

    event LogLockBoxDeposit(address sender, uint amount, uint releaseTime);
    event LogLockBoxWithdrawal(address receiver, uint amount);

    constructor(address tokenContract) public {
        token = IERC20(tokenContract);
    }

    function deposit(address beneficiary, uint totalAmount, uint trenchAmount, uint firstRelease, uint releaseStride) public returns(bool success) {
        require(token.transferFrom(msg.sender, address(this), totalAmount));
        LockBoxStruct memory l;
        l.beneficiary = beneficiary;
        l.balance = trenchAmount;
        l.releaseTime = firstRelease;
        lockBoxStructs.push(l);
        for (uint i = 1; i < 60; ++i) {
            uint time = firstRelease + (releaseStride * i);
            l.releaseTime = time;
            lockBoxStructs.push(l);
            emit LogLockBoxDeposit(msg.sender, trenchAmount, time);
        }
        return true;
    }

    function withdraw(uint lockBoxNumber) public returns(bool success) {
        LockBoxStruct storage l = lockBoxStructs[lockBoxNumber];
        require(l.beneficiary == msg.sender);
        require(l.releaseTime <= now);
        uint amount = l.balance;
        l.balance = 0;
        emit LogLockBoxWithdrawal(msg.sender, amount);
        require(token.transfer(msg.sender, amount));
        return true;
    }

}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"address","name":"tokenContract","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"releaseTime","type":"uint256"}],"name":"LogLockBoxDeposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"LogLockBoxWithdrawal","type":"event"},{"inputs":[{"internalType":"address","name":"beneficiary","type":"address"},{"internalType":"uint256","name":"totalAmount","type":"uint256"},{"internalType":"uint256","name":"trenchAmount","type":"uint256"},{"internalType":"uint256","name":"firstRelease","type":"uint256"},{"internalType":"uint256","name":"releaseStride","type":"uint256"}],"name":"deposit","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"lockBoxStructs","outputs":[{"internalType":"address","name":"beneficiary","type":"address"},{"internalType":"uint256","name":"balance","type":"uint256"},{"internalType":"uint256","name":"releaseTime","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"lockBoxNumber","type":"uint256"}],"name":"withdraw","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b5060405161081f38038061081f8339818101604052602081101561003357600080fd5b8101908080519060200190929190505050806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505061078b806100946000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c80632e1a7d4d146100465780633d8cf56f1461008c5780636893680914610108575b600080fd5b6100726004803603602081101561005c57600080fd5b810190808035906020019092919050505061018c565b604051808215151515815260200191505060405180910390f35b6100b8600480360360208110156100a257600080fd5b810190808035906020019092919050505061038e565b604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390f35b610172600480360360a081101561011e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919080359060200190929190803590602001909291905050506103e5565b604051808215151515815260200191505060405180910390f35b6000806001838154811061019c57fe5b906000526020600020906003020190503373ffffffffffffffffffffffffffffffffffffffff168160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461020857600080fd5b428160020154111561021957600080fd5b600081600101549050600082600101819055507f4ee0bce2f3dfb53dc0564ce5a7e1934da5c7866b06ba77f86c397b7b976a31443382604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060405180910390a16000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a9059cbb33836040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b15801561033f57600080fd5b505af1158015610353573d6000803e3d6000fd5b505050506040513d602081101561036957600080fd5b810190808051906020019092919050505061038357600080fd5b600192505050919050565b6001818154811061039b57fe5b90600052602060002090600302016000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010154908060020154905083565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166323b872dd3330886040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b1580156104c357600080fd5b505af11580156104d7573d6000803e3d6000fd5b505050506040513d60208110156104ed57600080fd5b810190808051906020019092919050505061050757600080fd5b61050f61071e565b86816000019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250508481602001818152505083816040018181525050600181908060018154018082558091505060019003906000526020600020906003020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550602082015181600101556040820151816002015550506000600190505b603c81101561070f5760008185028601905080836040018181525050600183908060018154018082558091505060019003906000526020600020906003020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550602082015181600101556040820151816002015550507fcf2fafad2e64ab2802e3c57893f71b2645379029535db982282b4b24f4ff567a338883604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a1508060010190506105eb565b50600191505095945050505050565b6040518060600160405280600073ffffffffffffffffffffffffffffffffffffffff1681526020016000815260200160008152509056fea2646970667358221220f6a55477a25b8fbd927c69d7a51eda9c08d0fde67e5f96dfcb74d63d045c8bc664736f6c63430006000033000000000000000000000000abe580e7ee158da464b51ee1a83ac0289622e6be

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100415760003560e01c80632e1a7d4d146100465780633d8cf56f1461008c5780636893680914610108575b600080fd5b6100726004803603602081101561005c57600080fd5b810190808035906020019092919050505061018c565b604051808215151515815260200191505060405180910390f35b6100b8600480360360208110156100a257600080fd5b810190808035906020019092919050505061038e565b604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390f35b610172600480360360a081101561011e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919080359060200190929190803590602001909291905050506103e5565b604051808215151515815260200191505060405180910390f35b6000806001838154811061019c57fe5b906000526020600020906003020190503373ffffffffffffffffffffffffffffffffffffffff168160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461020857600080fd5b428160020154111561021957600080fd5b600081600101549050600082600101819055507f4ee0bce2f3dfb53dc0564ce5a7e1934da5c7866b06ba77f86c397b7b976a31443382604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060405180910390a16000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a9059cbb33836040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b15801561033f57600080fd5b505af1158015610353573d6000803e3d6000fd5b505050506040513d602081101561036957600080fd5b810190808051906020019092919050505061038357600080fd5b600192505050919050565b6001818154811061039b57fe5b90600052602060002090600302016000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010154908060020154905083565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166323b872dd3330886040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050602060405180830381600087803b1580156104c357600080fd5b505af11580156104d7573d6000803e3d6000fd5b505050506040513d60208110156104ed57600080fd5b810190808051906020019092919050505061050757600080fd5b61050f61071e565b86816000019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250508481602001818152505083816040018181525050600181908060018154018082558091505060019003906000526020600020906003020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550602082015181600101556040820151816002015550506000600190505b603c81101561070f5760008185028601905080836040018181525050600183908060018154018082558091505060019003906000526020600020906003020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550602082015181600101556040820151816002015550507fcf2fafad2e64ab2802e3c57893f71b2645379029535db982282b4b24f4ff567a338883604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a1508060010190506105eb565b50600191505095945050505050565b6040518060600160405280600073ffffffffffffffffffffffffffffffffffffffff1681526020016000815260200160008152509056fea2646970667358221220f6a55477a25b8fbd927c69d7a51eda9c08d0fde67e5f96dfcb74d63d045c8bc664736f6c63430006000033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

000000000000000000000000abe580e7ee158da464b51ee1a83ac0289622e6be

-----Decoded View---------------
Arg [0] : tokenContract (address): 0xABe580E7ee158dA464b51ee1a83Ac0289622e6be

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000abe580e7ee158da464b51ee1a83ac0289622e6be


Deployed Bytecode Sourcemap

2807:1685:0:-:0;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2807:1685:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4069:418;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4069:418:0;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2970:37;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2970:37:0;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3378:683;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;3378:683:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4069:418;4122:12;4147:23;4173:14;4188:13;4173:29;;;;;;;;;;;;;;;;;;4147:55;;4238:10;4221:27;;:1;:13;;;;;;;;;;;;:27;;;4213:36;;;;;;4285:3;4268:1;:13;;;:20;;4260:29;;;;;;4300:11;4314:1;:9;;;4300:23;;4346:1;4334;:9;;:13;;;;4363:40;4384:10;4396:6;4363:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;4422:5;;;;;;;;;;;:14;;;4437:10;4449:6;4422:34;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4422:34:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4422:34:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4422:34:0;;;;;;;;;;;;;;;;4414:43;;;;;;4475:4;4468:11;;;;4069:418;;;:::o;2970:37::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;3378:683::-;3507:12;3540:5;;;;;;;;;;;:18;;;3559:10;3579:4;3586:11;3540:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3540:58:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3540:58:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3540:58:0;;;;;;;;;;;;;;;;3532:67;;;;;;3610:22;;:::i;:::-;3659:11;3643:1;:13;;:27;;;;;;;;;;;3693:12;3681:1;:9;;:24;;;;;3732:12;3716:1;:13;;:28;;;;;3755:14;3775:1;3755:22;;39:1:-1;33:3;27:10;23:18;57:10;52:3;45:23;79:10;72:17;;0:93;3755:22:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3793:6;3802:1;3793:10;;3788:244;3809:2;3805:1;:6;3788:244;;;3833:9;3877:1;3861:13;:17;3845:12;:34;3833:46;;3910:4;3894:1;:13;;:20;;;;;3929:14;3949:1;3929:22;;39:1:-1;33:3;27:10;23:18;57:10;52:3;45:23;79:10;72:17;;0:93;3929:22:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3971:49;3989:10;4001:12;4015:4;3971:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3788:244;3813:3;;;;;3788:244;;;;4049:4;4042:11;;;3378:683;;;;;;;:::o;2807:1685::-;;;;;;;;;;;;;;;;;;;;;;;;;;:::o

Swarm Source

ipfs://f6a55477a25b8fbd927c69d7a51eda9c08d0fde67e5f96dfcb74d63d045c8bc6

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
Loading...
Loading
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.