Sepolia Testnet

Contract

0xc2e7B0B527a9A265fb3DD562B6D4e1673b381d10

Overview

ETH Balance

0 ETH

Multichain Info

N/A
Transaction Hash
Method
Block
From
To
Value
Set Synthetix54873802024-03-15 0:00:1296 days ago1710460812IN
0xc2e7B0B5...73b381d10
0 ETH0.00005041.0696837
0x6080604054872022024-03-14 23:22:1296 days ago1710458532IN
 Create: SynthetixEscrow
0 ETH0.000150930.13318886

Advanced mode:
Parent Transaction Hash Block From To Value
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
SynthetixEscrow

Compiler Version
v0.5.16+commit.9c3226ce

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2024-03-15
*/

/*
   ____            __   __        __   _
  / __/__ __ ___  / /_ / /  ___  / /_ (_)__ __
 _\ \ / // // _ \/ __// _ \/ -_)/ __// / \ \ /
/___/ \_, //_//_/\__//_//_/\__/ \__//_/ /_\_\
     /___/

* Synthetix: SynthetixEscrow.sol
*
* Latest source (may be newer): https://github.com/Synthetixio/synthetix/blob/master/contracts/SynthetixEscrow.sol
* Docs: https://docs.synthetix.io/contracts/SynthetixEscrow
*
* Contract Dependencies: (none)
* Libraries: 
*	- SafeDecimalMath
*	- SafeMath
*
* MIT License
* ===========
*
* Copyright (c) 2024 Synthetix
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
*/



pragma solidity ^0.5.16;

// https://docs.synthetix.io/contracts/source/contracts/owned
contract Owned {
    address public owner;
    address public nominatedOwner;

    constructor(address _owner) public {
        require(_owner != address(0), "Owner address cannot be 0");
        owner = _owner;
        emit OwnerChanged(address(0), _owner);
    }

    function nominateNewOwner(address _owner) external onlyOwner {
        nominatedOwner = _owner;
        emit OwnerNominated(_owner);
    }

    function acceptOwnership() external {
        require(msg.sender == nominatedOwner, "You must be nominated before you can accept ownership");
        emit OwnerChanged(owner, nominatedOwner);
        owner = nominatedOwner;
        nominatedOwner = address(0);
    }

    modifier onlyOwner {
        _onlyOwner();
        _;
    }

    function _onlyOwner() private view {
        require(msg.sender == owner, "Only the contract owner may perform this action");
    }

    event OwnerNominated(address newOwner);
    event OwnerChanged(address oldOwner, address newOwner);
}


// https://docs.synthetix.io/contracts/source/contracts/limitedsetup
contract LimitedSetup {
    uint public setupExpiryTime;

    /**
     * @dev LimitedSetup Constructor.
     * @param setupDuration The time the setup period will last for.
     */
    constructor(uint setupDuration) internal {
        setupExpiryTime = now + setupDuration;
    }

    modifier onlyDuringSetup {
        require(now < setupExpiryTime, "Can only perform this action during setup");
        _;
    }
}


// https://docs.synthetix.io/contracts/source/interfaces/ihasbalance
interface IHasBalance {
    // Views
    function balanceOf(address account) external view returns (uint);
}


/**
 * @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) {
        require(b <= a, "SafeMath: subtraction overflow");
        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-solidity/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) {
        // Solidity only automatically asserts when dividing by 0
        require(b > 0, "SafeMath: division by zero");
        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) {
        require(b != 0, "SafeMath: modulo by zero");
        return a % b;
    }
}


// Libraries


// https://docs.synthetix.io/contracts/source/libraries/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;
    }

    // Computes `a - b`, setting the value to 0 if b > a.
    function floorsub(uint a, uint b) internal pure returns (uint) {
        return b >= a ? 0 : a - b;
    }

    /* ---------- Utilities ---------- */
    /*
     * Absolute value of the input, returned as a signed number.
     */
    function signedAbs(int x) internal pure returns (int) {
        return x < 0 ? -x : x;
    }

    /*
     * Absolute value of the input, returned as an unsigned number.
     */
    function abs(int x) internal pure returns (uint) {
        return uint(signedAbs(x));
    }
}


// https://docs.synthetix.io/contracts/source/interfaces/ierc20
interface IERC20 {
    // ERC20 Optional Views
    function name() external view returns (string memory);

    function symbol() external view returns (string memory);

    function decimals() external view returns (uint8);

    // Views
    function totalSupply() external view returns (uint);

    function balanceOf(address owner) external view returns (uint);

    function allowance(address owner, address spender) external view returns (uint);

    // Mutative functions
    function transfer(address to, uint value) external returns (bool);

    function approve(address spender, uint value) external returns (bool);

    function transferFrom(
        address from,
        address to,
        uint value
    ) external returns (bool);

    // Events
    event Transfer(address indexed from, address indexed to, uint value);

    event Approval(address indexed owner, address indexed spender, uint value);
}


// https://docs.synthetix.io/contracts/source/interfaces/isynth
interface ISynth {
    // Views
    function currencyKey() external view returns (bytes32);

    function transferableSynths(address account) external view returns (uint);

    // Mutative functions
    function transferAndSettle(address to, uint value) external returns (bool);

    function transferFromAndSettle(
        address from,
        address to,
        uint value
    ) external returns (bool);

    // Restricted: used internally to Synthetix
    function burn(address account, uint amount) external;

    function issue(address account, uint amount) external;
}


interface IVirtualSynth {
    // Views
    function balanceOfUnderlying(address account) external view returns (uint);

    function rate() external view returns (uint);

    function readyToSettle() external view returns (bool);

    function secsLeftInWaitingPeriod() external view returns (uint);

    function settled() external view returns (bool);

    function synth() external view returns (ISynth);

    // Mutative functions
    function settle(address account) external;
}


// https://docs.synthetix.io/contracts/source/interfaces/isynthetix
interface ISynthetix {
    // Views
    function anySynthOrSNXRateIsInvalid() external view returns (bool anyRateInvalid);

    function availableCurrencyKeys() external view returns (bytes32[] memory);

    function availableSynthCount() external view returns (uint);

    function availableSynths(uint index) external view returns (ISynth);

    function collateral(address account) external view returns (uint);

    function collateralisationRatio(address issuer) external view returns (uint);

    function debtBalanceOf(address issuer, bytes32 currencyKey) external view returns (uint);

    function isWaitingPeriod(bytes32 currencyKey) external view returns (bool);

    function maxIssuableSynths(address issuer) external view returns (uint maxIssuable);

    function remainingIssuableSynths(address issuer)
        external
        view
        returns (
            uint maxIssuable,
            uint alreadyIssued,
            uint totalSystemDebt
        );

    function synths(bytes32 currencyKey) external view returns (ISynth);

    function synthsByAddress(address synthAddress) external view returns (bytes32);

    function totalIssuedSynths(bytes32 currencyKey) external view returns (uint);

    function totalIssuedSynthsExcludeOtherCollateral(bytes32 currencyKey) external view returns (uint);

    function transferableSynthetix(address account) external view returns (uint transferable);

    function getFirstNonZeroEscrowIndex(address account) external view returns (uint);

    // Mutative Functions
    function burnSynths(uint amount) external;

    function burnSynthsOnBehalf(address burnForAddress, uint amount) external;

    function burnSynthsToTarget() external;

    function burnSynthsToTargetOnBehalf(address burnForAddress) external;

    function exchange(
        bytes32 sourceCurrencyKey,
        uint sourceAmount,
        bytes32 destinationCurrencyKey
    ) external returns (uint amountReceived);

    function exchangeOnBehalf(
        address exchangeForAddress,
        bytes32 sourceCurrencyKey,
        uint sourceAmount,
        bytes32 destinationCurrencyKey
    ) external returns (uint amountReceived);

    function exchangeWithTracking(
        bytes32 sourceCurrencyKey,
        uint sourceAmount,
        bytes32 destinationCurrencyKey,
        address rewardAddress,
        bytes32 trackingCode
    ) external returns (uint amountReceived);

    function exchangeWithTrackingForInitiator(
        bytes32 sourceCurrencyKey,
        uint sourceAmount,
        bytes32 destinationCurrencyKey,
        address rewardAddress,
        bytes32 trackingCode
    ) external returns (uint amountReceived);

    function exchangeOnBehalfWithTracking(
        address exchangeForAddress,
        bytes32 sourceCurrencyKey,
        uint sourceAmount,
        bytes32 destinationCurrencyKey,
        address rewardAddress,
        bytes32 trackingCode
    ) external returns (uint amountReceived);

    function exchangeWithVirtual(
        bytes32 sourceCurrencyKey,
        uint sourceAmount,
        bytes32 destinationCurrencyKey,
        bytes32 trackingCode
    ) external returns (uint amountReceived, IVirtualSynth vSynth);

    function exchangeAtomically(
        bytes32 sourceCurrencyKey,
        uint sourceAmount,
        bytes32 destinationCurrencyKey,
        bytes32 trackingCode,
        uint minAmount
    ) external returns (uint amountReceived);

    function issueMaxSynths() external;

    function issueMaxSynthsOnBehalf(address issueForAddress) external;

    function issueSynths(uint amount) external;

    function issueSynthsOnBehalf(address issueForAddress, uint amount) external;

    function mint() external returns (bool);

    function settle(bytes32 currencyKey)
        external
        returns (
            uint reclaimed,
            uint refunded,
            uint numEntries
        );

    // Liquidations
    function liquidateDelinquentAccount(address account) external returns (bool);

    function liquidateDelinquentAccountEscrowIndex(address account, uint escrowStartIndex) external returns (bool);

    function liquidateSelf() external returns (bool);

    // Restricted Functions

    function mintSecondary(address account, uint amount) external;

    function mintSecondaryRewards(uint amount) external;

    function burnSecondary(address account, uint amount) external;

    function migrateAccountBalances(address account) external returns (uint totalEscrowRevoked, uint totalLiquidBalance);
}


// Inheritance


// Libraires


// Internal references


// https://docs.synthetix.io/contracts/source/contracts/synthetixescrow
contract SynthetixEscrow is Owned, LimitedSetup(8 weeks), IHasBalance {
    using SafeMath for uint;

    /* The corresponding Synthetix contract. */
    ISynthetix public synthetix;

    /* Lists of (timestamp, quantity) pairs per account, sorted in ascending time order.
     * These are the times at which each given quantity of SNX vests. */
    mapping(address => uint[2][]) public vestingSchedules;

    /* An account's total vested synthetix balance to save recomputing this for fee extraction purposes. */
    mapping(address => uint) public totalVestedAccountBalance;

    /* The total remaining vested balance, for verifying the actual synthetix balance of this contract against. */
    uint public totalVestedBalance;

    uint public constant TIME_INDEX = 0;
    uint public constant QUANTITY_INDEX = 1;

    /* Limit vesting entries to disallow unbounded iteration over vesting schedules. */
    uint public constant MAX_VESTING_ENTRIES = 20;

    /* ========== CONSTRUCTOR ========== */

    constructor(address _owner, ISynthetix _synthetix) public Owned(_owner) {
        synthetix = _synthetix;
    }

    /* ========== SETTERS ========== */

    function setSynthetix(ISynthetix _synthetix) external onlyOwner {
        synthetix = _synthetix;
        emit SynthetixUpdated(address(_synthetix));
    }

    /* ========== VIEW FUNCTIONS ========== */

    /**
     * @notice A simple alias to totalVestedAccountBalance: provides ERC20 balance integration.
     */
    function balanceOf(address account) public view returns (uint) {
        return totalVestedAccountBalance[account];
    }

    /**
     * @notice The number of vesting dates in an account's schedule.
     */
    function numVestingEntries(address account) public view returns (uint) {
        return vestingSchedules[account].length;
    }

    /**
     * @notice Get a particular schedule entry for an account.
     * @return A pair of uints: (timestamp, synthetix quantity).
     */
    function getVestingScheduleEntry(address account, uint index) public view returns (uint[2] memory) {
        return vestingSchedules[account][index];
    }

    /**
     * @notice Get the time at which a given schedule entry will vest.
     */
    function getVestingTime(address account, uint index) public view returns (uint) {
        return getVestingScheduleEntry(account, index)[TIME_INDEX];
    }

    /**
     * @notice Get the quantity of SNX associated with a given schedule entry.
     */
    function getVestingQuantity(address account, uint index) public view returns (uint) {
        return getVestingScheduleEntry(account, index)[QUANTITY_INDEX];
    }

    /**
     * @notice Obtain the index of the next schedule entry that will vest for a given user.
     */
    function getNextVestingIndex(address account) public view returns (uint) {
        uint len = numVestingEntries(account);
        for (uint i = 0; i < len; i++) {
            if (getVestingTime(account, i) != 0) {
                return i;
            }
        }
        return len;
    }

    /**
     * @notice Obtain the next schedule entry that will vest for a given user.
     * @return A pair of uints: (timestamp, synthetix quantity). */
    function getNextVestingEntry(address account) public view returns (uint[2] memory) {
        uint index = getNextVestingIndex(account);
        if (index == numVestingEntries(account)) {
            return [uint(0), 0];
        }
        return getVestingScheduleEntry(account, index);
    }

    /**
     * @notice Obtain the time at which the next schedule entry will vest for a given user.
     */
    function getNextVestingTime(address account) external view returns (uint) {
        return getNextVestingEntry(account)[TIME_INDEX];
    }

    /**
     * @notice Obtain the quantity which the next schedule entry will vest for a given user.
     */
    function getNextVestingQuantity(address account) external view returns (uint) {
        return getNextVestingEntry(account)[QUANTITY_INDEX];
    }

    /* ========== MUTATIVE FUNCTIONS ========== */

    /**
     * @notice Destroy the vesting information associated with an account.
     */
    function purgeAccount(address account) external onlyOwner onlyDuringSetup {
        delete vestingSchedules[account];
        totalVestedBalance = totalVestedBalance.sub(totalVestedAccountBalance[account]);
        delete totalVestedAccountBalance[account];
    }

    /**
     * @notice Add a new vesting entry at a given time and quantity to an account's schedule.
     * @dev A call to this should be accompanied by either enough balance already available
     * in this contract, or a corresponding call to synthetix.endow(), to ensure that when
     * the funds are withdrawn, there is enough balance, as well as correctly calculating
     * the fees.
     * This may only be called by the owner during the contract's setup period.
     * Note; although this function could technically be used to produce unbounded
     * arrays, it's only in the foundation's command to add to these lists.
     * @param account The account to append a new vesting entry to.
     * @param time The absolute unix timestamp after which the vested quantity may be withdrawn.
     * @param quantity The quantity of SNX that will vest.
     */
    function appendVestingEntry(
        address account,
        uint time,
        uint quantity
    ) public onlyOwner onlyDuringSetup {
        /* No empty or already-passed vesting entries allowed. */
        require(now < time, "Time must be in the future");
        require(quantity != 0, "Quantity cannot be zero");

        /* There must be enough balance in the contract to provide for the vesting entry. */
        totalVestedBalance = totalVestedBalance.add(quantity);
        require(
            totalVestedBalance <= IERC20(address(synthetix)).balanceOf(address(this)),
            "Must be enough balance in the contract to provide for the vesting entry"
        );

        /* Disallow arbitrarily long vesting schedules in light of the gas limit. */
        uint scheduleLength = vestingSchedules[account].length;
        require(scheduleLength <= MAX_VESTING_ENTRIES, "Vesting schedule is too long");

        if (scheduleLength == 0) {
            totalVestedAccountBalance[account] = quantity;
        } else {
            /* Disallow adding new vested SNX earlier than the last one.
             * Since entries are only appended, this means that no vesting date can be repeated. */
            require(
                getVestingTime(account, numVestingEntries(account) - 1) < time,
                "Cannot add new vested entries earlier than the last one"
            );
            totalVestedAccountBalance[account] = totalVestedAccountBalance[account].add(quantity);
        }

        vestingSchedules[account].push([time, quantity]);
    }

    /**
     * @notice Construct a vesting schedule to release a quantities of SNX
     * over a series of intervals.
     * @dev Assumes that the quantities are nonzero
     * and that the sequence of timestamps is strictly increasing.
     * This may only be called by the owner during the contract's setup period.
     */
    function addVestingSchedule(
        address account,
        uint[] calldata times,
        uint[] calldata quantities
    ) external onlyOwner onlyDuringSetup {
        for (uint i = 0; i < times.length; i++) {
            appendVestingEntry(account, times[i], quantities[i]);
        }
    }

    /**
     * @notice Allow a user to withdraw any SNX in their schedule that have vested.
     */
    function vest() external {
        uint numEntries = numVestingEntries(msg.sender);
        uint total;
        for (uint i = 0; i < numEntries; i++) {
            uint time = getVestingTime(msg.sender, i);
            /* The list is sorted; when we reach the first future time, bail out. */
            if (time > now) {
                break;
            }
            uint qty = getVestingQuantity(msg.sender, i);
            if (qty > 0) {
                vestingSchedules[msg.sender][i] = [0, 0];
                total = total.add(qty);
            }
        }

        if (total != 0) {
            totalVestedBalance = totalVestedBalance.sub(total);
            totalVestedAccountBalance[msg.sender] = totalVestedAccountBalance[msg.sender].sub(total);
            IERC20(address(synthetix)).transfer(msg.sender, total);
            emit Vested(msg.sender, now, total);
        }
    }

    /* ========== EVENTS ========== */

    event SynthetixUpdated(address newSynthetix);

    event Vested(address indexed beneficiary, uint time, uint value);
}

Contract ABI

[{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"contract ISynthetix","name":"_synthetix","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerNominated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newSynthetix","type":"address"}],"name":"SynthetixUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beneficiary","type":"address"},{"indexed":false,"internalType":"uint256","name":"time","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Vested","type":"event"},{"constant":true,"inputs":[],"name":"MAX_VESTING_ENTRIES","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"QUANTITY_INDEX","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"TIME_INDEX","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"acceptOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256[]","name":"times","type":"uint256[]"},{"internalType":"uint256[]","name":"quantities","type":"uint256[]"}],"name":"addVestingSchedule","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"time","type":"uint256"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"appendVestingEntry","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getNextVestingEntry","outputs":[{"internalType":"uint256[2]","name":"","type":"uint256[2]"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getNextVestingIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getNextVestingQuantity","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getNextVestingTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getVestingQuantity","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getVestingScheduleEntry","outputs":[{"internalType":"uint256[2]","name":"","type":"uint256[2]"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getVestingTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"nominateNewOwner","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"nominatedOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"numVestingEntries","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"purgeAccount","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract ISynthetix","name":"_synthetix","type":"address"}],"name":"setSynthetix","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"setupExpiryTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"synthetix","outputs":[{"internalType":"contract ISynthetix","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"totalVestedAccountBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalVestedBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"vest","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"vestingSchedules","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b506040516113bf3803806113bf8339818101604052604081101561003357600080fd5b5080516020909101516249d400826001600160a01b03811661009c576040805162461bcd60e51b815260206004820152601960248201527f4f776e657220616464726573732063616e6e6f74206265203000000000000000604482015290519081900360640190fd5b600080546001600160a01b0319166001600160a01b038316908117825560408051928352602083019190915280517fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9281900390910190a1504201600255600380546001600160a01b0319166001600160a01b0392909216919091179055506112958061012a6000396000f3fe608060405234801561001057600080fd5b506004361061018e5760003560e01c806370a08231116100de5780639b217f9011610097578063d0cc82e311610071578063d0cc82e3146104fe578063da7bd3e914610506578063ee1d036c14610532578063fec9f9da1461055e5761018e565b80639b217f90146103f8578063a15d59ce14610424578063bb2a7d0c1461042c5761018e565b806370a082311461038c578063759b5225146103b257806379ba5097146103ba5780638ad58777146103c25780638da5cb5b146103ca57806397f46527146103d25761018e565b80632f5bb6611161014b57806346ba2d901161012557806346ba2d901461033257806353a47bb71461033a57806363667eb71461035e5780636b3905c4146103665761018e565b80632f5bb66114610297578063458efde3146102f857806345e5441f146103005761018e565b8063135c0701146101935780631627540c146101bb57806319e740c0146101e15780631bb47b4414610219578063204b676a1461024b578063227d517a14610271575b600080fd5b6101b9600480360360208110156101a957600080fd5b50356001600160a01b0316610584565b005b6101b9600480360360208110156101d157600080fd5b50356001600160a01b0316610635565b610207600480360360208110156101f757600080fd5b50356001600160a01b0316610691565b60408051918252519081900360200190f35b6101b96004803603606081101561022f57600080fd5b506001600160a01b0381351690602081013590604001356106d3565b6102076004803603602081101561026157600080fd5b50356001600160a01b0316610a0e565b6102076004803603602081101561028757600080fd5b50356001600160a01b0316610a29565b6102bd600480360360208110156102ad57600080fd5b50356001600160a01b0316610a3b565b6040518082600260200280838360005b838110156102e55781810151838201526020016102cd565b5050505090500191505060405180910390f35b6101b9610a8c565b6102076004803603606081101561031657600080fd5b506001600160a01b038135169060208101359060400135610c49565b610207610c85565b610342610c8b565b604080516001600160a01b039092168252519081900360200190f35b610207610c9a565b6102076004803603602081101561037c57600080fd5b50356001600160a01b0316610c9f565b610207600480360360208110156103a257600080fd5b50356001600160a01b0316610cb8565b610342610cd3565b6101b9610ce2565b610207610d9e565b610342610da3565b610207600480360360208110156103e857600080fd5b50356001600160a01b0316610db2565b6102076004803603604081101561040e57600080fd5b506001600160a01b038135169060200135610dc4565b610207610ddf565b6101b96004803603606081101561044257600080fd5b6001600160a01b03823516919081019060408101602082013564010000000081111561046d57600080fd5b82018360208201111561047f57600080fd5b803590602001918460208302840111640100000000831117156104a157600080fd5b9193909290916020810190356401000000008111156104bf57600080fd5b8201836020820111156104d157600080fd5b803590602001918460208302840111640100000000831117156104f357600080fd5b509092509050610de5565b610207610e6f565b6102bd6004803603604081101561051c57600080fd5b506001600160a01b038135169060200135610e74565b6102076004803603604081101561054857600080fd5b506001600160a01b038135169060200135610ee3565b6101b96004803603602081101561057457600080fd5b50356001600160a01b0316610ef6565b61058c610f52565b60025442106105cc5760405162461bcd60e51b81526004018080602001828103825260298152602001806112386029913960400191505060405180910390fd5b6001600160a01b03811660009081526004602052604081206105ed91611054565b6001600160a01b0381166000908152600560205260409020546006546106189163ffffffff610f9d16565b6006556001600160a01b0316600090815260056020526040812055565b61063d610f52565b600180546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce229181900360200190a150565b60008061069d83610a0e565b905060005b818110156106ca576106b48482610dc4565b156106c25791506106ce9050565b6001016106a2565b5090505b919050565b6106db610f52565b600254421061071b5760405162461bcd60e51b81526004018080602001828103825260298152602001806112386029913960400191505060405180910390fd5b81421061076f576040805162461bcd60e51b815260206004820152601a60248201527f54696d65206d75737420626520696e2074686520667574757265000000000000604482015290519081900360640190fd5b806107c1576040805162461bcd60e51b815260206004820152601760248201527f5175616e746974792063616e6e6f74206265207a65726f000000000000000000604482015290519081900360640190fd5b6006546107d4908263ffffffff610ffa16565b600655600354604080516370a0823160e01b815230600482015290516001600160a01b03909216916370a0823191602480820192602092909190829003018186803b15801561082257600080fd5b505afa158015610836573d6000803e3d6000fd5b505050506040513d602081101561084c57600080fd5b5051600654111561088e5760405162461bcd60e51b81526004018080602001828103825260478152602001806111c26047913960600191505060405180910390fd5b6001600160a01b03831660009081526004602052604090205460148111156108fd576040805162461bcd60e51b815260206004820152601c60248201527f56657374696e67207363686564756c6520697320746f6f206c6f6e6700000000604482015290519081900360640190fd5b80610922576001600160a01b03841660009081526005602052604090208290556109b7565b8261093885600161093288610a0e565b03610dc4565b106109745760405162461bcd60e51b815260040180806020018281038252603781526020018061118b6037913960400191505060405180910390fd5b6001600160a01b03841660009081526005602052604090205461099d908363ffffffff610ffa16565b6001600160a01b0385166000908152600560205260409020555b6001600160a01b0384166000908152600460209081526040808320815180830190925286825281830186905280546001810180835591855292909320610a069260029081029091019190611078565b505050505050565b6001600160a01b031660009081526004602052604090205490565b60056020526000908152604090205481565b610a436110b6565b6000610a4e83610691565b9050610a5983610a0e565b811415610a7b57505060408051808201909152600080825260208201526106ce565b610a858382610e74565b9392505050565b6000610a9733610a0e565b90506000805b82811015610b3c576000610ab13383610dc4565b905042811115610ac15750610b3c565b6000610acd3384610ee3565b90508015610b3257604080518082018252600080825260208083018290523382526004905291909120805485908110610b0257fe5b9060005260206000209060020201906002610b1e9291906110d4565b50610b2f848263ffffffff610ffa16565b93505b5050600101610a9d565b508015610c4557600654610b56908263ffffffff610f9d16565b60065533600090815260056020526040902054610b79908263ffffffff610f9d16565b33600081815260056020908152604080832094909455600354845163a9059cbb60e01b815260048101949094526024840186905293516001600160a01b039094169363a9059cbb93604480820194918390030190829087803b158015610bde57600080fd5b505af1158015610bf2573d6000803e3d6000fd5b505050506040513d6020811015610c0857600080fd5b50506040805142815260208101839052815133927ffbeff59d2bfda0d79ea8a29f8c57c66d48c7a13eabbdb90908d9115ec41c9dc6928290030190a25b5050565b60046020528260005260406000208281548110610c6257fe5b90600052602060002090600202018160028110610c7b57fe5b0154925083915050565b60025481565b6001546001600160a01b031681565b600081565b6000610caa82610a3b565b60005b602002015192915050565b6001600160a01b031660009081526005602052604090205490565b6003546001600160a01b031681565b6001546001600160a01b03163314610d2b5760405162461bcd60e51b81526004018080602001828103825260358152602001806111566035913960400191505060405180910390fd5b600054600154604080516001600160a01b03938416815292909116602083015280517fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9281900390910190a160018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b600181565b6000546001600160a01b031681565b6000610dbd82610a3b565b6001610cad565b6000610dd08383610e74565b60005b60200201519392505050565b60065481565b610ded610f52565b6002544210610e2d5760405162461bcd60e51b81526004018080602001828103825260298152602001806112386029913960400191505060405180910390fd5b60005b83811015610a0657610e6786868684818110610e4857fe5b90506020020135858585818110610e5b57fe5b905060200201356106d3565b600101610e30565b601481565b610e7c6110b6565b6001600160a01b0383166000908152600460205260409020805483908110610ea057fe5b600091825260209091206040805180820191829052926002908102909201919082845b815481526020019060010190808311610ec3575050505050905092915050565b6000610eef8383610e74565b6001610dd3565b610efe610f52565b600380546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f46e9c68bd7831071bdd478f1ae4c4a52463961a9d620383a0a121dbfc0e0f06d9181900360200190a150565b6000546001600160a01b03163314610f9b5760405162461bcd60e51b815260040180806020018281038252602f815260200180611209602f913960400191505060405180910390fd5b565b600082821115610ff4576040805162461bcd60e51b815260206004820152601e60248201527f536166654d6174683a207375627472616374696f6e206f766572666c6f770000604482015290519081900360640190fd5b50900390565b600082820183811015610a85576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b50805460008255600202906000526020600020908101906110759190611107565b50565b82600281019282156110a6579160200282015b828111156110a657825182559160200191906001019061108b565b506110b292915061112d565b5090565b60405180604001604052806002906020820280388339509192915050565b82600281019282156110a6579160200282015b828111156110a6578251829060ff169055916020019190600101906110e7565b61112a91905b808211156110b25760006111218282611147565b5060020161110d565b90565b61112a91905b808211156110b25760008155600101611133565b50600081556001016000905556fe596f75206d757374206265206e6f6d696e61746564206265666f726520796f752063616e20616363657074206f776e65727368697043616e6e6f7420616464206e65772076657374656420656e7472696573206561726c696572207468616e20746865206c617374206f6e654d75737420626520656e6f7567682062616c616e636520696e2074686520636f6e747261637420746f2070726f7669646520666f72207468652076657374696e6720656e7472794f6e6c792074686520636f6e7472616374206f776e6572206d617920706572666f726d207468697320616374696f6e43616e206f6e6c7920706572666f726d207468697320616374696f6e20647572696e67207365747570a265627a7a72315820f19bb5842e466642d3f0921e9e4a3fcbe6815bb5068e1a1ba08e0047b1f2528164736f6c6343000510003200000000000000000000000048914229dedd5a9922f44441ffccfc2cb7856ee90000000000000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061018e5760003560e01c806370a08231116100de5780639b217f9011610097578063d0cc82e311610071578063d0cc82e3146104fe578063da7bd3e914610506578063ee1d036c14610532578063fec9f9da1461055e5761018e565b80639b217f90146103f8578063a15d59ce14610424578063bb2a7d0c1461042c5761018e565b806370a082311461038c578063759b5225146103b257806379ba5097146103ba5780638ad58777146103c25780638da5cb5b146103ca57806397f46527146103d25761018e565b80632f5bb6611161014b57806346ba2d901161012557806346ba2d901461033257806353a47bb71461033a57806363667eb71461035e5780636b3905c4146103665761018e565b80632f5bb66114610297578063458efde3146102f857806345e5441f146103005761018e565b8063135c0701146101935780631627540c146101bb57806319e740c0146101e15780631bb47b4414610219578063204b676a1461024b578063227d517a14610271575b600080fd5b6101b9600480360360208110156101a957600080fd5b50356001600160a01b0316610584565b005b6101b9600480360360208110156101d157600080fd5b50356001600160a01b0316610635565b610207600480360360208110156101f757600080fd5b50356001600160a01b0316610691565b60408051918252519081900360200190f35b6101b96004803603606081101561022f57600080fd5b506001600160a01b0381351690602081013590604001356106d3565b6102076004803603602081101561026157600080fd5b50356001600160a01b0316610a0e565b6102076004803603602081101561028757600080fd5b50356001600160a01b0316610a29565b6102bd600480360360208110156102ad57600080fd5b50356001600160a01b0316610a3b565b6040518082600260200280838360005b838110156102e55781810151838201526020016102cd565b5050505090500191505060405180910390f35b6101b9610a8c565b6102076004803603606081101561031657600080fd5b506001600160a01b038135169060208101359060400135610c49565b610207610c85565b610342610c8b565b604080516001600160a01b039092168252519081900360200190f35b610207610c9a565b6102076004803603602081101561037c57600080fd5b50356001600160a01b0316610c9f565b610207600480360360208110156103a257600080fd5b50356001600160a01b0316610cb8565b610342610cd3565b6101b9610ce2565b610207610d9e565b610342610da3565b610207600480360360208110156103e857600080fd5b50356001600160a01b0316610db2565b6102076004803603604081101561040e57600080fd5b506001600160a01b038135169060200135610dc4565b610207610ddf565b6101b96004803603606081101561044257600080fd5b6001600160a01b03823516919081019060408101602082013564010000000081111561046d57600080fd5b82018360208201111561047f57600080fd5b803590602001918460208302840111640100000000831117156104a157600080fd5b9193909290916020810190356401000000008111156104bf57600080fd5b8201836020820111156104d157600080fd5b803590602001918460208302840111640100000000831117156104f357600080fd5b509092509050610de5565b610207610e6f565b6102bd6004803603604081101561051c57600080fd5b506001600160a01b038135169060200135610e74565b6102076004803603604081101561054857600080fd5b506001600160a01b038135169060200135610ee3565b6101b96004803603602081101561057457600080fd5b50356001600160a01b0316610ef6565b61058c610f52565b60025442106105cc5760405162461bcd60e51b81526004018080602001828103825260298152602001806112386029913960400191505060405180910390fd5b6001600160a01b03811660009081526004602052604081206105ed91611054565b6001600160a01b0381166000908152600560205260409020546006546106189163ffffffff610f9d16565b6006556001600160a01b0316600090815260056020526040812055565b61063d610f52565b600180546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce229181900360200190a150565b60008061069d83610a0e565b905060005b818110156106ca576106b48482610dc4565b156106c25791506106ce9050565b6001016106a2565b5090505b919050565b6106db610f52565b600254421061071b5760405162461bcd60e51b81526004018080602001828103825260298152602001806112386029913960400191505060405180910390fd5b81421061076f576040805162461bcd60e51b815260206004820152601a60248201527f54696d65206d75737420626520696e2074686520667574757265000000000000604482015290519081900360640190fd5b806107c1576040805162461bcd60e51b815260206004820152601760248201527f5175616e746974792063616e6e6f74206265207a65726f000000000000000000604482015290519081900360640190fd5b6006546107d4908263ffffffff610ffa16565b600655600354604080516370a0823160e01b815230600482015290516001600160a01b03909216916370a0823191602480820192602092909190829003018186803b15801561082257600080fd5b505afa158015610836573d6000803e3d6000fd5b505050506040513d602081101561084c57600080fd5b5051600654111561088e5760405162461bcd60e51b81526004018080602001828103825260478152602001806111c26047913960600191505060405180910390fd5b6001600160a01b03831660009081526004602052604090205460148111156108fd576040805162461bcd60e51b815260206004820152601c60248201527f56657374696e67207363686564756c6520697320746f6f206c6f6e6700000000604482015290519081900360640190fd5b80610922576001600160a01b03841660009081526005602052604090208290556109b7565b8261093885600161093288610a0e565b03610dc4565b106109745760405162461bcd60e51b815260040180806020018281038252603781526020018061118b6037913960400191505060405180910390fd5b6001600160a01b03841660009081526005602052604090205461099d908363ffffffff610ffa16565b6001600160a01b0385166000908152600560205260409020555b6001600160a01b0384166000908152600460209081526040808320815180830190925286825281830186905280546001810180835591855292909320610a069260029081029091019190611078565b505050505050565b6001600160a01b031660009081526004602052604090205490565b60056020526000908152604090205481565b610a436110b6565b6000610a4e83610691565b9050610a5983610a0e565b811415610a7b57505060408051808201909152600080825260208201526106ce565b610a858382610e74565b9392505050565b6000610a9733610a0e565b90506000805b82811015610b3c576000610ab13383610dc4565b905042811115610ac15750610b3c565b6000610acd3384610ee3565b90508015610b3257604080518082018252600080825260208083018290523382526004905291909120805485908110610b0257fe5b9060005260206000209060020201906002610b1e9291906110d4565b50610b2f848263ffffffff610ffa16565b93505b5050600101610a9d565b508015610c4557600654610b56908263ffffffff610f9d16565b60065533600090815260056020526040902054610b79908263ffffffff610f9d16565b33600081815260056020908152604080832094909455600354845163a9059cbb60e01b815260048101949094526024840186905293516001600160a01b039094169363a9059cbb93604480820194918390030190829087803b158015610bde57600080fd5b505af1158015610bf2573d6000803e3d6000fd5b505050506040513d6020811015610c0857600080fd5b50506040805142815260208101839052815133927ffbeff59d2bfda0d79ea8a29f8c57c66d48c7a13eabbdb90908d9115ec41c9dc6928290030190a25b5050565b60046020528260005260406000208281548110610c6257fe5b90600052602060002090600202018160028110610c7b57fe5b0154925083915050565b60025481565b6001546001600160a01b031681565b600081565b6000610caa82610a3b565b60005b602002015192915050565b6001600160a01b031660009081526005602052604090205490565b6003546001600160a01b031681565b6001546001600160a01b03163314610d2b5760405162461bcd60e51b81526004018080602001828103825260358152602001806111566035913960400191505060405180910390fd5b600054600154604080516001600160a01b03938416815292909116602083015280517fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9281900390910190a160018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b600181565b6000546001600160a01b031681565b6000610dbd82610a3b565b6001610cad565b6000610dd08383610e74565b60005b60200201519392505050565b60065481565b610ded610f52565b6002544210610e2d5760405162461bcd60e51b81526004018080602001828103825260298152602001806112386029913960400191505060405180910390fd5b60005b83811015610a0657610e6786868684818110610e4857fe5b90506020020135858585818110610e5b57fe5b905060200201356106d3565b600101610e30565b601481565b610e7c6110b6565b6001600160a01b0383166000908152600460205260409020805483908110610ea057fe5b600091825260209091206040805180820191829052926002908102909201919082845b815481526020019060010190808311610ec3575050505050905092915050565b6000610eef8383610e74565b6001610dd3565b610efe610f52565b600380546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f46e9c68bd7831071bdd478f1ae4c4a52463961a9d620383a0a121dbfc0e0f06d9181900360200190a150565b6000546001600160a01b03163314610f9b5760405162461bcd60e51b815260040180806020018281038252602f815260200180611209602f913960400191505060405180910390fd5b565b600082821115610ff4576040805162461bcd60e51b815260206004820152601e60248201527f536166654d6174683a207375627472616374696f6e206f766572666c6f770000604482015290519081900360640190fd5b50900390565b600082820183811015610a85576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b50805460008255600202906000526020600020908101906110759190611107565b50565b82600281019282156110a6579160200282015b828111156110a657825182559160200191906001019061108b565b506110b292915061112d565b5090565b60405180604001604052806002906020820280388339509192915050565b82600281019282156110a6579160200282015b828111156110a6578251829060ff169055916020019190600101906110e7565b61112a91905b808211156110b25760006111218282611147565b5060020161110d565b90565b61112a91905b808211156110b25760008155600101611133565b50600081556001016000905556fe596f75206d757374206265206e6f6d696e61746564206265666f726520796f752063616e20616363657074206f776e65727368697043616e6e6f7420616464206e65772076657374656420656e7472696573206561726c696572207468616e20746865206c617374206f6e654d75737420626520656e6f7567682062616c616e636520696e2074686520636f6e747261637420746f2070726f7669646520666f72207468652076657374696e6720656e7472794f6e6c792074686520636f6e7472616374206f776e6572206d617920706572666f726d207468697320616374696f6e43616e206f6e6c7920706572666f726d207468697320616374696f6e20647572696e67207365747570a265627a7a72315820f19bb5842e466642d3f0921e9e4a3fcbe6815bb5068e1a1ba08e0047b1f2528164736f6c63430005100032

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

00000000000000000000000048914229dedd5a9922f44441ffccfc2cb7856ee90000000000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _owner (address): 0x48914229deDd5A9922f44441ffCCfC2Cb7856Ee9
Arg [1] : _synthetix (address): 0x0000000000000000000000000000000000000000

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 00000000000000000000000048914229dedd5a9922f44441ffccfc2cb7856ee9
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000000


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

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

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