More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 1,731 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Burn Tokens | 20324303 | 6 hrs ago | IN | 0 ETH | 0.00065331 | ||||
Burn Tokens | 20319190 | 23 hrs ago | IN | 0 ETH | 0.00033159 | ||||
Burn Tokens | 20300003 | 3 days ago | IN | 0 ETH | 0.00008731 | ||||
Burn Tokens | 20281342 | 6 days ago | IN | 0 ETH | 0.00011292 | ||||
Burn Tokens | 20276217 | 6 days ago | IN | 0 ETH | 0.00026893 | ||||
Burn Tokens | 20270787 | 7 days ago | IN | 0 ETH | 0.00019222 | ||||
Burn Tokens | 20266197 | 8 days ago | IN | 0 ETH | 0.00007974 | ||||
Burn Tokens | 20263714 | 8 days ago | IN | 0 ETH | 0.00014608 | ||||
Burn Tokens | 20261690 | 9 days ago | IN | 0 ETH | 0.00016698 | ||||
Burn Tokens | 20256220 | 9 days ago | IN | 0 ETH | 0.00010531 | ||||
Burn Tokens | 20255968 | 9 days ago | IN | 0 ETH | 0.00014103 | ||||
Burn Tokens | 20255591 | 9 days ago | IN | 0 ETH | 0.00012036 | ||||
Burn Tokens | 20251872 | 10 days ago | IN | 0 ETH | 0.00006862 | ||||
Burn Tokens | 20249856 | 10 days ago | IN | 0 ETH | 0.00008275 | ||||
Burn Tokens | 20249688 | 10 days ago | IN | 0 ETH | 0.0000809 | ||||
Burn Tokens | 20247327 | 11 days ago | IN | 0 ETH | 0.00012374 | ||||
Burn Tokens | 20239581 | 12 days ago | IN | 0 ETH | 0.0003954 | ||||
Burn Tokens | 20234150 | 12 days ago | IN | 0 ETH | 0.00063561 | ||||
Burn Tokens | 20232063 | 13 days ago | IN | 0 ETH | 0.00045651 | ||||
Burn Tokens | 20229215 | 13 days ago | IN | 0 ETH | 0.00022923 | ||||
Burn Tokens | 20228735 | 13 days ago | IN | 0 ETH | 0.00022417 | ||||
Burn Tokens | 20228723 | 13 days ago | IN | 0 ETH | 0.00026412 | ||||
Burn Tokens | 20227529 | 13 days ago | IN | 0 ETH | 0.00063573 | ||||
Burn Tokens | 20225860 | 14 days ago | IN | 0 ETH | 0.00033939 | ||||
Burn Tokens | 20225134 | 14 days ago | IN | 0 ETH | 0.0002061 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
TokenBurner
Compiler Version
v0.8.21+commit.d9974bed
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; contract TokenBurner { IERC20 public token; event TokensBurned(address indexed user, uint256 amount, string mintlayerAddress); constructor() { token = IERC20(0x059956483753947536204e89bfaD909E1a434Cc6); } function isValidMintlayerAddress(string memory _mintlayerAddress) public pure returns (bool) { bytes memory b = bytes(_mintlayerAddress); if (b.length < 42 || b.length > 46) { return false; } // Checking if it starts with "mtc1q" if (b[0] != 'm' || b[1] != 't' || b[2] != 'c' || b[3] != '1') { return false; } return true; } function burnTokens(uint256 _amount, string memory _mintlayerAddress) public { require(_amount > 0, "Amount must be greater than 0"); require(isValidMintlayerAddress(_mintlayerAddress), "Invalid Mintlayer address"); // Transferring tokens to the contract require(token.transferFrom(msg.sender, address(this), _amount), "Transfer failed"); // Emitting event emit TokensBurned(msg.sender, _amount, _mintlayerAddress); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @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); /** * @dev Returns the value of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the value of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves a `value` amount of tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 value) 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 a `value` amount of tokens 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 value) external returns (bool); /** * @dev Moves a `value` amount of tokens from `from` to `to` using the * allowance mechanism. `value` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 value) external returns (bool); }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"string","name":"mintlayerAddress","type":"string"}],"name":"TokensBurned","type":"event"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"string","name":"_mintlayerAddress","type":"string"}],"name":"burnTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_mintlayerAddress","type":"string"}],"name":"isValidMintlayerAddress","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405234801561000f575f80fd5b505f80546001600160a01b03191673059956483753947536204e89bfad909e1a434cc6179055610522806100425f395ff3fe608060405234801561000f575f80fd5b506004361061003f575f3560e01c80633e193783146100435780638faa18561461006b578063fc0c546a14610080575b5f80fd5b6100566100513660046103e1565b6100aa565b60405190151581526020015b60405180910390f35b61007e61007936600461041b565b61019f565b005b5f54610092906001600160a01b031681565b6040516001600160a01b039091168152602001610062565b5f80829050602a815110806100c05750602e8151115b156100cd57505f92915050565b805f815181106100df576100df61045f565b6020910101516001600160f81b031916606d60f81b14158061012757508060018151811061010f5761010f61045f565b6020910101516001600160f81b031916601d60fa1b14155b806101585750806002815181106101405761014061045f565b6020910101516001600160f81b031916606360f81b14155b806101895750806003815181106101715761017161045f565b6020910101516001600160f81b031916603160f81b14155b1561019657505f92915050565b50600192915050565b5f82116101f35760405162461bcd60e51b815260206004820152601d60248201527f416d6f756e74206d7573742062652067726561746572207468616e203000000060448201526064015b60405180910390fd5b6101fc816100aa565b6102485760405162461bcd60e51b815260206004820152601960248201527f496e76616c6964204d696e746c6179657220616464726573730000000000000060448201526064016101ea565b5f546040516323b872dd60e01b8152336004820152306024820152604481018490526001600160a01b03909116906323b872dd906064016020604051808303815f875af115801561029b573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906102bf9190610473565b6102fd5760405162461bcd60e51b815260206004820152600f60248201526e151c985b9cd9995c8819985a5b1959608a1b60448201526064016101ea565b336001600160a01b03167ffad31924d655455395c87544c8aa1ffdb5a7505a22a3c2e03f28003b6556a75f8383604051610338929190610499565b60405180910390a25050565b634e487b7160e01b5f52604160045260245ffd5b5f82601f830112610367575f80fd5b813567ffffffffffffffff8082111561038257610382610344565b604051601f8301601f19908116603f011681019082821181831017156103aa576103aa610344565b816040528381528660208588010111156103c2575f80fd5b836020870160208301375f602085830101528094505050505092915050565b5f602082840312156103f1575f80fd5b813567ffffffffffffffff811115610407575f80fd5b61041384828501610358565b949350505050565b5f806040838503121561042c575f80fd5b82359150602083013567ffffffffffffffff811115610449575f80fd5b61045585828601610358565b9150509250929050565b634e487b7160e01b5f52603260045260245ffd5b5f60208284031215610483575f80fd5b81518015158114610492575f80fd5b9392505050565b8281525f602060408184015283518060408501525f5b818110156104cb578581018301518582016060015282016104af565b505f606082860101526060601f19601f83011685010192505050939250505056fea26469706673582212208dc6db9d302003055e6b9ad7406f7495519936d9c49c00476bb9015a588fe57b64736f6c63430008150033
Deployed Bytecode
0x608060405234801561000f575f80fd5b506004361061003f575f3560e01c80633e193783146100435780638faa18561461006b578063fc0c546a14610080575b5f80fd5b6100566100513660046103e1565b6100aa565b60405190151581526020015b60405180910390f35b61007e61007936600461041b565b61019f565b005b5f54610092906001600160a01b031681565b6040516001600160a01b039091168152602001610062565b5f80829050602a815110806100c05750602e8151115b156100cd57505f92915050565b805f815181106100df576100df61045f565b6020910101516001600160f81b031916606d60f81b14158061012757508060018151811061010f5761010f61045f565b6020910101516001600160f81b031916601d60fa1b14155b806101585750806002815181106101405761014061045f565b6020910101516001600160f81b031916606360f81b14155b806101895750806003815181106101715761017161045f565b6020910101516001600160f81b031916603160f81b14155b1561019657505f92915050565b50600192915050565b5f82116101f35760405162461bcd60e51b815260206004820152601d60248201527f416d6f756e74206d7573742062652067726561746572207468616e203000000060448201526064015b60405180910390fd5b6101fc816100aa565b6102485760405162461bcd60e51b815260206004820152601960248201527f496e76616c6964204d696e746c6179657220616464726573730000000000000060448201526064016101ea565b5f546040516323b872dd60e01b8152336004820152306024820152604481018490526001600160a01b03909116906323b872dd906064016020604051808303815f875af115801561029b573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906102bf9190610473565b6102fd5760405162461bcd60e51b815260206004820152600f60248201526e151c985b9cd9995c8819985a5b1959608a1b60448201526064016101ea565b336001600160a01b03167ffad31924d655455395c87544c8aa1ffdb5a7505a22a3c2e03f28003b6556a75f8383604051610338929190610499565b60405180910390a25050565b634e487b7160e01b5f52604160045260245ffd5b5f82601f830112610367575f80fd5b813567ffffffffffffffff8082111561038257610382610344565b604051601f8301601f19908116603f011681019082821181831017156103aa576103aa610344565b816040528381528660208588010111156103c2575f80fd5b836020870160208301375f602085830101528094505050505092915050565b5f602082840312156103f1575f80fd5b813567ffffffffffffffff811115610407575f80fd5b61041384828501610358565b949350505050565b5f806040838503121561042c575f80fd5b82359150602083013567ffffffffffffffff811115610449575f80fd5b61045585828601610358565b9150509250929050565b634e487b7160e01b5f52603260045260245ffd5b5f60208284031215610483575f80fd5b81518015158114610492575f80fd5b9392505050565b8281525f602060408184015283518060408501525f5b818110156104cb578581018301518582016060015282016104af565b505f606082860101526060601f19601f83011685010192505050939250505056fea26469706673582212208dc6db9d302003055e6b9ad7406f7495519936d9c49c00476bb9015a588fe57b64736f6c63430008150033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 26 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|---|---|---|---|---|
ETH | 100.00% | $0.179554 | 46,309,406.1889 | $8,315,032.36 |
[ 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.