More Info
Private Name Tags
ContractCreator
TokenTracker
Latest 25 from a total of 461 transactions
| Transaction Hash |
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Approve | 147403182 | 3 days ago | IN | 0 ETH | 0.000000026115 | ||||
| Transfer | 147327024 | 5 days ago | IN | 0 ETH | 0.000000352174 | ||||
| Transfer | 147326908 | 5 days ago | IN | 0 ETH | 0.000000353077 | ||||
| Approve | 147326846 | 5 days ago | IN | 0 ETH | 0.000000249756 | ||||
| Transfer | 147259326 | 6 days ago | IN | 0 ETH | 0.000000001875 | ||||
| Transfer | 147258876 | 6 days ago | IN | 0 ETH | 0.000000002065 | ||||
| Approve | 146832537 | 16 days ago | IN | 0 ETH | 0.000000000876 | ||||
| Approve | 146236111 | 30 days ago | IN | 0 ETH | 0.000000003291 | ||||
| Approve | 146225866 | 30 days ago | IN | 0 ETH | 0.000000004721 | ||||
| Approve | 146219285 | 30 days ago | IN | 0 ETH | 0.000000001061 | ||||
| Approve | 146183549 | 31 days ago | IN | 0 ETH | 0.000000005164 | ||||
| Approve | 146119870 | 33 days ago | IN | 0 ETH | 0.000000003434 | ||||
| Approve | 146119857 | 33 days ago | IN | 0 ETH | 0.000000006259 | ||||
| Approve | 146119843 | 33 days ago | IN | 0 ETH | 0.000000003305 | ||||
| Approve | 146119829 | 33 days ago | IN | 0 ETH | 0.00000000331 | ||||
| Approve | 146119821 | 33 days ago | IN | 0 ETH | 0.000000003322 | ||||
| Approve | 146119793 | 33 days ago | IN | 0 ETH | 0.000000003259 | ||||
| Approve | 146119075 | 33 days ago | IN | 0 ETH | 0.000000003454 | ||||
| Approve | 146119070 | 33 days ago | IN | 0 ETH | 0.000000003387 | ||||
| Approve | 146119045 | 33 days ago | IN | 0 ETH | 0.000000003388 | ||||
| Approve | 146119027 | 33 days ago | IN | 0 ETH | 0.00000000338 | ||||
| Approve | 146118946 | 33 days ago | IN | 0 ETH | 0.000000003532 | ||||
| Approve | 146118937 | 33 days ago | IN | 0 ETH | 0.000000003523 | ||||
| Approve | 146116617 | 33 days ago | IN | 0 ETH | 0.000000003366 | ||||
| Approve | 146116608 | 33 days ago | IN | 0 ETH | 0.000000003336 |
View more zero value Internal Transactions in Advanced View mode
Cross-Chain Transactions
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.18;
import { MiniMeBase } from "@vacp2p/minime/contracts/MiniMeBase.sol";
import { IERC165 } from "@openzeppelin/contracts/utils/introspection/IERC165.sol";
import { ILegacyMintableERC20, IOptimismMintableERC20 } from "./IOptimismMintableERC20.sol";
import { Semver } from "./Semver.sol";
/// @title OptimismMintableMiniMeToken
/// @notice OptimismMintableMiniMeToken is a standard extension of the base MiniMeToken token contract designed
/// to allow the StandardBridge contracts to mint and burn tokens. This makes it possible to
/// use an OptimismMintablERC20 as the L2 representation of an L1 token, or vice-versa.
/// Designed to be backwards compatible with the older StandardL2ERC20 token which was only
/// meant for use on L2.
contract OptimismMintableMiniMeToken is IOptimismMintableERC20, ILegacyMintableERC20, MiniMeBase, Semver {
/// @notice Error that is thrown if the sender is not the bridge.
error OptimismMintableMiniMeToken_SenderNotBridge();
/// @notice Address of the corresponding version of this token on the remote chain.
address public immutable REMOTE_TOKEN;
/// @notice Address of the StandardBridge on this network.
address public immutable BRIDGE;
/// @notice Emitted whenever tokens are minted for an account.
/// @param account Address of the account tokens are being minted for.
/// @param amount Amount of tokens minted.
event Mint(address indexed account, uint256 amount);
/// @notice Emitted whenever tokens are burned from an account.
/// @param account Address of the account tokens are being burned from.
/// @param amount Amount of tokens burned.
event Burn(address indexed account, uint256 amount);
/// @notice A modifier that only allows the bridge to call
modifier onlyBridge() {
if (msg.sender != BRIDGE) revert OptimismMintableMiniMeToken_SenderNotBridge();
_;
}
/// @custom:semver 1.0.1
/// @param _bridge Address of the L2 standard bridge.
/// @param _remoteToken Address of the corresponding L1 token.
/// @param _tokenName ERC20 name.
/// @param _tokenSymbol ERC20 symbol.
constructor(
address _bridge,
address _remoteToken,
MiniMeBase _parentToken,
uint256 _parentSnapShotBlock,
string memory _tokenName,
uint8 _decimalUnits,
string memory _tokenSymbol,
bool _transfersEnabled
)
MiniMeBase(_parentToken, _parentSnapShotBlock, _tokenName, _decimalUnits, _tokenSymbol, _transfersEnabled)
Semver(1, 0, 1)
{
REMOTE_TOKEN = _remoteToken;
BRIDGE = _bridge;
}
/// @notice Allows the StandardBridge on this network to mint tokens.
/// @param _to Address to mint tokens to.
/// @param _amount Amount of tokens to mint.
function mint(
address _to,
uint256 _amount
)
external
override(IOptimismMintableERC20, ILegacyMintableERC20)
onlyBridge
{
_mint(_to, _amount);
emit Mint(_to, _amount);
}
/// @notice Allows the StandardBridge on this network to burn tokens.
/// @param _from Address to burn tokens from.
/// @param _amount Amount of tokens to burn.
function burn(
address _from,
uint256 _amount
)
external
override(IOptimismMintableERC20, ILegacyMintableERC20)
onlyBridge
{
_burn(_from, _amount);
emit Burn(_from, _amount);
}
/// @notice ERC165 interface check function.
/// @param _interfaceId Interface ID to check.
/// @return Whether or not the interface is supported by this contract.
function supportsInterface(bytes4 _interfaceId) external pure returns (bool) {
bytes4 iface1 = type(IERC165).interfaceId;
// Interface corresponding to the legacy L2StandardERC20.
bytes4 iface2 = type(ILegacyMintableERC20).interfaceId;
// Interface corresponding to the updated OptimismMintableMiniMeToken (this contract).
bytes4 iface3 = type(IOptimismMintableERC20).interfaceId;
return _interfaceId == iface1 || _interfaceId == iface2 || _interfaceId == iface3;
}
/// @custom:legacy
/// @notice Legacy getter for the remote token. Use REMOTE_TOKEN going forward.
function l1Token() public view returns (address) {
return REMOTE_TOKEN;
}
/// @custom:legacy
/// @notice Legacy getter for the bridge. Use BRIDGE going forward.
function l2Bridge() public view returns (address) {
return BRIDGE;
}
/// @custom:legacy
/// @notice Legacy getter for REMOTE_TOKEN.
function remoteToken() public view returns (address) {
return REMOTE_TOKEN;
}
/// @custom:legacy
/// @notice Legacy getter for BRIDGE.
function bridge() public view returns (address) {
return BRIDGE;
}
}// SPDX-License-Identifier: GPL-3.0
pragma solidity ^0.8.0;
error TransfersDisabled();
error ParentSnapshotNotReached();
error NotEnoughBalance();
error NotEnoughAllowance();
error InvalidDestination();
error ControllerRejected();
error Overflow();
error AllowanceAlreadySet();
error ControllerNotSet();
error ERC2612ExpiredSignature(uint256 deadline);
error ERC2612InvalidSigner(address signer, address owner);
/*
Copyright 2016, Jordi Baylina
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
import { Controlled } from "./Controlled.sol";
import { TokenController } from "./TokenController.sol";
import { ApproveAndCallFallBack } from "./ApproveAndCallFallBack.sol";
import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import { IERC20Permit } from "@openzeppelin/contracts/token/ERC20/extensions/IERC20Permit.sol";
import { EIP712 } from "@openzeppelin/contracts/utils/cryptography/EIP712.sol";
import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
import { Nonces } from "./Nonces.sol";
/// @title MiniMeBase Contract
/// @author Jordi Baylina
/// @dev This token contract's goal is to make it easy for anyone to clone this
/// token using the token distribution at a given block, this will allow DAO's
/// and DApps to upgrade their features in a decentralized manner without
/// affecting the original token
abstract contract MiniMeBase is Controlled, IERC20, IERC20Permit, EIP712, Nonces {
string public name; //The Token's name: e.g. DigixDAO Tokens
uint8 public immutable decimals; //Number of decimals of the smallest unit
string public symbol; //An identifier: e.g. REP
string public constant TOKEN_VERSION = "MMT_0.2"; //An arbitrary versioning scheme
bytes32 private constant PERMIT_TYPEHASH =
keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)");
/// @dev `Checkpoint` is the structure that attaches a block number to a
/// given value, the block number attached is the one that last changed the
/// value
struct Checkpoint {
// `fromBlock` is the block number that the value was generated from
uint128 fromBlock;
// `value` is the amount of tokens at a specific block number
uint128 value;
}
// `parentToken` is the Token address that was cloned to produce this token;
// it will be 0x0 for a token that was not cloned
MiniMeBase public immutable parentToken;
// `parentSnapShotBlock` is the block number from the Parent Token that was
// used to determine the initial distribution of the Clone Token
uint256 public immutable parentSnapShotBlock;
// `creationBlock` is the block number that the Clone Token was created
uint256 public immutable creationBlock;
// `balances` is the map that tracks the balance of each address, in this
// contract when the balance changes the block number that the change
// occurred is also included in the map
mapping(address account => Checkpoint[] history) private balances;
// `allowed` tracks any extra transfer rights as in all ERC20 tokens
mapping(address account => mapping(address authorized => uint256 amount) allowance) private allowed;
// Tracks the history of the `totalSupply` of the token
Checkpoint[] private totalSupplyHistory;
// Flag that determines if the token is transferable or not.
bool public transfersEnabled;
/// @notice Constructor to create a MiniMeBase
/// @param _parentToken Address of the parent token, set to 0x0 if it is a
/// new token
/// @param _parentSnapShotBlock Block of the parent token that will
/// determine the initial distribution of the clone token, set to 0 if it
/// is a new token
/// @param _tokenName Name of the new token
/// @param _decimalUnits Number of decimals of the new token
/// @param _tokenSymbol Token Symbol for the new token
/// @param _transfersEnabled If true, tokens will be able to be transferred
constructor(
MiniMeBase _parentToken,
uint256 _parentSnapShotBlock,
string memory _tokenName,
uint8 _decimalUnits,
string memory _tokenSymbol,
bool _transfersEnabled
)
EIP712(_tokenName, TOKEN_VERSION)
{
name = _tokenName; // Set the name
decimals = _decimalUnits; // Set the decimals
symbol = _tokenSymbol; // Set the symbol
parentToken = _parentToken;
parentSnapShotBlock = _parentSnapShotBlock;
transfersEnabled = _transfersEnabled;
creationBlock = block.number;
}
///////////////////
// ERC20 Methods
///////////////////
/// @notice Send `_amount` tokens to `_to` from `msg.sender`
/// @param _to The address of the recipient
/// @param _amount The amount of tokens to be transferred
/// @return success Whether the transfer was successful or not
function transfer(address _to, uint256 _amount) public returns (bool success) {
if (!transfersEnabled) revert TransfersDisabled();
doTransfer(msg.sender, _to, _amount);
return true;
}
/// @notice Send `_amount` tokens to `_to` from `_from` on the condition it
/// is approved by `_from`
/// @param _from The address holding the tokens being transferred
/// @param _to The address of the recipient
/// @param _amount The amount of tokens to be transferred
/// @return success True if the transfer was successful
function transferFrom(address _from, address _to, uint256 _amount) public returns (bool success) {
// The controller of this contract can move tokens around at will,
// this is important to recognize! Confirm that you trust the
// controller of this contract, which in most situations should be
// another open source smart contract or 0x0
if (msg.sender != controller) {
if (!transfersEnabled) revert TransfersDisabled();
// The standard ERC 20 transferFrom functionality
if (allowed[_from][msg.sender] < _amount) revert NotEnoughAllowance();
allowed[_from][msg.sender] -= _amount;
}
doTransfer(_from, _to, _amount);
return true;
}
/// @dev This is the actual transfer function in the token contract, it can
/// only be called by other functions in this contract.
/// @param _from The address holding the tokens being transferred
/// @param _to The address of the recipient
/// @param _amount The amount of tokens to be transferred
function doTransfer(address _from, address _to, uint256 _amount) internal {
if (_amount == 0) {
emit Transfer(_from, _to, _amount); // Follow the spec to louch the event when transfer 0
return;
}
if (parentSnapShotBlock >= block.number) revert ParentSnapshotNotReached();
// Do not allow transfer to 0x0 or the token contract itself
if ((_to == address(0)) || (_to == address(this))) revert InvalidDestination();
// If the amount being transfered is more than the balance of the
// account the transfer throws
uint256 previousBalanceFrom = balanceOfAt(_from, block.number);
if (previousBalanceFrom < _amount) revert NotEnoughBalance();
// First update the balance array with the new value for the address
// sending the tokens
updateValueAtNow(balances[_from], previousBalanceFrom - _amount);
// Then update the balance array with the new value for the address
// receiving the tokens
uint256 previousBalanceTo = balanceOfAt(_to, block.number);
updateValueAtNow(balances[_to], previousBalanceTo + _amount);
// Alerts the token controller of the transfer
if (isContract(controller)) {
if (!TokenController(controller).onTransfer(_from, _to, _amount)) {
revert ControllerRejected();
}
}
// An event to make the transfer easy to find on the blockchain
emit Transfer(_from, _to, _amount);
}
/// @param _owner The address that's balance is being requested
/// @return balance The balance of `_owner` at the current block
function balanceOf(address _owner) public view returns (uint256 balance) {
return balanceOfAt(_owner, block.number);
}
/// @notice `msg.sender` approves `_spender` to spend `_amount` tokens on
/// its behalf. This is a modified version of the ERC20 approve function
/// to be a little bit safer
/// @param _spender The address of the account able to transfer the tokens
/// @param _amount The amount of tokens to be approved for transfer
/// @return success True if the approval was successful
function approve(address _spender, uint256 _amount) public returns (bool success) {
return doApprove(msg.sender, _spender, _amount);
}
/**
* @inheritdoc IERC20Permit
*/
function permit(
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
)
public
virtual
{
if (block.timestamp > deadline) {
revert ERC2612ExpiredSignature(deadline);
}
bytes32 structHash = keccak256(abi.encode(PERMIT_TYPEHASH, owner, spender, value, _useNonce(owner), deadline));
bytes32 hash = _hashTypedDataV4(structHash);
address signer = ECDSA.recover(hash, v, r, s);
if (signer != owner) {
revert ERC2612InvalidSigner(signer, owner);
}
doApprove(owner, spender, value);
}
function doApprove(address _owner, address _spender, uint256 _amount) internal returns (bool) {
if (!transfersEnabled) revert TransfersDisabled();
// To change the approve amount you first have to reduce the addresses`
// allowance to zero by calling `approve(_spender,0)` if it is not
// already 0 to mitigate the race condition described here:
// https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
if ((_amount != 0) && (allowed[_owner][_spender] != 0)) revert AllowanceAlreadySet();
// Alerts the token controller of the approve function call
if (isContract(controller)) {
if (!TokenController(controller).onApprove(_owner, _spender, _amount)) {
revert ControllerRejected();
}
}
allowed[_owner][_spender] = _amount;
emit Approval(_owner, _spender, _amount);
return true;
}
/// @dev This function makes it easy to read the `allowed[]` map
/// @param _owner The address of the account that owns the token
/// @param _spender The address of the account able to transfer the tokens
/// @return remaining Amount of remaining tokens of _owner that _spender is allowed
/// to spend
function allowance(address _owner, address _spender) public view returns (uint256 remaining) {
return allowed[_owner][_spender];
}
/// @notice `msg.sender` approves `_spender` to send `_amount` tokens on
/// its behalf, and then a function is triggered in the contract that is
/// being approved, `_spender`. This allows users to use their tokens to
/// interact with contracts in one function call instead of two
/// @param _spender The address of the contract able to transfer the tokens
/// @param _amount The amount of tokens to be approved for transfer
/// @return success True if the function call was successful
function approveAndCall(address _spender, uint256 _amount, bytes memory _extraData) public returns (bool success) {
approve(_spender, _amount);
ApproveAndCallFallBack(_spender).receiveApproval(msg.sender, _amount, address(this), _extraData);
return true;
}
/// @dev This function makes it easy to get the total number of tokens
/// @return The total number of tokens
function totalSupply() public view returns (uint256) {
return totalSupplyAt(block.number);
}
////////////////
// Query balance and totalSupply in History
////////////////
/// @dev Queries the balance of `_owner` at a specific `_blockNumber`
/// @param _owner The address from which the balance will be retrieved
/// @param _blockNumber The block number when the balance is queried
/// @return The balance at `_blockNumber`
function balanceOfAt(address _owner, uint256 _blockNumber) public view returns (uint256) {
// These next few lines are used when the balance of the token is
// requested before a check point was ever created for this token, it
// requires that the `parentToken.balanceOfAt` be queried at the
// genesis block for that token as this contains initial balance of
// this token
if ((balances[_owner].length == 0) || (balances[_owner][0].fromBlock > _blockNumber)) {
if (address(parentToken) != address(0)) {
return parentToken.balanceOfAt(_owner, min(_blockNumber, parentSnapShotBlock));
} else {
// Has no parent
return 0;
}
// This will return the expected balance during normal situations
} else {
return getValueAt(balances[_owner], _blockNumber);
}
}
/// @notice Total amount of tokens at a specific `_blockNumber`.
/// @param _blockNumber The block number when the totalSupply is queried
/// @return The total amount of tokens at `_blockNumber`
function totalSupplyAt(uint256 _blockNumber) public view returns (uint256) {
// These next few lines are used when the totalSupply of the token is
// requested before a check point was ever created for this token, it
// requires that the `parentToken.totalSupplyAt` be queried at the
// genesis block for this token as that contains totalSupply of this
// token at this block number.
if ((totalSupplyHistory.length == 0) || (totalSupplyHistory[0].fromBlock > _blockNumber)) {
if (address(parentToken) != address(0)) {
return parentToken.totalSupplyAt(min(_blockNumber, parentSnapShotBlock));
} else {
return 0;
}
// This will return the expected totalSupply during normal situations
} else {
return getValueAt(totalSupplyHistory, _blockNumber);
}
}
///
/// @inheritdoc IERC20Permit
///
function nonces(address owner) public view virtual override(IERC20Permit, Nonces) returns (uint256) {
return super.nonces(owner);
}
///
/// @inheritdoc IERC20Permit
///
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view virtual returns (bytes32) {
return _domainSeparatorV4();
}
////////////////
// Generate and destroy tokens
////////////////
/// @notice Generates `_amount` tokens that are assigned to `_owner`
/// @param _owner The address that will be assigned the new tokens
/// @param _amount The quantity of tokens generated
/// @return True if the tokens are generated correctly
function _mint(address _owner, uint256 _amount) internal virtual returns (bool) {
uint256 curTotalSupply = totalSupply();
if (uint128(curTotalSupply + _amount) < curTotalSupply) revert Overflow(); // Check for overflow
uint256 previousBalanceTo = balanceOf(_owner);
updateValueAtNow(totalSupplyHistory, curTotalSupply + _amount);
updateValueAtNow(balances[_owner], previousBalanceTo + _amount);
emit Transfer(address(0), _owner, _amount);
return true;
}
/// @notice Burns `_amount` tokens from `_owner`
/// @param _owner The address that will lose the tokens
/// @param _amount The quantity of tokens to burn
/// @return True if the tokens are burned correctly
function _burn(address _owner, uint256 _amount) internal virtual returns (bool) {
uint256 curTotalSupply = totalSupply();
uint256 previousBalanceFrom = balanceOf(_owner);
if (previousBalanceFrom < _amount) revert NotEnoughBalance();
updateValueAtNow(totalSupplyHistory, curTotalSupply - _amount);
updateValueAtNow(balances[_owner], previousBalanceFrom - _amount);
emit Transfer(_owner, address(0), _amount);
return true;
}
////////////////
// Enable tokens transfers
////////////////
/// @notice Enables token holders to transfer their tokens freely if true
/// @param _transfersEnabled True if transfers are allowed in the clone
function enableTransfers(bool _transfersEnabled) public onlyController {
transfersEnabled = _transfersEnabled;
}
////////////////
// Internal helper functions to query and set a value in a snapshot array
////////////////
/// @dev `getValueAt` retrieves the number of tokens at a given block number
/// @param checkpoints The history of values being queried
/// @param _block The block number to retrieve the value at
/// @return The number of tokens being queried
function getValueAt(Checkpoint[] storage checkpoints, uint256 _block) internal view returns (uint256) {
uint256 len = checkpoints.length;
if (len == 0) return 0;
// Shortcut for the actual value
if (_block >= checkpoints[len - 1].fromBlock) {
return checkpoints[len - 1].value;
}
if (_block < checkpoints[0].fromBlock) return 0;
// Binary search of the value in the array
uint256 sMin = 0;
uint256 max = len - 1;
while (max > sMin) {
uint256 mid = (max + sMin + 1) / 2;
if (checkpoints[mid].fromBlock <= _block) {
sMin = mid;
} else {
max = mid - 1;
}
}
return checkpoints[sMin].value;
}
/// @dev `updateValueAtNow` used to update the `balances` map and the
/// `totalSupplyHistory`
/// @param checkpoints The history of data being updated
/// @param _value The new number of tokens
function updateValueAtNow(Checkpoint[] storage checkpoints, uint256 _value) internal {
uint256 len = checkpoints.length;
if (len > 0) {
Checkpoint storage checkpoint = checkpoints[len - 1];
if (checkpoint.fromBlock < block.number) {
checkpoint = checkpoints.push();
checkpoint.fromBlock = uint128(block.number);
}
checkpoint.value = uint128(_value);
} else {
Checkpoint storage checkpoint = checkpoints.push();
checkpoint.fromBlock = uint128(block.number);
checkpoint.value = uint128(_value);
}
}
/// @dev Internal function to determine if an address is a contract
/// @param _addr The address being queried
/// @return True if `_addr` is a contract
function isContract(address _addr) internal view returns (bool) {
uint256 size;
if (_addr == address(0)) return false;
// solhint-disable-next-line no-inline-assembly
assembly {
size := extcodesize(_addr)
}
return size > 0;
}
/// @dev Helper function to return a min betwen the two uints
function min(uint256 a, uint256 b) internal pure returns (uint256) {
return a < b ? a : b;
}
/// @notice The fallback function: If the contract's controller has not been
/// set to 0, then the `proxyPayment` method is called which relays the
/// ether and creates tokens as described in the token controller contract
receive() external payable {
if (!isContract(controller)) revert ControllerNotSet();
if (!TokenController(controller).proxyPayment{ value: msg.value }(msg.sender)) {
revert ControllerRejected();
}
}
//////////
// Safety Methods
//////////
/// @notice This method can be used by the controller to extract mistakenly
/// sent tokens to this contract.
/// @param _token The address of the token contract that you want to recover
/// set to 0 in case you want to extract ether.
function claimTokens(IERC20 _token) public onlyController {
uint256 balance;
if (address(_token) == address(0)) {
balance = address(this).balance;
controller.transfer(balance);
} else {
balance = _token.balanceOf(address(this));
_token.transfer(controller, balance);
}
emit ClaimedTokens(address(_token), controller, balance);
}
////////////////
// Events
////////////////
event ClaimedTokens(address indexed _token, address indexed _controller, uint256 _amount);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import { IERC165 } from "@openzeppelin/contracts/utils/introspection/IERC165.sol";
/**
* @title IOptimismMintableERC20
* @notice This interface is available on the OptimismMintableERC20 contract. We declare it as a
* separate interface so that it can be used in custom implementations of
* OptimismMintableERC20.
*/
interface IOptimismMintableERC20 is IERC165 {
function remoteToken() external view returns (address);
function bridge() external returns (address);
function mint(address _to, uint256 _amount) external;
function burn(address _from, uint256 _amount) external;
}
/**
* @custom:legacy
* @title ILegacyMintableERC20
* @notice This interface was available on the legacy L2StandardERC20 contract. It remains available
* on the OptimismMintableERC20 contract for backwards compatibility.
*/
interface ILegacyMintableERC20 is IERC165 {
function l1Token() external view returns (address);
function mint(address _to, uint256 _amount) external;
function burn(address _from, uint256 _amount) external;
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import { Strings } from "@openzeppelin/contracts/utils/Strings.sol";
/// @title Semver
/// @notice Semver is a simple contract for managing contract versions.
contract Semver {
/// @notice Contract version number (major).
uint256 private immutable MAJOR_VERSION;
/// @notice Contract version number (minor).
uint256 private immutable MINOR_VERSION;
/// @notice Contract version number (patch).
uint256 private immutable PATCH_VERSION;
/// @param _major Version number (major).
/// @param _minor Version number (minor).
/// @param _patch Version number (patch).
constructor(uint256 _major, uint256 _minor, uint256 _patch) {
MAJOR_VERSION = _major;
MINOR_VERSION = _minor;
PATCH_VERSION = _patch;
}
/// @notice Returns the full semver contract version.
/// @return Semver contract version as a string.
function version() public view returns (string memory) {
return string(
abi.encodePacked(
Strings.toString(MAJOR_VERSION),
".",
Strings.toString(MINOR_VERSION),
".",
Strings.toString(PATCH_VERSION)
)
);
}
}// SPDX-License-Identifier: GPL-3.0
pragma solidity ^0.8.0;
error NotAuthorized();
contract Controlled {
/// @notice The address of the controller is the only address that can call
/// a function with this modifier
modifier onlyController() {
if (msg.sender != controller) revert NotAuthorized();
_;
}
address payable public controller;
constructor() {
controller = payable(msg.sender);
}
/// @notice Changes the controller of the contract
/// @param _newController The new controller of the contract
function changeController(address payable _newController) public onlyController {
controller = _newController;
}
}// SPDX-License-Identifier: GPL-3.0
pragma solidity ^0.8.0;
/// @dev The token controller contract must implement these functions
abstract contract TokenController {
/// @notice Called when `_owner` sends ether to the MiniMe Token contract
/// @param _owner The address that sent the ether to create tokens
/// @return True if the ether is accepted, false if it throws
function proxyPayment(address _owner) public payable virtual returns (bool);
/// @notice Notifies the controller about a token transfer allowing the
/// controller to react if desired
/// @param _from The origin of the transfer
/// @param _to The destination of the transfer
/// @param _amount The amount of the transfer
/// @return False if the controller does not authorize the transfer
function onTransfer(address _from, address _to, uint256 _amount) public virtual returns (bool);
/// @notice Notifies the controller about an approval allowing the
/// controller to react if desired
/// @param _owner The address that calls `approve()`
/// @param _spender The spender in the `approve()` call
/// @param _amount The amount in the `approve()` call
/// @return False if the controller does not authorize the approval
function onApprove(address _owner, address _spender, uint256 _amount) public virtual returns (bool);
}// SPDX-License-Identifier: GPL-3.0
pragma solidity ^0.8.0;
/// @title Approve And Call Fallback Token Interface
/// @dev This interface must be implemented by other contracts
/// wishing to accept approve and call from MiniMe token contracts.
abstract contract ApproveAndCallFallBack {
function receiveApproval(address from, uint256 _amount, address _token, bytes memory _data) public virtual;
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/IERC20.sol)
pragma solidity ^0.8.0;
/**
* @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 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 `to`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address to, 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 `from` to `to` 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 from, address to, uint256 amount) external returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/extensions/IERC20Permit.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
* https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
*
* Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
* presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't
* need to send a transaction, and thus is not required to hold Ether at all.
*/
interface IERC20Permit {
/**
* @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,
* given ``owner``'s signed approval.
*
* IMPORTANT: The same issues {IERC20-approve} has related to transaction
* ordering also apply here.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - `spender` cannot be the zero address.
* - `deadline` must be a timestamp in the future.
* - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
* over the EIP712-formatted function arguments.
* - the signature must use ``owner``'s current nonce (see {nonces}).
*
* For more information on the signature format, see the
* https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
* section].
*/
function permit(
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) external;
/**
* @dev Returns the current nonce for `owner`. This value must be
* included whenever a signature is generated for {permit}.
*
* Every successful call to {permit} increases ``owner``'s nonce by one. This
* prevents a signature from being used multiple times.
*/
function nonces(address owner) external view returns (uint256);
/**
* @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.
*/
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view returns (bytes32);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (utils/cryptography/EIP712.sol)
pragma solidity ^0.8.8;
import "./ECDSA.sol";
import "../ShortStrings.sol";
import "../../interfaces/IERC5267.sol";
/**
* @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.
*
* The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible,
* thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding
* they need in their contracts using a combination of `abi.encode` and `keccak256`.
*
* This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding
* scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA
* ({_hashTypedDataV4}).
*
* The implementation of the domain separator was designed to be as efficient as possible while still properly updating
* the chain id to protect against replay attacks on an eventual fork of the chain.
*
* NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method
* https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].
*
* NOTE: In the upgradeable version of this contract, the cached values will correspond to the address, and the domain
* separator of the implementation contract. This will cause the `_domainSeparatorV4` function to always rebuild the
* separator from the immutable values, which is cheaper than accessing a cached version in cold storage.
*
* _Available since v3.4._
*
* @custom:oz-upgrades-unsafe-allow state-variable-immutable state-variable-assignment
*/
abstract contract EIP712 is IERC5267 {
using ShortStrings for *;
bytes32 private constant _TYPE_HASH =
keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)");
// Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to
// invalidate the cached domain separator if the chain id changes.
bytes32 private immutable _cachedDomainSeparator;
uint256 private immutable _cachedChainId;
address private immutable _cachedThis;
bytes32 private immutable _hashedName;
bytes32 private immutable _hashedVersion;
ShortString private immutable _name;
ShortString private immutable _version;
string private _nameFallback;
string private _versionFallback;
/**
* @dev Initializes the domain separator and parameter caches.
*
* The meaning of `name` and `version` is specified in
* https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]:
*
* - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol.
* - `version`: the current major version of the signing domain.
*
* NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart
* contract upgrade].
*/
constructor(string memory name, string memory version) {
_name = name.toShortStringWithFallback(_nameFallback);
_version = version.toShortStringWithFallback(_versionFallback);
_hashedName = keccak256(bytes(name));
_hashedVersion = keccak256(bytes(version));
_cachedChainId = block.chainid;
_cachedDomainSeparator = _buildDomainSeparator();
_cachedThis = address(this);
}
/**
* @dev Returns the domain separator for the current chain.
*/
function _domainSeparatorV4() internal view returns (bytes32) {
if (address(this) == _cachedThis && block.chainid == _cachedChainId) {
return _cachedDomainSeparator;
} else {
return _buildDomainSeparator();
}
}
function _buildDomainSeparator() private view returns (bytes32) {
return keccak256(abi.encode(_TYPE_HASH, _hashedName, _hashedVersion, block.chainid, address(this)));
}
/**
* @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this
* function returns the hash of the fully encoded EIP712 message for this domain.
*
* This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example:
*
* ```solidity
* bytes32 digest = _hashTypedDataV4(keccak256(abi.encode(
* keccak256("Mail(address to,string contents)"),
* mailTo,
* keccak256(bytes(mailContents))
* )));
* address signer = ECDSA.recover(digest, signature);
* ```
*/
function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) {
return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash);
}
/**
* @dev See {EIP-5267}.
*
* _Available since v4.9._
*/
function eip712Domain()
public
view
virtual
override
returns (
bytes1 fields,
string memory name,
string memory version,
uint256 chainId,
address verifyingContract,
bytes32 salt,
uint256[] memory extensions
)
{
return (
hex"0f", // 01111
_name.toStringWithFallback(_nameFallback),
_version.toStringWithFallback(_versionFallback),
block.chainid,
address(this),
bytes32(0),
new uint256[](0)
);
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (utils/cryptography/ECDSA.sol)
pragma solidity ^0.8.0;
import "../Strings.sol";
/**
* @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.
*
* These functions can be used to verify that a message was signed by the holder
* of the private keys of a given address.
*/
library ECDSA {
enum RecoverError {
NoError,
InvalidSignature,
InvalidSignatureLength,
InvalidSignatureS,
InvalidSignatureV // Deprecated in v4.8
}
function _throwError(RecoverError error) private pure {
if (error == RecoverError.NoError) {
return; // no error: do nothing
} else if (error == RecoverError.InvalidSignature) {
revert("ECDSA: invalid signature");
} else if (error == RecoverError.InvalidSignatureLength) {
revert("ECDSA: invalid signature length");
} else if (error == RecoverError.InvalidSignatureS) {
revert("ECDSA: invalid signature 's' value");
}
}
/**
* @dev Returns the address that signed a hashed message (`hash`) with
* `signature` or error string. This address can then be used for verification purposes.
*
* The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:
* this function rejects them by requiring the `s` value to be in the lower
* half order, and the `v` value to be either 27 or 28.
*
* IMPORTANT: `hash` _must_ be the result of a hash operation for the
* verification to be secure: it is possible to craft signatures that
* recover to arbitrary addresses for non-hashed data. A safe way to ensure
* this is by receiving a hash of the original message (which may otherwise
* be too long), and then calling {toEthSignedMessageHash} on it.
*
* Documentation for signature generation:
* - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]
* - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]
*
* _Available since v4.3._
*/
function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) {
if (signature.length == 65) {
bytes32 r;
bytes32 s;
uint8 v;
// ecrecover takes the signature parameters, and the only way to get them
// currently is to use assembly.
/// @solidity memory-safe-assembly
assembly {
r := mload(add(signature, 0x20))
s := mload(add(signature, 0x40))
v := byte(0, mload(add(signature, 0x60)))
}
return tryRecover(hash, v, r, s);
} else {
return (address(0), RecoverError.InvalidSignatureLength);
}
}
/**
* @dev Returns the address that signed a hashed message (`hash`) with
* `signature`. This address can then be used for verification purposes.
*
* The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:
* this function rejects them by requiring the `s` value to be in the lower
* half order, and the `v` value to be either 27 or 28.
*
* IMPORTANT: `hash` _must_ be the result of a hash operation for the
* verification to be secure: it is possible to craft signatures that
* recover to arbitrary addresses for non-hashed data. A safe way to ensure
* this is by receiving a hash of the original message (which may otherwise
* be too long), and then calling {toEthSignedMessageHash} on it.
*/
function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {
(address recovered, RecoverError error) = tryRecover(hash, signature);
_throwError(error);
return recovered;
}
/**
* @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.
*
* See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]
*
* _Available since v4.3._
*/
function tryRecover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address, RecoverError) {
bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff);
uint8 v = uint8((uint256(vs) >> 255) + 27);
return tryRecover(hash, v, r, s);
}
/**
* @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.
*
* _Available since v4.2._
*/
function recover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address) {
(address recovered, RecoverError error) = tryRecover(hash, r, vs);
_throwError(error);
return recovered;
}
/**
* @dev Overload of {ECDSA-tryRecover} that receives the `v`,
* `r` and `s` signature fields separately.
*
* _Available since v4.3._
*/
function tryRecover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address, RecoverError) {
// EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature
// unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines
// the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most
// signatures from current libraries generate a unique signature with an s-value in the lower half order.
//
// If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value
// with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or
// vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept
// these malleable signatures as well.
if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {
return (address(0), RecoverError.InvalidSignatureS);
}
// If the signature is valid (and not malleable), return the signer address
address signer = ecrecover(hash, v, r, s);
if (signer == address(0)) {
return (address(0), RecoverError.InvalidSignature);
}
return (signer, RecoverError.NoError);
}
/**
* @dev Overload of {ECDSA-recover} that receives the `v`,
* `r` and `s` signature fields separately.
*/
function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {
(address recovered, RecoverError error) = tryRecover(hash, v, r, s);
_throwError(error);
return recovered;
}
/**
* @dev Returns an Ethereum Signed Message, created from a `hash`. This
* produces hash corresponding to the one signed with the
* https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]
* JSON-RPC method as part of EIP-191.
*
* See {recover}.
*/
function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32 message) {
// 32 is the length in bytes of hash,
// enforced by the type signature above
/// @solidity memory-safe-assembly
assembly {
mstore(0x00, "\x19Ethereum Signed Message:\n32")
mstore(0x1c, hash)
message := keccak256(0x00, 0x3c)
}
}
/**
* @dev Returns an Ethereum Signed Message, created from `s`. This
* produces hash corresponding to the one signed with the
* https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]
* JSON-RPC method as part of EIP-191.
*
* See {recover}.
*/
function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) {
return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s));
}
/**
* @dev Returns an Ethereum Signed Typed Data, created from a
* `domainSeparator` and a `structHash`. This produces hash corresponding
* to the one signed with the
* https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]
* JSON-RPC method as part of EIP-712.
*
* See {recover}.
*/
function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32 data) {
/// @solidity memory-safe-assembly
assembly {
let ptr := mload(0x40)
mstore(ptr, "\x19\x01")
mstore(add(ptr, 0x02), domainSeparator)
mstore(add(ptr, 0x22), structHash)
data := keccak256(ptr, 0x42)
}
}
/**
* @dev Returns an Ethereum Signed Data with intended validator, created from a
* `validator` and `data` according to the version 0 of EIP-191.
*
* See {recover}.
*/
function toDataWithIntendedValidatorHash(address validator, bytes memory data) internal pure returns (bytes32) {
return keccak256(abi.encodePacked("\x19\x00", validator, data));
}
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/**
* @dev Provides tracking nonces for addresses. Nonces will only increment.
*/
abstract contract Nonces {
/**
* @dev The nonce used for an `account` is not the expected current nonce.
*/
error InvalidAccountNonce(address account, uint256 currentNonce);
mapping(address account => uint256) private _nonces;
/**
* @dev Returns the next unused nonce for an address.
*/
function nonces(address owner) public view virtual returns (uint256) {
return _nonces[owner];
}
/**
* @dev Consumes a nonce.
*
* Returns the current value and increments nonce.
*/
function _useNonce(address owner) internal virtual returns (uint256) {
// For each account, the nonce has an initial value of 0, can only be incremented by one, and cannot be
// decremented or reset. This guarantees that the nonce never overflows.
unchecked {
// It is important to do x++ and not ++x here.
return _nonces[owner]++;
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (utils/Strings.sol)
pragma solidity ^0.8.0;
import "./math/Math.sol";
import "./math/SignedMath.sol";
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant _SYMBOLS = "0123456789abcdef";
uint8 private constant _ADDRESS_LENGTH = 20;
/**
* @dev Converts a `uint256` to its ASCII `string` decimal representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
unchecked {
uint256 length = Math.log10(value) + 1;
string memory buffer = new string(length);
uint256 ptr;
/// @solidity memory-safe-assembly
assembly {
ptr := add(buffer, add(32, length))
}
while (true) {
ptr--;
/// @solidity memory-safe-assembly
assembly {
mstore8(ptr, byte(mod(value, 10), _SYMBOLS))
}
value /= 10;
if (value == 0) break;
}
return buffer;
}
}
/**
* @dev Converts a `int256` to its ASCII `string` decimal representation.
*/
function toString(int256 value) internal pure returns (string memory) {
return string(abi.encodePacked(value < 0 ? "-" : "", toString(SignedMath.abs(value))));
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
*/
function toHexString(uint256 value) internal pure returns (string memory) {
unchecked {
return toHexString(value, Math.log256(value) + 1);
}
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
*/
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
bytes memory buffer = new bytes(2 * length + 2);
buffer[0] = "0";
buffer[1] = "x";
for (uint256 i = 2 * length + 1; i > 1; --i) {
buffer[i] = _SYMBOLS[value & 0xf];
value >>= 4;
}
require(value == 0, "Strings: hex length insufficient");
return string(buffer);
}
/**
* @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
*/
function toHexString(address addr) internal pure returns (string memory) {
return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
}
/**
* @dev Returns true if the two strings are equal.
*/
function equal(string memory a, string memory b) internal pure returns (bool) {
return keccak256(bytes(a)) == keccak256(bytes(b));
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (utils/ShortStrings.sol)
pragma solidity ^0.8.8;
import "./StorageSlot.sol";
// | string | 0xAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA |
// | length | 0x BB |
type ShortString is bytes32;
/**
* @dev This library provides functions to convert short memory strings
* into a `ShortString` type that can be used as an immutable variable.
*
* Strings of arbitrary length can be optimized using this library if
* they are short enough (up to 31 bytes) by packing them with their
* length (1 byte) in a single EVM word (32 bytes). Additionally, a
* fallback mechanism can be used for every other case.
*
* Usage example:
*
* ```solidity
* contract Named {
* using ShortStrings for *;
*
* ShortString private immutable _name;
* string private _nameFallback;
*
* constructor(string memory contractName) {
* _name = contractName.toShortStringWithFallback(_nameFallback);
* }
*
* function name() external view returns (string memory) {
* return _name.toStringWithFallback(_nameFallback);
* }
* }
* ```
*/
library ShortStrings {
// Used as an identifier for strings longer than 31 bytes.
bytes32 private constant _FALLBACK_SENTINEL = 0x00000000000000000000000000000000000000000000000000000000000000FF;
error StringTooLong(string str);
error InvalidShortString();
/**
* @dev Encode a string of at most 31 chars into a `ShortString`.
*
* This will trigger a `StringTooLong` error is the input string is too long.
*/
function toShortString(string memory str) internal pure returns (ShortString) {
bytes memory bstr = bytes(str);
if (bstr.length > 31) {
revert StringTooLong(str);
}
return ShortString.wrap(bytes32(uint256(bytes32(bstr)) | bstr.length));
}
/**
* @dev Decode a `ShortString` back to a "normal" string.
*/
function toString(ShortString sstr) internal pure returns (string memory) {
uint256 len = byteLength(sstr);
// using `new string(len)` would work locally but is not memory safe.
string memory str = new string(32);
/// @solidity memory-safe-assembly
assembly {
mstore(str, len)
mstore(add(str, 0x20), sstr)
}
return str;
}
/**
* @dev Return the length of a `ShortString`.
*/
function byteLength(ShortString sstr) internal pure returns (uint256) {
uint256 result = uint256(ShortString.unwrap(sstr)) & 0xFF;
if (result > 31) {
revert InvalidShortString();
}
return result;
}
/**
* @dev Encode a string into a `ShortString`, or write it to storage if it is too long.
*/
function toShortStringWithFallback(string memory value, string storage store) internal returns (ShortString) {
if (bytes(value).length < 32) {
return toShortString(value);
} else {
StorageSlot.getStringSlot(store).value = value;
return ShortString.wrap(_FALLBACK_SENTINEL);
}
}
/**
* @dev Decode a string that was encoded to `ShortString` or written to storage using {setWithFallback}.
*/
function toStringWithFallback(ShortString value, string storage store) internal pure returns (string memory) {
if (ShortString.unwrap(value) != _FALLBACK_SENTINEL) {
return toString(value);
} else {
return store;
}
}
/**
* @dev Return the length of a string that was encoded to `ShortString` or written to storage using {setWithFallback}.
*
* WARNING: This will return the "byte length" of the string. This may not reflect the actual length in terms of
* actual characters as the UTF-8 encoding of a single character can span over multiple bytes.
*/
function byteLengthWithFallback(ShortString value, string storage store) internal view returns (uint256) {
if (ShortString.unwrap(value) != _FALLBACK_SENTINEL) {
return byteLength(value);
} else {
return bytes(store).length;
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (interfaces/IERC5267.sol)
pragma solidity ^0.8.0;
interface IERC5267 {
/**
* @dev MAY be emitted to signal that the domain could have changed.
*/
event EIP712DomainChanged();
/**
* @dev returns the fields and values that describe the domain separator used by this contract for EIP-712
* signature.
*/
function eip712Domain()
external
view
returns (
bytes1 fields,
string memory name,
string memory version,
uint256 chainId,
address verifyingContract,
bytes32 salt,
uint256[] memory extensions
);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (utils/math/Math.sol)
pragma solidity ^0.8.0;
/**
* @dev Standard math utilities missing in the Solidity language.
*/
library Math {
enum Rounding {
Down, // Toward negative infinity
Up, // Toward infinity
Zero // Toward zero
}
/**
* @dev Returns the largest of two numbers.
*/
function max(uint256 a, uint256 b) internal pure returns (uint256) {
return a > b ? a : b;
}
/**
* @dev Returns the smallest of two numbers.
*/
function min(uint256 a, uint256 b) internal pure returns (uint256) {
return a < b ? a : b;
}
/**
* @dev Returns the average of two numbers. The result is rounded towards
* zero.
*/
function average(uint256 a, uint256 b) internal pure returns (uint256) {
// (a + b) / 2 can overflow.
return (a & b) + (a ^ b) / 2;
}
/**
* @dev Returns the ceiling of the division of two numbers.
*
* This differs from standard division with `/` in that it rounds up instead
* of rounding down.
*/
function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
// (a + b - 1) / b can overflow on addition, so we distribute.
return a == 0 ? 0 : (a - 1) / b + 1;
}
/**
* @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0
* @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)
* with further edits by Uniswap Labs also under MIT license.
*/
function mulDiv(uint256 x, uint256 y, uint256 denominator) internal pure returns (uint256 result) {
unchecked {
// 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
// use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
// variables such that product = prod1 * 2^256 + prod0.
uint256 prod0; // Least significant 256 bits of the product
uint256 prod1; // Most significant 256 bits of the product
assembly {
let mm := mulmod(x, y, not(0))
prod0 := mul(x, y)
prod1 := sub(sub(mm, prod0), lt(mm, prod0))
}
// Handle non-overflow cases, 256 by 256 division.
if (prod1 == 0) {
// Solidity will revert if denominator == 0, unlike the div opcode on its own.
// The surrounding unchecked block does not change this fact.
// See https://docs.soliditylang.org/en/latest/control-structures.html#checked-or-unchecked-arithmetic.
return prod0 / denominator;
}
// Make sure the result is less than 2^256. Also prevents denominator == 0.
require(denominator > prod1, "Math: mulDiv overflow");
///////////////////////////////////////////////
// 512 by 256 division.
///////////////////////////////////////////////
// Make division exact by subtracting the remainder from [prod1 prod0].
uint256 remainder;
assembly {
// Compute remainder using mulmod.
remainder := mulmod(x, y, denominator)
// Subtract 256 bit number from 512 bit number.
prod1 := sub(prod1, gt(remainder, prod0))
prod0 := sub(prod0, remainder)
}
// Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.
// See https://cs.stackexchange.com/q/138556/92363.
// Does not overflow because the denominator cannot be zero at this stage in the function.
uint256 twos = denominator & (~denominator + 1);
assembly {
// Divide denominator by twos.
denominator := div(denominator, twos)
// Divide [prod1 prod0] by twos.
prod0 := div(prod0, twos)
// Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
twos := add(div(sub(0, twos), twos), 1)
}
// Shift in bits from prod1 into prod0.
prod0 |= prod1 * twos;
// Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
// that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
// four bits. That is, denominator * inv = 1 mod 2^4.
uint256 inverse = (3 * denominator) ^ 2;
// Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works
// in modular arithmetic, doubling the correct bits in each step.
inverse *= 2 - denominator * inverse; // inverse mod 2^8
inverse *= 2 - denominator * inverse; // inverse mod 2^16
inverse *= 2 - denominator * inverse; // inverse mod 2^32
inverse *= 2 - denominator * inverse; // inverse mod 2^64
inverse *= 2 - denominator * inverse; // inverse mod 2^128
inverse *= 2 - denominator * inverse; // inverse mod 2^256
// Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
// This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
// less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
// is no longer required.
result = prod0 * inverse;
return result;
}
}
/**
* @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
*/
function mulDiv(uint256 x, uint256 y, uint256 denominator, Rounding rounding) internal pure returns (uint256) {
uint256 result = mulDiv(x, y, denominator);
if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {
result += 1;
}
return result;
}
/**
* @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.
*
* Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
*/
function sqrt(uint256 a) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
// For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
//
// We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
// `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
//
// This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
// → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
// → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
//
// Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
uint256 result = 1 << (log2(a) >> 1);
// At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
// since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
// every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
// into the expected uint128 result.
unchecked {
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
return min(result, a / result);
}
}
/**
* @notice Calculates sqrt(a), following the selected rounding direction.
*/
function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = sqrt(a);
return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);
}
}
/**
* @dev Return the log in base 2, rounded down, of a positive value.
* Returns 0 if given 0.
*/
function log2(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 128;
}
if (value >> 64 > 0) {
value >>= 64;
result += 64;
}
if (value >> 32 > 0) {
value >>= 32;
result += 32;
}
if (value >> 16 > 0) {
value >>= 16;
result += 16;
}
if (value >> 8 > 0) {
value >>= 8;
result += 8;
}
if (value >> 4 > 0) {
value >>= 4;
result += 4;
}
if (value >> 2 > 0) {
value >>= 2;
result += 2;
}
if (value >> 1 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 2, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log2(value);
return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 10, rounded down, of a positive value.
* Returns 0 if given 0.
*/
function log10(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >= 10 ** 64) {
value /= 10 ** 64;
result += 64;
}
if (value >= 10 ** 32) {
value /= 10 ** 32;
result += 32;
}
if (value >= 10 ** 16) {
value /= 10 ** 16;
result += 16;
}
if (value >= 10 ** 8) {
value /= 10 ** 8;
result += 8;
}
if (value >= 10 ** 4) {
value /= 10 ** 4;
result += 4;
}
if (value >= 10 ** 2) {
value /= 10 ** 2;
result += 2;
}
if (value >= 10 ** 1) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 10, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log10(value);
return result + (rounding == Rounding.Up && 10 ** result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 256, rounded down, of a positive value.
* Returns 0 if given 0.
*
* Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
*/
function log256(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 16;
}
if (value >> 64 > 0) {
value >>= 64;
result += 8;
}
if (value >> 32 > 0) {
value >>= 32;
result += 4;
}
if (value >> 16 > 0) {
value >>= 16;
result += 2;
}
if (value >> 8 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 256, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log256(value);
return result + (rounding == Rounding.Up && 1 << (result << 3) < value ? 1 : 0);
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/SignedMath.sol)
pragma solidity ^0.8.0;
/**
* @dev Standard signed math utilities missing in the Solidity language.
*/
library SignedMath {
/**
* @dev Returns the largest of two signed numbers.
*/
function max(int256 a, int256 b) internal pure returns (int256) {
return a > b ? a : b;
}
/**
* @dev Returns the smallest of two signed numbers.
*/
function min(int256 a, int256 b) internal pure returns (int256) {
return a < b ? a : b;
}
/**
* @dev Returns the average of two signed numbers without overflow.
* The result is rounded towards zero.
*/
function average(int256 a, int256 b) internal pure returns (int256) {
// Formula from the book "Hacker's Delight"
int256 x = (a & b) + ((a ^ b) >> 1);
return x + (int256(uint256(x) >> 255) & (a ^ b));
}
/**
* @dev Returns the absolute unsigned value of a signed value.
*/
function abs(int256 n) internal pure returns (uint256) {
unchecked {
// must be unchecked in order to support `n = type(int256).min`
return uint256(n >= 0 ? n : -n);
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (utils/StorageSlot.sol)
// This file was procedurally generated from scripts/generate/templates/StorageSlot.js.
pragma solidity ^0.8.0;
/**
* @dev Library for reading and writing primitive types to specific storage slots.
*
* Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.
* This library helps with reading and writing to such slots without the need for inline assembly.
*
* The functions in this library return Slot structs that contain a `value` member that can be used to read or write.
*
* Example usage to set ERC1967 implementation slot:
* ```solidity
* contract ERC1967 {
* bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;
*
* function _getImplementation() internal view returns (address) {
* return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;
* }
*
* function _setImplementation(address newImplementation) internal {
* require(Address.isContract(newImplementation), "ERC1967: new implementation is not a contract");
* StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;
* }
* }
* ```
*
* _Available since v4.1 for `address`, `bool`, `bytes32`, `uint256`._
* _Available since v4.9 for `string`, `bytes`._
*/
library StorageSlot {
struct AddressSlot {
address value;
}
struct BooleanSlot {
bool value;
}
struct Bytes32Slot {
bytes32 value;
}
struct Uint256Slot {
uint256 value;
}
struct StringSlot {
string value;
}
struct BytesSlot {
bytes value;
}
/**
* @dev Returns an `AddressSlot` with member `value` located at `slot`.
*/
function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `BooleanSlot` with member `value` located at `slot`.
*/
function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `Bytes32Slot` with member `value` located at `slot`.
*/
function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `Uint256Slot` with member `value` located at `slot`.
*/
function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `StringSlot` with member `value` located at `slot`.
*/
function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `StringSlot` representation of the string storage pointer `store`.
*/
function getStringSlot(string storage store) internal pure returns (StringSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := store.slot
}
}
/**
* @dev Returns an `BytesSlot` with member `value` located at `slot`.
*/
function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`.
*/
function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := store.slot
}
}
}{
"remappings": [
"forge-std/=lib/forge-std/src/",
"@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/",
"@vacp2p/minime/contracts/=lib/minime/contracts/",
"ds-test/=lib/forge-std/lib/ds-test/src/",
"erc4626-tests/=lib/openzeppelin-contracts/lib/erc4626-tests/",
"minime/=lib/minime/",
"openzeppelin-contracts/=lib/openzeppelin-contracts/",
"openzeppelin/=lib/openzeppelin-contracts/contracts/"
],
"optimizer": {
"enabled": true,
"runs": 10000
},
"metadata": {
"useLiteralContent": false,
"bytecodeHash": "none",
"appendCBOR": false
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"evmVersion": "paris",
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"_bridge","type":"address"},{"internalType":"address","name":"_remoteToken","type":"address"},{"internalType":"contract MiniMeBase","name":"_parentToken","type":"address"},{"internalType":"uint256","name":"_parentSnapShotBlock","type":"uint256"},{"internalType":"string","name":"_tokenName","type":"string"},{"internalType":"uint8","name":"_decimalUnits","type":"uint8"},{"internalType":"string","name":"_tokenSymbol","type":"string"},{"internalType":"bool","name":"_transfersEnabled","type":"bool"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AllowanceAlreadySet","type":"error"},{"inputs":[],"name":"ControllerNotSet","type":"error"},{"inputs":[],"name":"ControllerRejected","type":"error"},{"inputs":[{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"ERC2612ExpiredSignature","type":"error"},{"inputs":[{"internalType":"address","name":"signer","type":"address"},{"internalType":"address","name":"owner","type":"address"}],"name":"ERC2612InvalidSigner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"currentNonce","type":"uint256"}],"name":"InvalidAccountNonce","type":"error"},{"inputs":[],"name":"InvalidDestination","type":"error"},{"inputs":[],"name":"InvalidShortString","type":"error"},{"inputs":[],"name":"NotAuthorized","type":"error"},{"inputs":[],"name":"NotEnoughAllowance","type":"error"},{"inputs":[],"name":"NotEnoughBalance","type":"error"},{"inputs":[],"name":"OptimismMintableMiniMeToken_SenderNotBridge","type":"error"},{"inputs":[],"name":"Overflow","type":"error"},{"inputs":[],"name":"ParentSnapshotNotReached","type":"error"},{"inputs":[{"internalType":"string","name":"str","type":"string"}],"name":"StringTooLong","type":"error"},{"inputs":[],"name":"TransfersDisabled","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Burn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_token","type":"address"},{"indexed":true,"internalType":"address","name":"_controller","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"ClaimedTokens","type":"event"},{"anonymous":false,"inputs":[],"name":"EIP712DomainChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Mint","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"BRIDGE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"REMOTE_TOKEN","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"TOKEN_VERSION","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"remaining","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_spender","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_spender","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"bytes","name":"_extraData","type":"bytes"}],"name":"approveAndCall","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"balance","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"uint256","name":"_blockNumber","type":"uint256"}],"name":"balanceOfAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"bridge","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_from","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"_newController","type":"address"}],"name":"changeController","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"_token","type":"address"}],"name":"claimTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"controller","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"creationBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"eip712Domain","outputs":[{"internalType":"bytes1","name":"fields","type":"bytes1"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"version","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"address","name":"verifyingContract","type":"address"},{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"uint256[]","name":"extensions","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_transfersEnabled","type":"bool"}],"name":"enableTransfers","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"l1Token","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"l2Bridge","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"nonces","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"parentSnapShotBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"parentToken","outputs":[{"internalType":"contract MiniMeBase","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"permit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"remoteToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"_interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_blockNumber","type":"uint256"}],"name":"totalSupplyAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_from","type":"address"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"transfersEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]Contract Creation Code
6102806040523480156200001257600080fd5b506040516200340638038062003406833981016040819052620000359162000331565b60408051808201909152600781526626a6aa2f98171960c91b6020820152600080546001600160a01b031916331781556001918290899089908990899089908990849062000084828a620001b0565b6101205262000095816002620001b0565b61014052815160208084019190912060e052815190820120610100524660a0526200012360e05161010051604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f60208201529081019290925260608201524660808201523060a082015260009060c00160405160208183030381529060405280519060200120905090565b60805250503060c05260046200013a8582620004a2565b5060ff8316610160526005620001518382620004a2565b506001600160a01b03958616610180526101a09490945250506009805460ff19169215159290921790915550436101c0526101e09390935261020091909152610220529687166102405250505050929091166102605250620005c89050565b6000602083511015620001d057620001c883620001e9565b9050620001e3565b81620001dd8482620004a2565b5060ff90505b92915050565b600080829050601f8151111562000220578260405163305a27a960e01b81526004016200021791906200056e565b60405180910390fd5b80516200022d82620005a3565b179392505050565b6001600160a01b03811681146200024b57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b838110156200028157818101518382015260200162000267565b50506000910152565b600082601f8301126200029c57600080fd5b81516001600160401b0380821115620002b957620002b96200024e565b604051601f8301601f19908116603f01168101908282118183101715620002e457620002e46200024e565b81604052838152866020858801011115620002fe57600080fd5b6200031184602083016020890162000264565b9695505050505050565b805180151581146200032c57600080fd5b919050565b600080600080600080600080610100898b0312156200034f57600080fd5b88516200035c8162000235565b60208a01519098506200036f8162000235565b60408a0151909750620003828162000235565b60608a015160808b015191975095506001600160401b0380821115620003a757600080fd5b620003b58c838d016200028a565b955060a08b0151915060ff82168214620003ce57600080fd5b60c08b015191945080821115620003e457600080fd5b50620003f38b828c016200028a565b9250506200040460e08a016200031b565b90509295985092959890939650565b600181811c908216806200042857607f821691505b6020821081036200044957634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200049d57600081815260208120601f850160051c81016020861015620004785750805b601f850160051c820191505b81811015620004995782815560010162000484565b5050505b505050565b81516001600160401b03811115620004be57620004be6200024e565b620004d681620004cf845462000413565b846200044f565b602080601f8311600181146200050e5760008415620004f55750858301515b600019600386901b1c1916600185901b17855562000499565b600085815260208120601f198616915b828110156200053f578886015182559484019460019091019084016200051e565b50858210156200055e5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60208152600082518060208401526200058f81604085016020870162000264565b601f01601f19169190910160400192915050565b80516020808301519190811015620004495760001960209190910360031b1b16919050565b60805160a05160c05160e05161010051610120516101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051612d33620006d3600039600081816106c10152818161081e01528181610bd401526110f5015260008181610395015261070e01526000610e8301526000610e5a01526000610e310152600061042301526000818161074401528181610d500152818161105401526118a80152600081816105f301528181610ced01528181610d1c01528181610ff201526110210152600061049a01526000610f3001526000610f0501526000611c1101526000611be901526000611b4401526000611b6e01526000611b980152612d336000f3fe6080604052600436106102385760003560e01c806384b0196e11610138578063cae9ca51116100b0578063df8de3e71161007f578063ee9a31a211610064578063ee9a31a21461080c578063f41e60c514610840578063f77c47911461086057600080fd5b8063df8de3e7146107ec578063e78cea92146106b257600080fd5b8063cae9ca5114610766578063d505accf14610786578063d6c0b2c4146106ff578063dd62ed3e146107a657600080fd5b8063a9059cbb11610107578063bef97c87116100ec578063bef97c87146106e5578063c01e1bd6146106ff578063c5bcc4f11461073257600080fd5b8063a9059cbb14610692578063ae1f6aaf146106b257600080fd5b806384b0196e1461061557806395d89b411461063d578063981b24d0146106525780639dc29fac1461067257600080fd5b806332892177116101cb5780634ee2cd7e1161019a57806370a082311161017f57806370a08231146105a15780637ecebe00146105c157806380a54001146105e157600080fd5b80634ee2cd7e1461056c57806354fd4d501461058c57600080fd5b806332892177146104ce5780633644e515146105175780633cebb8231461052c57806340c10f191461054c57600080fd5b80631763451411610207578063176345141461041157806318160ddd1461045357806323b872dd14610468578063313ce5671461048857600080fd5b806301ffc9a71461034e578063033964be1461038357806306fdde03146103cf578063095ea7b3146103f157600080fd5b3661034957600054610252906001600160a01b0316610880565b610288576040517f2110f99100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000546040517ff48c30540000000000000000000000000000000000000000000000000000000081523360048201526001600160a01b039091169063f48c305490349060240160206040518083038185885af11580156102ec573d6000803e3d6000fd5b50505050506040513d601f19601f8201168201806040525081019061031191906126ef565b610347576040517fef18515800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b005b600080fd5b34801561035a57600080fd5b5061036e610369366004612713565b6108a2565b60405190151581526020015b60405180910390f35b34801561038f57600080fd5b506103b77f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b03909116815260200161037a565b3480156103db57600080fd5b506103e4610993565b60405161037a91906127c3565b3480156103fd57600080fd5b5061036e61040c3660046127eb565b610a21565b34801561041d57600080fd5b506104457f000000000000000000000000000000000000000000000000000000000000000081565b60405190815260200161037a565b34801561045f57600080fd5b50610445610a37565b34801561047457600080fd5b5061036e610483366004612817565b610a47565b34801561049457600080fd5b506104bc7f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff909116815260200161037a565b3480156104da57600080fd5b506103e46040518060400160405280600781526020017f4d4d545f302e320000000000000000000000000000000000000000000000000081525081565b34801561052357600080fd5b50610445610b41565b34801561053857600080fd5b50610347610547366004612858565b610b4b565b34801561055857600080fd5b506103476105673660046127eb565b610bc9565b34801561057857600080fd5b506104456105873660046127eb565b610c7d565b34801561059857600080fd5b506103e4610e2a565b3480156105ad57600080fd5b506104456105bc366004612858565b610ecd565b3480156105cd57600080fd5b506104456105dc366004612858565b610ed9565b3480156105ed57600080fd5b506103b77f000000000000000000000000000000000000000000000000000000000000000081565b34801561062157600080fd5b5061062a610ef7565b60405161037a9796959493929190612875565b34801561064957600080fd5b506103e4610f9c565b34801561065e57600080fd5b5061044561066d366004612927565b610fa9565b34801561067e57600080fd5b5061034761068d3660046127eb565b6110ea565b34801561069e57600080fd5b5061036e6106ad3660046127eb565b611192565b3480156106be57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006103b7565b3480156106f157600080fd5b5060095461036e9060ff1681565b34801561070b57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006103b7565b34801561073e57600080fd5b506104457f000000000000000000000000000000000000000000000000000000000000000081565b34801561077257600080fd5b5061036e61078136600461296f565b6111e5565b34801561079257600080fd5b506103476107a1366004612a5a565b611279565b3480156107b257600080fd5b506104456107c1366004612ad1565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205490565b3480156107f857600080fd5b50610347610807366004612858565b6113eb565b34801561081857600080fd5b506103b77f000000000000000000000000000000000000000000000000000000000000000081565b34801561084c57600080fd5b5061034761085b366004612b0a565b6115df565b34801561086c57600080fd5b506000546103b7906001600160a01b031681565b6000806001600160a01b03831661089a5750600092915050565b50503b151590565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061095b57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b8061098a57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b600480546109a090612b27565b80601f01602080910402602001604051908101604052809291908181526020018280546109cc90612b27565b8015610a195780601f106109ee57610100808354040283529160200191610a19565b820191906000526020600020905b8154815290600101906020018083116109fc57829003601f168201915b505050505081565b6000610a2e338484611654565b90505b92915050565b6000610a4243610fa9565b905090565b600080546001600160a01b03163314610b2c5760095460ff16610a96576040517f8574adcf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b0384166000908152600760209081526040808320338452909152902054821115610af3576040517f4fd3af0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038416600090815260076020908152604080832033845290915281208054849290610b26908490612ba9565b90915550505b610b3784848461184b565b5060019392505050565b6000610a42611b37565b6000546001600160a01b03163314610b8f576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b336001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001614610c2b576040517f62f16ccd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610c358282611c62565b50816001600160a01b03167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d412139688582604051610c7191815260200190565b60405180910390a25050565b6001600160a01b0382166000908152600660205260408120541580610ce657506001600160a01b03831660009081526006602052604081208054849290610cc657610cc6612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff16115b15610e08577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031615610e00577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316634ee2cd7e84610d74857f0000000000000000000000000000000000000000000000000000000000000000611d53565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381865afa158015610dd5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610df99190612beb565b9050610a31565b506000610a31565b6001600160a01b0383166000908152600660205260409020610df99083611d69565b6060610e557f0000000000000000000000000000000000000000000000000000000000000000611f36565b610e7e7f0000000000000000000000000000000000000000000000000000000000000000611f36565b610ea77f0000000000000000000000000000000000000000000000000000000000000000611f36565b604051602001610eb993929190612c04565b604051602081830303815290604052905090565b6000610a318243610c7d565b6001600160a01b038116600090815260036020526040812054610a31565b600060608082808083610f2b7f00000000000000000000000000000000000000000000000000000000000000006001611ff4565b610f567f00000000000000000000000000000000000000000000000000000000000000006002611ff4565b604080516000808252602082019092527f0f000000000000000000000000000000000000000000000000000000000000009b939a50919850469750309650945092509050565b600580546109a090612b27565b6008546000901580610feb5750816008600081548110610fcb57610fcb612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff16115b156110df577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316156110d7577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663981b24d0611078847f0000000000000000000000000000000000000000000000000000000000000000611d53565b6040518263ffffffff1660e01b815260040161109691815260200190565b602060405180830381865afa1580156110b3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a319190612beb565b506000919050565b610a31600883611d69565b336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461114c576040517f62f16ccd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111568282612098565b50816001600160a01b03167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca582604051610c7191815260200190565b60095460009060ff166111d1576040517f8574adcf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111dc33848461184b565b50600192915050565b60006111f18484610a21565b506040517f8f4ffcb10000000000000000000000000000000000000000000000000000000081526001600160a01b03851690638f4ffcb19061123d903390879030908890600401612c7a565b600060405180830381600087803b15801561125757600080fd5b505af115801561126b573d6000803e3d6000fd5b506001979650505050505050565b834211156112bb576040517f62791302000000000000000000000000000000000000000000000000000000008152600481018590526024015b60405180910390fd5b60007f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c98888886113088c6001600160a01b0316600090815260036020526040902080546001810190915590565b6040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810186905260e00160405160208183030381529060405280519060200120905060006113638261215f565b90506000611373828787876121a7565b9050896001600160a01b0316816001600160a01b0316146113d3576040517f4b800e460000000000000000000000000000000000000000000000000000000081526001600160a01b0380831660048301528b1660248201526044016112b2565b6113de8a8a8a611654565b5050505050505050505050565b6000546001600160a01b0316331461142f576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006001600160a01b03821661148157506000805460405147926001600160a01b039092169183156108fc02918491818181858888f1935050505015801561147b573d6000803e3d6000fd5b50611596565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b038316906370a0823190602401602060405180830381865afa1580156114de573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115029190612beb565b6000546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081526001600160a01b0391821660048201526024810183905291925083169063a9059cbb906044016020604051808303816000875af1158015611570573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061159491906126ef565b505b6000546040518281526001600160a01b03918216918416907ff931edb47c50b4b4104c187b5814a9aef5f709e17e2ecf9617e860cacade929c9060200160405180910390a35050565b6000546001600160a01b03163314611623576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b60095460009060ff16611693576040517f8574adcf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81158015906116c657506001600160a01b0380851660009081526007602090815260408083209387168352929052205415155b156116fd576040517fba793a6c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054611712906001600160a01b0316610880565b156117e5576000546040517fda682aeb0000000000000000000000000000000000000000000000000000000081526001600160a01b0386811660048301528581166024830152604482018590529091169063da682aeb906064016020604051808303816000875af115801561178b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117af91906126ef565b6117e5576040517fef18515800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b0384811660008181526007602090815260408083209488168084529482529182902086905590518581527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a35060019392505050565b806000036118a557816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8360405161189891815260200190565b60405180910390a3505050565b437f0000000000000000000000000000000000000000000000000000000000000000106118fe576040517f9c7fec5b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038216158061191c57506001600160a01b03821630145b15611953576040517fac6b05f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061195f8443610c7d565b90508181101561199b576040517fad3a8b9e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b03841660009081526006602052604090206119c6906119c18484612ba9565b6121cf565b60006119d28443610c7d565b6001600160a01b03851660009081526006602052604090209091506119fb906119c18584612cb6565b600054611a10906001600160a01b0316610880565b15611ae3576000546040517f4a3931490000000000000000000000000000000000000000000000000000000081526001600160a01b03878116600483015286811660248301526044820186905290911690634a393149906064016020604051808303816000875af1158015611a89573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611aad91906126ef565b611ae3576040517fef18515800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836001600160a01b0316856001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef85604051611b2891815260200190565b60405180910390a35050505050565b6000306001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016148015611b9057507f000000000000000000000000000000000000000000000000000000000000000046145b15611bba57507f000000000000000000000000000000000000000000000000000000000000000090565b610a42604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f60208201527f0000000000000000000000000000000000000000000000000000000000000000918101919091527f000000000000000000000000000000000000000000000000000000000000000060608201524660808201523060a082015260009060c00160405160208183030381529060405280519060200120905090565b600080611c6d610a37565b905080611c7a8482612cb6565b6fffffffffffffffffffffffffffffffff161015611cc4576040517f35278d1200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611ccf85610ecd565b9050611ce060086119c18685612cb6565b6001600160a01b0385166000908152600660205260409020611d06906119c18684612cb6565b6040518481526001600160a01b038616906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef906020015b60405180910390a3506001949350505050565b6000818310611d625781610a2e565b5090919050565b8154600090808203611d7f576000915050610a31565b83611d8b600183612ba9565b81548110611d9b57611d9b612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff168310611e165783611dcb600183612ba9565b81548110611ddb57611ddb612bbc565b60009182526020909120015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff169150610a319050565b83600081548110611e2957611e29612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff16831015611e58576000915050610a31565b600080611e66600184612ba9565b90505b81811115611ee85760006002611e7f8484612cb6565b611e8a906001612cb6565b611e949190612cc9565b905085878281548110611ea957611ea9612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff1611611ed457809250611ee2565b611edf600182612ba9565b91505b50611e69565b858281548110611efa57611efa612bbc565b60009182526020909120015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff169695505050505050565b60606000611f43836122e7565b600101905060008167ffffffffffffffff811115611f6357611f63612940565b6040519080825280601f01601f191660200182016040528015611f8d576020820181803683370190505b5090508181016020015b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff017f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a8504945084611f9757509392505050565b606060ff831461200757610df9836123c9565b81805461201390612b27565b80601f016020809104026020016040519081016040528092919081815260200182805461203f90612b27565b801561208c5780601f106120615761010080835404028352916020019161208c565b820191906000526020600020905b81548152906001019060200180831161206f57829003601f168201915b50505050509050610a31565b6000806120a3610a37565b905060006120b085610ecd565b9050838110156120ec576040517fad3a8b9e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6120fb60086119c18685612ba9565b6001600160a01b0385166000908152600660205260409020612121906119c18684612ba9565b6040518481526000906001600160a01b038716907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001611d40565b6000610a3161216c611b37565b836040517f19010000000000000000000000000000000000000000000000000000000000008152600281019290925260228201526042902090565b60008060006121b887878787612408565b915091506121c5816124ea565b5095945050505050565b815480156122a1576000836121e5600184612ba9565b815481106121f5576121f5612bbc565b60009182526020909120018054909150436fffffffffffffffffffffffffffffffff909116101561226e575082546001810184556000848152602090200180547fffffffffffffffffffffffffffffffff0000000000000000000000000000000016436fffffffffffffffffffffffffffffffff161781555b80546fffffffffffffffffffffffffffffffff808516700100000000000000000000000000000000029116179055505050565b82546001810184556000848152602090206fffffffffffffffffffffffffffffffff84811670010000000000000000000000000000000002439190911617910155505050565b6000807a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008310612330577a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000830492506040015b6d04ee2d6d415b85acef8100000000831061235c576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc10000831061237a57662386f26fc10000830492506010015b6305f5e1008310612392576305f5e100830492506008015b61271083106123a657612710830492506004015b606483106123b8576064830492506002015b600a8310610a315760010192915050565b606060006123d6836126a0565b604080516020808252818301909252919250600091906020820181803683375050509182525060208101929092525090565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561243f57506000905060036124e1565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015612493573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001519150506001600160a01b0381166124da576000600192509250506124e1565b9150600090505b94509492505050565b60008160048111156124fe576124fe612d04565b036125065750565b600181600481111561251a5761251a612d04565b03612581576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016112b2565b600281600481111561259557612595612d04565b036125fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016112b2565b600381600481111561261057612610612d04565b0361269d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f756500000000000000000000000000000000000000000000000000000000000060648201526084016112b2565b50565b600060ff8216601f811115610a31576040517fb3512b0c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b801515811461269d57600080fd5b60006020828403121561270157600080fd5b815161270c816126e1565b9392505050565b60006020828403121561272557600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461270c57600080fd5b60005b83811015612770578181015183820152602001612758565b50506000910152565b60008151808452612791816020860160208601612755565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610a2e6020830184612779565b6001600160a01b038116811461269d57600080fd5b600080604083850312156127fe57600080fd5b8235612809816127d6565b946020939093013593505050565b60008060006060848603121561282c57600080fd5b8335612837816127d6565b92506020840135612847816127d6565b929592945050506040919091013590565b60006020828403121561286a57600080fd5b813561270c816127d6565b7fff00000000000000000000000000000000000000000000000000000000000000881681526000602060e0818401526128b160e084018a612779565b83810360408501526128c3818a612779565b606085018990526001600160a01b038816608086015260a0850187905284810360c0860152855180825283870192509083019060005b81811015612915578351835292840192918401916001016128f9565b50909c9b505050505050505050505050565b60006020828403121561293957600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008060006060848603121561298457600080fd5b833561298f816127d6565b925060208401359150604084013567ffffffffffffffff808211156129b357600080fd5b818601915086601f8301126129c757600080fd5b8135818111156129d9576129d9612940565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715612a1f57612a1f612940565b81604052828152896020848701011115612a3857600080fd5b8260208601602083013760006020848301015280955050505050509250925092565b600080600080600080600060e0888a031215612a7557600080fd5b8735612a80816127d6565b96506020880135612a90816127d6565b95506040880135945060608801359350608088013560ff81168114612ab457600080fd5b9699959850939692959460a0840135945060c09093013592915050565b60008060408385031215612ae457600080fd5b8235612aef816127d6565b91506020830135612aff816127d6565b809150509250929050565b600060208284031215612b1c57600080fd5b813561270c816126e1565b600181811c90821680612b3b57607f821691505b602082108103612b74577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b81810381811115610a3157610a31612b7a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215612bfd57600080fd5b5051919050565b60008451612c16818460208901612755565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551612c52816001850160208a01612755565b60019201918201528351612c6d816002840160208801612755565b0160020195945050505050565b60006001600160a01b03808716835285602084015280851660408401525060806060830152612cac6080830184612779565b9695505050505050565b80820180821115610a3157610a31612b7a565b600082612cff577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd0000000000000000000000004200000000000000000000000000000000000010000000000000000000000000744d70fdbe2ba4cf95131626614a1763df805b9e0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000014537461747573204e6574776f726b20546f6b656e0000000000000000000000000000000000000000000000000000000000000000000000000000000000000003534e540000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x6080604052600436106102385760003560e01c806384b0196e11610138578063cae9ca51116100b0578063df8de3e71161007f578063ee9a31a211610064578063ee9a31a21461080c578063f41e60c514610840578063f77c47911461086057600080fd5b8063df8de3e7146107ec578063e78cea92146106b257600080fd5b8063cae9ca5114610766578063d505accf14610786578063d6c0b2c4146106ff578063dd62ed3e146107a657600080fd5b8063a9059cbb11610107578063bef97c87116100ec578063bef97c87146106e5578063c01e1bd6146106ff578063c5bcc4f11461073257600080fd5b8063a9059cbb14610692578063ae1f6aaf146106b257600080fd5b806384b0196e1461061557806395d89b411461063d578063981b24d0146106525780639dc29fac1461067257600080fd5b806332892177116101cb5780634ee2cd7e1161019a57806370a082311161017f57806370a08231146105a15780637ecebe00146105c157806380a54001146105e157600080fd5b80634ee2cd7e1461056c57806354fd4d501461058c57600080fd5b806332892177146104ce5780633644e515146105175780633cebb8231461052c57806340c10f191461054c57600080fd5b80631763451411610207578063176345141461041157806318160ddd1461045357806323b872dd14610468578063313ce5671461048857600080fd5b806301ffc9a71461034e578063033964be1461038357806306fdde03146103cf578063095ea7b3146103f157600080fd5b3661034957600054610252906001600160a01b0316610880565b610288576040517f2110f99100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000546040517ff48c30540000000000000000000000000000000000000000000000000000000081523360048201526001600160a01b039091169063f48c305490349060240160206040518083038185885af11580156102ec573d6000803e3d6000fd5b50505050506040513d601f19601f8201168201806040525081019061031191906126ef565b610347576040517fef18515800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b005b600080fd5b34801561035a57600080fd5b5061036e610369366004612713565b6108a2565b60405190151581526020015b60405180910390f35b34801561038f57600080fd5b506103b77f000000000000000000000000744d70fdbe2ba4cf95131626614a1763df805b9e81565b6040516001600160a01b03909116815260200161037a565b3480156103db57600080fd5b506103e4610993565b60405161037a91906127c3565b3480156103fd57600080fd5b5061036e61040c3660046127eb565b610a21565b34801561041d57600080fd5b506104457f0000000000000000000000000000000000000000000000000000000006a2b14981565b60405190815260200161037a565b34801561045f57600080fd5b50610445610a37565b34801561047457600080fd5b5061036e610483366004612817565b610a47565b34801561049457600080fd5b506104bc7f000000000000000000000000000000000000000000000000000000000000001281565b60405160ff909116815260200161037a565b3480156104da57600080fd5b506103e46040518060400160405280600781526020017f4d4d545f302e320000000000000000000000000000000000000000000000000081525081565b34801561052357600080fd5b50610445610b41565b34801561053857600080fd5b50610347610547366004612858565b610b4b565b34801561055857600080fd5b506103476105673660046127eb565b610bc9565b34801561057857600080fd5b506104456105873660046127eb565b610c7d565b34801561059857600080fd5b506103e4610e2a565b3480156105ad57600080fd5b506104456105bc366004612858565b610ecd565b3480156105cd57600080fd5b506104456105dc366004612858565b610ed9565b3480156105ed57600080fd5b506103b77f000000000000000000000000000000000000000000000000000000000000000081565b34801561062157600080fd5b5061062a610ef7565b60405161037a9796959493929190612875565b34801561064957600080fd5b506103e4610f9c565b34801561065e57600080fd5b5061044561066d366004612927565b610fa9565b34801561067e57600080fd5b5061034761068d3660046127eb565b6110ea565b34801561069e57600080fd5b5061036e6106ad3660046127eb565b611192565b3480156106be57600080fd5b507f00000000000000000000000042000000000000000000000000000000000000106103b7565b3480156106f157600080fd5b5060095461036e9060ff1681565b34801561070b57600080fd5b507f000000000000000000000000744d70fdbe2ba4cf95131626614a1763df805b9e6103b7565b34801561073e57600080fd5b506104457f000000000000000000000000000000000000000000000000000000000000000081565b34801561077257600080fd5b5061036e61078136600461296f565b6111e5565b34801561079257600080fd5b506103476107a1366004612a5a565b611279565b3480156107b257600080fd5b506104456107c1366004612ad1565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205490565b3480156107f857600080fd5b50610347610807366004612858565b6113eb565b34801561081857600080fd5b506103b77f000000000000000000000000420000000000000000000000000000000000001081565b34801561084c57600080fd5b5061034761085b366004612b0a565b6115df565b34801561086c57600080fd5b506000546103b7906001600160a01b031681565b6000806001600160a01b03831661089a5750600092915050565b50503b151590565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061095b57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b8061098a57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b600480546109a090612b27565b80601f01602080910402602001604051908101604052809291908181526020018280546109cc90612b27565b8015610a195780601f106109ee57610100808354040283529160200191610a19565b820191906000526020600020905b8154815290600101906020018083116109fc57829003601f168201915b505050505081565b6000610a2e338484611654565b90505b92915050565b6000610a4243610fa9565b905090565b600080546001600160a01b03163314610b2c5760095460ff16610a96576040517f8574adcf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b0384166000908152600760209081526040808320338452909152902054821115610af3576040517f4fd3af0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038416600090815260076020908152604080832033845290915281208054849290610b26908490612ba9565b90915550505b610b3784848461184b565b5060019392505050565b6000610a42611b37565b6000546001600160a01b03163314610b8f576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b336001600160a01b037f00000000000000000000000042000000000000000000000000000000000000101614610c2b576040517f62f16ccd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610c358282611c62565b50816001600160a01b03167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d412139688582604051610c7191815260200190565b60405180910390a25050565b6001600160a01b0382166000908152600660205260408120541580610ce657506001600160a01b03831660009081526006602052604081208054849290610cc657610cc6612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff16115b15610e08577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031615610e00577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316634ee2cd7e84610d74857f0000000000000000000000000000000000000000000000000000000000000000611d53565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381865afa158015610dd5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610df99190612beb565b9050610a31565b506000610a31565b6001600160a01b0383166000908152600660205260409020610df99083611d69565b6060610e557f0000000000000000000000000000000000000000000000000000000000000001611f36565b610e7e7f0000000000000000000000000000000000000000000000000000000000000000611f36565b610ea77f0000000000000000000000000000000000000000000000000000000000000001611f36565b604051602001610eb993929190612c04565b604051602081830303815290604052905090565b6000610a318243610c7d565b6001600160a01b038116600090815260036020526040812054610a31565b600060608082808083610f2b7f537461747573204e6574776f726b20546f6b656e0000000000000000000000146001611ff4565b610f567f4d4d545f302e32000000000000000000000000000000000000000000000000076002611ff4565b604080516000808252602082019092527f0f000000000000000000000000000000000000000000000000000000000000009b939a50919850469750309650945092509050565b600580546109a090612b27565b6008546000901580610feb5750816008600081548110610fcb57610fcb612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff16115b156110df577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316156110d7577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663981b24d0611078847f0000000000000000000000000000000000000000000000000000000000000000611d53565b6040518263ffffffff1660e01b815260040161109691815260200190565b602060405180830381865afa1580156110b3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a319190612beb565b506000919050565b610a31600883611d69565b336001600160a01b037f0000000000000000000000004200000000000000000000000000000000000010161461114c576040517f62f16ccd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111568282612098565b50816001600160a01b03167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca582604051610c7191815260200190565b60095460009060ff166111d1576040517f8574adcf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111dc33848461184b565b50600192915050565b60006111f18484610a21565b506040517f8f4ffcb10000000000000000000000000000000000000000000000000000000081526001600160a01b03851690638f4ffcb19061123d903390879030908890600401612c7a565b600060405180830381600087803b15801561125757600080fd5b505af115801561126b573d6000803e3d6000fd5b506001979650505050505050565b834211156112bb576040517f62791302000000000000000000000000000000000000000000000000000000008152600481018590526024015b60405180910390fd5b60007f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c98888886113088c6001600160a01b0316600090815260036020526040902080546001810190915590565b6040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810186905260e00160405160208183030381529060405280519060200120905060006113638261215f565b90506000611373828787876121a7565b9050896001600160a01b0316816001600160a01b0316146113d3576040517f4b800e460000000000000000000000000000000000000000000000000000000081526001600160a01b0380831660048301528b1660248201526044016112b2565b6113de8a8a8a611654565b5050505050505050505050565b6000546001600160a01b0316331461142f576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006001600160a01b03821661148157506000805460405147926001600160a01b039092169183156108fc02918491818181858888f1935050505015801561147b573d6000803e3d6000fd5b50611596565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b038316906370a0823190602401602060405180830381865afa1580156114de573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115029190612beb565b6000546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081526001600160a01b0391821660048201526024810183905291925083169063a9059cbb906044016020604051808303816000875af1158015611570573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061159491906126ef565b505b6000546040518281526001600160a01b03918216918416907ff931edb47c50b4b4104c187b5814a9aef5f709e17e2ecf9617e860cacade929c9060200160405180910390a35050565b6000546001600160a01b03163314611623576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b60095460009060ff16611693576040517f8574adcf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81158015906116c657506001600160a01b0380851660009081526007602090815260408083209387168352929052205415155b156116fd576040517fba793a6c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054611712906001600160a01b0316610880565b156117e5576000546040517fda682aeb0000000000000000000000000000000000000000000000000000000081526001600160a01b0386811660048301528581166024830152604482018590529091169063da682aeb906064016020604051808303816000875af115801561178b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117af91906126ef565b6117e5576040517fef18515800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b0384811660008181526007602090815260408083209488168084529482529182902086905590518581527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a35060019392505050565b806000036118a557816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8360405161189891815260200190565b60405180910390a3505050565b437f0000000000000000000000000000000000000000000000000000000000000000106118fe576040517f9c7fec5b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038216158061191c57506001600160a01b03821630145b15611953576040517fac6b05f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061195f8443610c7d565b90508181101561199b576040517fad3a8b9e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b03841660009081526006602052604090206119c6906119c18484612ba9565b6121cf565b60006119d28443610c7d565b6001600160a01b03851660009081526006602052604090209091506119fb906119c18584612cb6565b600054611a10906001600160a01b0316610880565b15611ae3576000546040517f4a3931490000000000000000000000000000000000000000000000000000000081526001600160a01b03878116600483015286811660248301526044820186905290911690634a393149906064016020604051808303816000875af1158015611a89573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611aad91906126ef565b611ae3576040517fef18515800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836001600160a01b0316856001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef85604051611b2891815260200190565b60405180910390a35050505050565b6000306001600160a01b037f000000000000000000000000650af3c15af43dcb218406d30784416d64cfb6b216148015611b9057507f000000000000000000000000000000000000000000000000000000000000000a46145b15611bba57507ff0006e6aa51bd89c019fa0b2ab0bb6119b3f8208eefb2242d111d3d7bb35183c90565b610a42604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f60208201527fec06ba6f0d44380e554220ce65276e605e8cc46f2cdf90db295fa96807e3c0c8918101919091527fd12b0de940888e83c2c48451dcc7ab143b1a5b7d620f8fc5b7335d9bbd9d15c660608201524660808201523060a082015260009060c00160405160208183030381529060405280519060200120905090565b600080611c6d610a37565b905080611c7a8482612cb6565b6fffffffffffffffffffffffffffffffff161015611cc4576040517f35278d1200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611ccf85610ecd565b9050611ce060086119c18685612cb6565b6001600160a01b0385166000908152600660205260409020611d06906119c18684612cb6565b6040518481526001600160a01b038616906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef906020015b60405180910390a3506001949350505050565b6000818310611d625781610a2e565b5090919050565b8154600090808203611d7f576000915050610a31565b83611d8b600183612ba9565b81548110611d9b57611d9b612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff168310611e165783611dcb600183612ba9565b81548110611ddb57611ddb612bbc565b60009182526020909120015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff169150610a319050565b83600081548110611e2957611e29612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff16831015611e58576000915050610a31565b600080611e66600184612ba9565b90505b81811115611ee85760006002611e7f8484612cb6565b611e8a906001612cb6565b611e949190612cc9565b905085878281548110611ea957611ea9612bbc565b6000918252602090912001546fffffffffffffffffffffffffffffffff1611611ed457809250611ee2565b611edf600182612ba9565b91505b50611e69565b858281548110611efa57611efa612bbc565b60009182526020909120015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff169695505050505050565b60606000611f43836122e7565b600101905060008167ffffffffffffffff811115611f6357611f63612940565b6040519080825280601f01601f191660200182016040528015611f8d576020820181803683370190505b5090508181016020015b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff017f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a8504945084611f9757509392505050565b606060ff831461200757610df9836123c9565b81805461201390612b27565b80601f016020809104026020016040519081016040528092919081815260200182805461203f90612b27565b801561208c5780601f106120615761010080835404028352916020019161208c565b820191906000526020600020905b81548152906001019060200180831161206f57829003601f168201915b50505050509050610a31565b6000806120a3610a37565b905060006120b085610ecd565b9050838110156120ec576040517fad3a8b9e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6120fb60086119c18685612ba9565b6001600160a01b0385166000908152600660205260409020612121906119c18684612ba9565b6040518481526000906001600160a01b038716907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001611d40565b6000610a3161216c611b37565b836040517f19010000000000000000000000000000000000000000000000000000000000008152600281019290925260228201526042902090565b60008060006121b887878787612408565b915091506121c5816124ea565b5095945050505050565b815480156122a1576000836121e5600184612ba9565b815481106121f5576121f5612bbc565b60009182526020909120018054909150436fffffffffffffffffffffffffffffffff909116101561226e575082546001810184556000848152602090200180547fffffffffffffffffffffffffffffffff0000000000000000000000000000000016436fffffffffffffffffffffffffffffffff161781555b80546fffffffffffffffffffffffffffffffff808516700100000000000000000000000000000000029116179055505050565b82546001810184556000848152602090206fffffffffffffffffffffffffffffffff84811670010000000000000000000000000000000002439190911617910155505050565b6000807a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008310612330577a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000830492506040015b6d04ee2d6d415b85acef8100000000831061235c576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc10000831061237a57662386f26fc10000830492506010015b6305f5e1008310612392576305f5e100830492506008015b61271083106123a657612710830492506004015b606483106123b8576064830492506002015b600a8310610a315760010192915050565b606060006123d6836126a0565b604080516020808252818301909252919250600091906020820181803683375050509182525060208101929092525090565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561243f57506000905060036124e1565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015612493573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001519150506001600160a01b0381166124da576000600192509250506124e1565b9150600090505b94509492505050565b60008160048111156124fe576124fe612d04565b036125065750565b600181600481111561251a5761251a612d04565b03612581576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016112b2565b600281600481111561259557612595612d04565b036125fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016112b2565b600381600481111561261057612610612d04565b0361269d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f756500000000000000000000000000000000000000000000000000000000000060648201526084016112b2565b50565b600060ff8216601f811115610a31576040517fb3512b0c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b801515811461269d57600080fd5b60006020828403121561270157600080fd5b815161270c816126e1565b9392505050565b60006020828403121561272557600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461270c57600080fd5b60005b83811015612770578181015183820152602001612758565b50506000910152565b60008151808452612791816020860160208601612755565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610a2e6020830184612779565b6001600160a01b038116811461269d57600080fd5b600080604083850312156127fe57600080fd5b8235612809816127d6565b946020939093013593505050565b60008060006060848603121561282c57600080fd5b8335612837816127d6565b92506020840135612847816127d6565b929592945050506040919091013590565b60006020828403121561286a57600080fd5b813561270c816127d6565b7fff00000000000000000000000000000000000000000000000000000000000000881681526000602060e0818401526128b160e084018a612779565b83810360408501526128c3818a612779565b606085018990526001600160a01b038816608086015260a0850187905284810360c0860152855180825283870192509083019060005b81811015612915578351835292840192918401916001016128f9565b50909c9b505050505050505050505050565b60006020828403121561293957600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008060006060848603121561298457600080fd5b833561298f816127d6565b925060208401359150604084013567ffffffffffffffff808211156129b357600080fd5b818601915086601f8301126129c757600080fd5b8135818111156129d9576129d9612940565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715612a1f57612a1f612940565b81604052828152896020848701011115612a3857600080fd5b8260208601602083013760006020848301015280955050505050509250925092565b600080600080600080600060e0888a031215612a7557600080fd5b8735612a80816127d6565b96506020880135612a90816127d6565b95506040880135945060608801359350608088013560ff81168114612ab457600080fd5b9699959850939692959460a0840135945060c09093013592915050565b60008060408385031215612ae457600080fd5b8235612aef816127d6565b91506020830135612aff816127d6565b809150509250929050565b600060208284031215612b1c57600080fd5b813561270c816126e1565b600181811c90821680612b3b57607f821691505b602082108103612b74577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b81810381811115610a3157610a31612b7a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215612bfd57600080fd5b5051919050565b60008451612c16818460208901612755565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551612c52816001850160208a01612755565b60019201918201528351612c6d816002840160208801612755565b0160020195945050505050565b60006001600160a01b03808716835285602084015280851660408401525060806060830152612cac6080830184612779565b9695505050505050565b80820180821115610a3157610a31612b7a565b600082612cff577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000004200000000000000000000000000000000000010000000000000000000000000744d70fdbe2ba4cf95131626614a1763df805b9e0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000014537461747573204e6574776f726b20546f6b656e0000000000000000000000000000000000000000000000000000000000000000000000000000000000000003534e540000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _bridge (address): 0x4200000000000000000000000000000000000010
Arg [1] : _remoteToken (address): 0x744d70FDBE2Ba4CF95131626614a1763DF805B9E
Arg [2] : _parentToken (address): 0x0000000000000000000000000000000000000000
Arg [3] : _parentSnapShotBlock (uint256): 0
Arg [4] : _tokenName (string): Status Network Token
Arg [5] : _decimalUnits (uint8): 18
Arg [6] : _tokenSymbol (string): SNT
Arg [7] : _transfersEnabled (bool): True
-----Encoded View---------------
12 Constructor Arguments found :
Arg [0] : 0000000000000000000000004200000000000000000000000000000000000010
Arg [1] : 000000000000000000000000744d70fdbe2ba4cf95131626614a1763df805b9e
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000100
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000012
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [8] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [9] : 537461747573204e6574776f726b20546f6b656e000000000000000000000000
Arg [10] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [11] : 534e540000000000000000000000000000000000000000000000000000000000
Net Worth in USD
Net Worth in ETH
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
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.