ETH Price: $2,431.84 (+3.34%)

Contract

0x2b781634e4cb0b5236cC957DABA88F911FD66fCD
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Claim Fee203153452024-07-15 23:59:3580 days ago1721087975IN
0x2b781634...11FD66fCD
0 ETH0.000409425.47547087
Claim Fee192415802024-02-16 16:16:35231 days ago1708100195IN
0x2b781634...11FD66fCD
0 ETH0.0034403532.86697592
Claim Fee190324942024-01-18 8:15:23260 days ago1705565723IN
0x2b781634...11FD66fCD
0 ETH0.0022629830.30368734
Claim Fee180461392023-09-02 3:24:11398 days ago1693625051IN
0x2b781634...11FD66fCD
0 ETH0.0009610.48328079
Claim Fee169096512023-03-26 5:54:35558 days ago1679810075IN
0x2b781634...11FD66fCD
0 ETH0.001230611.32370014
Claim Fee155917062022-09-22 21:55:59742 days ago1663883759IN
0x2b781634...11FD66fCD
0 ETH0.001158449.21043813
Claim Fee153181892022-08-11 2:47:59785 days ago1660186079IN
0x2b781634...11FD66fCD
0 ETH0.0027902533.54682128
Claim Fee152574362022-08-01 15:19:22795 days ago1659367162IN
0x2b781634...11FD66fCD
0 ETH0.0028431534.18276857
Claim Fee152417372022-07-30 4:35:34797 days ago1659155734IN
0x2b781634...11FD66fCD
0 ETH0.000749117.35332158
Claim Fee152022992022-07-24 1:02:14803 days ago1658624534IN
0x2b781634...11FD66fCD
0 ETH0.00047125.66523794
Claim Fee151513342022-07-16 3:32:48811 days ago1657942368IN
0x2b781634...11FD66fCD
0 ETH0.000745028.78830255
Claim Fee149497992022-06-12 11:03:13845 days ago1655031793IN
0x2b781634...11FD66fCD
0 ETH0.0012036516.11820784
Claim Fee147383962022-05-08 21:08:32879 days ago1652044112IN
0x2b781634...11FD66fCD
0 ETH0.0020718527.7442649
Claim Fee147176242022-05-05 13:57:57883 days ago1651759077IN
0x2b781634...11FD66fCD
0 ETH0.0065112571.10298217
Claim Fee146965002022-05-02 5:33:57886 days ago1651469637IN
0x2b781634...11FD66fCD
0 ETH0.0026556729
Claim Fee144918292022-03-31 4:33:19918 days ago1648701199IN
0x2b781634...11FD66fCD
0 ETH0.003549828.2234424
Claim Fee143963092022-03-16 7:39:58933 days ago1647416398IN
0x2b781634...11FD66fCD
0 ETH0.0018469616.9952989
Claim Fee142496452022-02-21 13:17:29956 days ago1645449449IN
0x2b781634...11FD66fCD
0 ETH0.0055836360.97334122
Claim Fee141954162022-02-13 3:50:46964 days ago1644724246IN
0x2b781634...11FD66fCD
0 ETH0.0031639336.12833695
Claim Fee140691062022-01-24 15:25:02984 days ago1643037902IN
0x2b781634...11FD66fCD
0 ETH0.00997456119.9225895
Claim Fee140541642022-01-22 7:47:54986 days ago1642837674IN
0x2b781634...11FD66fCD
0 ETH0.01344675161.66823741
Claim Fee140114122022-01-15 17:33:16993 days ago1642267996IN
0x2b781634...11FD66fCD
0 ETH0.0084947797
Claim Fee138941262021-12-28 13:57:381011 days ago1640699858IN
0x2b781634...11FD66fCD
0 ETH0.0062593471.4740728
Claim Fee138591072021-12-23 3:45:141016 days ago1640231114IN
0x2b781634...11FD66fCD
0 ETH0.0068988775.3358303
Claim Fee137920622021-12-12 18:52:091027 days ago1639335129IN
0x2b781634...11FD66fCD
0 ETH0.0064074558.95983268
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
FeePool

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, MIT license
File 1 of 7 : FeePool.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.12;

import "@openzeppelin/contracts/math/SafeMath.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/utils/ReentrancyGuard.sol";
import "./lib/SafeDecimalMath.sol";
import "./interface/IAddressResolver.sol";
import "./interface/IFeePool.sol";


contract FeePool is ReentrancyGuard, IFeePool{
    using SafeMath for uint;
    using SafeDecimalMath for uint;

    bytes32 public constant BOR = "BORING";
    bytes32 public constant OTOKEN = "oToken";
    bytes32 public constant PPTOKEN = "ppToken";

    bytes32 public tunnelKey;
    IAddressResolver public addrReso;

    uint public borFeePerTokenStored;
    uint public oTokenFeePerTokenStored;

    mapping(address => uint) public userBORFee;
    mapping(address => uint) public userBORFeePaid;
    mapping(address => uint) public userOTokenFee;
    mapping(address => uint) public userOTokenFeePaid;



    mapping(address => uint) private _balances;

    constructor(IAddressResolver _addrReso, bytes32 _tunnelKey) public {
        addrReso = _addrReso;
        tunnelKey = _tunnelKey;
    }

    function bor() internal view returns (IERC20) {
        return IERC20(addrReso.requireAndKey2Address(BOR, "BORING contract is address(0) in FeePool"));
    }

    function otoken() internal view returns(IERC20) {
        return IERC20(addrReso.requireKKAddrs(tunnelKey, OTOKEN, "oToken contract is address(0) in FeePool"));
    }

    function ptoken() internal view returns(IERC20) {
        return IERC20(addrReso.requireKKAddrs(tunnelKey, PPTOKEN, "oToken contract is address(0) in FeePool"));
    }

    function totalSupply() external view returns (uint256) {
        return ptoken().totalSupply();
    }

    function balanceOf(address account) external view returns (uint256) {
        return _balances[account];
    }

    function borFeePerToken() public view returns(uint) {
        return borFeePerTokenStored;
    }

    function oTokenFeePerToken() public view returns(uint) {
        return oTokenFeePerTokenStored;
    }

    function earned(address account) public view override returns(uint, uint) {
        uint borFee = _balances[account].multiplyDecimal(borFeePerTokenStored.sub(userBORFeePaid[account])).add(userBORFee[account]);
        uint btokenFee = _balances[account].multiplyDecimal(oTokenFeePerTokenStored.sub(userOTokenFeePaid[account])).add(userOTokenFee[account]);
        return (borFee, btokenFee);
    }

    function getTotalFee() public view returns(uint, uint) {
        return (bor().balanceOf(address(this)), otoken().balanceOf(address(this)));
    }

    function notifyBORFeeAmount(uint amount) external override onlyTunnel {
        borFeePerTokenStored = borFeePerTokenStored.add(amount.divideDecimal(ptoken().totalSupply()));
    }

    function notifyBTokenFeeAmount(uint amount) external override onlyTunnel {

        oTokenFeePerTokenStored = oTokenFeePerTokenStored.add(amount.divideDecimal(ptoken().totalSupply()));
    }

    function notifyPTokenAmount(address account, uint amount) external override onlyTunnel {
        // first update account rewards
        (uint earnedBOR, uint earnedOToken) = earned(account);
        userBORFee[account] = earnedBOR; 
        userOTokenFee[account] = earnedOToken; 

        userBORFeePaid[account] = borFeePerTokenStored;
        userOTokenFeePaid[account] = oTokenFeePerTokenStored;

        _balances[account] = _balances[account].add(amount);
    }

    function withdraw(address account, uint amount) external override onlyTunnel{
        _claimFee(account);
        _balances[account] = _balances[account].sub(amount);
    }

    function claimFee() external {
        _claimFee(msg.sender);
    }

    function _claimFee(address account) internal {
        (uint earnedBOR, uint earnedOToken) = earned(account);
        userBORFee[account] = 0;
        userBORFeePaid[account] = borFeePerTokenStored;

        userOTokenFee[account] = 0;
        userOTokenFeePaid[account] = oTokenFeePerTokenStored;
        
        bor().transfer(account, earnedBOR);
        otoken().transfer(account, earnedOToken);

    }

    // modifier
    modifier onlyTunnel {
        require(
            msg.sender == addrReso.key2address(tunnelKey),
            "caller is not tunnel"
        );
        _;
    }


}

File 2 of 7 : SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a, "SafeMath: addition overflow");

        return c;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return sub(a, b, "SafeMath: subtraction overflow");
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b <= a, errorMessage);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b, "SafeMath: multiplication overflow");

        return c;
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return div(a, b, "SafeMath: division by zero");
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b > 0, errorMessage);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return mod(a, b, "SafeMath: modulo by zero");
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts with custom message when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b != 0, errorMessage);
        return a % b;
    }
}

File 3 of 7 : IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

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

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

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

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

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

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

File 4 of 7 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

/**
 * @dev Contract module that helps prevent reentrant calls to a function.
 *
 * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
 * available, which can be applied to functions to make sure there are no nested
 * (reentrant) calls to them.
 *
 * Note that because there is a single `nonReentrant` guard, functions marked as
 * `nonReentrant` may not call one another. This can be worked around by making
 * those functions `private`, and then adding `external` `nonReentrant` entry
 * points to them.
 *
 * TIP: If you would like to learn more about reentrancy and alternative ways
 * to protect against it, check out our blog post
 * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
 */
contract ReentrancyGuard {
    // Booleans are more expensive than uint256 or any type that takes up a full
    // word because each write operation emits an extra SLOAD to first read the
    // slot's contents, replace the bits taken up by the boolean, and then write
    // back. This is the compiler's defense against contract upgrades and
    // pointer aliasing, and it cannot be disabled.

    // The values being non-zero value makes deployment a bit more expensive,
    // but in exchange the refund on every call to nonReentrant will be lower in
    // amount. Since refunds are capped to a percentage of the total
    // transaction's gas, it is best to keep them low in cases like this one, to
    // increase the likelihood of the full refund coming into effect.
    uint256 private constant _NOT_ENTERED = 1;
    uint256 private constant _ENTERED = 2;

    uint256 private _status;

    constructor () internal {
        _status = _NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and make it call a
     * `private` function that does the actual work.
     */
    modifier nonReentrant() {
        // On the first call to nonReentrant, _notEntered will be true
        require(_status != _ENTERED, "ReentrancyGuard: reentrant call");

        // Any calls to nonReentrant after this point will fail
        _status = _ENTERED;

        _;

        // By storing the original value once again, a refund is triggered (see
        // https://eips.ethereum.org/EIPS/eip-2200)
        _status = _NOT_ENTERED;
    }
}

File 5 of 7 : IAddressResolver.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.12;

interface IAddressResolver {
    
    function key2address(bytes32 key) external view returns(address);
    function address2key(address addr) external view returns(bytes32);
    function requireAndKey2Address(bytes32 name, string calldata reason) external view returns(address);

    function setAddress(bytes32 key, address addr) external;
    function setMultiAddress(bytes32[] memory keys, address[] memory addrs) external;
    
    function setKkAddr(bytes32 k1, bytes32 k2, address addr) external;
    function setMultiKKAddr(bytes32[] memory k1s, bytes32[] memory k2s, address[] memory addrs) external;

    function kk2addr(bytes32 k1, bytes32 k2) external view returns(address);
    function requireKKAddrs(bytes32 k1, bytes32 k2, string calldata reason) external view returns(address);
}

File 6 of 7 : IFeePool.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.12;

interface IFeePool {

    function earned(address account) external view returns(uint, uint);

    function notifyBORFeeAmount(uint amount) external;
    function notifyBTokenFeeAmount(uint amount) external;
    function notifyPTokenAmount(address account, uint amount) external;
    
    function withdraw(address account, uint amount) external;

}

File 7 of 7 : SafeDecimalMath.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.6.8;

// Libraries
import "@openzeppelin/contracts/math/SafeMath.sol";

// https://docs.synthetix.io/contracts/SafeDecimalMath
library SafeDecimalMath {
    using SafeMath for uint;

    /* Number of decimal places in the representations. */
    uint8 public constant decimals = 18;
    uint8 public constant highPrecisionDecimals = 27;

    /* The number representing 1.0. */
    uint public constant UNIT = 10**uint(decimals);

    /* The number representing 1.0 for higher fidelity numbers. */
    uint public constant PRECISE_UNIT = 10**uint(highPrecisionDecimals);
    uint private constant UNIT_TO_HIGH_PRECISION_CONVERSION_FACTOR = 10**uint(highPrecisionDecimals - decimals);

    /**
     * @return Provides an interface to UNIT.
     */
    function unit() external pure returns (uint) {
        return UNIT;
    }

    /**
     * @return Provides an interface to PRECISE_UNIT.
     */
    function preciseUnit() external pure returns (uint) {
        return PRECISE_UNIT;
    }

    /**
     * @return The result of multiplying x and y, interpreting the operands as fixed-point
     * decimals.
     *
     * @dev A unit factor is divided out after the product of x and y is evaluated,
     * so that product must be less than 2**256. As this is an integer division,
     * the internal division always rounds down. This helps save on gas. Rounding
     * is more expensive on gas.
     */
    function multiplyDecimal(uint x, uint y) internal pure returns (uint) {
        /* Divide by UNIT to remove the extra factor introduced by the product. */
        return x.mul(y) / UNIT;
    }

    /**
     * @return The result of safely multiplying x and y, interpreting the operands
     * as fixed-point decimals of the specified precision unit.
     *
     * @dev The operands should be in the form of a the specified unit factor which will be
     * divided out after the product of x and y is evaluated, so that product must be
     * less than 2**256.
     *
     * Unlike multiplyDecimal, this function rounds the result to the nearest increment.
     * Rounding is useful when you need to retain fidelity for small decimal numbers
     * (eg. small fractions or percentages).
     */
    function _multiplyDecimalRound(
        uint x,
        uint y,
        uint precisionUnit
    ) private pure returns (uint) {
        /* Divide by UNIT to remove the extra factor introduced by the product. */
        uint quotientTimesTen = x.mul(y) / (precisionUnit / 10);

        if (quotientTimesTen % 10 >= 5) {
            quotientTimesTen += 10;
        }

        return quotientTimesTen / 10;
    }

    /**
     * @return The result of safely multiplying x and y, interpreting the operands
     * as fixed-point decimals of a precise unit.
     *
     * @dev The operands should be in the precise unit factor which will be
     * divided out after the product of x and y is evaluated, so that product must be
     * less than 2**256.
     *
     * Unlike multiplyDecimal, this function rounds the result to the nearest increment.
     * Rounding is useful when you need to retain fidelity for small decimal numbers
     * (eg. small fractions or percentages).
     */
    function multiplyDecimalRoundPrecise(uint x, uint y) internal pure returns (uint) {
        return _multiplyDecimalRound(x, y, PRECISE_UNIT);
    }

    /**
     * @return The result of safely multiplying x and y, interpreting the operands
     * as fixed-point decimals of a standard unit.
     *
     * @dev The operands should be in the standard unit factor which will be
     * divided out after the product of x and y is evaluated, so that product must be
     * less than 2**256.
     *
     * Unlike multiplyDecimal, this function rounds the result to the nearest increment.
     * Rounding is useful when you need to retain fidelity for small decimal numbers
     * (eg. small fractions or percentages).
     */
    function multiplyDecimalRound(uint x, uint y) internal pure returns (uint) {
        return _multiplyDecimalRound(x, y, UNIT);
    }

    /**
     * @return The result of safely dividing x and y. The return value is a high
     * precision decimal.
     *
     * @dev y is divided after the product of x and the standard precision unit
     * is evaluated, so the product of x and UNIT must be less than 2**256. As
     * this is an integer division, the result is always rounded down.
     * This helps save on gas. Rounding is more expensive on gas.
     */
    function divideDecimal(uint x, uint y) internal pure returns (uint) {
        /* Reintroduce the UNIT factor that will be divided out by y. */
        return x.mul(UNIT).div(y);
    }

    /**
     * @return The result of safely dividing x and y. The return value is as a rounded
     * decimal in the precision unit specified in the parameter.
     *
     * @dev y is divided after the product of x and the specified precision unit
     * is evaluated, so the product of x and the specified precision unit must
     * be less than 2**256. The result is rounded to the nearest increment.
     */
    function _divideDecimalRound(
        uint x,
        uint y,
        uint precisionUnit
    ) private pure returns (uint) {
        uint resultTimesTen = x.mul(precisionUnit * 10).div(y);

        if (resultTimesTen % 10 >= 5) {
            resultTimesTen += 10;
        }

        return resultTimesTen / 10;
    }

    /**
     * @return The result of safely dividing x and y. The return value is as a rounded
     * standard precision decimal.
     *
     * @dev y is divided after the product of x and the standard precision unit
     * is evaluated, so the product of x and the standard precision unit must
     * be less than 2**256. The result is rounded to the nearest increment.
     */
    function divideDecimalRound(uint x, uint y) internal pure returns (uint) {
        return _divideDecimalRound(x, y, UNIT);
    }

    /**
     * @return The result of safely dividing x and y. The return value is as a rounded
     * high precision decimal.
     *
     * @dev y is divided after the product of x and the high precision unit
     * is evaluated, so the product of x and the high precision unit must
     * be less than 2**256. The result is rounded to the nearest increment.
     */
    function divideDecimalRoundPrecise(uint x, uint y) internal pure returns (uint) {
        return _divideDecimalRound(x, y, PRECISE_UNIT);
    }

    /**
     * @dev Convert a standard decimal representation to a high precision one.
     */
    function decimalToPreciseDecimal(uint i) internal pure returns (uint) {
        return i.mul(UNIT_TO_HIGH_PRECISION_CONVERSION_FACTOR);
    }

    /**
     * @dev Convert a high precision decimal to a standard decimal representation.
     */
    function preciseDecimalToDecimal(uint i) internal pure returns (uint) {
        uint quotientTimesTen = i / (UNIT_TO_HIGH_PRECISION_CONVERSION_FACTOR / 10);

        if (quotientTimesTen % 10 >= 5) {
            quotientTimesTen += 10;
        }

        return quotientTimesTen / 10;
    }
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract IAddressResolver","name":"_addrReso","type":"address"},{"internalType":"bytes32","name":"_tunnelKey","type":"bytes32"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"BOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OTOKEN","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PPTOKEN","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"addrReso","outputs":[{"internalType":"contract IAddressResolver","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"borFeePerToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"borFeePerTokenStored","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"earned","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"notifyBORFeeAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"notifyBTokenFeeAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"notifyPTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"oTokenFeePerToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"oTokenFeePerTokenStored","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tunnelKey","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"userBORFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"userBORFeePaid","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"userOTokenFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"userOTokenFeePaid","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b5060405161118b38038061118b8339818101604052604081101561003357600080fd5b50805160209091015160016000818155600280546001600160a01b0319166001600160a01b03909516949094179093555561111790819061007490396000f3fe608060405234801561001057600080fd5b50600436106101415760003560e01c806370a08231116100b8578063c3d665871161007c578063c3d66587146102d5578063c544df0c146102fb578063c7daed2a14610303578063cf36ddcc14610329578063dad0e12314610331578063f3fef3a31461033957610141565b806370a082311461025c5780637ae316d01461028257806399d32fc41461028a5780639bc51d0914610292578063a5f72be3146102af57610141565b80632e9eaf611161010a5780632e9eaf61146101dd5780632f4f0d1c146101e55780633328817e146101ed57806346e992ae1461020a57806356f5ef04146102305780635c7975511461023857610141565b80628cc2621461014657806318160ddd146101855780631a63f35c1461019f57806326abdad4146101cd57806329b2cb43146101d5575b600080fd5b61016c6004803603602081101561015c57600080fd5b50356001600160a01b0316610365565b6040805192835260208301919091528051918290030190f35b61018d61042f565b60408051918252519081900360200190f35b6101cb600480360360408110156101b557600080fd5b506001600160a01b0381351690602001356104a2565b005b61018d6105f3565b61018d610600565b61018d610606565b61018d61060c565b6101cb6004803603602081101561020357600080fd5b5035610612565b61018d6004803603602081101561022057600080fd5b50356001600160a01b0316610768565b61018d61077a565b610240610788565b604080516001600160a01b039092168252519081900360200190f35b61018d6004803603602081101561027257600080fd5b50356001600160a01b0316610797565b61016c6107b2565b6101cb6108be565b6101cb600480360360208110156102a857600080fd5b50356108c9565b61018d600480360360208110156102c557600080fd5b50356001600160a01b03166109b4565b61018d600480360360208110156102eb57600080fd5b50356001600160a01b03166109c6565b61018d6109d8565b61018d6004803603602081101561031957600080fd5b50356001600160a01b03166109e5565b61018d6109f7565b61018d6109fd565b6101cb6004803603604081101561034f57600080fd5b506001600160a01b038135169060200135610a03565b6001600160a01b0381166000908152600560209081526040808320546006909252822054600354839283926103c7926103c1916103a29190610b1d565b6001600160a01b03881660009081526009602052604090205490610b68565b90610b8c565b6001600160a01b03851660009081526007602090815260408083205460089092528220546004549394509192610423926103c19161040491610b1d565b6001600160a01b03891660009081526009602052604090205490610b68565b91935090915050915091565b6000610439610be6565b6001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561047157600080fd5b505afa158015610485573d6000803e3d6000fd5b505050506040513d602081101561049b57600080fd5b5051905090565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b1580156104f157600080fd5b505afa158015610505573d6000803e3d6000fd5b505050506040513d602081101561051b57600080fd5b50516001600160a01b03163314610570576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b60008061057c84610365565b6001600160a01b03861660009081526005602090815260408083208590556007825280832084905560035460068352818420556004546008835281842055600990915290205491935091506105d19084610b8c565b6001600160a01b03909416600090815260096020526040902093909355505050565b65424f52494e4760d01b81565b60035490565b60035481565b60015481565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b15801561066157600080fd5b505afa158015610675573d6000803e3d6000fd5b505050506040513d602081101561068b57600080fd5b50516001600160a01b031633146106e0576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b6107626107596106ee610be6565b6001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561072657600080fd5b505afa15801561073a573d6000803e3d6000fd5b505050506040513d602081101561075057600080fd5b50518390610c66565b60045490610b8c565b60045550565b60056020526000908152604090205481565b6638382a37b5b2b760c91b81565b6002546001600160a01b031681565b6001600160a01b031660009081526009602052604090205490565b6000806107bd610c84565b6001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561080957600080fd5b505afa15801561081d573d6000803e3d6000fd5b505050506040513d602081101561083357600080fd5b505161083d610cf5565b6001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561088957600080fd5b505afa15801561089d573d6000803e3d6000fd5b505050506040513d60208110156108b357600080fd5b505190925090509091565b6108c733610d74565b565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b15801561091857600080fd5b505afa15801561092c573d6000803e3d6000fd5b505050506040513d602081101561094257600080fd5b50516001600160a01b03163314610997576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b6109ae6109a56106ee610be6565b60035490610b8c565b60035550565b60076020526000908152604090205481565b60066020526000908152604090205481565b6537aa37b5b2b760d11b81565b60086020526000908152604090205481565b60045481565b60045490565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b158015610a5257600080fd5b505afa158015610a66573d6000803e3d6000fd5b505050506040513d6020811015610a7c57600080fd5b50516001600160a01b03163314610ad1576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b610ada82610d74565b6001600160a01b038216600090815260096020526040902054610afd9082610b1d565b6001600160a01b0390921660009081526009602052604090209190915550565b6000610b5f83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610ede565b90505b92915050565b6000670de0b6b3a7640000610b7d8484610f75565b81610b8457fe5b049392505050565b600082820183811015610b5f576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6002546001546040516305ad37e160e11b8152600481018281526638382a37b5b2b760c91b602483018190526060604484019081526028606485018190526000966001600160a01b031695630b5a6fc295909492916084909101906110718239604001935050505060206040518083038186803b15801561047157600080fd5b6000610b5f82610c7e85670de0b6b3a7640000610f75565b90610fce565b60025460408051635da2251d60e11b815265424f52494e4760d01b60048201818152602483019384526028604484018190526000956001600160a01b03169463bb444a3a94909160649091019061109982396040019250505060206040518083038186803b15801561047157600080fd5b6002546001546040516305ad37e160e11b8152600481018281526537aa37b5b2b760d11b602483018190526060604484019081526028606485018190526000966001600160a01b031695630b5a6fc295909492916084909101906110718239604001935050505060206040518083038186803b15801561047157600080fd5b600080610d8083610365565b6001600160a01b03851660009081526005602090815260408083208390556003546006835281842055600782528083208390556004546008909252909120559092509050610dcc610c84565b6001600160a01b031663a9059cbb84846040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015610e2257600080fd5b505af1158015610e36573d6000803e3d6000fd5b505050506040513d6020811015610e4c57600080fd5b50610e579050610cf5565b6001600160a01b031663a9059cbb84836040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015610ead57600080fd5b505af1158015610ec1573d6000803e3d6000fd5b505050506040513d6020811015610ed757600080fd5b5050505050565b60008184841115610f6d5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f32578181015183820152602001610f1a565b50505050905090810190601f168015610f5f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600082610f8457506000610b62565b82820282848281610f9157fe5b0414610b5f5760405162461bcd60e51b81526004018080602001828103825260218152602001806110c16021913960400191505060405180910390fd5b6000610b5f83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f0000000000008152506000818361105a5760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f32578181015183820152602001610f1a565b50600083858161106657fe5b049594505050505056fe6f546f6b656e20636f6e7472616374206973206164647265737328302920696e20466565506f6f6c424f52494e4720636f6e7472616374206973206164647265737328302920696e20466565506f6f6c536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a264697066735822122003143e8f330c55182744b8d5e55a6bef03f71f3da1e3f1d8794ec302671207c964736f6c634300060c0033000000000000000000000000ce61e08c01fb6e1ca1bb4d0acf4eb1d5fe66bf794254430000000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106101415760003560e01c806370a08231116100b8578063c3d665871161007c578063c3d66587146102d5578063c544df0c146102fb578063c7daed2a14610303578063cf36ddcc14610329578063dad0e12314610331578063f3fef3a31461033957610141565b806370a082311461025c5780637ae316d01461028257806399d32fc41461028a5780639bc51d0914610292578063a5f72be3146102af57610141565b80632e9eaf611161010a5780632e9eaf61146101dd5780632f4f0d1c146101e55780633328817e146101ed57806346e992ae1461020a57806356f5ef04146102305780635c7975511461023857610141565b80628cc2621461014657806318160ddd146101855780631a63f35c1461019f57806326abdad4146101cd57806329b2cb43146101d5575b600080fd5b61016c6004803603602081101561015c57600080fd5b50356001600160a01b0316610365565b6040805192835260208301919091528051918290030190f35b61018d61042f565b60408051918252519081900360200190f35b6101cb600480360360408110156101b557600080fd5b506001600160a01b0381351690602001356104a2565b005b61018d6105f3565b61018d610600565b61018d610606565b61018d61060c565b6101cb6004803603602081101561020357600080fd5b5035610612565b61018d6004803603602081101561022057600080fd5b50356001600160a01b0316610768565b61018d61077a565b610240610788565b604080516001600160a01b039092168252519081900360200190f35b61018d6004803603602081101561027257600080fd5b50356001600160a01b0316610797565b61016c6107b2565b6101cb6108be565b6101cb600480360360208110156102a857600080fd5b50356108c9565b61018d600480360360208110156102c557600080fd5b50356001600160a01b03166109b4565b61018d600480360360208110156102eb57600080fd5b50356001600160a01b03166109c6565b61018d6109d8565b61018d6004803603602081101561031957600080fd5b50356001600160a01b03166109e5565b61018d6109f7565b61018d6109fd565b6101cb6004803603604081101561034f57600080fd5b506001600160a01b038135169060200135610a03565b6001600160a01b0381166000908152600560209081526040808320546006909252822054600354839283926103c7926103c1916103a29190610b1d565b6001600160a01b03881660009081526009602052604090205490610b68565b90610b8c565b6001600160a01b03851660009081526007602090815260408083205460089092528220546004549394509192610423926103c19161040491610b1d565b6001600160a01b03891660009081526009602052604090205490610b68565b91935090915050915091565b6000610439610be6565b6001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561047157600080fd5b505afa158015610485573d6000803e3d6000fd5b505050506040513d602081101561049b57600080fd5b5051905090565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b1580156104f157600080fd5b505afa158015610505573d6000803e3d6000fd5b505050506040513d602081101561051b57600080fd5b50516001600160a01b03163314610570576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b60008061057c84610365565b6001600160a01b03861660009081526005602090815260408083208590556007825280832084905560035460068352818420556004546008835281842055600990915290205491935091506105d19084610b8c565b6001600160a01b03909416600090815260096020526040902093909355505050565b65424f52494e4760d01b81565b60035490565b60035481565b60015481565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b15801561066157600080fd5b505afa158015610675573d6000803e3d6000fd5b505050506040513d602081101561068b57600080fd5b50516001600160a01b031633146106e0576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b6107626107596106ee610be6565b6001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561072657600080fd5b505afa15801561073a573d6000803e3d6000fd5b505050506040513d602081101561075057600080fd5b50518390610c66565b60045490610b8c565b60045550565b60056020526000908152604090205481565b6638382a37b5b2b760c91b81565b6002546001600160a01b031681565b6001600160a01b031660009081526009602052604090205490565b6000806107bd610c84565b6001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561080957600080fd5b505afa15801561081d573d6000803e3d6000fd5b505050506040513d602081101561083357600080fd5b505161083d610cf5565b6001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561088957600080fd5b505afa15801561089d573d6000803e3d6000fd5b505050506040513d60208110156108b357600080fd5b505190925090509091565b6108c733610d74565b565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b15801561091857600080fd5b505afa15801561092c573d6000803e3d6000fd5b505050506040513d602081101561094257600080fd5b50516001600160a01b03163314610997576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b6109ae6109a56106ee610be6565b60035490610b8c565b60035550565b60076020526000908152604090205481565b60066020526000908152604090205481565b6537aa37b5b2b760d11b81565b60086020526000908152604090205481565b60045481565b60045490565b6002546001546040805163130852b360e11b81526004810192909252516001600160a01b0390921691632610a56691602480820192602092909190829003018186803b158015610a5257600080fd5b505afa158015610a66573d6000803e3d6000fd5b505050506040513d6020811015610a7c57600080fd5b50516001600160a01b03163314610ad1576040805162461bcd60e51b815260206004820152601460248201527318d85b1b195c881a5cc81b9bdd081d1d5b9b995b60621b604482015290519081900360640190fd5b610ada82610d74565b6001600160a01b038216600090815260096020526040902054610afd9082610b1d565b6001600160a01b0390921660009081526009602052604090209190915550565b6000610b5f83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610ede565b90505b92915050565b6000670de0b6b3a7640000610b7d8484610f75565b81610b8457fe5b049392505050565b600082820183811015610b5f576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6002546001546040516305ad37e160e11b8152600481018281526638382a37b5b2b760c91b602483018190526060604484019081526028606485018190526000966001600160a01b031695630b5a6fc295909492916084909101906110718239604001935050505060206040518083038186803b15801561047157600080fd5b6000610b5f82610c7e85670de0b6b3a7640000610f75565b90610fce565b60025460408051635da2251d60e11b815265424f52494e4760d01b60048201818152602483019384526028604484018190526000956001600160a01b03169463bb444a3a94909160649091019061109982396040019250505060206040518083038186803b15801561047157600080fd5b6002546001546040516305ad37e160e11b8152600481018281526537aa37b5b2b760d11b602483018190526060604484019081526028606485018190526000966001600160a01b031695630b5a6fc295909492916084909101906110718239604001935050505060206040518083038186803b15801561047157600080fd5b600080610d8083610365565b6001600160a01b03851660009081526005602090815260408083208390556003546006835281842055600782528083208390556004546008909252909120559092509050610dcc610c84565b6001600160a01b031663a9059cbb84846040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015610e2257600080fd5b505af1158015610e36573d6000803e3d6000fd5b505050506040513d6020811015610e4c57600080fd5b50610e579050610cf5565b6001600160a01b031663a9059cbb84836040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015610ead57600080fd5b505af1158015610ec1573d6000803e3d6000fd5b505050506040513d6020811015610ed757600080fd5b5050505050565b60008184841115610f6d5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f32578181015183820152602001610f1a565b50505050905090810190601f168015610f5f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600082610f8457506000610b62565b82820282848281610f9157fe5b0414610b5f5760405162461bcd60e51b81526004018080602001828103825260218152602001806110c16021913960400191505060405180910390fd5b6000610b5f83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f0000000000008152506000818361105a5760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f32578181015183820152602001610f1a565b50600083858161106657fe5b049594505050505056fe6f546f6b656e20636f6e7472616374206973206164647265737328302920696e20466565506f6f6c424f52494e4720636f6e7472616374206973206164647265737328302920696e20466565506f6f6c536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a264697066735822122003143e8f330c55182744b8d5e55a6bef03f71f3da1e3f1d8794ec302671207c964736f6c634300060c0033

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

000000000000000000000000ce61e08c01fb6e1ca1bb4d0acf4eb1d5fe66bf794254430000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _addrReso (address): 0xCE61e08C01fb6E1ca1BB4d0ACF4eB1D5Fe66bF79
Arg [1] : _tunnelKey (bytes32): 0x4254430000000000000000000000000000000000000000000000000000000000

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000ce61e08c01fb6e1ca1bb4d0acf4eb1d5fe66bf79
Arg [1] : 4254430000000000000000000000000000000000000000000000000000000000


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

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

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.