ETH Price: $3,852.80 (+5.14%)

Token

ERC-20: StakeStone Bitcoin (SBTC)
 

Overview

Max Total Supply

119.88594087 SBTC

Holders

26

Total Transfers

-

Market

Onchain Market Cap

$0.00

Circulating Supply Market Cap

-

Other Info

Token Contract (WITH 18 Decimals)

Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
StoneBTC

Compiler Version
v0.8.26+commit.8a97fa7a

Optimization Enabled:
Yes with 200 runs

Other Settings:
paris EvmVersion, BSL 1.1 license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2024-10-02
*/

// SPDX-License-Identifier: BUSL-1.1
pragma solidity =0.8.26 ^0.8.20;

// lib/openzeppelin-contracts/contracts/access/IAccessControl.sol

// OpenZeppelin Contracts (last updated v5.0.0) (access/IAccessControl.sol)

/**
 * @dev External interface of AccessControl declared to support ERC165 detection.
 */
interface IAccessControl {
    /**
     * @dev The `account` is missing a role.
     */
    error AccessControlUnauthorizedAccount(address account, bytes32 neededRole);

    /**
     * @dev The caller of a function is not the expected one.
     *
     * NOTE: Don't confuse with {AccessControlUnauthorizedAccount}.
     */
    error AccessControlBadConfirmation();

    /**
     * @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.
     */
    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);

    /**
     * @dev Emitted when `account` is revoked `role`.
     *
     * `sender` is the account that originated the contract call:
     *   - if using `revokeRole`, it is the admin role bearer
     *   - if using `renounceRole`, it is the role bearer (i.e. `account`)
     */
    event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) external view returns (bool);

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {AccessControl-_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) external view returns (bytes32);

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been granted `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `callerConfirmation`.
     */
    function renounceRole(bytes32 role, address callerConfirmation) external;
}

// lib/openzeppelin-contracts/contracts/interfaces/draft-IERC6093.sol

// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/draft-IERC6093.sol)

/**
 * @dev Standard ERC20 Errors
 * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC20 tokens.
 */
interface IERC20Errors {
    /**
     * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     * @param balance Current balance for the interacting account.
     * @param needed Minimum amount required to perform a transfer.
     */
    error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed);

    /**
     * @dev Indicates a failure with the token `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     */
    error ERC20InvalidSender(address sender);

    /**
     * @dev Indicates a failure with the token `receiver`. Used in transfers.
     * @param receiver Address to which tokens are being transferred.
     */
    error ERC20InvalidReceiver(address receiver);

    /**
     * @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers.
     * @param spender Address that may be allowed to operate on tokens without being their owner.
     * @param allowance Amount of tokens a `spender` is allowed to operate with.
     * @param needed Minimum amount required to perform a transfer.
     */
    error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed);

    /**
     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
     * @param approver Address initiating an approval operation.
     */
    error ERC20InvalidApprover(address approver);

    /**
     * @dev Indicates a failure with the `spender` to be approved. Used in approvals.
     * @param spender Address that may be allowed to operate on tokens without being their owner.
     */
    error ERC20InvalidSpender(address spender);
}

/**
 * @dev Standard ERC721 Errors
 * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC721 tokens.
 */
interface IERC721Errors {
    /**
     * @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in EIP-20.
     * Used in balance queries.
     * @param owner Address of the current owner of a token.
     */
    error ERC721InvalidOwner(address owner);

    /**
     * @dev Indicates a `tokenId` whose `owner` is the zero address.
     * @param tokenId Identifier number of a token.
     */
    error ERC721NonexistentToken(uint256 tokenId);

    /**
     * @dev Indicates an error related to the ownership over a particular token. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     * @param tokenId Identifier number of a token.
     * @param owner Address of the current owner of a token.
     */
    error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner);

    /**
     * @dev Indicates a failure with the token `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     */
    error ERC721InvalidSender(address sender);

    /**
     * @dev Indicates a failure with the token `receiver`. Used in transfers.
     * @param receiver Address to which tokens are being transferred.
     */
    error ERC721InvalidReceiver(address receiver);

    /**
     * @dev Indicates a failure with the `operator`’s approval. Used in transfers.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     * @param tokenId Identifier number of a token.
     */
    error ERC721InsufficientApproval(address operator, uint256 tokenId);

    /**
     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
     * @param approver Address initiating an approval operation.
     */
    error ERC721InvalidApprover(address approver);

    /**
     * @dev Indicates a failure with the `operator` to be approved. Used in approvals.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     */
    error ERC721InvalidOperator(address operator);
}

/**
 * @dev Standard ERC1155 Errors
 * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC1155 tokens.
 */
interface IERC1155Errors {
    /**
     * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     * @param balance Current balance for the interacting account.
     * @param needed Minimum amount required to perform a transfer.
     * @param tokenId Identifier number of a token.
     */
    error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId);

    /**
     * @dev Indicates a failure with the token `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     */
    error ERC1155InvalidSender(address sender);

    /**
     * @dev Indicates a failure with the token `receiver`. Used in transfers.
     * @param receiver Address to which tokens are being transferred.
     */
    error ERC1155InvalidReceiver(address receiver);

    /**
     * @dev Indicates a failure with the `operator`’s approval. Used in transfers.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     * @param owner Address of the current owner of a token.
     */
    error ERC1155MissingApprovalForAll(address operator, address owner);

    /**
     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
     * @param approver Address initiating an approval operation.
     */
    error ERC1155InvalidApprover(address approver);

    /**
     * @dev Indicates a failure with the `operator` to be approved. Used in approvals.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     */
    error ERC1155InvalidOperator(address operator);

    /**
     * @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation.
     * Used in batch transfers.
     * @param idsLength Length of the array of token identifiers
     * @param valuesLength Length of the array of token amounts
     */
    error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength);
}

// lib/openzeppelin-contracts/contracts/token/ERC20/IERC20.sol

// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol)

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);

    /**
     * @dev Returns the value of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the value of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves a `value` amount of tokens from the caller's account to `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, uint256 value) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets a `value` amount of tokens as the allowance of `spender` over the
     * caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 value) external returns (bool);

    /**
     * @dev Moves a `value` amount of tokens from `from` to `to` using the
     * allowance mechanism. `value` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(address from, address to, uint256 value) external returns (bool);
}

// lib/openzeppelin-contracts/contracts/utils/Context.sol

// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.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 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;
    }
}

// lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol

// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/IERC165.sol)

/**
 * @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);
}

// src/Errors/Errors.sol

/// @dev Error for unsupported token
error UnsupportedToken();

/// @dev Error for invalid parameter
error InvalidParameter();

/// @dev Error for trying to remove valuable supported token
error NonEmptySupportedToken();

/// @dev Error for deposit function paused
error DepositPaused();

/// @dev Error for withdraw function paused
error WithdrawPaused();

/// @dev Error for Bridge Capacity exceeds
error ExceedCap();

/// @dev Error for fee too high
error TooHighFee();

/// @dev Error for no fee recipient
error NoFeeRecipient();

/// @dev Error for maximum deposit capacity reached
error CapacityReached();

/// @dev Error for user not in whitelist
error NotWhitelisted();

// lib/openzeppelin-contracts/contracts/access/Ownable.sol

// OpenZeppelin Contracts (last updated v5.0.0) (access/Ownable.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.
 *
 * The initial owner is set to the address provided by the deployer. 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;

    /**
     * @dev The caller account is not authorized to perform an operation.
     */
    error OwnableUnauthorizedAccount(address account);

    /**
     * @dev The owner is not a valid owner account. (eg. `address(0)`)
     */
    error OwnableInvalidOwner(address owner);

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

    /**
     * @dev Initializes the contract setting the address provided by the deployer as the initial owner.
     */
    constructor(address initialOwner) {
        if (initialOwner == address(0)) {
            revert OwnableInvalidOwner(address(0));
        }
        _transferOwnership(initialOwner);
    }

    /**
     * @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 {
        if (owner() != _msgSender()) {
            revert OwnableUnauthorizedAccount(_msgSender());
        }
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby disabling 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 {
        if (newOwner == address(0)) {
            revert OwnableInvalidOwner(address(0));
        }
        _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);
    }
}

// lib/openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol

// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/extensions/IERC20Metadata.sol)

/**
 * @dev Interface for the optional metadata functions from the ERC20 standard.
 */
interface IERC20Metadata is IERC20 {
    /**
     * @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.
     */
    function decimals() external view returns (uint8);
}

// lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol

// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/ERC165.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);
 * }
 * ```
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

// lib/openzeppelin-contracts/contracts/access/AccessControl.sol

// OpenZeppelin Contracts (last updated v5.0.0) (access/AccessControl.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
 * function call, use {hasRole}:
 *
 * ```solidity
 * function foo() public {
 *     require(hasRole(MY_ROLE, msg.sender));
 *     ...
 * }
 * ```
 *
 * Roles can be granted and revoked dynamically via the {grantRole} and
 * {revokeRole} functions. Each role has an associated admin role, and only
 * accounts that have a role's admin role can call {grantRole} and {revokeRole}.
 *
 * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
 * that only accounts with this role will be able to grant or revoke other
 * roles. More complex role relationships can be created by using
 * {_setRoleAdmin}.
 *
 * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
 * grant and revoke this role. Extra precautions should be taken to secure
 * accounts that have been granted it. We recommend using {AccessControlDefaultAdminRules}
 * to enforce additional security measures for this role.
 */
abstract contract AccessControl is Context, IAccessControl, ERC165 {
    struct RoleData {
        mapping(address account => bool) hasRole;
        bytes32 adminRole;
    }

    mapping(bytes32 role => RoleData) private _roles;

    bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;

    /**
     * @dev Modifier that checks that an account has a specific role. Reverts
     * with an {AccessControlUnauthorizedAccount} error including the required role.
     */
    modifier onlyRole(bytes32 role) {
        _checkRole(role);
        _;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) public view virtual returns (bool) {
        return _roles[role].hasRole[account];
    }

    /**
     * @dev Reverts with an {AccessControlUnauthorizedAccount} error if `_msgSender()`
     * is missing `role`. Overriding this function changes the behavior of the {onlyRole} modifier.
     */
    function _checkRole(bytes32 role) internal view virtual {
        _checkRole(role, _msgSender());
    }

    /**
     * @dev Reverts with an {AccessControlUnauthorizedAccount} error if `account`
     * is missing `role`.
     */
    function _checkRole(bytes32 role, address account) internal view virtual {
        if (!hasRole(role, account)) {
            revert AccessControlUnauthorizedAccount(account, role);
        }
    }

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) public view virtual returns (bytes32) {
        return _roles[role].adminRole;
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     *
     * May emit a {RoleGranted} event.
     */
    function grantRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) {
        _grantRole(role, account);
    }

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     *
     * May emit a {RoleRevoked} event.
     */
    function revokeRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) {
        _revokeRole(role, account);
    }

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been revoked `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `callerConfirmation`.
     *
     * May emit a {RoleRevoked} event.
     */
    function renounceRole(bytes32 role, address callerConfirmation) public virtual {
        if (callerConfirmation != _msgSender()) {
            revert AccessControlBadConfirmation();
        }

        _revokeRole(role, callerConfirmation);
    }

    /**
     * @dev Sets `adminRole` as ``role``'s admin role.
     *
     * Emits a {RoleAdminChanged} event.
     */
    function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
        bytes32 previousAdminRole = getRoleAdmin(role);
        _roles[role].adminRole = adminRole;
        emit RoleAdminChanged(role, previousAdminRole, adminRole);
    }

    /**
     * @dev Attempts to grant `role` to `account` and returns a boolean indicating if `role` was granted.
     *
     * Internal function without access restriction.
     *
     * May emit a {RoleGranted} event.
     */
    function _grantRole(bytes32 role, address account) internal virtual returns (bool) {
        if (!hasRole(role, account)) {
            _roles[role].hasRole[account] = true;
            emit RoleGranted(role, account, _msgSender());
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Attempts to revoke `role` to `account` and returns a boolean indicating if `role` was revoked.
     *
     * Internal function without access restriction.
     *
     * May emit a {RoleRevoked} event.
     */
    function _revokeRole(bytes32 role, address account) internal virtual returns (bool) {
        if (hasRole(role, account)) {
            _roles[role].hasRole[account] = false;
            emit RoleRevoked(role, account, _msgSender());
            return true;
        } else {
            return false;
        }
    }
}

// lib/openzeppelin-contracts/contracts/token/ERC20/ERC20.sol

// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/ERC20.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}.
 *
 * 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
 * conventional and does not conflict with the expectations of ERC20
 * applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 */
abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors {
    mapping(address account => uint256) private _balances;

    mapping(address account => mapping(address spender => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @dev Sets the values for {name} and {symbol}.
     *
     * All two of these values are immutable: they can only be set once during
     * construction.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view virtual returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5.05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the default value returned by this function, unless
     * it's overridden.
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual returns (uint8) {
        return 18;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view virtual returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - the caller must have a balance of at least `value`.
     */
    function transfer(address to, uint256 value) public virtual returns (bool) {
        address owner = _msgSender();
        _transfer(owner, to, value);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * NOTE: If `value` is the maximum `uint256`, the allowance is not updated on
     * `transferFrom`. This is semantically equivalent to an infinite approval.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 value) public virtual returns (bool) {
        address owner = _msgSender();
        _approve(owner, spender, value);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20}.
     *
     * NOTE: Does not update the allowance if the current allowance
     * is the maximum `uint256`.
     *
     * Requirements:
     *
     * - `from` and `to` cannot be the zero address.
     * - `from` must have a balance of at least `value`.
     * - the caller must have allowance for ``from``'s tokens of at least
     * `value`.
     */
    function transferFrom(address from, address to, uint256 value) public virtual returns (bool) {
        address spender = _msgSender();
        _spendAllowance(from, spender, value);
        _transfer(from, to, value);
        return true;
    }

    /**
     * @dev Moves a `value` amount of tokens from `from` to `to`.
     *
     * This internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * NOTE: This function is not virtual, {_update} should be overridden instead.
     */
    function _transfer(address from, address to, uint256 value) internal {
        if (from == address(0)) {
            revert ERC20InvalidSender(address(0));
        }
        if (to == address(0)) {
            revert ERC20InvalidReceiver(address(0));
        }
        _update(from, to, value);
    }

    /**
     * @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from`
     * (or `to`) is the zero address. All customizations to transfers, mints, and burns should be done by overriding
     * this function.
     *
     * Emits a {Transfer} event.
     */
    function _update(address from, address to, uint256 value) internal virtual {
        if (from == address(0)) {
            // Overflow check required: The rest of the code assumes that totalSupply never overflows
            _totalSupply += value;
        } else {
            uint256 fromBalance = _balances[from];
            if (fromBalance < value) {
                revert ERC20InsufficientBalance(from, fromBalance, value);
            }
            unchecked {
                // Overflow not possible: value <= fromBalance <= totalSupply.
                _balances[from] = fromBalance - value;
            }
        }

        if (to == address(0)) {
            unchecked {
                // Overflow not possible: value <= totalSupply or value <= fromBalance <= totalSupply.
                _totalSupply -= value;
            }
        } else {
            unchecked {
                // Overflow not possible: balance + value is at most totalSupply, which we know fits into a uint256.
                _balances[to] += value;
            }
        }

        emit Transfer(from, to, value);
    }

    /**
     * @dev Creates a `value` amount of tokens and assigns them to `account`, by transferring it from address(0).
     * Relies on the `_update` mechanism
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * NOTE: This function is not virtual, {_update} should be overridden instead.
     */
    function _mint(address account, uint256 value) internal {
        if (account == address(0)) {
            revert ERC20InvalidReceiver(address(0));
        }
        _update(address(0), account, value);
    }

    /**
     * @dev Destroys a `value` amount of tokens from `account`, lowering the total supply.
     * Relies on the `_update` mechanism.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * NOTE: This function is not virtual, {_update} should be overridden instead
     */
    function _burn(address account, uint256 value) internal {
        if (account == address(0)) {
            revert ERC20InvalidSender(address(0));
        }
        _update(account, address(0), value);
    }

    /**
     * @dev Sets `value` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     *
     * Overrides to this logic should be done to the variant with an additional `bool emitEvent` argument.
     */
    function _approve(address owner, address spender, uint256 value) internal {
        _approve(owner, spender, value, true);
    }

    /**
     * @dev Variant of {_approve} with an optional flag to enable or disable the {Approval} event.
     *
     * By default (when calling {_approve}) the flag is set to true. On the other hand, approval changes made by
     * `_spendAllowance` during the `transferFrom` operation set the flag to false. This saves gas by not emitting any
     * `Approval` event during `transferFrom` operations.
     *
     * Anyone who wishes to continue emitting `Approval` events on the`transferFrom` operation can force the flag to
     * true using the following override:
     * ```
     * function _approve(address owner, address spender, uint256 value, bool) internal virtual override {
     *     super._approve(owner, spender, value, true);
     * }
     * ```
     *
     * Requirements are the same as {_approve}.
     */
    function _approve(address owner, address spender, uint256 value, bool emitEvent) internal virtual {
        if (owner == address(0)) {
            revert ERC20InvalidApprover(address(0));
        }
        if (spender == address(0)) {
            revert ERC20InvalidSpender(address(0));
        }
        _allowances[owner][spender] = value;
        if (emitEvent) {
            emit Approval(owner, spender, value);
        }
    }

    /**
     * @dev Updates `owner` s allowance for `spender` based on spent `value`.
     *
     * Does not update the allowance value in case of infinite allowance.
     * Revert if not enough allowance is available.
     *
     * Does not emit an {Approval} event.
     */
    function _spendAllowance(address owner, address spender, uint256 value) internal virtual {
        uint256 currentAllowance = allowance(owner, spender);
        if (currentAllowance != type(uint256).max) {
            if (currentAllowance < value) {
                revert ERC20InsufficientAllowance(spender, currentAllowance, value);
            }
            unchecked {
                _approve(owner, spender, currentAllowance - value, false);
            }
        }
    }
}

// src/Token/StoneBTC.sol

contract StoneBTC is ERC20, AccessControl {
    bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE");
    bytes32 public constant BURNER_ROLE = keccak256("BURNER_ROLE");
    constructor(
        string memory _name,
        string memory _symbol
    ) ERC20(_name, _symbol) {
        _grantRole(DEFAULT_ADMIN_ROLE, msg.sender);
    }

    function mint(address _to, uint256 _amount) external onlyRole(MINTER_ROLE) {
        _mint(_to, _amount);
    }

    function burn(
        address _from,
        uint256 _amount
    ) external onlyRole(BURNER_ROLE) {
        _burn(_from, _amount);
    }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_symbol","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AccessControlBadConfirmation","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"neededRole","type":"bytes32"}],"name":"AccessControlUnauthorizedAccount","type":"error"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"allowance","type":"uint256"},{"internalType":"uint256","name":"needed","type":"uint256"}],"name":"ERC20InsufficientAllowance","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"balance","type":"uint256"},{"internalType":"uint256","name":"needed","type":"uint256"}],"name":"ERC20InsufficientBalance","type":"error"},{"inputs":[{"internalType":"address","name":"approver","type":"address"}],"name":"ERC20InvalidApprover","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC20InvalidReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"}],"name":"ERC20InvalidSender","type":"error"},{"inputs":[{"internalType":"address","name":"spender","type":"address"}],"name":"ERC20InvalidSpender","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"BURNER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_from","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"callerConfirmation","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50604051610fa2380380610fa283398101604081905261002f916101cb565b8181600361003d83826102bd565b50600461004a82826102bd565b5061005a91506000905033610062565b50505061037b565b60008281526005602090815260408083206001600160a01b038516845290915281205460ff166101085760008381526005602090815260408083206001600160a01b03861684529091529020805460ff191660011790556100c03390565b6001600160a01b0316826001600160a01b0316847f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a450600161010c565b5060005b92915050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261013957600080fd5b81516001600160401b0381111561015257610152610112565b604051601f8201601f19908116603f011681016001600160401b038111828210171561018057610180610112565b60405281815283820160200185101561019857600080fd5b60005b828110156101b75760208186018101518383018201520161019b565b506000918101602001919091529392505050565b600080604083850312156101de57600080fd5b82516001600160401b038111156101f457600080fd5b61020085828601610128565b602085015190935090506001600160401b0381111561021e57600080fd5b61022a85828601610128565b9150509250929050565b600181811c9082168061024857607f821691505b60208210810361026857634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156102b857806000526020600020601f840160051c810160208510156102955750805b601f840160051c820191505b818110156102b557600081556001016102a1565b50505b505050565b81516001600160401b038111156102d6576102d6610112565b6102ea816102e48454610234565b8461026e565b6020601f82116001811461031e57600083156103065750848201515b600019600385901b1c1916600184901b1784556102b5565b600084815260208120601f198516915b8281101561034e578785015182556020948501946001909201910161032e565b508482101561036c5786840151600019600387901b60f8161c191681555b50505050600190811b01905550565b610c188061038a6000396000f3fe608060405234801561001057600080fd5b506004361061012c5760003560e01c806340c10f19116100ad578063a217fddf11610071578063a217fddf14610291578063a9059cbb14610299578063d5391393146102ac578063d547741f146102d3578063dd62ed3e146102e657600080fd5b806340c10f191461022757806370a082311461023a57806391d148541461026357806395d89b41146102765780639dc29fac1461027e57600080fd5b8063248a9ca3116100f4578063248a9ca3146101a6578063282c51f3146101c95780632f2ff15d146101f0578063313ce5671461020557806336568abe1461021457600080fd5b806301ffc9a71461013157806306fdde0314610159578063095ea7b31461016e57806318160ddd1461018157806323b872dd14610193575b600080fd5b61014461013f3660046109fb565b61031f565b60405190151581526020015b60405180910390f35b610161610356565b6040516101509190610a2c565b61014461017c366004610a96565b6103e8565b6002545b604051908152602001610150565b6101446101a1366004610ac0565b610400565b6101856101b4366004610afd565b60009081526005602052604090206001015490565b6101857f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84881565b6102036101fe366004610b16565b610424565b005b60405160128152602001610150565b610203610222366004610b16565b61044f565b610203610235366004610a96565b610487565b610185610248366004610b42565b6001600160a01b031660009081526020819052604090205490565b610144610271366004610b16565b6104bb565b6101616104e6565b61020361028c366004610a96565b6104f5565b610185600081565b6101446102a7366004610a96565b610529565b6101857f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6102036102e1366004610b16565b610537565b6101856102f4366004610b5d565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b60006001600160e01b03198216637965db0b60e01b148061035057506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606003805461036590610b87565b80601f016020809104026020016040519081016040528092919081815260200182805461039190610b87565b80156103de5780601f106103b3576101008083540402835291602001916103de565b820191906000526020600020905b8154815290600101906020018083116103c157829003601f168201915b5050505050905090565b6000336103f681858561055c565b5060019392505050565b60003361040e858285610569565b6104198585856105e6565b506001949350505050565b60008281526005602052604090206001015461043f81610645565b6104498383610652565b50505050565b6001600160a01b03811633146104785760405163334bd91960e11b815260040160405180910390fd5b61048282826106e6565b505050565b7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a66104b181610645565b6104828383610753565b60009182526005602090815260408084206001600160a01b0393909316845291905290205460ff1690565b60606004805461036590610b87565b7f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84861051f81610645565b610482838361078d565b6000336103f68185856105e6565b60008281526005602052604090206001015461055281610645565b61044983836106e6565b61048283838360016107c3565b6001600160a01b03838116600090815260016020908152604080832093861683529290522054600019811461044957818110156105d757604051637dc7a0d960e11b81526001600160a01b038416600482015260248101829052604481018390526064015b60405180910390fd5b610449848484840360006107c3565b6001600160a01b03831661061057604051634b637e8f60e11b8152600060048201526024016105ce565b6001600160a01b03821661063a5760405163ec442f0560e01b8152600060048201526024016105ce565b610482838383610898565b61064f81336109c2565b50565b600061065e83836104bb565b6106de5760008381526005602090815260408083206001600160a01b03861684529091529020805460ff191660011790556106963390565b6001600160a01b0316826001600160a01b0316847f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a4506001610350565b506000610350565b60006106f283836104bb565b156106de5760008381526005602090815260408083206001600160a01b0386168085529252808320805460ff1916905551339286917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a4506001610350565b6001600160a01b03821661077d5760405163ec442f0560e01b8152600060048201526024016105ce565b61078960008383610898565b5050565b6001600160a01b0382166107b757604051634b637e8f60e11b8152600060048201526024016105ce565b61078982600083610898565b6001600160a01b0384166107ed5760405163e602df0560e01b8152600060048201526024016105ce565b6001600160a01b03831661081757604051634a1406b160e11b8152600060048201526024016105ce565b6001600160a01b038085166000908152600160209081526040808320938716835292905220829055801561044957826001600160a01b0316846001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161088a91815260200190565b60405180910390a350505050565b6001600160a01b0383166108c35780600260008282546108b89190610bc1565b909155506109359050565b6001600160a01b038316600090815260208190526040902054818110156109165760405163391434e360e21b81526001600160a01b038516600482015260248101829052604481018390526064016105ce565b6001600160a01b03841660009081526020819052604090209082900390555b6001600160a01b03821661095157600280548290039055610970565b6001600160a01b03821660009081526020819052604090208054820190555b816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516109b591815260200190565b60405180910390a3505050565b6109cc82826104bb565b6107895760405163e2517d3f60e01b81526001600160a01b0382166004820152602481018390526044016105ce565b600060208284031215610a0d57600080fd5b81356001600160e01b031981168114610a2557600080fd5b9392505050565b602081526000825180602084015260005b81811015610a5a5760208186018101516040868401015201610a3d565b506000604082850101526040601f19601f83011684010191505092915050565b80356001600160a01b0381168114610a9157600080fd5b919050565b60008060408385031215610aa957600080fd5b610ab283610a7a565b946020939093013593505050565b600080600060608486031215610ad557600080fd5b610ade84610a7a565b9250610aec60208501610a7a565b929592945050506040919091013590565b600060208284031215610b0f57600080fd5b5035919050565b60008060408385031215610b2957600080fd5b82359150610b3960208401610a7a565b90509250929050565b600060208284031215610b5457600080fd5b610a2582610a7a565b60008060408385031215610b7057600080fd5b610b7983610a7a565b9150610b3960208401610a7a565b600181811c90821680610b9b57607f821691505b602082108103610bbb57634e487b7160e01b600052602260045260246000fd5b50919050565b8082018082111561035057634e487b7160e01b600052601160045260246000fdfea26469706673582212208e55d0166c44d0d91314a6fd4944c61baca138da8224f3a672c217e38d9d55ba64736f6c634300081a00330000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000125374616b6553746f6e6520426974636f696e000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000045342544300000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061012c5760003560e01c806340c10f19116100ad578063a217fddf11610071578063a217fddf14610291578063a9059cbb14610299578063d5391393146102ac578063d547741f146102d3578063dd62ed3e146102e657600080fd5b806340c10f191461022757806370a082311461023a57806391d148541461026357806395d89b41146102765780639dc29fac1461027e57600080fd5b8063248a9ca3116100f4578063248a9ca3146101a6578063282c51f3146101c95780632f2ff15d146101f0578063313ce5671461020557806336568abe1461021457600080fd5b806301ffc9a71461013157806306fdde0314610159578063095ea7b31461016e57806318160ddd1461018157806323b872dd14610193575b600080fd5b61014461013f3660046109fb565b61031f565b60405190151581526020015b60405180910390f35b610161610356565b6040516101509190610a2c565b61014461017c366004610a96565b6103e8565b6002545b604051908152602001610150565b6101446101a1366004610ac0565b610400565b6101856101b4366004610afd565b60009081526005602052604090206001015490565b6101857f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84881565b6102036101fe366004610b16565b610424565b005b60405160128152602001610150565b610203610222366004610b16565b61044f565b610203610235366004610a96565b610487565b610185610248366004610b42565b6001600160a01b031660009081526020819052604090205490565b610144610271366004610b16565b6104bb565b6101616104e6565b61020361028c366004610a96565b6104f5565b610185600081565b6101446102a7366004610a96565b610529565b6101857f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6102036102e1366004610b16565b610537565b6101856102f4366004610b5d565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b60006001600160e01b03198216637965db0b60e01b148061035057506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606003805461036590610b87565b80601f016020809104026020016040519081016040528092919081815260200182805461039190610b87565b80156103de5780601f106103b3576101008083540402835291602001916103de565b820191906000526020600020905b8154815290600101906020018083116103c157829003601f168201915b5050505050905090565b6000336103f681858561055c565b5060019392505050565b60003361040e858285610569565b6104198585856105e6565b506001949350505050565b60008281526005602052604090206001015461043f81610645565b6104498383610652565b50505050565b6001600160a01b03811633146104785760405163334bd91960e11b815260040160405180910390fd5b61048282826106e6565b505050565b7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a66104b181610645565b6104828383610753565b60009182526005602090815260408084206001600160a01b0393909316845291905290205460ff1690565b60606004805461036590610b87565b7f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84861051f81610645565b610482838361078d565b6000336103f68185856105e6565b60008281526005602052604090206001015461055281610645565b61044983836106e6565b61048283838360016107c3565b6001600160a01b03838116600090815260016020908152604080832093861683529290522054600019811461044957818110156105d757604051637dc7a0d960e11b81526001600160a01b038416600482015260248101829052604481018390526064015b60405180910390fd5b610449848484840360006107c3565b6001600160a01b03831661061057604051634b637e8f60e11b8152600060048201526024016105ce565b6001600160a01b03821661063a5760405163ec442f0560e01b8152600060048201526024016105ce565b610482838383610898565b61064f81336109c2565b50565b600061065e83836104bb565b6106de5760008381526005602090815260408083206001600160a01b03861684529091529020805460ff191660011790556106963390565b6001600160a01b0316826001600160a01b0316847f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a4506001610350565b506000610350565b60006106f283836104bb565b156106de5760008381526005602090815260408083206001600160a01b0386168085529252808320805460ff1916905551339286917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a4506001610350565b6001600160a01b03821661077d5760405163ec442f0560e01b8152600060048201526024016105ce565b61078960008383610898565b5050565b6001600160a01b0382166107b757604051634b637e8f60e11b8152600060048201526024016105ce565b61078982600083610898565b6001600160a01b0384166107ed5760405163e602df0560e01b8152600060048201526024016105ce565b6001600160a01b03831661081757604051634a1406b160e11b8152600060048201526024016105ce565b6001600160a01b038085166000908152600160209081526040808320938716835292905220829055801561044957826001600160a01b0316846001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161088a91815260200190565b60405180910390a350505050565b6001600160a01b0383166108c35780600260008282546108b89190610bc1565b909155506109359050565b6001600160a01b038316600090815260208190526040902054818110156109165760405163391434e360e21b81526001600160a01b038516600482015260248101829052604481018390526064016105ce565b6001600160a01b03841660009081526020819052604090209082900390555b6001600160a01b03821661095157600280548290039055610970565b6001600160a01b03821660009081526020819052604090208054820190555b816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516109b591815260200190565b60405180910390a3505050565b6109cc82826104bb565b6107895760405163e2517d3f60e01b81526001600160a01b0382166004820152602481018390526044016105ce565b600060208284031215610a0d57600080fd5b81356001600160e01b031981168114610a2557600080fd5b9392505050565b602081526000825180602084015260005b81811015610a5a5760208186018101516040868401015201610a3d565b506000604082850101526040601f19601f83011684010191505092915050565b80356001600160a01b0381168114610a9157600080fd5b919050565b60008060408385031215610aa957600080fd5b610ab283610a7a565b946020939093013593505050565b600080600060608486031215610ad557600080fd5b610ade84610a7a565b9250610aec60208501610a7a565b929592945050506040919091013590565b600060208284031215610b0f57600080fd5b5035919050565b60008060408385031215610b2957600080fd5b82359150610b3960208401610a7a565b90509250929050565b600060208284031215610b5457600080fd5b610a2582610a7a565b60008060408385031215610b7057600080fd5b610b7983610a7a565b9150610b3960208401610a7a565b600181811c90821680610b9b57607f821691505b602082108103610bbb57634e487b7160e01b600052602260045260246000fd5b50919050565b8082018082111561035057634e487b7160e01b600052601160045260246000fdfea26469706673582212208e55d0166c44d0d91314a6fd4944c61baca138da8224f3a672c217e38d9d55ba64736f6c634300081a0033

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

0000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000125374616b6553746f6e6520426974636f696e000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000045342544300000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _name (string): StakeStone Bitcoin
Arg [1] : _symbol (string): SBTC

-----Encoded View---------------
6 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000040
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000080
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000012
Arg [3] : 5374616b6553746f6e6520426974636f696e0000000000000000000000000000
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000004
Arg [5] : 5342544300000000000000000000000000000000000000000000000000000000


Deployed Bytecode Sourcemap

38794:625:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;22896:204;;;;;;:::i;:::-;;:::i;:::-;;;470:14:1;;463:22;445:41;;433:2;418:18;22896:204:0;;;;;;;;29435:91;;;:::i;:::-;;;;;;;:::i;31728:190::-;;;;;;:::i;:::-;;:::i;30537:99::-;30616:12;;30537:99;;;1658:25:1;;;1646:2;1631:18;30537:99:0;1512:177:1;32496:249:0;;;;;;:::i;:::-;;:::i;24176:122::-;;;;;;:::i;:::-;24241:7;24268:12;;;:6;:12;;;;;:22;;;;24176:122;38912:62;;38950:24;38912:62;;24608:138;;;;;;:::i;:::-;;:::i;:::-;;30388:84;;;30462:2;2933:36:1;;2921:2;2906:18;30388:84:0;2791:184:1;25745:251:0;;;;;;:::i;:::-;;:::i;39153:113::-;;;;;;:::i;:::-;;:::i;30699:118::-;;;;;;:::i;:::-;-1:-1:-1;;;;;30791:18:0;30764:7;30791:18;;;;;;;;;;;;30699:118;23192:138;;;;;;:::i;:::-;;:::i;29645:95::-;;;:::i;39274:142::-;;;;;;:::i;:::-;;:::i;22504:49::-;;22549:4;22504:49;;31022:182;;;;;;:::i;:::-;;:::i;38843:62::-;;38881:24;38843:62;;25039:140;;;;;;:::i;:::-;;:::i;31267:142::-;;;;;;:::i;:::-;-1:-1:-1;;;;;31374:18:0;;;31347:7;31374:18;;;:11;:18;;;;;;;;:27;;;;;;;;;;;;;31267:142;22896:204;22981:4;-1:-1:-1;;;;;;23005:47:0;;-1:-1:-1;;;23005:47:0;;:87;;-1:-1:-1;;;;;;;;;;20361:40:0;;;23056:36;22998:94;22896:204;-1:-1:-1;;22896:204:0:o;29435:91::-;29480:13;29513:5;29506:12;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;29435:91;:::o;31728:190::-;31801:4;13767:10;31857:31;13767:10;31873:7;31882:5;31857:8;:31::i;:::-;-1:-1:-1;31906:4:0;;31728:190;-1:-1:-1;;;31728:190:0:o;32496:249::-;32583:4;13767:10;32641:37;32657:4;13767:10;32672:5;32641:15;:37::i;:::-;32689:26;32699:4;32705:2;32709:5;32689:9;:26::i;:::-;-1:-1:-1;32733:4:0;;32496:249;-1:-1:-1;;;;32496:249:0:o;24608:138::-;24241:7;24268:12;;;:6;:12;;;;;:22;;;22788:16;22799:4;22788:10;:16::i;:::-;24713:25:::1;24724:4;24730:7;24713:10;:25::i;:::-;;24608:138:::0;;;:::o;25745:251::-;-1:-1:-1;;;;;25839:34:0;;13767:10;25839:34;25835:104;;25897:30;;-1:-1:-1;;;25897:30:0;;;;;;;;;;;25835:104;25951:37;25963:4;25969:18;25951:11;:37::i;:::-;;25745:251;;:::o;39153:113::-;38881:24;22788:16;22799:4;22788:10;:16::i;:::-;39239:19:::1;39245:3;39250:7;39239:5;:19::i;23192:138::-:0;23269:4;23293:12;;;:6;:12;;;;;;;;-1:-1:-1;;;;;23293:29:0;;;;;;;;;;;;;;;23192:138::o;29645:95::-;29692:13;29725:7;29718:14;;;;;:::i;39274:142::-;38950:24;22788:16;22799:4;22788:10;:16::i;:::-;39387:21:::1;39393:5;39400:7;39387:5;:21::i;31022:182::-:0;31091:4;13767:10;31147:27;13767:10;31164:2;31168:5;31147:9;:27::i;25039:140::-;24241:7;24268:12;;;:6;:12;;;;;:22;;;22788:16;22799:4;22788:10;:16::i;:::-;25145:26:::1;25157:4;25163:7;25145:11;:26::i;36555:130::-:0;36640:37;36649:5;36656:7;36665:5;36672:4;36640:8;:37::i;38271:487::-;-1:-1:-1;;;;;31374:18:0;;;38371:24;31374:18;;;:11;:18;;;;;;;;:27;;;;;;;;;;-1:-1:-1;;38438:37:0;;38434:317;;38515:5;38496:16;:24;38492:132;;;38548:60;;-1:-1:-1;;;38548:60:0;;-1:-1:-1;;;;;4041:32:1;;38548:60:0;;;4023:51:1;4090:18;;;4083:34;;;4133:18;;;4126:34;;;3996:18;;38548:60:0;;;;;;;;38492:132;38667:57;38676:5;38683:7;38711:5;38692:16;:24;38718:5;38667:8;:57::i;33130:308::-;-1:-1:-1;;;;;33214:18:0;;33210:88;;33256:30;;-1:-1:-1;;;33256:30:0;;33283:1;33256:30;;;4317:51:1;4290:18;;33256:30:0;4171:203:1;33210:88:0;-1:-1:-1;;;;;33312:16:0;;33308:88;;33352:32;;-1:-1:-1;;;33352:32:0;;33381:1;33352:32;;;4317:51:1;4290:18;;33352:32:0;4171:203:1;33308:88:0;33406:24;33414:4;33420:2;33424:5;33406:7;:24::i;23545:105::-;23612:30;23623:4;13767:10;23612;:30::i;:::-;23545:105;:::o;26622:324::-;26699:4;26721:22;26729:4;26735:7;26721;:22::i;:::-;26716:223;;26760:12;;;;:6;:12;;;;;;;;-1:-1:-1;;;;;26760:29:0;;;;;;;;;:36;;-1:-1:-1;;26760:36:0;26792:4;26760:36;;;26843:12;13767:10;;13687:98;26843:12;-1:-1:-1;;;;;26816:40:0;26834:7;-1:-1:-1;;;;;26816:40:0;26828:4;26816:40;;;;;;;;;;-1:-1:-1;26878:4:0;26871:11;;26716:223;-1:-1:-1;26922:5:0;26915:12;;27190:325;27268:4;27289:22;27297:4;27303:7;27289;:22::i;:::-;27285:223;;;27360:5;27328:12;;;:6;:12;;;;;;;;-1:-1:-1;;;;;27328:29:0;;;;;;;;;;:37;;-1:-1:-1;;27328:37:0;;;27385:40;13767:10;;27328:12;;27385:40;;27360:5;27385:40;-1:-1:-1;27447:4:0;27440:11;;35250:213;-1:-1:-1;;;;;35321:21:0;;35317:93;;35366:32;;-1:-1:-1;;;35366:32:0;;35395:1;35366:32;;;4317:51:1;4290:18;;35366:32:0;4171:203:1;35317:93:0;35420:35;35436:1;35440:7;35449:5;35420:7;:35::i;:::-;35250:213;;:::o;35791:211::-;-1:-1:-1;;;;;35862:21:0;;35858:91;;35907:30;;-1:-1:-1;;;35907:30:0;;35934:1;35907:30;;;4317:51:1;4290:18;;35907:30:0;4171:203:1;35858:91:0;35959:35;35967:7;35984:1;35988:5;35959:7;:35::i;37536:443::-;-1:-1:-1;;;;;37649:19:0;;37645:91;;37692:32;;-1:-1:-1;;;37692:32:0;;37721:1;37692:32;;;4317:51:1;4290:18;;37692:32:0;4171:203:1;37645:91:0;-1:-1:-1;;;;;37750:21:0;;37746:92;;37795:31;;-1:-1:-1;;;37795:31:0;;37823:1;37795:31;;;4317:51:1;4290:18;;37795:31:0;4171:203:1;37746:92:0;-1:-1:-1;;;;;37848:18:0;;;;;;;:11;:18;;;;;;;;:27;;;;;;;;;:35;;;37894:78;;;;37945:7;-1:-1:-1;;;;;37929:31:0;37938:5;-1:-1:-1;;;;;37929:31:0;;37954:5;37929:31;;;;1658:25:1;;1646:2;1631:18;;1512:177;37929:31:0;;;;;;;;37536:443;;;;:::o;33762:1135::-;-1:-1:-1;;;;;33852:18:0;;33848:552;;34006:5;33990:12;;:21;;;;;;;:::i;:::-;;;;-1:-1:-1;33848:552:0;;-1:-1:-1;33848:552:0;;-1:-1:-1;;;;;34066:15:0;;34044:19;34066:15;;;;;;;;;;;34100:19;;;34096:117;;;34147:50;;-1:-1:-1;;;34147:50:0;;-1:-1:-1;;;;;4041:32:1;;34147:50:0;;;4023:51:1;4090:18;;;4083:34;;;4133:18;;;4126:34;;;3996:18;;34147:50:0;3821:345:1;34096:117:0;-1:-1:-1;;;;;34336:15:0;;:9;:15;;;;;;;;;;34354:19;;;;34336:37;;33848:552;-1:-1:-1;;;;;34416:16:0;;34412:435;;34582:12;:21;;;;;;;34412:435;;;-1:-1:-1;;;;;34798:13:0;;:9;:13;;;;;;;;;;:22;;;;;;34412:435;34879:2;-1:-1:-1;;;;;34864:25:0;34873:4;-1:-1:-1;;;;;34864:25:0;;34883:5;34864:25;;;;1658::1;;1646:2;1631:18;;1512:177;34864:25:0;;;;;;;;33762:1135;;;:::o;23786:201::-;23875:22;23883:4;23889:7;23875;:22::i;:::-;23870:110;;23921:47;;-1:-1:-1;;;23921:47:0;;-1:-1:-1;;;;;4798:32:1;;23921:47:0;;;4780:51:1;4847:18;;;4840:34;;;4753:18;;23921:47:0;4606:274:1;14:286;72:6;125:2;113:9;104:7;100:23;96:32;93:52;;;141:1;138;131:12;93:52;167:23;;-1:-1:-1;;;;;;219:32:1;;209:43;;199:71;;266:1;263;256:12;199:71;289:5;14:286;-1:-1:-1;;;14:286:1:o;497:527::-;646:2;635:9;628:21;609:4;678:6;672:13;721:6;716:2;705:9;701:18;694:34;746:1;756:140;770:6;767:1;764:13;756:140;;;881:2;865:14;;;861:23;;855:30;850:2;831:17;;;827:26;820:66;785:10;756:140;;;760:3;945:1;940:2;931:6;920:9;916:22;912:31;905:42;1015:2;1008;1004:7;999:2;991:6;987:15;983:29;972:9;968:45;964:54;956:62;;;497:527;;;;:::o;1029:173::-;1097:20;;-1:-1:-1;;;;;1146:31:1;;1136:42;;1126:70;;1192:1;1189;1182:12;1126:70;1029:173;;;:::o;1207:300::-;1275:6;1283;1336:2;1324:9;1315:7;1311:23;1307:32;1304:52;;;1352:1;1349;1342:12;1304:52;1375:29;1394:9;1375:29;:::i;:::-;1365:39;1473:2;1458:18;;;;1445:32;;-1:-1:-1;;;1207:300:1:o;1694:374::-;1771:6;1779;1787;1840:2;1828:9;1819:7;1815:23;1811:32;1808:52;;;1856:1;1853;1846:12;1808:52;1879:29;1898:9;1879:29;:::i;:::-;1869:39;;1927:38;1961:2;1950:9;1946:18;1927:38;:::i;:::-;1694:374;;1917:48;;-1:-1:-1;;;2034:2:1;2019:18;;;;2006:32;;1694:374::o;2073:226::-;2132:6;2185:2;2173:9;2164:7;2160:23;2156:32;2153:52;;;2201:1;2198;2191:12;2153:52;-1:-1:-1;2246:23:1;;2073:226;-1:-1:-1;2073:226:1:o;2486:300::-;2554:6;2562;2615:2;2603:9;2594:7;2590:23;2586:32;2583:52;;;2631:1;2628;2621:12;2583:52;2676:23;;;-1:-1:-1;2742:38:1;2776:2;2761:18;;2742:38;:::i;:::-;2732:48;;2486:300;;;;;:::o;2980:186::-;3039:6;3092:2;3080:9;3071:7;3067:23;3063:32;3060:52;;;3108:1;3105;3098:12;3060:52;3131:29;3150:9;3131:29;:::i;3171:260::-;3239:6;3247;3300:2;3288:9;3279:7;3275:23;3271:32;3268:52;;;3316:1;3313;3306:12;3268:52;3339:29;3358:9;3339:29;:::i;:::-;3329:39;;3387:38;3421:2;3410:9;3406:18;3387:38;:::i;3436:380::-;3515:1;3511:12;;;;3558;;;3579:61;;3633:4;3625:6;3621:17;3611:27;;3579:61;3686:2;3678:6;3675:14;3655:18;3652:38;3649:161;;3732:10;3727:3;3723:20;3720:1;3713:31;3767:4;3764:1;3757:15;3795:4;3792:1;3785:15;3649:161;;3436:380;;;:::o;4379:222::-;4444:9;;;4465:10;;;4462:133;;;4517:10;4512:3;4508:20;4505:1;4498:31;4552:4;4549:1;4542:15;4580:4;4577:1;4570:15

Swarm Source

ipfs://8e55d0166c44d0d91314a6fd4944c61baca138da8224f3a672c217e38d9d55ba
Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.