FRAX Price: $1.04 (+7.80%)

Contract

0x7F2aFd3Fa3f9CFFb66AaA2ccE0f7527B37C8bbfA

Overview

FRAX Balance | FXTL Balance

0.00000007373070947 FRAX | 5,148 FXTL

FRAX Value

Less Than $0.01 (@ $1.04/FRAX)

Token Holdings

More Info

Private Name Tags

Multichain Info

No addresses found
Transaction Hash
Block
From
To
Send264735542025-10-06 13:36:59110 days ago1759757819IN
0x7F2aFd3F...B37C8bbfA
0.09009009 FRAX0.0047364520.00000025
Send235187252025-07-30 4:02:41178 days ago1753848161IN
0x7F2aFd3F...B37C8bbfA
0.00005174 FRAX0.000145790.00109925
Send235056752025-07-29 20:47:41178 days ago1753822061IN
0x7F2aFd3F...B37C8bbfA
0.00005174 FRAX0.000135930.01566
Send229182392025-07-16 6:26:29192 days ago1752647189IN
0x7F2aFd3F...B37C8bbfA
0.00007726 FRAX0.02253254100.00000025
Send222630032025-07-01 2:25:17207 days ago1751336717IN
0x7F2aFd3F...B37C8bbfA
0.000089 FRAX0.0219991100.00000025
Send202544972025-05-15 14:35:05254 days ago1747319705IN
0x7F2aFd3F...B37C8bbfA
0.00031332 FRAX0.000000280.00120133
Send201136262025-05-12 8:19:23257 days ago1747037963IN
0x7F2aFd3F...B37C8bbfA
0.00031332 FRAX0.000000230.00110111
Send194483622025-04-26 22:43:55272 days ago1745707435IN
0x7F2aFd3F...B37C8bbfA
0.00031332 FRAX0.000000270.00110025
Send170775762025-03-03 1:37:43327 days ago1740965863IN
0x7F2aFd3F...B37C8bbfA
0.00007574 FRAX0.000000090.00010025
Set Mapped Bridg...168846312025-02-26 14:26:13332 days ago1740579973IN
0x7F2aFd3F...B37C8bbfA
0 FRAX0.000000250.00100025
Set Mapped Token168846252025-02-26 14:26:01332 days ago1740579961IN
0x7F2aFd3F...B37C8bbfA
0 FRAX0.000049051.00000025
Set Mapped Token168846222025-02-26 14:25:55332 days ago1740579955IN
0x7F2aFd3F...B37C8bbfA
0 FRAX0.000000270.00100025
Send162133842025-02-11 1:31:19347 days ago1739237479IN
0x7F2aFd3F...B37C8bbfA
0.00007708 FRAX0.00000030.00100025
Send161806712025-02-10 7:20:53348 days ago1739172053IN
0x7F2aFd3F...B37C8bbfA
0.00009635 FRAX0.000000090.00010025
Send161559462025-02-09 17:36:43349 days ago1739122603IN
0x7F2aFd3F...B37C8bbfA
0.00007708 FRAX0.00000030.00100025
Send161087022025-02-08 15:21:55350 days ago1739028115IN
0x7F2aFd3F...B37C8bbfA
0.00009635 FRAX0.000000320.00100025
Send161014032025-02-08 11:18:37350 days ago1739013517IN
0x7F2aFd3F...B37C8bbfA
0.0001927 FRAX0.000000310.00100025
Send161009932025-02-08 11:04:57350 days ago1739012697IN
0x7F2aFd3F...B37C8bbfA
0.00009635 FRAX0.00000030.00100025
Send159397552025-02-04 17:30:21354 days ago1738690221IN
0x7F2aFd3F...B37C8bbfA
0.00009635 FRAX0.000000510.00110025
Send158548682025-02-02 18:20:47356 days ago1738520447IN
0x7F2aFd3F...B37C8bbfA
0.00008193 FRAX0.000002630.00110025
Send158294152025-02-02 4:12:21356 days ago1738469541IN
0x7F2aFd3F...B37C8bbfA
0.00016387 FRAX0.000000280.00010025
Send157716742025-01-31 20:07:39358 days ago1738354059IN
0x7F2aFd3F...B37C8bbfA
0.00008193 FRAX0.000000570.00110025
Send156018062025-01-27 21:45:23361 days ago1738014323IN
0x7F2aFd3F...B37C8bbfA
0.00015779 FRAX0.000000980.00010025
Send156009162025-01-27 21:15:43361 days ago1738012543IN
0x7F2aFd3F...B37C8bbfA
0.00015779 FRAX0.00000090.00010025
Send154603602025-01-24 15:10:31365 days ago1737731431IN
0x7F2aFd3F...B37C8bbfA
0.00015779 FRAX0.000001830.00110025
View all transactions

Latest 25 internal transactions (View All)

Advanced mode:
Parent Transaction Hash Block From To
301917112025-12-31 15:15:3324 days ago1767194133
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
301917112025-12-31 15:15:3324 days ago1767194133
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296773272025-12-19 17:29:2536 days ago1766165365
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296773272025-12-19 17:29:2536 days ago1766165365
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296772582025-12-19 17:27:0736 days ago1766165227
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296772582025-12-19 17:27:0736 days ago1766165227
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296767002025-12-19 17:08:3136 days ago1766164111
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296767002025-12-19 17:08:3136 days ago1766164111
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296766772025-12-19 17:07:4536 days ago1766164065
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
296766772025-12-19 17:07:4536 days ago1766164065
0x7F2aFd3F...B37C8bbfA
0.29462327 FRAX
276066562025-11-01 19:07:0384 days ago1762024023
0x7F2aFd3F...B37C8bbfA
0.15873015 FRAX
276066562025-11-01 19:07:0384 days ago1762024023
0x7F2aFd3F...B37C8bbfA
0.15873015 FRAX
264735542025-10-06 13:36:59110 days ago1759757819
0x7F2aFd3F...B37C8bbfA
0.09009009 FRAX
264689582025-10-06 11:03:47110 days ago1759748627
0x7F2aFd3F...B37C8bbfA
0.00000003 FRAX
264070152025-10-05 0:39:01111 days ago1759624741
0x7F2aFd3F...B37C8bbfA
0.00000003 FRAX
235187252025-07-30 4:02:41178 days ago1753848161
0x7F2aFd3F...B37C8bbfA
0.00005174 FRAX
235056752025-07-29 20:47:41178 days ago1753822061
0x7F2aFd3F...B37C8bbfA
0.00005174 FRAX
229182392025-07-16 6:26:29192 days ago1752647189
0x7F2aFd3F...B37C8bbfA
0.00007726 FRAX
222630032025-07-01 2:25:17207 days ago1751336717
0x7F2aFd3F...B37C8bbfA
0.000089 FRAX
202544972025-05-15 14:35:05254 days ago1747319705
0x7F2aFd3F...B37C8bbfA
0.00031332 FRAX
201136262025-05-12 8:19:23257 days ago1747037963
0x7F2aFd3F...B37C8bbfA
0.00031332 FRAX
194483622025-04-26 22:43:55272 days ago1745707435
0x7F2aFd3F...B37C8bbfA
0.00031332 FRAX
170775762025-03-03 1:37:43327 days ago1740965863
0x7F2aFd3F...B37C8bbfA
0.00007574 FRAX
162133842025-02-11 1:31:19347 days ago1739237479
0x7F2aFd3F...B37C8bbfA
0.00007708 FRAX
161806712025-02-10 7:20:53348 days ago1739172053
0x7F2aFd3F...B37C8bbfA
0.00009635 FRAX
View All Internal Transactions

Cross-Chain Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
xERC20Hyperlane

Compiler Version
v0.8.22+commit.4fc1097e

Optimization Enabled:
Yes with 200 runs

Other Settings:
paris EvmVersion, Unlicense license
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.22;

import { Ownable } from "@openzeppelin/contracts/access/Ownable.sol";
import { IERC20 } from "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import { IXERC20 } from "./interface/IXERC20.sol";
import { IMailbox } from "./hyperlane/interfaces/IMailbox.sol";

library TypeCasts {
  // alignment preserving cast
  function addressToBytes32(address _addr) internal pure returns (bytes32) {
    return bytes32(uint256(uint160(_addr)));
  }

  // alignment preserving cast
  function bytes32ToAddress(bytes32 _buf) internal pure returns (address) {
    return address(uint160(uint256(_buf)));
  }
}

contract xERC20Hyperlane is Ownable {
  using TypeCasts for address;
  using TypeCasts for bytes32;

  uint256 public feeBps;
  mapping(address => mapping(uint32 => address)) public mappedTokens;
  mapping(uint32 => address) public mappedBridges;
  IMailbox immutable mailbox;

  event TokenMapped(address indexed _token, uint32 indexed _chainId, address indexed _dstToken);
  event BridgeMapped(uint32 indexed _chainId, address indexed _bridge);
  event FeeBpsSet(uint256 indexed _feeBps);
  event TokenSent(
    address indexed _token,
    uint256 _amount,
    address indexed _to,
    uint32 indexed _dstChainId,
    bytes32 _guid
  );
  event TokenReceived(
    address indexed _token,
    uint256 _amount,
    address indexed _to,
    uint32 indexed _srcChainId,
    bytes32 _guid
  );

  error TokenNotSet();
  error ChainIdNotSet();
  error DestinationBridgeNotSet(uint32 _chainId);
  error OriginNotAllowed(uint32 _chainId, address _sender);

  /**
   * @notice Only accept messages from an Hyperlane Mailbox contract
   */
  modifier onlyMailbox() {
    require(msg.sender == address(mailbox), "MailboxClient: sender not mailbox");
    _;
  }

  constructor(uint256 _feeBps, address _mailbox) Ownable() {
    mailbox = IMailbox(_mailbox);
    feeBps = _feeBps;
  }

  // ADMIN FUNCTIONS
  function setFeeBps(uint256 _feeBps) public onlyOwner {
    feeBps = _feeBps;
    emit FeeBpsSet(_feeBps);
  }

  function setMappedToken(uint32 _chainId, address _srcToken, address _dstToken) public onlyOwner {
    mappedTokens[_srcToken][_chainId] = _dstToken;
    emit TokenMapped(_srcToken, _chainId, _dstToken);
  }

  function setMappedBridge(uint32 _chainId, address _bridge) public onlyOwner {
    mappedBridges[_chainId] = _bridge;
    emit BridgeMapped(_chainId, _bridge);
  }

  function withdrawFee(address _token) public onlyOwner {
    uint256 _amount = IERC20(_token).balanceOf(address(this));
    IERC20(_token).transfer(msg.sender, _amount);
  }

  function withdrawFee(address _token, uint256 _amount) public onlyOwner {
    IERC20(_token).transfer(msg.sender, _amount);
  }

  function withdrawEth() public onlyOwner {
    uint256 _amount = address(this).balance;
    payable(msg.sender).transfer(_amount);
  }

  function withdrawEth(uint256 _amount) public onlyOwner {
    payable(msg.sender).transfer(_amount);
  }

  // PUBLIC FUNCTIONS
  function quote(uint32 _dstChainId, address _token, uint256 _amount, address _to) external view returns (uint256 fee) {
    return _quoteInternal(_dstChainId, _token, _amount, _to);
  }

  function send(address _token, uint256 _amount, address _to, uint32 _dstChainId) external payable {
    _send(_dstChainId, _token, _amount, _to);
  }

  // INTERNAL FUNCTIONS
  function _quoteInternal(
    uint32 _dstChainId,
    address _token,
    uint256 _amount,
    address _to
  ) internal view returns (uint256 fee) {
    address _bridge = mappedBridges[_dstChainId];
    if (_bridge == address(0)) {
      revert DestinationBridgeNotSet(_dstChainId);
    }
    uint256 _amountAfterFee = (_amount * (10000 - feeBps)) / 10000;
    bytes memory _payload = abi.encode(_to, _token, _amountAfterFee);
    fee = mailbox.quoteDispatch(_dstChainId, _bridge.addressToBytes32(), _payload);
    return fee;
  }

  function _send(uint32 _dstChainId, address _token, uint256 _amount, address _to) internal {
    address _bridge = mappedBridges[_dstChainId];
    if (_bridge == address(0)) {
      revert DestinationBridgeNotSet(_dstChainId);
    }
    // transfer tokens to this contract
    IERC20(_token).transferFrom(msg.sender, address(this), _amount);

    // take fee and burn the tokens
    uint256 _amountAfterFee = (_amount * (10000 - feeBps)) / 10000;
    IXERC20(_token).burn(address(this), _amountAfterFee);

    bytes memory _payload = abi.encode(_to, _token, _amountAfterFee);
    bytes32 _guid = mailbox.dispatch{ value: msg.value }(_dstChainId, _bridge.addressToBytes32(), _payload);
    emit TokenSent(_token, _amountAfterFee, _to, _dstChainId, _guid);
  }

  function handle(uint32 _origin, bytes32 _sender, bytes calldata _data) external payable virtual onlyMailbox {
    if (mappedBridges[_origin] != _sender.bytes32ToAddress()) {
      revert OriginNotAllowed(_origin, _sender.bytes32ToAddress());
    }
    // Decode the payload to get the message
    (address _to, address _srcToken, uint256 _amount) = abi.decode(_data, (address, address, uint256));

    // get the mapped token using the current chain id and received source token
    address _dstToken = mappedTokens[_srcToken][_origin];
    if (_dstToken == address(0)) {
      revert TokenNotSet();
    }

    // mint the tokens to the destination address
    IXERC20(_dstToken).mint(_to, _amount);
    emit TokenReceived(_dstToken, _amount, _to, _origin, bytes32(0));
  }

  receive() external payable {}
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.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 v4.4.1 (token/ERC20/extensions/draft-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.7.0) (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../extensions/draft-IERC20Permit.sol";
import "../../../utils/Address.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
        }
    }

    function safePermit(
        IERC20Permit token,
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) internal {
        uint256 nonceBefore = token.nonces(owner);
        token.permit(owner, spender, value, deadline, v, r, s);
        uint256 nonceAfter = token.nonces(owner);
        require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed");
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) {
            // Return data is optional
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://consensys.net/diligence/blog/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
     * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
     *
     * _Available since v4.8._
     */
    function verifyCallResultFromTarget(
        address target,
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        if (success) {
            if (returndata.length == 0) {
                // only check isContract if the call was successful and the return data is empty
                // otherwise we already know that it was a contract
                require(isContract(target), "Address: call to non-contract");
            }
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    /**
     * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason or using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    function _revert(bytes memory returndata, string memory errorMessage) private pure {
        // Look for revert reason and bubble it up if present
        if (returndata.length > 0) {
            // The easiest way to bubble the revert reason is using memory via assembly
            /// @solidity memory-safe-assembly
            assembly {
                let returndata_size := mload(returndata)
                revert(add(32, returndata), returndata_size)
            }
        } else {
            revert(errorMessage);
        }
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;

/**
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

// SPDX-License-Identifier: MIT OR Apache-2.0
pragma solidity >=0.6.11;

interface IInterchainSecurityModule {
    enum Types {
        UNUSED,
        ROUTING,
        AGGREGATION,
        LEGACY_MULTISIG,
        MERKLE_ROOT_MULTISIG,
        MESSAGE_ID_MULTISIG,
        NULL, // used with relayer carrying no metadata
        CCIP_READ,
        ARB_L2_TO_L1,
        WEIGHTED_MERKLE_ROOT_MULTISIG,
        WEIGHTED_MESSAGE_ID_MULTISIG,
        OP_L2_TO_L1
    }

    /**
     * @notice Returns an enum that represents the type of security model
     * encoded by this ISM.
     * @dev Relayers infer how to fetch and format metadata.
     */
    function moduleType() external view returns (uint8);

    /**
     * @notice Defines a security model responsible for verifying interchain
     * messages based on the provided metadata.
     * @param _metadata Off-chain metadata provided by a relayer, specific to
     * the security model encoded by the module (e.g. validator signatures)
     * @param _message Hyperlane encoded interchain message
     * @return True if the message was verified
     */
    function verify(
        bytes calldata _metadata,
        bytes calldata _message
    ) external returns (bool);
}

interface ISpecifiesInterchainSecurityModule {
    function interchainSecurityModule()
        external
        view
        returns (IInterchainSecurityModule);
}

// SPDX-License-Identifier: MIT OR Apache-2.0
pragma solidity >=0.8.0;

import {IInterchainSecurityModule} from "./IInterchainSecurityModule.sol";
import {IPostDispatchHook} from "./hooks/IPostDispatchHook.sol";

interface IMailbox {
    // ============ Events ============
    /**
     * @notice Emitted when a new message is dispatched via Hyperlane
     * @param sender The address that dispatched the message
     * @param destination The destination domain of the message
     * @param recipient The message recipient address on `destination`
     * @param message Raw bytes of message
     */
    event Dispatch(
        address indexed sender,
        uint32 indexed destination,
        bytes32 indexed recipient,
        bytes message
    );

    /**
     * @notice Emitted when a new message is dispatched via Hyperlane
     * @param messageId The unique message identifier
     */
    event DispatchId(bytes32 indexed messageId);

    /**
     * @notice Emitted when a Hyperlane message is processed
     * @param messageId The unique message identifier
     */
    event ProcessId(bytes32 indexed messageId);

    /**
     * @notice Emitted when a Hyperlane message is delivered
     * @param origin The origin domain of the message
     * @param sender The message sender address on `origin`
     * @param recipient The address that handled the message
     */
    event Process(
        uint32 indexed origin,
        bytes32 indexed sender,
        address indexed recipient
    );

    function localDomain() external view returns (uint32);

    function delivered(bytes32 messageId) external view returns (bool);

    function defaultIsm() external view returns (IInterchainSecurityModule);

    function defaultHook() external view returns (IPostDispatchHook);

    function requiredHook() external view returns (IPostDispatchHook);

    function latestDispatchedId() external view returns (bytes32);

    function dispatch(
        uint32 destinationDomain,
        bytes32 recipientAddress,
        bytes calldata messageBody
    ) external payable returns (bytes32 messageId);

    function quoteDispatch(
        uint32 destinationDomain,
        bytes32 recipientAddress,
        bytes calldata messageBody
    ) external view returns (uint256 fee);

    function dispatch(
        uint32 destinationDomain,
        bytes32 recipientAddress,
        bytes calldata body,
        bytes calldata defaultHookMetadata
    ) external payable returns (bytes32 messageId);

    function quoteDispatch(
        uint32 destinationDomain,
        bytes32 recipientAddress,
        bytes calldata messageBody,
        bytes calldata defaultHookMetadata
    ) external view returns (uint256 fee);

    function dispatch(
        uint32 destinationDomain,
        bytes32 recipientAddress,
        bytes calldata body,
        bytes calldata customHookMetadata,
        IPostDispatchHook customHook
    ) external payable returns (bytes32 messageId);

    function quoteDispatch(
        uint32 destinationDomain,
        bytes32 recipientAddress,
        bytes calldata messageBody,
        bytes calldata customHookMetadata,
        IPostDispatchHook customHook
    ) external view returns (uint256 fee);

    function process(
        bytes calldata metadata,
        bytes calldata message
    ) external payable;

    function recipientIsm(
        address recipient
    ) external view returns (IInterchainSecurityModule module);
}

// SPDX-License-Identifier: MIT OR Apache-2.0
pragma solidity >=0.8.0;

/*@@@@@@@       @@@@@@@@@
 @@@@@@@@@       @@@@@@@@@
  @@@@@@@@@       @@@@@@@@@
   @@@@@@@@@       @@@@@@@@@
    @@@@@@@@@@@@@@@@@@@@@@@@@
     @@@@@  HYPERLANE  @@@@@@@
    @@@@@@@@@@@@@@@@@@@@@@@@@
   @@@@@@@@@       @@@@@@@@@
  @@@@@@@@@       @@@@@@@@@
 @@@@@@@@@       @@@@@@@@@
@@@@@@@@@       @@@@@@@@*/

interface IPostDispatchHook {
    enum Types {
        UNUSED,
        ROUTING,
        AGGREGATION,
        MERKLE_TREE,
        INTERCHAIN_GAS_PAYMASTER,
        FALLBACK_ROUTING,
        ID_AUTH_ISM,
        PAUSABLE,
        PROTOCOL_FEE,
        LAYER_ZERO_V1,
        RATE_LIMITED,
        ARB_L2_TO_L1,
        OP_L2_TO_L1
    }

    /**
     * @notice Returns an enum that represents the type of hook
     */
    function hookType() external view returns (uint8);

    /**
     * @notice Returns whether the hook supports metadata
     * @param metadata metadata
     * @return Whether the hook supports metadata
     */
    function supportsMetadata(
        bytes calldata metadata
    ) external view returns (bool);

    /**
     * @notice Post action after a message is dispatched via the Mailbox
     * @param metadata The metadata required for the hook
     * @param message The message passed from the Mailbox.dispatch() call
     */
    function postDispatch(
        bytes calldata metadata,
        bytes calldata message
    ) external payable;

    /**
     * @notice Compute the payment required by the postDispatch call
     * @param metadata The metadata required for the hook
     * @param message The message passed from the Mailbox.dispatch() call
     * @return Quoted payment for the postDispatch call
     */
    function quoteDispatch(
        bytes calldata metadata,
        bytes calldata message
    ) external view returns (uint256);
}

// SPDX-License-Identifier: UNLICENSED
pragma solidity >=0.8.4 <0.9.0;

interface IXERC20 {
  /**
   * @notice Emits when a lockbox is set
   *
   * @param _lockbox The address of the lockbox
   */
  event LockboxSet(address _lockbox);

  /**
   * @notice Emits when a limit is set
   *
   * @param _mintingLimit The updated minting limit we are setting to the bridge
   * @param _burningLimit The updated burning limit we are setting to the bridge
   * @param _bridge The address of the bridge we are setting the limit too
   */
  event BridgeLimitsSet(uint256 _mintingLimit, uint256 _burningLimit, address indexed _bridge);

  /**
   * @notice Reverts when a user with too low of a limit tries to call mint/burn
   */
  error IXERC20_NotHighEnoughLimits();

  /**
   * @notice Reverts when caller is not the factory
   */
  error IXERC20_NotFactory();

  /**
   * @notice Reverts when limits are too high
   */
  error IXERC20_LimitsTooHigh();

  /**
   * @notice Contains the full minting and burning data for a particular bridge
   *
   * @param minterParams The minting parameters for the bridge
   * @param burnerParams The burning parameters for the bridge
   */
  struct Bridge {
    BridgeParameters minterParams;
    BridgeParameters burnerParams;
  }

  /**
   * @notice Contains the mint or burn parameters for a bridge
   *
   * @param timestamp The timestamp of the last mint/burn
   * @param ratePerSecond The rate per second of the bridge
   * @param maxLimit The max limit of the bridge
   * @param currentLimit The current limit of the bridge
   */
  struct BridgeParameters {
    uint256 timestamp;
    uint256 ratePerSecond;
    uint256 maxLimit;
    uint256 currentLimit;
  }

  /**
   * @notice Sets the lockbox address
   *
   * @param _lockbox The address of the lockbox
   */
  function setLockbox(address _lockbox) external;

  /**
   * @notice Updates the limits of any bridge
   * @dev Can only be called by the owner
   * @param _mintingLimit The updated minting limit we are setting to the bridge
   * @param _burningLimit The updated burning limit we are setting to the bridge
   * @param _bridge The address of the bridge we are setting the limits too
   */
  function setLimits(address _bridge, uint256 _mintingLimit, uint256 _burningLimit) external;

  /**
   * @notice Returns the max limit of a minter
   *
   * @param _minter The minter we are viewing the limits of
   *  @return _limit The limit the minter has
   */
  function mintingMaxLimitOf(address _minter) external view returns (uint256 _limit);

  /**
   * @notice Returns the max limit of a bridge
   *
   * @param _bridge the bridge we are viewing the limits of
   * @return _limit The limit the bridge has
   */
  function burningMaxLimitOf(address _bridge) external view returns (uint256 _limit);

  /**
   * @notice Returns the current limit of a minter
   *
   * @param _minter The minter we are viewing the limits of
   * @return _limit The limit the minter has
   */
  function mintingCurrentLimitOf(address _minter) external view returns (uint256 _limit);

  /**
   * @notice Returns the current limit of a bridge
   *
   * @param _bridge the bridge we are viewing the limits of
   * @return _limit The limit the bridge has
   */
  function burningCurrentLimitOf(address _bridge) external view returns (uint256 _limit);

  /**
   * @notice Mints tokens for a user
   * @dev Can only be called by a minter
   * @param _user The address of the user who needs tokens minted
   * @param _amount The amount of tokens being minted
   */
  function mint(address _user, uint256 _amount) external;

  /**
   * @notice Burns tokens for a user
   * @dev Can only be called by a minter
   * @param _user The address of the user who needs tokens burned
   * @param _amount The amount of tokens being burned
   */
  function burn(address _user, uint256 _amount) external;
}

Settings
{
  "evmVersion": "paris",
  "libraries": {},
  "metadata": {
    "bytecodeHash": "ipfs",
    "useLiteralContent": true
  },
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "remappings": [],
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"uint256","name":"_feeBps","type":"uint256"},{"internalType":"address","name":"_mailbox","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ChainIdNotSet","type":"error"},{"inputs":[{"internalType":"uint32","name":"_chainId","type":"uint32"}],"name":"DestinationBridgeNotSet","type":"error"},{"inputs":[{"internalType":"uint32","name":"_chainId","type":"uint32"},{"internalType":"address","name":"_sender","type":"address"}],"name":"OriginNotAllowed","type":"error"},{"inputs":[],"name":"TokenNotSet","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint32","name":"_chainId","type":"uint32"},{"indexed":true,"internalType":"address","name":"_bridge","type":"address"}],"name":"BridgeMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"_feeBps","type":"uint256"}],"name":"FeeBpsSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_token","type":"address"},{"indexed":true,"internalType":"uint32","name":"_chainId","type":"uint32"},{"indexed":true,"internalType":"address","name":"_dstToken","type":"address"}],"name":"TokenMapped","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_token","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"_to","type":"address"},{"indexed":true,"internalType":"uint32","name":"_srcChainId","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"_guid","type":"bytes32"}],"name":"TokenReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_token","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"_to","type":"address"},{"indexed":true,"internalType":"uint32","name":"_dstChainId","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"_guid","type":"bytes32"}],"name":"TokenSent","type":"event"},{"inputs":[],"name":"feeBps","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"_origin","type":"uint32"},{"internalType":"bytes32","name":"_sender","type":"bytes32"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"handle","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"}],"name":"mappedBridges","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint32","name":"","type":"uint32"}],"name":"mappedTokens","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"_dstChainId","type":"uint32"},{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"address","name":"_to","type":"address"}],"name":"quote","outputs":[{"internalType":"uint256","name":"fee","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint32","name":"_dstChainId","type":"uint32"}],"name":"send","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_feeBps","type":"uint256"}],"name":"setFeeBps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"_chainId","type":"uint32"},{"internalType":"address","name":"_bridge","type":"address"}],"name":"setMappedBridge","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"_chainId","type":"uint32"},{"internalType":"address","name":"_srcToken","type":"address"},{"internalType":"address","name":"_dstToken","type":"address"}],"name":"setMappedToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawEth","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdrawEth","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"withdrawFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdrawFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

60a060405234801561001057600080fd5b506040516111e93803806111e983398101604081905261002f9161009c565b6100383361004c565b6001600160a01b03166080526001556100d9565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600080604083850312156100af57600080fd5b825160208401519092506001600160a01b03811681146100ce57600080fd5b809150509250929050565b6080516110e7610102600039600081816104ad0152818161099a0152610bb201526110e76000f3fe6080604052600436106100f75760003560e01c8063715018a61161008a578063c311d04911610059578063c311d049146102ab578063f2fde38b146102cb578063f908f339146102eb578063fd9be5221461030b57600080fd5b8063715018a61461024357806372c27b62146102585780638da5cb5b14610278578063a0ef91df1461029657600080fd5b80634ae951fc116100c65780634ae951fc146101bc57806356d5d475146101dc5780635fc984a9146101ef5780636760111c1461020257600080fd5b8063028e7d32146101035780631ac3ddeb1461015657806324a9d853146101785780633f6e82c31461019c57600080fd5b366100fe57005b600080fd5b34801561010f57600080fd5b5061013961011e366004610cf2565b6003602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b34801561016257600080fd5b50610176610171366004610d29565b61032b565b005b34801561018457600080fd5b5061018e60015481565b60405190815260200161014d565b3480156101a857600080fd5b5061018e6101b7366004610d46565b610418565b3480156101c857600080fd5b506101766101d7366004610d97565b61042f565b6101766101ea366004610de0565b6104a2565b6101766101fd366004610e67565b6106a0565b34801561020e57600080fd5b5061013961021d366004610eb8565b60026020908152600092835260408084209091529082529020546001600160a01b031681565b34801561024f57600080fd5b506101766106b2565b34801561026457600080fd5b50610176610273366004610eed565b6106c6565b34801561028457600080fd5b506000546001600160a01b0316610139565b3480156102a257600080fd5b50610176610701565b3480156102b757600080fd5b506101766102c6366004610eed565b61073c565b3480156102d757600080fd5b506101766102e6366004610d29565b610771565b3480156102f757600080fd5b50610176610306366004610f06565b6107ea565b34801561031757600080fd5b50610176610326366004610f3d565b610850565b61033361088b565b6040516370a0823160e01b81523060048201526000906001600160a01b038316906370a0823190602401602060405180830381865afa15801561037a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061039e9190610f69565b60405163a9059cbb60e01b8152336004820152602481018290529091506001600160a01b0383169063a9059cbb906044015b6020604051808303816000875af11580156103ef573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104139190610f82565b505050565b6000610426858585856108e5565b95945050505050565b61043761088b565b6001600160a01b03828116600081815260026020908152604080832063ffffffff8916808552925280832080546001600160a01b0319169587169586179055519092917f15b609c835edb2b4e866ce0b52ade03aa9fa21fab07383b0a0d7f3258c956a6391a4505050565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146105295760405162461bcd60e51b815260206004820152602160248201527f4d61696c626f78436c69656e743a2073656e646572206e6f74206d61696c626f6044820152600f60fb1b60648201526084015b60405180910390fd5b63ffffffff84166000908152600360205260409020546001600160a01b03808516911614610581576040516306cb420b60e01b815263ffffffff851660048201526001600160a01b0384166024820152604401610520565b6000808061059184860186610fa4565b6001600160a01b03808316600090815260026020908152604080832063ffffffff8f168452909152902054939650919450925016806105e357604051634b62f01360e01b815260040160405180910390fd5b6040516340c10f1960e01b81526001600160a01b038581166004830152602482018490528216906340c10f1990604401600060405180830381600087803b15801561062d57600080fd5b505af1158015610641573d6000803e3d6000fd5b5050604080518581526000602082015263ffffffff8c1693506001600160a01b0380891693508516917f94d4076657c103b5c4c62e0537f4775b58368a87c57ee50a98b67424f63ff81d91015b60405180910390a45050505050505050565b6106ac81858585610a22565b50505050565b6106ba61088b565b6106c46000610c89565b565b6106ce61088b565b600181905560405181907f4f78c4ceb393a616bbd264a4584a9ad15d722042ce1e135e6a8380217f5cb42b90600090a250565b61070961088b565b6040514790339082156108fc029083906000818181858888f19350505050158015610738573d6000803e3d6000fd5b5050565b61074461088b565b604051339082156108fc029083906000818181858888f19350505050158015610738573d6000803e3d6000fd5b61077961088b565b6001600160a01b0381166107de5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610520565b6107e781610c89565b50565b6107f261088b565b63ffffffff821660008181526003602052604080822080546001600160a01b0319166001600160a01b03861690811790915590519092917f521b71c922535bd3ec113a5bcaea61a55e459a5a7ed5657ea0ce17f54523ce5a91a35050565b61085861088b565b60405163a9059cbb60e01b8152336004820152602481018290526001600160a01b0383169063a9059cbb906044016103d0565b6000546001600160a01b031633146106c45760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610520565b63ffffffff84166000908152600360205260408120546001600160a01b03168061092a5760405163f89869b160e01b815263ffffffff87166004820152602401610520565b600061271060015461271061093f9190610ffb565b6109499087611014565b610953919061102b565b604080516001600160a01b03878116602083015289811682840152606080830185905283518084039091018152608083019384905263138857a360e31b90935292935090917f0000000000000000000000000000000000000000000000000000000000000000811691639c42bd18916109d5918c91881690869060840161104d565b602060405180830381865afa1580156109f2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a169190610f69565b98975050505050505050565b63ffffffff84166000908152600360205260409020546001600160a01b031680610a675760405163f89869b160e01b815263ffffffff86166004820152602401610520565b6040516323b872dd60e01b8152336004820152306024820152604481018490526001600160a01b038516906323b872dd906064016020604051808303816000875af1158015610aba573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ade9190610f82565b506000612710600154612710610af49190610ffb565b610afe9086611014565b610b08919061102b565b604051632770a7eb60e21b8152306004820152602481018290529091506001600160a01b03861690639dc29fac90604401600060405180830381600087803b158015610b5357600080fd5b505af1158015610b67573d6000803e3d6000fd5b5050604080516001600160a01b03878116602083015289811682840152606080830187905283518084039091018152608083019384905263fa31de0160e01b909352919350600092507f000000000000000000000000000000000000000000000000000000000000000082169163fa31de01913491610bef918d918a1690889060840161104d565b60206040518083038185885af1158015610c0d573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190610c329190610f69565b90508763ffffffff16856001600160a01b0316886001600160a01b03167fa81fe4f47f4d57fa23a0adede4a96172fc2b54d7facdef004614e7ba3b18c356868560405161068e929190918252602082015260400190565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b803563ffffffff81168114610ced57600080fd5b919050565b600060208284031215610d0457600080fd5b610d0d82610cd9565b9392505050565b6001600160a01b03811681146107e757600080fd5b600060208284031215610d3b57600080fd5b8135610d0d81610d14565b60008060008060808587031215610d5c57600080fd5b610d6585610cd9565b93506020850135610d7581610d14565b9250604085013591506060850135610d8c81610d14565b939692955090935050565b600080600060608486031215610dac57600080fd5b610db584610cd9565b92506020840135610dc581610d14565b91506040840135610dd581610d14565b809150509250925092565b60008060008060608587031215610df657600080fd5b610dff85610cd9565b935060208501359250604085013567ffffffffffffffff80821115610e2357600080fd5b818701915087601f830112610e3757600080fd5b813581811115610e4657600080fd5b886020828501011115610e5857600080fd5b95989497505060200194505050565b60008060008060808587031215610e7d57600080fd5b8435610e8881610d14565b9350602085013592506040850135610e9f81610d14565b9150610ead60608601610cd9565b905092959194509250565b60008060408385031215610ecb57600080fd5b8235610ed681610d14565b9150610ee460208401610cd9565b90509250929050565b600060208284031215610eff57600080fd5b5035919050565b60008060408385031215610f1957600080fd5b610f2283610cd9565b91506020830135610f3281610d14565b809150509250929050565b60008060408385031215610f5057600080fd5b8235610f5b81610d14565b946020939093013593505050565b600060208284031215610f7b57600080fd5b5051919050565b600060208284031215610f9457600080fd5b81518015158114610d0d57600080fd5b600080600060608486031215610fb957600080fd5b8335610fc481610d14565b92506020840135610fd481610d14565b929592945050506040919091013590565b634e487b7160e01b600052601160045260246000fd5b8181038181111561100e5761100e610fe5565b92915050565b808202811582820484141761100e5761100e610fe5565b60008261104857634e487b7160e01b600052601260045260246000fd5b500490565b63ffffffff841681526000602084602084015260606040840152835180606085015260005b8181101561108e57858101830151858201608001528201611072565b506000608082860101526080601f19601f8301168501019250505094935050505056fea26469706673582212206ca9b177075e89d0d1265a094b386797a5fec537512fab634e19026afa32015564736f6c63430008160033000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000002f9db5616fa3fad1ab06cb2c906830ba63d135e3

Deployed Bytecode

0x6080604052600436106100f75760003560e01c8063715018a61161008a578063c311d04911610059578063c311d049146102ab578063f2fde38b146102cb578063f908f339146102eb578063fd9be5221461030b57600080fd5b8063715018a61461024357806372c27b62146102585780638da5cb5b14610278578063a0ef91df1461029657600080fd5b80634ae951fc116100c65780634ae951fc146101bc57806356d5d475146101dc5780635fc984a9146101ef5780636760111c1461020257600080fd5b8063028e7d32146101035780631ac3ddeb1461015657806324a9d853146101785780633f6e82c31461019c57600080fd5b366100fe57005b600080fd5b34801561010f57600080fd5b5061013961011e366004610cf2565b6003602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b34801561016257600080fd5b50610176610171366004610d29565b61032b565b005b34801561018457600080fd5b5061018e60015481565b60405190815260200161014d565b3480156101a857600080fd5b5061018e6101b7366004610d46565b610418565b3480156101c857600080fd5b506101766101d7366004610d97565b61042f565b6101766101ea366004610de0565b6104a2565b6101766101fd366004610e67565b6106a0565b34801561020e57600080fd5b5061013961021d366004610eb8565b60026020908152600092835260408084209091529082529020546001600160a01b031681565b34801561024f57600080fd5b506101766106b2565b34801561026457600080fd5b50610176610273366004610eed565b6106c6565b34801561028457600080fd5b506000546001600160a01b0316610139565b3480156102a257600080fd5b50610176610701565b3480156102b757600080fd5b506101766102c6366004610eed565b61073c565b3480156102d757600080fd5b506101766102e6366004610d29565b610771565b3480156102f757600080fd5b50610176610306366004610f06565b6107ea565b34801561031757600080fd5b50610176610326366004610f3d565b610850565b61033361088b565b6040516370a0823160e01b81523060048201526000906001600160a01b038316906370a0823190602401602060405180830381865afa15801561037a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061039e9190610f69565b60405163a9059cbb60e01b8152336004820152602481018290529091506001600160a01b0383169063a9059cbb906044015b6020604051808303816000875af11580156103ef573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104139190610f82565b505050565b6000610426858585856108e5565b95945050505050565b61043761088b565b6001600160a01b03828116600081815260026020908152604080832063ffffffff8916808552925280832080546001600160a01b0319169587169586179055519092917f15b609c835edb2b4e866ce0b52ade03aa9fa21fab07383b0a0d7f3258c956a6391a4505050565b336001600160a01b037f0000000000000000000000002f9db5616fa3fad1ab06cb2c906830ba63d135e316146105295760405162461bcd60e51b815260206004820152602160248201527f4d61696c626f78436c69656e743a2073656e646572206e6f74206d61696c626f6044820152600f60fb1b60648201526084015b60405180910390fd5b63ffffffff84166000908152600360205260409020546001600160a01b03808516911614610581576040516306cb420b60e01b815263ffffffff851660048201526001600160a01b0384166024820152604401610520565b6000808061059184860186610fa4565b6001600160a01b03808316600090815260026020908152604080832063ffffffff8f168452909152902054939650919450925016806105e357604051634b62f01360e01b815260040160405180910390fd5b6040516340c10f1960e01b81526001600160a01b038581166004830152602482018490528216906340c10f1990604401600060405180830381600087803b15801561062d57600080fd5b505af1158015610641573d6000803e3d6000fd5b5050604080518581526000602082015263ffffffff8c1693506001600160a01b0380891693508516917f94d4076657c103b5c4c62e0537f4775b58368a87c57ee50a98b67424f63ff81d91015b60405180910390a45050505050505050565b6106ac81858585610a22565b50505050565b6106ba61088b565b6106c46000610c89565b565b6106ce61088b565b600181905560405181907f4f78c4ceb393a616bbd264a4584a9ad15d722042ce1e135e6a8380217f5cb42b90600090a250565b61070961088b565b6040514790339082156108fc029083906000818181858888f19350505050158015610738573d6000803e3d6000fd5b5050565b61074461088b565b604051339082156108fc029083906000818181858888f19350505050158015610738573d6000803e3d6000fd5b61077961088b565b6001600160a01b0381166107de5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610520565b6107e781610c89565b50565b6107f261088b565b63ffffffff821660008181526003602052604080822080546001600160a01b0319166001600160a01b03861690811790915590519092917f521b71c922535bd3ec113a5bcaea61a55e459a5a7ed5657ea0ce17f54523ce5a91a35050565b61085861088b565b60405163a9059cbb60e01b8152336004820152602481018290526001600160a01b0383169063a9059cbb906044016103d0565b6000546001600160a01b031633146106c45760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610520565b63ffffffff84166000908152600360205260408120546001600160a01b03168061092a5760405163f89869b160e01b815263ffffffff87166004820152602401610520565b600061271060015461271061093f9190610ffb565b6109499087611014565b610953919061102b565b604080516001600160a01b03878116602083015289811682840152606080830185905283518084039091018152608083019384905263138857a360e31b90935292935090917f0000000000000000000000002f9db5616fa3fad1ab06cb2c906830ba63d135e3811691639c42bd18916109d5918c91881690869060840161104d565b602060405180830381865afa1580156109f2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a169190610f69565b98975050505050505050565b63ffffffff84166000908152600360205260409020546001600160a01b031680610a675760405163f89869b160e01b815263ffffffff86166004820152602401610520565b6040516323b872dd60e01b8152336004820152306024820152604481018490526001600160a01b038516906323b872dd906064016020604051808303816000875af1158015610aba573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ade9190610f82565b506000612710600154612710610af49190610ffb565b610afe9086611014565b610b08919061102b565b604051632770a7eb60e21b8152306004820152602481018290529091506001600160a01b03861690639dc29fac90604401600060405180830381600087803b158015610b5357600080fd5b505af1158015610b67573d6000803e3d6000fd5b5050604080516001600160a01b03878116602083015289811682840152606080830187905283518084039091018152608083019384905263fa31de0160e01b909352919350600092507f0000000000000000000000002f9db5616fa3fad1ab06cb2c906830ba63d135e382169163fa31de01913491610bef918d918a1690889060840161104d565b60206040518083038185885af1158015610c0d573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190610c329190610f69565b90508763ffffffff16856001600160a01b0316886001600160a01b03167fa81fe4f47f4d57fa23a0adede4a96172fc2b54d7facdef004614e7ba3b18c356868560405161068e929190918252602082015260400190565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b803563ffffffff81168114610ced57600080fd5b919050565b600060208284031215610d0457600080fd5b610d0d82610cd9565b9392505050565b6001600160a01b03811681146107e757600080fd5b600060208284031215610d3b57600080fd5b8135610d0d81610d14565b60008060008060808587031215610d5c57600080fd5b610d6585610cd9565b93506020850135610d7581610d14565b9250604085013591506060850135610d8c81610d14565b939692955090935050565b600080600060608486031215610dac57600080fd5b610db584610cd9565b92506020840135610dc581610d14565b91506040840135610dd581610d14565b809150509250925092565b60008060008060608587031215610df657600080fd5b610dff85610cd9565b935060208501359250604085013567ffffffffffffffff80821115610e2357600080fd5b818701915087601f830112610e3757600080fd5b813581811115610e4657600080fd5b886020828501011115610e5857600080fd5b95989497505060200194505050565b60008060008060808587031215610e7d57600080fd5b8435610e8881610d14565b9350602085013592506040850135610e9f81610d14565b9150610ead60608601610cd9565b905092959194509250565b60008060408385031215610ecb57600080fd5b8235610ed681610d14565b9150610ee460208401610cd9565b90509250929050565b600060208284031215610eff57600080fd5b5035919050565b60008060408385031215610f1957600080fd5b610f2283610cd9565b91506020830135610f3281610d14565b809150509250929050565b60008060408385031215610f5057600080fd5b8235610f5b81610d14565b946020939093013593505050565b600060208284031215610f7b57600080fd5b5051919050565b600060208284031215610f9457600080fd5b81518015158114610d0d57600080fd5b600080600060608486031215610fb957600080fd5b8335610fc481610d14565b92506020840135610fd481610d14565b929592945050506040919091013590565b634e487b7160e01b600052601160045260246000fd5b8181038181111561100e5761100e610fe5565b92915050565b808202811582820484141761100e5761100e610fe5565b60008261104857634e487b7160e01b600052601260045260246000fd5b500490565b63ffffffff841681526000602084602084015260606040840152835180606085015260005b8181101561108e57858101830151858201608001528201611072565b506000608082860101526080601f19601f8301168501019250505094935050505056fea26469706673582212206ca9b177075e89d0d1265a094b386797a5fec537512fab634e19026afa32015564736f6c63430008160033

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

000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000002f9db5616fa3fad1ab06cb2c906830ba63d135e3

-----Decoded View---------------
Arg [0] : _feeBps (uint256): 10
Arg [1] : _mailbox (address): 0x2f9DB5616fa3fAd1aB06cB2C906830BA63d135e3

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [1] : 0000000000000000000000002f9db5616fa3fad1ab06cb2c906830ba63d135e3


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.