S Price: $0.541364 (-10.20%)
    /

    Contract

    0x20F604FfBaa9Cd518B8e8789021Dda4d52cf391A

    Overview

    S Balance

    Sonic LogoSonic LogoSonic Logo0 S

    S Value

    $0.00

    Multichain Info

    No addresses found
    Transaction Hash
    Method
    Block
    Age
    From
    To
    Amount

    There are no matching entries

    1 Internal Transaction found.

    Latest 1 internal transaction

    Parent Transaction Hash Block Age From To Amount
    46335792025-01-20 3:18:1167 days ago1737343091
     Contract Creation
    0 S
    Loading...
    Loading

    Contract Source Code Verified (Exact Match)

    Contract Name:
    EmptyContract

    Compiler Version
    v0.8.20+commit.a1b79de6

    Optimization Enabled:
    Yes with 20000 runs

    Other Settings:
    shanghai EvmVersion
    File 1 of 48 : FactoryProxy.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.8.20;
    import {
    ITransparentUpgradeableProxy,
    TransparentUpgradeableProxy
    } from "openzeppelin-contracts/contracts/proxy/transparent/TransparentUpgradeableProxy.sol";
    import {AccessControlUpgradeable} from
    "openzeppelin-contracts-upgradeable/contracts/access/AccessControlUpgradeable.sol";
    import {TimelockController} from "openzeppelin-contracts/contracts/governance/TimelockController.sol";
    import {LockedFBTCFactory} from "../../src/LockedFBTCFactory.sol";
    import {LockedFBTC} from "../../src/LockedFBTC.sol";
    import {LockedFBTCBeacon} from "../../src/LockedFBTCBeacon.sol";
    import {BeaconProxy} from "@openzeppelin/contracts/proxy/beacon/BeaconProxy.sol";
    import {console2 as console} from "forge-std/console2.sol";
    contract EmptyContract {}
    interface ICreate2Deployer {
    function deploy(uint256 value, bytes32 salt, bytes memory code) external;
    function computeAddress(bytes32 salt, bytes32 codeHash) external view returns (address);
    }
    struct FactoryDeployments {
    TimelockController factoryProxyAdmin;
    TimelockController beaconAdmin;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 2 of 48 : TransparentUpgradeableProxy.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (proxy/transparent/TransparentUpgradeableProxy.sol)
    pragma solidity ^0.8.0;
    import "../ERC1967/ERC1967Proxy.sol";
    /**
    * @dev Interface for {TransparentUpgradeableProxy}. In order to implement transparency, {TransparentUpgradeableProxy}
    * does not implement this interface directly, and some of its functions are implemented by an internal dispatch
    * mechanism. The compiler is unaware that these functions are implemented by {TransparentUpgradeableProxy} and will not
    * include them in the ABI so this interface must be used to interact with it.
    */
    interface ITransparentUpgradeableProxy is IERC1967 {
    function admin() external view returns (address);
    function implementation() external view returns (address);
    function changeAdmin(address) external;
    function upgradeTo(address) external;
    function upgradeToAndCall(address, bytes memory) external payable;
    }
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 3 of 48 : AccessControlUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (access/AccessControl.sol)
    pragma solidity ^0.8.0;
    import "./IAccessControlUpgradeable.sol";
    import "../utils/ContextUpgradeable.sol";
    import "../utils/StringsUpgradeable.sol";
    import "../utils/introspection/ERC165Upgradeable.sol";
    import {Initializable} from "../proxy/utils/Initializable.sol";
    /**
    * @dev Contract module that allows children to implement role-based access
    * control mechanisms. This is a lightweight version that doesn't allow enumerating role
    * members except through off-chain means by accessing the contract event logs. Some
    * applications may benefit from on-chain enumerability, for those cases see
    * {AccessControlEnumerable}.
    *
    * Roles are referred to by their `bytes32` identifier. These should be exposed
    * in the external API and be unique. The best way to achieve this is by
    * using `public constant` hash digests:
    *
    * ```solidity
    * bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
    * ```
    *
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 4 of 48 : TimelockController.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (governance/TimelockController.sol)
    pragma solidity ^0.8.0;
    import "../access/AccessControl.sol";
    import "../token/ERC721/IERC721Receiver.sol";
    import "../token/ERC1155/IERC1155Receiver.sol";
    /**
    * @dev Contract module which acts as a timelocked controller. When set as the
    * owner of an `Ownable` smart contract, it enforces a timelock on all
    * `onlyOwner` maintenance operations. This gives time for users of the
    * controlled contract to exit before a potentially dangerous maintenance
    * operation is applied.
    *
    * By default, this contract is self administered, meaning administration tasks
    * have to go through the timelock process. The proposer (resp executor) role
    * is in charge of proposing (resp executing) operations. A common use case is
    * to position this {TimelockController} as the owner of a smart contract, with
    * a multisig or a DAO as the sole proposer.
    *
    * _Available since v3.3._
    */
    contract TimelockController is AccessControl, IERC721Receiver, IERC1155Receiver {
    bytes32 public constant TIMELOCK_ADMIN_ROLE = keccak256("TIMELOCK_ADMIN_ROLE");
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 5 of 48 : LockedFBTCFactory.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: LGPL-3.0-only
    pragma solidity 0.8.20;
    import {BeaconProxy} from "@openzeppelin/contracts/proxy/beacon/BeaconProxy.sol";
    import {EnumerableSet} from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol";
    import {Initializable} from "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol";
    import {PausableUpgradeable} from "@openzeppelin/contracts-upgradeable/security/PausableUpgradeable.sol";
    import {AccessControlUpgradeable} from "@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol";
    import {LockedFBTC} from "./LockedFBTC.sol";
    interface ProtocolEvents {
    /// @notice Emitted when a protocol configuration has been updated.
    /// @param setterSelector The selector of the function that updated the configuration.
    /// @param setterSignature The signature of the function that updated the configuration.
    /// @param value The abi-encoded data passed to the function that updated the configuration. Since this event will
    /// only be emitted by setters, this data corresponds to the updated values in the protocol configuration.
    event ProtocolConfigChanged(bytes4 indexed setterSelector, string setterSignature, bytes value);
    /// @notice Event emitted when a LockedFBTC contract is deployed.
    /// @param minter The address of the account responsible for minting the lockedFBTC in the deployed contract.
    /// @param proxyAddress The address of the proxy that was created and deployed for the LockedFBTC contract.
    event LockedFBTCDeployed(address indexed minter, address indexed proxyAddress);
    }
    contract LockedFBTCFactory is Initializable, ProtocolEvents, PausableUpgradeable, AccessControlUpgradeable {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 6 of 48 : LockedFBTC.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: LGPL-3.0-only
    pragma solidity 0.8.20;
    import {ERC20Upgradeable} from "@openzeppelin/contracts-upgradeable/token/ERC20/ERC20Upgradeable.sol";
    import {IERC20Upgradeable} from "@openzeppelin/contracts-upgradeable/token/ERC20/IERC20Upgradeable.sol";
    import {SafeERC20Upgradeable} from "@openzeppelin/contracts-upgradeable/token/ERC20/utils/SafeERC20Upgradeable.sol";
    import {PausableUpgradeable} from "@openzeppelin/contracts-upgradeable/security/PausableUpgradeable.sol";
    import {AccessControlUpgradeable} from "@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol";
    import {Initializable} from "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol";
    import {IFireBridge} from "./Interfaces/IFireBridge.sol";
    import {Request} from "./Common.sol";
    contract LockedFBTC is Initializable, ERC20Upgradeable, PausableUpgradeable, AccessControlUpgradeable {
    // event
    /// @notice Event emitted when lockedFBTC is minted.
    /// @param minter Address of the account performing the minting.
    /// @param receivedAmount Amount of lockedFBTC received.
    /// @param fee Fee deducted from the minting process.
    event MintLockedFbtcRequest(address indexed minter, uint256 receivedAmount, uint256 fee);
    /// @notice Event emitted when initiating a mint FBTC and burn lockedFBTC request.
    /// @param owner Address of the account requesting the redemption.
    /// @param depositTx Transaction hash of the deposit.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 7 of 48 : LockedFBTCBeacon.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.8.0;
    import "@openzeppelin/contracts/proxy/beacon/UpgradeableBeacon.sol";
    import "@openzeppelin/contracts/access/Ownable.sol";
    contract LockedFBTCBeacon is UpgradeableBeacon {
    constructor(address implementation, address owner) UpgradeableBeacon(implementation) {
    transferOwnership(owner);
    }
    /// @notice Allows the owner to upgrade the implementation of the beacon.
    /// @param newImplementation The address of the new implementation contract.
    function upgradeImplementation(address newImplementation) external onlyOwner {
    upgradeTo(newImplementation);
    }
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 8 of 48 : BeaconProxy.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.7.0) (proxy/beacon/BeaconProxy.sol)
    pragma solidity ^0.8.0;
    import "./IBeacon.sol";
    import "../Proxy.sol";
    import "../ERC1967/ERC1967Upgrade.sol";
    /**
    * @dev This contract implements a proxy that gets the implementation address for each call from an {UpgradeableBeacon}.
    *
    * The beacon address is stored in storage slot `uint256(keccak256('eip1967.proxy.beacon')) - 1`, so that it doesn't
    * conflict with the storage layout of the implementation behind the proxy.
    *
    * _Available since v3.4._
    */
    contract BeaconProxy is Proxy, ERC1967Upgrade {
    /**
    * @dev Initializes the proxy with `beacon`.
    *
    * If `data` is nonempty, it's used as data in a delegate call to the implementation returned by the beacon. This
    * will typically be an encoded function call, and allows initializing the storage of the proxy like a Solidity
    * constructor.
    *
    * Requirements:
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 9 of 48 : console2.sol
    1
    2
    3
    4
    // SPDX-License-Identifier: MIT
    pragma solidity >=0.4.22 <0.9.0;
    import {console as console2} from "./console.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 10 of 48 : ERC1967Proxy.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.7.0) (proxy/ERC1967/ERC1967Proxy.sol)
    pragma solidity ^0.8.0;
    import "../Proxy.sol";
    import "./ERC1967Upgrade.sol";
    /**
    * @dev This contract implements an upgradeable proxy. It is upgradeable because calls are delegated to an
    * implementation address that can be changed. This address is stored in storage in the location specified by
    * https://eips.ethereum.org/EIPS/eip-1967[EIP1967], so that it doesn't conflict with the storage layout of the
    * implementation behind the proxy.
    */
    contract ERC1967Proxy is Proxy, ERC1967Upgrade {
    /**
    * @dev Initializes the upgradeable proxy with an initial implementation specified by `_logic`.
    *
    * If `_data` is nonempty, it's used as data in a delegate call to `_logic`. This will typically be an encoded
    * function call, and allows initializing the storage of the proxy like a Solidity constructor.
    */
    constructor(address _logic, bytes memory _data) payable {
    _upgradeToAndCall(_logic, _data, false);
    }
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 11 of 48 : IAccessControlUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol)
    pragma solidity ^0.8.0;
    /**
    * @dev External interface of AccessControl declared to support ERC165 detection.
    */
    interface IAccessControlUpgradeable {
    /**
    * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
    *
    * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
    * {RoleAdminChanged} not being emitted signaling this.
    *
    * _Available since v3.1._
    */
    event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);
    /**
    * @dev Emitted when `account` is granted `role`.
    *
    * `sender` is the account that originated the contract call, an admin role
    * bearer except when using {AccessControl-_setupRole}.
    */
    event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 12 of 48 : ContextUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.4) (utils/Context.sol)
    pragma solidity ^0.8.0;
    import {Initializable} from "../proxy/utils/Initializable.sol";
    /**
    * @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 ContextUpgradeable is Initializable {
    function __Context_init() internal onlyInitializing {
    }
    function __Context_init_unchained() internal onlyInitializing {
    }
    function _msgSender() internal view virtual returns (address) {
    return msg.sender;
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 13 of 48 : StringsUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (utils/Strings.sol)
    pragma solidity ^0.8.0;
    import "./math/MathUpgradeable.sol";
    import "./math/SignedMathUpgradeable.sol";
    /**
    * @dev String operations.
    */
    library StringsUpgradeable {
    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 = MathUpgradeable.log10(value) + 1;
    string memory buffer = new string(length);
    uint256 ptr;
    /// @solidity memory-safe-assembly
    assembly {
    ptr := add(buffer, add(32, length))
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 14 of 48 : ERC165Upgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)
    pragma solidity ^0.8.0;
    import "./IERC165Upgradeable.sol";
    import {Initializable} from "../../proxy/utils/Initializable.sol";
    /**
    * @dev Implementation of the {IERC165} interface.
    *
    * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
    * for the additional interface id that will be supported. For example:
    *
    * ```solidity
    * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
    * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
    * }
    * ```
    *
    * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
    */
    abstract contract ERC165Upgradeable is Initializable, IERC165Upgradeable {
    function __ERC165_init() internal onlyInitializing {
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 15 of 48 : Initializable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (proxy/utils/Initializable.sol)
    pragma solidity ^0.8.2;
    import "../../utils/AddressUpgradeable.sol";
    /**
    * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
    * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an
    * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
    * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
    *
    * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be
    * reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in
    * case an upgrade adds a module that needs to be initialized.
    *
    * For example:
    *
    * [.hljs-theme-light.nopadding]
    * ```solidity
    * contract MyToken is ERC20Upgradeable {
    * function initialize() initializer public {
    * __ERC20_init("MyToken", "MTK");
    * }
    * }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 16 of 48 : AccessControl.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (access/AccessControl.sol)
    pragma solidity ^0.8.0;
    import "./IAccessControl.sol";
    import "../utils/Context.sol";
    import "../utils/Strings.sol";
    import "../utils/introspection/ERC165.sol";
    /**
    * @dev Contract module that allows children to implement role-based access
    * control mechanisms. This is a lightweight version that doesn't allow enumerating role
    * members except through off-chain means by accessing the contract event logs. Some
    * applications may benefit from on-chain enumerability, for those cases see
    * {AccessControlEnumerable}.
    *
    * Roles are referred to by their `bytes32` identifier. These should be exposed
    * in the external API and be unique. The best way to achieve this is by
    * using `public constant` hash digests:
    *
    * ```solidity
    * bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
    * ```
    *
    * Roles can be used to represent a set of permissions. To restrict access to a
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 17 of 48 : IERC721Receiver.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)
    pragma solidity ^0.8.0;
    /**
    * @title ERC721 token receiver interface
    * @dev Interface for any contract that wants to support safeTransfers
    * from ERC721 asset contracts.
    */
    interface IERC721Receiver {
    /**
    * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
    * by `operator` from `from`, this function is called.
    *
    * It must return its Solidity selector to confirm the token transfer.
    * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
    *
    * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
    */
    function onERC721Received(
    address operator,
    address from,
    uint256 tokenId,
    bytes calldata data
    ) external returns (bytes4);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 18 of 48 : IERC1155Receiver.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol)
    pragma solidity ^0.8.0;
    import "../../utils/introspection/IERC165.sol";
    /**
    * @dev _Available since v3.1._
    */
    interface IERC1155Receiver is IERC165 {
    /**
    * @dev Handles the receipt of a single ERC1155 token type. This function is
    * called at the end of a `safeTransferFrom` after the balance has been updated.
    *
    * NOTE: To accept the transfer, this must return
    * `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))`
    * (i.e. 0xf23a6e61, or its own function selector).
    *
    * @param operator The address which initiated the transfer (i.e. msg.sender)
    * @param from The address which previously owned the token
    * @param id The ID of the token being transferred
    * @param value The amount of tokens being transferred
    * @param data Additional data with no specified format
    * @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed
    */
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 19 of 48 : EnumerableSet.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (utils/structs/EnumerableSet.sol)
    // This file was procedurally generated from scripts/generate/templates/EnumerableSet.js.
    pragma solidity ^0.8.0;
    /**
    * @dev Library for managing
    * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
    * types.
    *
    * Sets have the following properties:
    *
    * - Elements are added, removed, and checked for existence in constant time
    * (O(1)).
    * - Elements are enumerated in O(n). No guarantees are made on the ordering.
    *
    * ```solidity
    * contract Example {
    * // Add the library methods
    * using EnumerableSet for EnumerableSet.AddressSet;
    *
    * // Declare a set state variable
    * EnumerableSet.AddressSet private mySet;
    * }
    * ```
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 20 of 48 : PausableUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol)
    pragma solidity ^0.8.0;
    import "../utils/ContextUpgradeable.sol";
    import {Initializable} from "../proxy/utils/Initializable.sol";
    /**
    * @dev Contract module which allows children to implement an emergency stop
    * mechanism that can be triggered by an authorized account.
    *
    * This module is used through inheritance. It will make available the
    * modifiers `whenNotPaused` and `whenPaused`, which can be applied to
    * the functions of your contract. Note that they will not be pausable by
    * simply including this module, only once the modifiers are put in place.
    */
    abstract contract PausableUpgradeable is Initializable, ContextUpgradeable {
    /**
    * @dev Emitted when the pause is triggered by `account`.
    */
    event Paused(address account);
    /**
    * @dev Emitted when the pause is lifted by `account`.
    */
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 21 of 48 : ERC20Upgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/ERC20.sol)
    pragma solidity ^0.8.0;
    import "./IERC20Upgradeable.sol";
    import "./extensions/IERC20MetadataUpgradeable.sol";
    import "../../utils/ContextUpgradeable.sol";
    import {Initializable} from "../../proxy/utils/Initializable.sol";
    /**
    * @dev Implementation of the {IERC20} interface.
    *
    * This implementation is agnostic to the way tokens are created. This means
    * that a supply mechanism has to be added in a derived contract using {_mint}.
    * For a generic mechanism see {ERC20PresetMinterPauser}.
    *
    * TIP: For a detailed writeup see our guide
    * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How
    * to implement supply mechanisms].
    *
    * The default value of {decimals} is 18. To change this, you should override
    * this function so it returns a different value.
    *
    * We have followed general OpenZeppelin Contracts guidelines: functions revert
    * instead returning `false` on failure. This behavior is nonetheless
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 22 of 48 : IERC20Upgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // 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 IERC20Upgradeable {
    /**
    * @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.
    */
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 23 of 48 : SafeERC20Upgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.3) (token/ERC20/utils/SafeERC20.sol)
    pragma solidity ^0.8.0;
    import "../IERC20Upgradeable.sol";
    import "../extensions/IERC20PermitUpgradeable.sol";
    import "../../../utils/AddressUpgradeable.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 SafeERC20Upgradeable {
    using AddressUpgradeable for address;
    /**
    * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value,
    * non-reverting calls are assumed to be successful.
    */
    function safeTransfer(IERC20Upgradeable token, address to, uint256 value) internal {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 24 of 48 : IFireBridge.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    // SPDX-License-Identifier: MIT
    pragma solidity 0.8.20;
    import {Request, UserInfo, RequestLib, Operation} from "../Common.sol";
    interface IFireBridge {
    /// @notice Initiate a FBTC minting request for the qualifiedUser.
    /// @param _amount The amount of FBTC to mint.
    /// @param _depositTxid The BTC deposit txid
    /// @param _outputIndex The transaction output index to user's deposit address.
    /// @return _hash The hash of the new created request.
    /// @return _r The full new created request.
    function addMintRequest(uint256 _amount, bytes32 _depositTxid, uint256 _outputIndex)
    external
    returns (bytes32 _hash, Request memory _r);
    /// @notice Initiate a FBTC burning request for the qualifiedUser.
    /// @param _amount The amount of FBTC to burn.
    /// @return _hash The hash of the new created request.
    /// @return _r The full new created request.
    function addBurnRequest(uint256 _amount) external returns (bytes32 _hash, Request memory _r);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 25 of 48 : Common.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: LGPL-3.0-only
    pragma solidity 0.8.20;
    enum Operation {
    Nop, // starts from 1.
    Mint,
    Burn,
    CrosschainRequest,
    CrosschainConfirm
    }
    enum Status {
    Unused,
    Pending,
    Confirmed,
    Rejected
    }
    struct Request {
    Operation op;
    Status status;
    uint128 nonce; // Those can be packed into one slot in evm storage.
    bytes32 srcChain;
    bytes srcAddress;
    bytes32 dstChain;
    bytes dstAddress;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 26 of 48 : UpgradeableBeacon.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts v4.4.1 (proxy/beacon/UpgradeableBeacon.sol)
    pragma solidity ^0.8.0;
    import "./IBeacon.sol";
    import "../../access/Ownable.sol";
    import "../../utils/Address.sol";
    /**
    * @dev This contract is used in conjunction with one or more instances of {BeaconProxy} to determine their
    * implementation contract, which is where they will delegate all function calls.
    *
    * An owner is able to change the implementation the beacon points to, thus upgrading the proxies that use this beacon.
    */
    contract UpgradeableBeacon is IBeacon, Ownable {
    address private _implementation;
    /**
    * @dev Emitted when the implementation returned by the beacon is changed.
    */
    event Upgraded(address indexed implementation);
    /**
    * @dev Sets the address of the initial implementation, and the deployer account as the owner who can upgrade the
    * beacon.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 27 of 48 : Ownable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.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.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 28 of 48 : IBeacon.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts v4.4.1 (proxy/beacon/IBeacon.sol)
    pragma solidity ^0.8.0;
    /**
    * @dev This is the interface that {BeaconProxy} expects of its beacon.
    */
    interface IBeacon {
    /**
    * @dev Must return an address that can be used as a delegate call target.
    *
    * {BeaconProxy} will check that this address is a contract.
    */
    function implementation() external view returns (address);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 29 of 48 : Proxy.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.6.0) (proxy/Proxy.sol)
    pragma solidity ^0.8.0;
    /**
    * @dev This abstract contract provides a fallback function that delegates all calls to another contract using the EVM
    * instruction `delegatecall`. We refer to the second contract as the _implementation_ behind the proxy, and it has to
    * be specified by overriding the virtual {_implementation} function.
    *
    * Additionally, delegation to the implementation can be triggered manually through the {_fallback} function, or to a
    * different contract through the {_delegate} function.
    *
    * The success and return data of the delegated call will be returned back to the caller of the proxy.
    */
    abstract contract Proxy {
    /**
    * @dev Delegates the current call to `implementation`.
    *
    * This function does not return to its internal call site, it will return directly to the external caller.
    */
    function _delegate(address implementation) internal virtual {
    assembly {
    // Copy msg.data. We take full control of memory in this inline assembly
    // block because it will not return to Solidity code. We overwrite the
    // Solidity scratch pad at memory position 0.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 30 of 48 : ERC1967Upgrade.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (proxy/ERC1967/ERC1967Upgrade.sol)
    pragma solidity ^0.8.2;
    import "../beacon/IBeacon.sol";
    import "../../interfaces/IERC1967.sol";
    import "../../interfaces/draft-IERC1822.sol";
    import "../../utils/Address.sol";
    import "../../utils/StorageSlot.sol";
    /**
    * @dev This abstract contract provides getters and event emitting update functions for
    * https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots.
    *
    * _Available since v4.1._
    */
    abstract contract ERC1967Upgrade is IERC1967 {
    // This is the keccak-256 hash of "eip1967.proxy.rollback" subtracted by 1
    bytes32 private constant _ROLLBACK_SLOT = 0x4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143;
    /**
    * @dev Storage slot with the address of the current implementation.
    * This is the keccak-256 hash of "eip1967.proxy.implementation" subtracted by 1, and is
    * validated in the constructor.
    */
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 31 of 48 : console.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity >=0.4.22 <0.9.0;
    library console {
    address constant CONSOLE_ADDRESS = address(0x000000000000000000636F6e736F6c652e6c6f67);
    function _castLogPayloadViewToPure(
    function(bytes memory) internal view fnIn
    ) internal pure returns (function(bytes memory) internal pure fnOut) {
    assembly {
    fnOut := fnIn
    }
    }
    function _sendLogPayload(bytes memory payload) internal pure {
    _castLogPayloadViewToPure(_sendLogPayloadView)(payload);
    }
    function _sendLogPayloadView(bytes memory payload) private view {
    uint256 payloadLength = payload.length;
    address consoleAddress = CONSOLE_ADDRESS;
    /// @solidity memory-safe-assembly
    assembly {
    let payloadStart := add(payload, 32)
    let r := staticcall(gas(), consoleAddress, payloadStart, payloadLength, 0, 0)
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 32 of 48 : MathUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // 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 MathUpgradeable {
    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) {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 33 of 48 : SignedMathUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // 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 SignedMathUpgradeable {
    /**
    * @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.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 34 of 48 : IERC165Upgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    // 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 IERC165Upgradeable {
    /**
    * @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);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 35 of 48 : AddressUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (utils/Address.sol)
    pragma solidity ^0.8.1;
    /**
    * @dev Collection of functions related to the address type
    */
    library AddressUpgradeable {
    /**
    * @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
    *
    * Furthermore, `isContract` will also return true if the target contract within
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 36 of 48 : IAccessControl.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol)
    pragma solidity ^0.8.0;
    /**
    * @dev External interface of AccessControl declared to support ERC165 detection.
    */
    interface IAccessControl {
    /**
    * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
    *
    * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
    * {RoleAdminChanged} not being emitted signaling this.
    *
    * _Available since v3.1._
    */
    event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);
    /**
    * @dev Emitted when `account` is granted `role`.
    *
    * `sender` is the account that originated the contract call, an admin role
    * bearer except when using {AccessControl-_setupRole}.
    */
    event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 37 of 48 : Context.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.4) (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;
    }
    function _contextSuffixLength() internal view virtual returns (uint256) {
    return 0;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 38 of 48 : Strings.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // 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))
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 39 of 48 : ERC165.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)
    pragma solidity ^0.8.0;
    import "./IERC165.sol";
    /**
    * @dev Implementation of the {IERC165} interface.
    *
    * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
    * for the additional interface id that will be supported. For example:
    *
    * ```solidity
    * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
    * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
    * }
    * ```
    *
    * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
    */
    abstract contract ERC165 is IERC165 {
    /**
    * @dev See {IERC165-supportsInterface}.
    */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 40 of 48 : IERC165.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    // 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);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 41 of 48 : IERC20MetadataUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)
    pragma solidity ^0.8.0;
    import "../IERC20Upgradeable.sol";
    /**
    * @dev Interface for the optional metadata functions from the ERC20 standard.
    *
    * _Available since v4.1._
    */
    interface IERC20MetadataUpgradeable is IERC20Upgradeable {
    /**
    * @dev Returns the name of the token.
    */
    function name() external view returns (string memory);
    /**
    * @dev Returns the symbol of the token.
    */
    function symbol() external view returns (string memory);
    /**
    * @dev Returns the decimals places of the token.
    */
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 42 of 48 : IERC20PermitUpgradeable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.4) (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.
    *
    * ==== Security Considerations
    *
    * There are two important considerations concerning the use of `permit`. The first is that a valid permit signature
    * expresses an allowance, and it should not be assumed to convey additional meaning. In particular, it should not be
    * considered as an intention to spend the allowance in any specific way. The second is that because permits have
    * built-in replay protection and can be submitted by anyone, they can be frontrun. A protocol that uses permits should
    * take this into consideration and allow a `permit` call to fail. Combining these two aspects, a pattern that may be
    * generally recommended is:
    *
    * ```solidity
    * function doThingWithPermit(..., uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) public {
    * try token.permit(msg.sender, address(this), value, deadline, v, r, s) {} catch {}
    * doThing(..., value);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 43 of 48 : Address.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.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
    *
    * Furthermore, `isContract` will also return true if the target contract within
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 44 of 48 : IERC1967.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.9.0) (interfaces/IERC1967.sol)
    pragma solidity ^0.8.0;
    /**
    * @dev ERC-1967: Proxy Storage Slots. This interface contains the events defined in the ERC.
    *
    * _Available since v4.8.3._
    */
    interface IERC1967 {
    /**
    * @dev Emitted when the implementation is upgraded.
    */
    event Upgraded(address indexed implementation);
    /**
    * @dev Emitted when the admin account has changed.
    */
    event AdminChanged(address previousAdmin, address newAdmin);
    /**
    * @dev Emitted when the beacon is changed.
    */
    event BeaconUpgraded(address indexed beacon);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 45 of 48 : draft-IERC1822.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    // SPDX-License-Identifier: MIT
    // OpenZeppelin Contracts (last updated v4.5.0) (interfaces/draft-IERC1822.sol)
    pragma solidity ^0.8.0;
    /**
    * @dev ERC1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified
    * proxy whose upgrades are fully controlled by the current implementation.
    */
    interface IERC1822Proxiable {
    /**
    * @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation
    * address.
    *
    * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks
    * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this
    * function revert if invoked through a proxy.
    */
    function proxiableUUID() external view returns (bytes32);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 46 of 48 : StorageSlot.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // 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;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 47 of 48 : Math.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // 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) {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 48 of 48 : SignedMath.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // 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.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Settings
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    {
    "remappings": [
    "@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/",
    "@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/",
    "ds-test/=lib/forge-std/lib/ds-test/src/",
    "forge-std/=lib/forge-std/src/",
    "openzeppelin-contracts/=lib/openzeppelin-contracts/",
    "erc4626-tests/=lib/openzeppelin-contracts-upgradeable/lib/erc4626-tests/",
    "openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/",
    "openzeppelin/=lib/openzeppelin-contracts-upgradeable/contracts/"
    ],
    "optimizer": {
    "enabled": true,
    "runs": 20000
    },
    "metadata": {
    "useLiteralContent": false,
    "bytecodeHash": "ipfs",
    "appendCBOR": true
    },
    "outputSelection": {
    "*": {
    "*": [
    "evm.bytecode",
    "evm.deployedBytecode",
    "devdoc",
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Contract Security Audit

    Contract ABI

    API
    []

    6080604052348015600e575f80fd5b50603e80601a5f395ff3fe60806040525f80fdfea2646970667358221220a66b2c7acfdc1f207ce53582e9fcefc2a45269826dc99d1fa77be0482f26410d64736f6c63430008140033

    Deployed Bytecode

    0x60806040525f80fdfea2646970667358221220a66b2c7acfdc1f207ce53582e9fcefc2a45269826dc99d1fa77be0482f26410d64736f6c63430008140033

    Block Age Transaction Gas Used Reward
    view all blocks ##produced##

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

    Validator Index Block Age Amount
    View All Withdrawals

    Transaction Hash Block Age Value Eth2 PubKey Valid
    View All Deposits
    [ 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.