More Info
Private Name Tags
ContractCreator
TokenTracker
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
TosTeamLockContract
Compiler Version
v0.4.21+commit.dfe3193c
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2018-06-11 */ pragma solidity ^0.4.18; /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { function totalSupply() public view returns (uint256); function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) public view returns (uint256); function transferFrom(address from, address to, uint256 value) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval(address indexed owner, address indexed spender, uint256 value); } contract TOSERC20 is ERC20 { function lockBalanceOf(address who) public view returns (uint256); } /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure. * To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { function safeTransfer(ERC20 token, address to, uint256 value) internal { assert(token.transfer(to, value)); } function safeTransferFrom( ERC20 token, address from, address to, uint256 value ) internal { assert(token.transferFrom(from, to, value)); } function safeApprove(ERC20 token, address spender, uint256 value) internal { assert(token.approve(spender, value)); } } /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a * b; assert(a == 0 || c / a == b); return c; } function div(uint256 a, uint256 b) internal pure returns (uint256) { // assert(b > 0); // Solidity automatically throws when dividing by 0 uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return c; } function sub(uint256 a, uint256 b) internal pure returns (uint256) { assert(b <= a); return a - b; } function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; assert(c >= a); return c; } } /** * @title TosTeamLockContract * @dev TosTeamLockContract is a token holder contract that will allow a * beneficiary to extract the tokens after a given unlock time */ contract TosTeamLockContract { using SafeERC20 for TOSERC20; using SafeMath for uint; string public constant name = "TosTeamLockContract"; uint256 public constant RELEASE_TIME = 1623254400; //2021/6/10 0:0:0; uint256 public constant RELEASE_PERIODS = 180 days; TOSERC20 public tosToken = TOSERC20(0xFb5a551374B656C6e39787B1D3A03fEAb7f3a98E); address public beneficiary = 0xA24cB9920d882e084Cc29304d1f9c80D288F8054; uint256 public numOfReleased = 0; function TosTeamLockContract() public {} /** * @notice Transfers tokens held by timelock to beneficiary. */ function release() public { // solium-disable-next-line security/no-block-members require(now >= RELEASE_TIME); uint256 num = (now - RELEASE_TIME) / RELEASE_PERIODS; require(num + 1 > numOfReleased); uint256 amount = tosToken.balanceOf(this).mul(30).div(100); require(amount > 0); tosToken.safeTransfer(beneficiary, amount); numOfReleased = numOfReleased.add(1); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"constant":true,"inputs":[],"name":"RELEASE_PERIODS","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"numOfReleased","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"beneficiary","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"RELEASE_TIME","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"release","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"tosToken","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"}]
Contract Creation Code
606060405260008054600160a060020a031990811673fb5a551374b656c6e39787b1d3a03feab7f3a98e1782556001805490911673a24cb9920d882e084cc29304d1f9c80d288f8054179055600255341561005957600080fd5b610406806100686000396000f3006060604052600436106100685763ffffffff60e060020a600035041662ad3a23811461006d57806306fdde031461009257806334f251461461011c57806338af3eed1461012f5780633dc1579a1461015e57806386d1a69f14610171578063877aaf4f14610186575b600080fd5b341561007857600080fd5b610080610199565b60405190815260200160405180910390f35b341561009d57600080fd5b6100a56101a0565b60405160208082528190810183818151815260200191508051906020019080838360005b838110156100e15780820151838201526020016100c9565b50505050905090810190601f16801561010e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561012757600080fd5b6100806101d7565b341561013a57600080fd5b6101426101dd565b604051600160a060020a03909116815260200160405180910390f35b341561016957600080fd5b6100806101ec565b341561017c57600080fd5b6101846101f4565b005b341561019157600080fd5b610142610302565b62ed4e0081565b60408051908101604052601381527f546f735465616d4c6f636b436f6e747261637400000000000000000000000000602082015281565b60025481565b600154600160a060020a031681565b6360c0e58081565b6000806360c0e58042101561020857600080fd5b60025462ed4e00426360c0e57f1901049250600183011161022857600080fd5b6000546102b5906064906102a990601e90600160a060020a03166370a082313060405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b151561028657600080fd5b5af1151561029357600080fd5b505050604051805191905063ffffffff61031116565b9063ffffffff61033c16565b9050600081116102c457600080fd5b6001546000546102e791600160a060020a0391821691168363ffffffff61035316565b6002546102fb90600163ffffffff6103cb16565b6002555050565b600054600160a060020a031681565b600082820283158061032d575082848281151561032a57fe5b04145b151561033557fe5b9392505050565b600080828481151561034a57fe5b04949350505050565b82600160a060020a031663a9059cbb838360405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b15156103a757600080fd5b5af115156103b457600080fd5b5050506040518051905015156103c657fe5b505050565b60008282018381101561033557fe00a165627a7a72305820255f44b0448d950f5669b923d678e0b363ecb8cdd2e5e85156526482805913e40029
Deployed Bytecode
0x6060604052600436106100685763ffffffff60e060020a600035041662ad3a23811461006d57806306fdde031461009257806334f251461461011c57806338af3eed1461012f5780633dc1579a1461015e57806386d1a69f14610171578063877aaf4f14610186575b600080fd5b341561007857600080fd5b610080610199565b60405190815260200160405180910390f35b341561009d57600080fd5b6100a56101a0565b60405160208082528190810183818151815260200191508051906020019080838360005b838110156100e15780820151838201526020016100c9565b50505050905090810190601f16801561010e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561012757600080fd5b6100806101d7565b341561013a57600080fd5b6101426101dd565b604051600160a060020a03909116815260200160405180910390f35b341561016957600080fd5b6100806101ec565b341561017c57600080fd5b6101846101f4565b005b341561019157600080fd5b610142610302565b62ed4e0081565b60408051908101604052601381527f546f735465616d4c6f636b436f6e747261637400000000000000000000000000602082015281565b60025481565b600154600160a060020a031681565b6360c0e58081565b6000806360c0e58042101561020857600080fd5b60025462ed4e00426360c0e57f1901049250600183011161022857600080fd5b6000546102b5906064906102a990601e90600160a060020a03166370a082313060405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b151561028657600080fd5b5af1151561029357600080fd5b505050604051805191905063ffffffff61031116565b9063ffffffff61033c16565b9050600081116102c457600080fd5b6001546000546102e791600160a060020a0391821691168363ffffffff61035316565b6002546102fb90600163ffffffff6103cb16565b6002555050565b600054600160a060020a031681565b600082820283158061032d575082848281151561032a57fe5b04145b151561033557fe5b9392505050565b600080828481151561034a57fe5b04949350505050565b82600160a060020a031663a9059cbb838360405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b15156103a757600080fd5b5af115156103b457600080fd5b5050506040518051905015156103c657fe5b505050565b60008282018381101561033557fe00a165627a7a72305820255f44b0448d950f5669b923d678e0b363ecb8cdd2e5e85156526482805913e40029
Swarm Source
bzzr://255f44b0448d950f5669b923d678e0b363ecb8cdd2e5e85156526482805913e4
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 31 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
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.