ETH Price: $3,013.57 (-8.32%)

Contract

0x981C6644bfb019Cb70D3ceBaeCa1c5E5B1E679ff
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Withdraw Tokens206882422024-09-06 1:22:47129 days ago1725585767IN
0x981C6644...5B1E679ff
0 ETH0.000058811.48691855

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
VestingContract

Compiler Version
v0.8.26+commit.8a97fa7a

Optimization Enabled:
Yes with 200 runs

Other Settings:
shanghai EvmVersion
File 1 of 1 : VestingContract.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.26;

interface IERC20 {
    function balanceOf(address account) external view returns (uint256);
    function transfer(address to, uint256 value) external returns (bool);
}

contract VestingContract {
    address public owner;
    address public tokenAddress;
    uint256 public lockedUntil;

    constructor(address tokenAddress_, uint256 secondsLocked_) {
        owner = msg.sender;
        tokenAddress = tokenAddress_;
        lockedUntil = block.timestamp + secondsLocked_;
    }

    function withdrawTokens() public {
        require(owner == msg.sender, "Not owner");
        require(block.timestamp > lockedUntil, "Tokens are locked");
        uint256 amount_ = IERC20(tokenAddress).balanceOf(address(this));
        IERC20(tokenAddress).transfer(msg.sender, amount_);
    }
}

Settings
{
  "remappings": [
    "@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/",
    "ds-test/=lib/openzeppelin-contracts/lib/forge-std/lib/ds-test/src/",
    "erc4626-tests/=lib/openzeppelin-contracts/lib/erc4626-tests/",
    "forge-std/=lib/forge-std/src/",
    "openzeppelin-contracts/=lib/openzeppelin-contracts/"
  ],
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "metadata": {
    "useLiteralContent": false,
    "bytecodeHash": "ipfs",
    "appendCBOR": true
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "evmVersion": "shanghai",
  "viaIR": false,
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"tokenAddress_","type":"address"},{"internalType":"uint256","name":"secondsLocked_","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"lockedUntil","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tokenAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdrawTokens","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6080604052348015600e575f80fd5b5060405161035f38038061035f833981016040819052602b916065565b5f8054336001600160a01b031991821617909155600180549091166001600160a01b038416179055605b8142609a565b6002555060be9050565b5f80604083850312156075575f80fd5b82516001600160a01b0381168114608a575f80fd5b6020939093015192949293505050565b8082018082111560b857634e487b7160e01b5f52601160045260245ffd5b92915050565b610294806100cb5f395ff3fe608060405234801561000f575f80fd5b506004361061004a575f3560e01c80638d8f2adb1461004e5780638da5cb5b146100585780639d76ea5814610087578063ce0617ec1461009a575b5f80fd5b6100566100b1565b005b5f5461006a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b60015461006a906001600160a01b031681565b6100a360025481565b60405190815260200161007e565b5f546001600160a01b031633146100fb5760405162461bcd60e51b81526020600482015260096024820152682737ba1037bbb732b960b91b60448201526064015b60405180910390fd5b60025442116101405760405162461bcd60e51b8152602060048201526011602482015270151bdad95b9cc8185c99481b1bd8dad959607a1b60448201526064016100f2565b6001546040516370a0823160e01b81523060048201525f916001600160a01b0316906370a0823190602401602060405180830381865afa158015610186573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101aa9190610221565b60015460405163a9059cbb60e01b8152336004820152602481018390529192506001600160a01b03169063a9059cbb906044016020604051808303815f875af11580156101f9573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061021d9190610238565b5050565b5f60208284031215610231575f80fd5b5051919050565b5f60208284031215610248575f80fd5b81518015158114610257575f80fd5b939250505056fea264697066735822122028fe16e19bc58f31a9325e21b0b960a70d7bcaee314b57cdfca6e25c198ecc2c64736f6c634300081a00330000000000000000000000009fdc282c8d513ef43d43ff1eae39320d7804dd7e000000000000000000000000000000000000000000000000000000000000000a

Deployed Bytecode

0x608060405234801561000f575f80fd5b506004361061004a575f3560e01c80638d8f2adb1461004e5780638da5cb5b146100585780639d76ea5814610087578063ce0617ec1461009a575b5f80fd5b6100566100b1565b005b5f5461006a906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b60015461006a906001600160a01b031681565b6100a360025481565b60405190815260200161007e565b5f546001600160a01b031633146100fb5760405162461bcd60e51b81526020600482015260096024820152682737ba1037bbb732b960b91b60448201526064015b60405180910390fd5b60025442116101405760405162461bcd60e51b8152602060048201526011602482015270151bdad95b9cc8185c99481b1bd8dad959607a1b60448201526064016100f2565b6001546040516370a0823160e01b81523060048201525f916001600160a01b0316906370a0823190602401602060405180830381865afa158015610186573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906101aa9190610221565b60015460405163a9059cbb60e01b8152336004820152602481018390529192506001600160a01b03169063a9059cbb906044016020604051808303815f875af11580156101f9573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061021d9190610238565b5050565b5f60208284031215610231575f80fd5b5051919050565b5f60208284031215610248575f80fd5b81518015158114610257575f80fd5b939250505056fea264697066735822122028fe16e19bc58f31a9325e21b0b960a70d7bcaee314b57cdfca6e25c198ecc2c64736f6c634300081a0033

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

0000000000000000000000009fdc282c8d513ef43d43ff1eae39320d7804dd7e000000000000000000000000000000000000000000000000000000000000000a

-----Decoded View---------------
Arg [0] : tokenAddress_ (address): 0x9Fdc282C8d513Ef43d43fF1eAe39320D7804DD7e
Arg [1] : secondsLocked_ (uint256): 10

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 0000000000000000000000009fdc282c8d513ef43d43ff1eae39320d7804dd7e
Arg [1] : 000000000000000000000000000000000000000000000000000000000000000a


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.