Sponsored:   Temco - Join the Largest VC Backed ICO on the Bitcoin Network! TEMCO KYC Whitelist Starts Now!!
Overview
Balance: 0 Ether
Ether Value: $0
Transactions: 7082 txns
 Latest 25 transactions from a total of 7082 transactions

TxHash Age From To Value [TxFee]
0xc262da1b91e8b9cff005fddcc463cf455c98137440ccd83f9a57f52f8acc6189138 days 18 hrs ago0xb10c85274d2a58ddec72c1d826e75256ff93dead  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000200343
0xf104b79f4d2f4e4f58e3ed0ba67d25dc33efece88c50b78aa96862daaf6eea21138 days 18 hrs ago0xb10c85274d2a58ddec72c1d826e75256ff93dead  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.00035725
0x49664842161baa09553d5e43039b28e39742b7234165033e0c2bc68d0edfe581138 days 23 hrs ago0xc20e992c35fbfd339e3aa50cbb5bf9c4e58b97f5  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000194512
0xea57fe9b99fac7cacefa8831658e40d8ff056df0ddd7f5488e6cc6e6491889e2146 days 19 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0xf4fe0afa92efeb2afb23e370d55f52edb407bcfd91750da173d6c7d4bbc227be146 days 20 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x72696009e7fdec40cb2c251e968954c06672968a3ef0b03afe60279445741e3f146 days 20 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000140772
0xc7f5fde27c1d69e39707c5380e56a1a0e22377a4906720538d1e67d4759488f6146 days 21 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000246351
0x4c473a41027bfb561562c27ba645f9ad572e96279c93cc63cb01a220f6e1ac21146 days 21 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000246351
0xfc2de6fa86a66dd039e96cb5f3c82e016f99f8477f686c02c1d2fe9e0b037b9a146 days 22 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x67336f0c42e66c6616ffd098c2f1c0a235eba9af828ff3efb6fdf37105545564146 days 22 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x1c61f3a69c194bddaf19298de2e5cf263c5a7dba9a839ae92271f0101b25259a146 days 23 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000140772
0x95ab0ec4bcbe92ff7d5e5f725f385914e24b497d520e6d91ab3a0b6c4a42aef4146 days 23 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x9c0dd89153463d61544995e096b40cae51887c7e6265f6d559441d1034cbe9eb147 days 18 mins ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000140772
0x725b5fa82a55aae9bfb709e7a345293954f32e61db268c53c37149900dbdc1cb147 days 50 mins ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x7d9cb8927a0bcc5ec9e3854fd105acaff7699e93b44f5fea5d92d63a78ee227b147 days 1 hr ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0xe11378240088ea3095a0ce0569ae1224a1fd6c22875d0ed46aa482707fd6dd23147 days 1 hr ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000140772
0x2a9cb6d8d7219b3c03e1259e9409ed070e23d5cd0e223b05c7c4906071f5529c147 days 2 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000140772
0xb6c10f09c39f69981a8429a2487798179cc99e30f5ccabe2eb91ea7507f0a6b9147 days 2 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000211158
0xb267abd595c474cce57052214806134efb67623a8bb331f60e62e992bd916da2147 days 3 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000211158
0x24dc7561bb44a64da565984dc1a75953fa901e83dfed4cfa08725183d046290c147 days 3 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000140772
0xe4a1fa32b5ddad2587404a81350f69f232e24d4cae81a642eca149355e4b8b5d147 days 4 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x545046b3535a31939f3c54144a94487b49108b5237347c30dd8016591edf0aaa147 days 4 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x834006d869f3bc0743dc91c7d125a47dcf50bc2e412d34236d41b011072bab2a147 days 5 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000210774
0xccfc55dafc4765aa0e208143150aa1d2048b4f5153991e2ffd757ffc02712cb1147 days 5 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000175965
0x2fab12394b826d74d9ab35c2f9858b6d3705246a3f6b11633cde46aff2d99c91147 days 6 hrs ago0xb10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b  IN   0x523630976eb6147621b5c31c781ebe2ec2a806e00 Ether0.000210774
[ Download CSV Export  ] 
 Internal Transactions as a result of Contract Execution
 Latest 25 Internal Txns, Click here To View More View All
ParentTxHash Block Age From To Value
0xc262da1b91e8b9cff005fddcc463cf455c98137440ccd83f9a57f52f8acc61896037601138 days 18 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x49be88f0fcc3a8393a59d3688480d7d253c37d2a708.827568880910056283 Ether
0x49664842161baa09553d5e43039b28e39742b7234165033e0c2bc68d0edfe5816036272138 days 23 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xc20e992c35fbfd339e3aa50cbb5bf9c4e58b97f50.1443616988291836 Ether
0x75d6bd0cdcb2b864939375a61989b5359093714d29508481b0859129e5fa31905929795157 days 1 hr ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xa09e7838e188814640c01d2d135be2c919f451fa0.020319940853524912 Ether
0x301385bc84c501f1d0f122210ecea8dd80abfd06d9705a219b4fd3f3844e50bd5927977157 days 8 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x18c672e9e14c617f27aae4dd806f8bc24d8096230.001405844782727315 Ether
0xa6cfba869fe4dd6aa47f4a760ebadef441f0b997174b4e57886ee2564a811c4d5910938160 days 7 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x6475ccd47d2572ce4a739e023c75025b8f600e340.046332664220203219 Ether
0xafd097c398212ddd8a5b9d106ec0b24e8c88d66bcc52a95fd3eb2625159d314c5874984166 days 10 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x7c98de0fd0b100027d9714bbb4b6e1a025da60be0.02929416649132081 Ether
0x1739ada35ddec394fc38a6c77dda47e042e6a9b68f4ab71b8e3f56761174ea805862026168 days 16 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x81261845d959a0d7f89429f9da68bd478f3a640a0.016201037266387975 Ether
0xccc7563c29019b6c7f10aaebb0ed7123f00d039326a10c2465572f034564edd85850585170 days 16 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xa5ba3ec5cce28b4ac575cf1dd9086f9bf0dfd9100.026545453643512204 Ether
0x6ccde4c348b50489f2d72338cc97bf012605d34386a6de84716a941299f170005811578177 days 8 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xcda16a18d3f942571e7ba81b7d2219a6802c45a10.054435574581337832 Ether
0x1698efa566d722f39edde33efb63098b5e2fa85358b535ee97c8d7343fa29f9e5785205181 days 20 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xae4287b6c28bf407afcdd5b04f2d044d45c32b230.020449702261525613 Ether
0x7804cb43f1badb40c2a3c438f1e54576662e53c8e910306ad0fd89b9210a3f145773967183 days 19 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x74415f5c83a77a3410fc3e21e5e1a4b111216c510.000941883884638845 Ether
0xce43f3d10d8c637dcc16771ade4d54ad89fc32e6a570c3c9e7dc007bba3234055767559184 days 22 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x244194fceab435e1b87a5129db4b4b308ae6f05f0.786664565393721784 Ether
0xdfcab5397cedcc226a5a2afc4aa132f51058891b362c808064315c4fac8491055751822187 days 17 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xd9ba84b9acdaa7ab4450004dfb98eee4f8a250e50.008112581466836895 Ether
0xf2933882f4aaa7d1f5dea802f5f4078b566f0e9d0b5c0d6de315ef0a3a088bcb5749414188 days 4 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xfa00cf3f32dcaacb69d23e0c7eb9ce51a7ea572f2.719835208056377395 Ether
0x73f3eb4e02441d07a377c5c52443b1cc98b7ba5ac129d6c783113d79eadf04945749235188 days 4 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x0d397b54102f0817a7ca4f11bd6f7742709091ca0.008143796431563472 Ether
0xad60bbed07743fa748da2c94da90c157685b1e6f39a0f8bd9fa2768bb84f15045742176189 days 11 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xfe24a09be662793120e7a1076047f8e6d8428e1e0.000000446311563234 Ether
0xf2dc3cc77e8b9531bf885b84b9ab902857d7f4fb44718304da8a82dd12c950045742037189 days 11 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xfe24a09be662793120e7a1076047f8e6d8428e1e0.507457694725912161 Ether
0x0c908e75c437848900612e3adade1fb12657e26cd166bed4003e00499f6645cf5736496190 days 11 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xfe24a09be662793120e7a1076047f8e6d8428e1e0.52032314570985424 Ether
0xd4f457d5b1001a796979c2084727c695ddc3c912085580a22f81382bf5b8e2175732788191 days 3 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x2b053ae11104925fee42db51843875a9712236a00.013782780795355985 Ether
0x99d169e511c6c7872262036a911e34e10f6739448366e5af19d4ba5407d400205724982192 days 12 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xfe24a09be662793120e7a1076047f8e6d8428e1e0.990049751243818756 Ether
0x063a0ca88beb139824c9be3f9973d10de248526546b57463311ec3d369afe9755717602193 days 19 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x2b053ae11104925fee42db51843875a9712236a00.006504099056178588 Ether
0xc54628e0fc3d29cd291041b9b26bfc87115f6d1f71aa6d0baa4baf72be56f4825717513193 days 20 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x2eea47f2ed59ea9c403221c1cfbe820319e202840.008449051917488308 Ether
0x0f3b080809aa852df09ef4cb5376c71983c58752235650b1d94ae106224325e95717492193 days 20 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00x2b053ae11104925fee42db51843875a9712236a00.000011324729258632 Ether
0xd366d042180fd92cab5ee57b6d112de86119309d4c5139b68586d0622a1792195717217193 days 21 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xfe24a09be662793120e7a1076047f8e6d8428e1e0.184245265655470679 Ether
0x8f128ad4bfd49d51a9ba0ead42afe7a0fc292f529f9ddb8626120f956c2a76435717216193 days 21 hrs ago0x523630976eb6147621b5c31c781ebe2ec2a806e00xfe24a09be662793120e7a1076047f8e6d8428e1e0.182530079790124648 Ether
[ Download CSV Export  ] 
Contract Self Destruct Called At TxHash 0xc262da1b91e8b9cff005fddcc463cf455c98137440ccd83f9a57f52f8acc6189

Warning: The Compiled Contract might be susceptible to ExpExponentCleanup (medium/high-severity), EventStructWrongData (very low-severity), NestedArrayFunctionCallDecoder (medium-severity) SolidityCompiler Bugs.

Contract Source Code Verified (Exact Match)
Contract Name: EtherNomin
Compiler Text: v0.4.21+commit.dfe3193c
Optimization Enabled: Yes
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts

/*
-----------------------------------------------------------------
FILE HEADER
-----------------------------------------------------------------

file:       EtherNomin.sol
version:    1.0
authors:    Anton Jurisevic
            Dominic Romanowski
            Mike Spain

date:       2018-04-03
checked:    Mike Spain
approved:   Samuel Brooks

repo:       https://github.com/Havven/havven
commit:     fa705dd2feabc9def03bce135f6a153a4b70b111

-----------------------------------------------------------------
*/

pragma solidity ^0.4.21;

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

A contract with a limited setup period. Any function modified
with the setup modifier will cease to work after the
conclusion of the configurable-length post-construction setup period.

-----------------------------------------------------------------
*/

contract LimitedSetup {

    uint setupExpiryTime;

    function LimitedSetup(uint setupDuration)
        public
    {
        setupExpiryTime = now + setupDuration;
    }

    modifier setupFunction
    {
        require(now < setupExpiryTime);
        _;
    }
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

An Owned contract, to be inherited by other contracts.
Requires its owner to be explicitly set in the constructor.
Provides an onlyOwner access modifier.

To change owner, the current owner must nominate the next owner,
who then has to accept the nomination. The nomination can be
cancelled before it is accepted by the new owner by having the
previous owner change the nomination (setting it to 0).

-----------------------------------------------------------------
*/

contract Owned {
    address public owner;
    address public nominatedOwner;

    function Owned(address _owner)
        public
    {
        owner = _owner;
    }

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

    function acceptOwnership()
        external
    {
        require(msg.sender == nominatedOwner);
        emit OwnerChanged(owner, nominatedOwner);
        owner = nominatedOwner;
        nominatedOwner = address(0);
    }

    modifier onlyOwner
    {
        require(msg.sender == owner);
        _;
    }

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

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

A proxy contract that, if it does not recognise the function
being called on it, passes all value and call data to an
underlying target contract.

-----------------------------------------------------------------
*/

contract Proxy is Owned {
    Proxyable target;

    function Proxy(Proxyable _target, address _owner)
        Owned(_owner)
        public
    {
        target = _target;
        emit TargetChanged(_target);
    }

    function _setTarget(address _target) 
        external
        onlyOwner
    {
        require(_target != address(0));
        target = Proxyable(_target);
        emit TargetChanged(_target);
    }

    function () 
        public
        payable
    {
        target.setMessageSender(msg.sender);
        assembly {
            // Copy call data into free memory region.
            let free_ptr := mload(0x40)
            calldatacopy(free_ptr, 0, calldatasize)

            // Forward all gas, ether, and data to the target contract.
            let result := call(gas, sload(target_slot), callvalue, free_ptr, calldatasize, 0, 0)
            returndatacopy(free_ptr, 0, returndatasize)

            // Revert if the call failed, otherwise return the result.
            if iszero(result) { revert(free_ptr, calldatasize) }
            return(free_ptr, returndatasize)
        } 
    }

    event TargetChanged(address targetAddress);
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

This contract contains the Proxyable interface.
Any contract the proxy wraps must implement this, in order
for the proxy to be able to pass msg.sender into the underlying
contract as the state parameter, messageSender.

-----------------------------------------------------------------
*/

contract Proxyable is Owned {
    // the proxy this contract exists behind.
    Proxy public proxy;

    // The caller of the proxy, passed through to this contract.
    // Note that every function using this member must apply the onlyProxy or
    // optionalProxy modifiers, otherwise their invocations can use stale values.
    address messageSender;

    function Proxyable(address _owner)
        Owned(_owner)
        public { }

    function setProxy(Proxy _proxy)
        external
        onlyOwner
    {
        proxy = _proxy;
        emit ProxyChanged(_proxy);
    }

    function setMessageSender(address sender)
        external
        onlyProxy
    {
        messageSender = sender;
    }

    modifier onlyProxy
    {
        require(Proxy(msg.sender) == proxy);
        _;
    }

    modifier optionalProxy
    {
        if (Proxy(msg.sender) != proxy) {
            messageSender = msg.sender;
        }
        _;
    }

    // Combine the optionalProxy and onlyOwner_Proxy modifiers.
    // This is slightly cheaper and safer, since there is an ordering requirement.
    modifier optionalProxy_onlyOwner
    {
        if (Proxy(msg.sender) != proxy) {
            messageSender = msg.sender;
        }
        require(messageSender == owner);
        _;
    }

    event ProxyChanged(address proxyAddress);

}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

A fixed point decimal library that provides basic mathematical
operations, and checks for unsafe arguments, for example that
would lead to overflows.

Exceptions are thrown whenever those unsafe operations
occur.

-----------------------------------------------------------------
*/

contract SafeDecimalMath {

    // Number of decimal places in the representation.
    uint8 public constant decimals = 18;

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

    /* True iff adding x and y will not overflow. */
    function addIsSafe(uint x, uint y)
        pure
        internal
        returns (bool)
    {
        return x + y >= y;
    }

    /* Return the result of adding x and y, throwing an exception in case of overflow. */
    function safeAdd(uint x, uint y)
        pure
        internal
        returns (uint)
    {
        require(x + y >= y);
        return x + y;
    }

    /* True iff subtracting y from x will not overflow in the negative direction. */
    function subIsSafe(uint x, uint y)
        pure
        internal
        returns (bool)
    {
        return y <= x;
    }

    /* Return the result of subtracting y from x, throwing an exception in case of overflow. */
    function safeSub(uint x, uint y)
        pure
        internal
        returns (uint)
    {
        require(y <= x);
        return x - y;
    }

    /* True iff multiplying x and y would not overflow. */
    function mulIsSafe(uint x, uint y)
        pure
        internal
        returns (bool)
    {
        if (x == 0) {
            return true;
        }
        return (x * y) / x == y;
    }

    /* Return the result of multiplying x and y, throwing an exception in case of overflow.*/
    function safeMul(uint x, uint y)
        pure
        internal
        returns (uint)
    {
        if (x == 0) {
            return 0;
        }
        uint p = x * y;
        require(p / x == y);
        return p;
    }

    /* Return the result of multiplying x and y, interpreting the operands as fixed-point
     * demicimals. Throws an exception in case of overflow. A unit factor is divided out
     * after the product of x and y is evaluated, so that product must be less than 2**256.
     * 
     * Incidentally, the internal division always rounds down: we could have rounded to the nearest integer,
     * but then we would be spending a significant fraction of a cent (of order a microether
     * at present gas prices) in order to save less than one part in 0.5 * 10^18 per operation, if the operands
     * contain small enough fractional components. It would also marginally diminish the 
     * domain this function is defined upon. 
     */
    function safeMul_dec(uint x, uint y)
        pure
        internal
        returns (uint)
    {
        // Divide by UNIT to remove the extra factor introduced by the product.
        // UNIT be 0.
        return safeMul(x, y) / UNIT;

    }

    /* True iff the denominator of x/y is nonzero. */
    function divIsSafe(uint x, uint y)
        pure
        internal
        returns (bool)
    {
        return y != 0;
    }

    /* Return the result of dividing x by y, throwing an exception if the divisor is zero. */
    function safeDiv(uint x, uint y)
        pure
        internal
        returns (uint)
    {
        // Although a 0 denominator already throws an exception,
        // it is equivalent to a THROW operation, which consumes all gas.
        // A require statement emits REVERT instead, which remits remaining gas.
        require(y != 0);
        return x / y;
    }

    /* Return the result of dividing x by y, interpreting the operands as fixed point decimal numbers.
     * Throws an exception in case of overflow or zero divisor; x must be less than 2^256 / UNIT.
     * Internal rounding is downward: a similar caveat holds as with safeDecMul().*/
    function safeDiv_dec(uint x, uint y)
        pure
        internal
        returns (uint)
    {
        // Reintroduce the UNIT factor that will be divided out by y.
        return safeDiv(safeMul(x, UNIT), y);
    }

    /* Convert an unsigned integer to a unsigned fixed-point decimal.
     * Throw an exception if the result would be out of range. */
    function intToDec(uint i)
        pure
        internal
        returns (uint)
    {
        return safeMul(i, UNIT);
    }
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

This provides the nomin contract with a confiscation
facility, if enough havven owners vote to confiscate a target
account's nomins.

This is designed to provide a mechanism to respond to abusive
contracts such as nomin wrappers, which would allow users to
trade wrapped nomins without accruing fees on those transactions.

In order to prevent tyranny, an account may only be frozen if
users controlling at least 30% of the value of havvens participate,
and a two thirds majority is attained in that vote.
In order to prevent tyranny of the majority or mob justice,
confiscation motions are only approved if the havven foundation
approves the result.
This latter requirement may be lifted in future versions.

The foundation, or any user with a sufficient havven balance may bring a
confiscation motion.
A motion lasts for a default period of one week, with a further confirmation
period in which the foundation approves the result.
The latter period may conclude early upon the foundation's decision to either
veto or approve the mooted confiscation motion.
If the confirmation period elapses without the foundation making a decision,
the motion fails.

The weight of a havven holder's vote is determined by examining their
average balance over the last completed fee period prior to the
beginning of a given motion.
Thus, since a fee period can roll over in the middle of a motion, we must
also track a user's average balance of the last two periods.
This system is designed such that it cannot be attacked by users transferring
funds between themselves, while also not requiring them to lock their havvens
for the duration of the vote. This is possible since any transfer that increases
the average balance in one account will be reflected by an equivalent reduction
in the voting weight in the other.
At present a user may cast a vote only for one motion at a time,
but may cancel their vote at any time except during the confirmation period,
when the vote tallies must remain static until the matter has been settled.

A motion to confiscate the balance of a given address composes
a state machine built of the following states:


Waiting:
  - A user with standing brings a motion:
    If the target address is not frozen;
    initialise vote tallies to 0;
    transition to the Voting state.

  - An account cancels a previous residual vote:
    remain in the Waiting state.

Voting:
  - The foundation vetoes the in-progress motion:
    transition to the Waiting state.

  - The voting period elapses:
    transition to the Confirmation state.

  - An account votes (for or against the motion):
    its weight is added to the appropriate tally;
    remain in the Voting state.

  - An account cancels its previous vote:
    its weight is deducted from the appropriate tally (if any);
    remain in the Voting state.

Confirmation:
  - The foundation vetoes the completed motion:
    transition to the Waiting state.

  - The foundation approves confiscation of the target account:
    freeze the target account, transfer its nomin balance to the fee pool;
    transition to the Waiting state.

  - The confirmation period elapses:
    transition to the Waiting state.


User votes are not automatically cancelled upon the conclusion of a motion.
Therefore, after a motion comes to a conclusion, if a user wishes to vote 
in another motion, they must manually cancel their vote in order to do so.

This procedure is designed to be relatively simple.
There are some things that can be added to enhance the functionality
at the expense of simplicity and efficiency:
  
  - Democratic unfreezing of nomin accounts (induces multiple categories of vote)
  - Configurable per-vote durations;
  - Vote standing denominated in a fiat quantity rather than a quantity of havvens;
  - Confiscate from multiple addresses in a single vote;

We might consider updating the contract with any of these features at a later date if necessary.

-----------------------------------------------------------------
*/

contract Court is Owned, SafeDecimalMath {

    /* ========== STATE VARIABLES ========== */

    // The addresses of the token contracts this confiscation court interacts with.
    Havven public havven;
    EtherNomin public nomin;

    // The minimum havven balance required to be considered to have standing
    // to begin confiscation proceedings.
    uint public minStandingBalance = 100 * UNIT;

    // The voting period lasts for this duration,
    // and if set, must fall within the given bounds.
    uint public votingPeriod = 1 weeks;
    uint constant MIN_VOTING_PERIOD = 3 days;
    uint constant MAX_VOTING_PERIOD = 4 weeks;

    // Duration of the period during which the foundation may confirm
    // or veto a motion that has concluded.
    // If set, the confirmation duration must fall within the given bounds.
    uint public confirmationPeriod = 1 weeks;
    uint constant MIN_CONFIRMATION_PERIOD = 1 days;
    uint constant MAX_CONFIRMATION_PERIOD = 2 weeks;

    // No fewer than this fraction of havvens must participate in a motion
    // in order for a quorum to be reached.
    // The participation fraction required may be set no lower than 10%.
    uint public requiredParticipation = 3 * UNIT / 10;
    uint constant MIN_REQUIRED_PARTICIPATION = UNIT / 10;

    // At least this fraction of participating votes must be in favour of
    // confiscation for the motion to pass.
    // The required majority may be no lower than 50%.
    uint public requiredMajority = (2 * UNIT) / 3;
    uint constant MIN_REQUIRED_MAJORITY = UNIT / 2;

    // The next ID to use for opening a motion.
    uint nextMotionID = 1;

    // Mapping from motion IDs to target addresses.
    mapping(uint => address) public motionTarget;

    // The ID a motion on an address is currently operating at.
    // Zero if no such motion is running.
    mapping(address => uint) public targetMotionID;

    // The timestamp at which a motion began. This is used to determine
    // whether a motion is: running, in the confirmation period,
    // or has concluded.
    // A motion runs from its start time t until (t + votingPeriod),
    // and then the confirmation period terminates no later than
    // (t + votingPeriod + confirmationPeriod).
    mapping(uint => uint) public motionStartTime;

    // The tallies for and against confiscation of a given balance.
    // These are set to zero at the start of a motion, and also on conclusion,
    // just to keep the state clean.
    mapping(uint => uint) public votesFor;
    mapping(uint => uint) public votesAgainst;

    // The last/penultimate average balance of a user at the time they voted
    // in a particular motion.
    // If we did not save this information then we would have to
    // disallow transfers into an account lest it cancel a vote
    // with greater weight than that with which it originally voted,
    // and the fee period rolled over in between.
    mapping(address => mapping(uint => uint)) voteWeight;

    // The possible vote types.
    // Abstention: not participating in a motion; This is the default value.
    // Yea: voting in favour of a motion.
    // Nay: voting against a motion.
    enum Vote {Abstention, Yea, Nay}

    // A given account's vote in some confiscation motion.
    // This requires the default value of the Vote enum to correspond to an abstention.
    mapping(address => mapping(uint => Vote)) public vote;

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

    function Court(Havven _havven, EtherNomin _nomin, address _owner)
        Owned(_owner)
        public
    {
        havven = _havven;
        nomin = _nomin;
    }


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

    function setMinStandingBalance(uint balance)
        external
        onlyOwner
    {
        // No requirement on the standing threshold here;
        // the foundation can set this value such that
        // anyone or no one can actually start a motion.
        minStandingBalance = balance;
    }

    function setVotingPeriod(uint duration)
        external
        onlyOwner
    {
        require(MIN_VOTING_PERIOD <= duration &&
                duration <= MAX_VOTING_PERIOD);
        // Require that the voting period is no longer than a single fee period,
        // So that a single vote can span at most two fee periods.
        require(duration <= havven.targetFeePeriodDurationSeconds());
        votingPeriod = duration;
    }

    function setConfirmationPeriod(uint duration)
        external
        onlyOwner
    {
        require(MIN_CONFIRMATION_PERIOD <= duration &&
                duration <= MAX_CONFIRMATION_PERIOD);
        confirmationPeriod = duration;
    }

    function setRequiredParticipation(uint fraction)
        external
        onlyOwner
    {
        require(MIN_REQUIRED_PARTICIPATION <= fraction);
        requiredParticipation = fraction;
    }

    function setRequiredMajority(uint fraction)
        external
        onlyOwner
    {
        require(MIN_REQUIRED_MAJORITY <= fraction);
        requiredMajority = fraction;
    }


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

    /* There is a motion in progress on the specified
     * account, and votes are being accepted in that motion. */
    function motionVoting(uint motionID)
        public
        view
        returns (bool)
    {
        // No need to check (startTime < now) as there is no way
        // to set future start times for votes.
        // These values are timestamps, they will not overflow
        // as they can only ever be initialised to relatively small values.
        return now < motionStartTime[motionID] + votingPeriod;
    }

    /* A vote on the target account has concluded, but the motion
     * has not yet been approved, vetoed, or closed. */
    function motionConfirming(uint motionID)
        public
        view
        returns (bool)
    {
        // These values are timestamps, they will not overflow
        // as they can only ever be initialised to relatively small values.
        uint startTime = motionStartTime[motionID];
        return startTime + votingPeriod <= now &&
               now < startTime + votingPeriod + confirmationPeriod;
    }

    /* A vote motion either not begun, or it has completely terminated. */
    function motionWaiting(uint motionID)
        public
        view
        returns (bool)
    {
        // These values are timestamps, they will not overflow
        // as they can only ever be initialised to relatively small values.
        return motionStartTime[motionID] + votingPeriod + confirmationPeriod <= now;
    }

    /* If the motion was to terminate at this instant, it would pass.
     * That is: there was sufficient participation and a sizeable enough majority. */
    function motionPasses(uint motionID)
        public
        view
        returns (bool)
    {
        uint yeas = votesFor[motionID];
        uint nays = votesAgainst[motionID];
        uint totalVotes = safeAdd(yeas, nays);

        if (totalVotes == 0) {
            return false;
        }

        uint participation = safeDiv_dec(totalVotes, havven.totalSupply());
        uint fractionInFavour = safeDiv_dec(yeas, totalVotes);

        // We require the result to be strictly greater than the requirement
        // to enforce a majority being "50% + 1", and so on.
        return participation > requiredParticipation &&
               fractionInFavour > requiredMajority;
    }

    function hasVoted(address account, uint motionID)
        public
        view
        returns (bool)
    {
        return vote[account][motionID] != Vote.Abstention;
    }


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

    /* Begin a motion to confiscate the funds in a given nomin account.
     * Only the foundation, or accounts with sufficient havven balances
     * may elect to start such a motion.
     * Returns the ID of the motion that was begun. */
    function beginMotion(address target)
        external
        returns (uint)
    {
        // A confiscation motion must be mooted by someone with standing.
        require((havven.balanceOf(msg.sender) >= minStandingBalance) ||
                msg.sender == owner);

        // Require that the voting period is longer than a single fee period,
        // So that a single vote can span at most two fee periods.
        require(votingPeriod <= havven.targetFeePeriodDurationSeconds());

        // There must be no confiscation motion already running for this account.
        require(targetMotionID[target] == 0);

        // Disallow votes on accounts that have previously been frozen.
        require(!nomin.frozen(target));

        uint motionID = nextMotionID++;
        motionTarget[motionID] = target;
        targetMotionID[target] = motionID;

        motionStartTime[motionID] = now;
        emit MotionBegun(msg.sender, msg.sender, target, target, motionID, motionID);

        return motionID;
    }

    /* Shared vote setup function between voteFor and voteAgainst.
     * Returns the voter's vote weight. */
    function setupVote(uint motionID)
        internal
        returns (uint)
    {
        // There must be an active vote for this target running.
        // Vote totals must only change during the voting phase.
        require(motionVoting(motionID));

        // The voter must not have an active vote this motion.
        require(!hasVoted(msg.sender, motionID));

        // The voter may not cast votes on themselves.
        require(msg.sender != motionTarget[motionID]);

        // Ensure the voter's vote weight is current.
        havven.recomputeAccountLastAverageBalance(msg.sender);

        uint weight;
        // We use a fee period guaranteed to have terminated before
        // the start of the vote. Select the right period if
        // a fee period rolls over in the middle of the vote.
        if (motionStartTime[motionID] < havven.feePeriodStartTime()) {
            weight = havven.penultimateAverageBalance(msg.sender);
        } else {
            weight = havven.lastAverageBalance(msg.sender);
        }

        // Users must have a nonzero voting weight to vote.
        require(weight > 0);

        voteWeight[msg.sender][motionID] = weight;

        return weight;
    }

    /* The sender casts a vote in favour of confiscation of the
     * target account's nomin balance. */
    function voteFor(uint motionID)
        external
    {
        uint weight = setupVote(motionID);
        vote[msg.sender][motionID] = Vote.Yea;
        votesFor[motionID] = safeAdd(votesFor[motionID], weight);
        emit VotedFor(msg.sender, msg.sender, motionID, motionID, weight);
    }

    /* The sender casts a vote against confiscation of the
     * target account's nomin balance. */
    function voteAgainst(uint motionID)
        external
    {
        uint weight = setupVote(motionID);
        vote[msg.sender][motionID] = Vote.Nay;
        votesAgainst[motionID] = safeAdd(votesAgainst[motionID], weight);
        emit VotedAgainst(msg.sender, msg.sender, motionID, motionID, weight);
    }

    /* Cancel an existing vote by the sender on a motion
     * to confiscate the target balance. */
    function cancelVote(uint motionID)
        external
    {
        // An account may cancel its vote either before the confirmation phase
        // when the motion is still open, or after the confirmation phase,
        // when the motion has concluded.
        // But the totals must not change during the confirmation phase itself.
        require(!motionConfirming(motionID));

        Vote senderVote = vote[msg.sender][motionID];

        // If the sender has not voted then there is no need to update anything.
        require(senderVote != Vote.Abstention);

        // If we are not voting, there is no reason to update the vote totals.
        if (motionVoting(motionID)) {
            if (senderVote == Vote.Yea) {
                votesFor[motionID] = safeSub(votesFor[motionID], voteWeight[msg.sender][motionID]);
            } else {
                // Since we already ensured that the vote is not an abstention,
                // the only option remaining is Vote.Nay.
                votesAgainst[motionID] = safeSub(votesAgainst[motionID], voteWeight[msg.sender][motionID]);
            }
            // A cancelled vote is only meaningful if a vote is running
            emit VoteCancelled(msg.sender, msg.sender, motionID, motionID);
        }

        delete voteWeight[msg.sender][motionID];
        delete vote[msg.sender][motionID];
    }

    function _closeMotion(uint motionID)
        internal
    {
        delete targetMotionID[motionTarget[motionID]];
        delete motionTarget[motionID];
        delete motionStartTime[motionID];
        delete votesFor[motionID];
        delete votesAgainst[motionID];
        emit MotionClosed(motionID, motionID);
    }

    /* If a motion has concluded, or if it lasted its full duration but not passed,
     * then anyone may close it. */
    function closeMotion(uint motionID)
        external
    {
        require((motionConfirming(motionID) && !motionPasses(motionID)) || motionWaiting(motionID));
        _closeMotion(motionID);
    }

    /* The foundation may only confiscate a balance during the confirmation
     * period after a motion has passed. */
    function approveMotion(uint motionID)
        external
        onlyOwner
    {
        require(motionConfirming(motionID) && motionPasses(motionID));
        address target = motionTarget[motionID];
        nomin.confiscateBalance(target);
        _closeMotion(motionID);
        emit MotionApproved(motionID, motionID);
    }

    /* The foundation may veto a motion at any time. */
    function vetoMotion(uint motionID)
        external
        onlyOwner
    {
        require(!motionWaiting(motionID));
        _closeMotion(motionID);
        emit MotionVetoed(motionID, motionID);
    }


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

    event MotionBegun(address initiator, address indexed initiatorIndex, address target, address indexed targetIndex, uint motionID, uint indexed motionIDIndex);

    event VotedFor(address voter, address indexed voterIndex, uint motionID, uint indexed motionIDIndex, uint weight);

    event VotedAgainst(address voter, address indexed voterIndex, uint motionID, uint indexed motionIDIndex, uint weight);

    event VoteCancelled(address voter, address indexed voterIndex, uint motionID, uint indexed motionIDIndex);

    event MotionClosed(uint motionID, uint indexed motionIDIndex);

    event MotionVetoed(uint motionID, uint indexed motionIDIndex);

    event MotionApproved(uint motionID, uint indexed motionIDIndex);
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

A token which also has a configurable fee rate
charged on its transfers. This is designed to be overridden in
order to produce an ERC20-compliant token.

These fees accrue into a pool, from which a nominated authority
may withdraw.

This contract utilises a state for upgradability purposes.
It relies on being called underneath a proxy contract, as
included in Proxy.sol.

-----------------------------------------------------------------
*/

contract ExternStateProxyFeeToken is Proxyable, SafeDecimalMath {

    /* ========== STATE VARIABLES ========== */

    // Stores balances and allowances.
    TokenState public state;

    // Other ERC20 fields
    string public name;
    string public symbol;
    uint public totalSupply;

    // A percentage fee charged on each transfer.
    uint public transferFeeRate;
    // Fee may not exceed 10%.
    uint constant MAX_TRANSFER_FEE_RATE = UNIT / 10;
    // The address with the authority to distribute fees.
    address public feeAuthority;


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

    function ExternStateProxyFeeToken(string _name, string _symbol,
                                      uint _transferFeeRate, address _feeAuthority,
                                      TokenState _state, address _owner)
        Proxyable(_owner)
        public
    {
        if (_state == TokenState(0)) {
            state = new TokenState(_owner, address(this));
        } else {
            state = _state;
        }

        name = _name;
        symbol = _symbol;
        feeAuthority = _feeAuthority;

        require(_transferFeeRate <= MAX_TRANSFER_FEE_RATE);
        transferFeeRate = _transferFeeRate;
    }

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

    function setTransferFeeRate(uint _transferFeeRate)
        external
        optionalProxy_onlyOwner
    {
        require(_transferFeeRate <= MAX_TRANSFER_FEE_RATE);
        transferFeeRate = _transferFeeRate;
        emit TransferFeeRateUpdated(_transferFeeRate);
    }

    function setFeeAuthority(address _feeAuthority)
        external
        optionalProxy_onlyOwner
    {
        feeAuthority = _feeAuthority;
        emit FeeAuthorityUpdated(_feeAuthority);
    }

    function setState(TokenState _state)
        external
        optionalProxy_onlyOwner
    {
        state = _state;
        emit StateUpdated(_state);
    }

    /* ========== VIEWS ========== */

    function balanceOf(address account)
        public
        view
        returns (uint)
    {
        return state.balanceOf(account);
    }

    function allowance(address from, address to)
        public
        view
        returns (uint)
    {
        return state.allowance(from, to);
    }

    // Return the fee charged on top in order to transfer _value worth of tokens.
    function transferFeeIncurred(uint value)
        public
        view
        returns (uint)
    {
        return safeMul_dec(value, transferFeeRate);
        // Transfers less than the reciprocal of transferFeeRate should be completely eaten up by fees.
        // This is on the basis that transfers less than this value will result in a nil fee.
        // Probably too insignificant to worry about, but the following code will achieve it.
        //      if (fee == 0 && transferFeeRate != 0) {
        //          return _value;
        //      }
        //      return fee;
    }

    // The value that you would need to send so that the recipient receives
    // a specified value.
    function transferPlusFee(uint value)
        external
        view
        returns (uint)
    {
        return safeAdd(value, transferFeeIncurred(value));
    }

    // The quantity to send in order that the sender spends a certain value of tokens.
    function priceToSpend(uint value)
        external
        view
        returns (uint)
    {
        return safeDiv_dec(value, safeAdd(UNIT, transferFeeRate));
    }

    // The balance of the nomin contract itself is the fee pool.
    // Collected fees sit here until they are distributed.
    function feePool()
        external
        view
        returns (uint)
    {
        return state.balanceOf(address(this));
    }


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

    /* Whatever calls this should have either the optionalProxy or onlyProxy modifier,
     * and pass in messageSender. */
    function _transfer_byProxy(address sender, address to, uint value)
        internal
        returns (bool)
    {
        require(to != address(0));

        // The fee is deducted from the sender's balance, in addition to
        // the transferred quantity.
        uint fee = transferFeeIncurred(value);
        uint totalCharge = safeAdd(value, fee);

        // Insufficient balance will be handled by the safe subtraction.
        state.setBalanceOf(sender, safeSub(state.balanceOf(sender), totalCharge));
        state.setBalanceOf(to, safeAdd(state.balanceOf(to), value));
        state.setBalanceOf(address(this), safeAdd(state.balanceOf(address(this)), fee));

        emit Transfer(sender, to, value);
        emit TransferFeePaid(sender, fee);
        emit Transfer(sender, address(this), fee);

        return true;
    }

    /* Whatever calls this should have either the optionalProxy or onlyProxy modifier,
     * and pass in messageSender. */
    function _transferFrom_byProxy(address sender, address from, address to, uint value)
        internal
        returns (bool)
    {
        require(to != address(0));

        // The fee is deducted from the sender's balance, in addition to
        // the transferred quantity.
        uint fee = transferFeeIncurred(value);
        uint totalCharge = safeAdd(value, fee);

        // Insufficient balance will be handled by the safe subtraction.
        state.setBalanceOf(from, safeSub(state.balanceOf(from), totalCharge));
        state.setAllowance(from, sender, safeSub(state.allowance(from, sender), totalCharge));
        state.setBalanceOf(to, safeAdd(state.balanceOf(to), value));
        state.setBalanceOf(address(this), safeAdd(state.balanceOf(address(this)), fee));

        emit Transfer(from, to, value);
        emit TransferFeePaid(from, fee);
        emit Transfer(from, address(this), fee);

        return true;
    }

    function approve(address spender, uint value)
        external
        optionalProxy
        returns (bool)
    {
        address sender = messageSender;
        state.setAllowance(sender, spender, value);

        emit Approval(sender, spender, value);

        return true;
    }

    /* Withdraw tokens from the fee pool into a given account. */
    function withdrawFee(address account, uint value)
        external
        returns (bool)
    {
        require(msg.sender == feeAuthority && account != address(0));
        
        // 0-value withdrawals do nothing.
        if (value == 0) {
            return false;
        }

        // Safe subtraction ensures an exception is thrown if the balance is insufficient.
        state.setBalanceOf(address(this), safeSub(state.balanceOf(address(this)), value));
        state.setBalanceOf(account, safeAdd(state.balanceOf(account), value));

        emit FeesWithdrawn(account, account, value);
        emit Transfer(address(this), account, value);

        return true;
    }

    /* Donate tokens from the sender's balance into the fee pool. */
    function donateToFeePool(uint n)
        external
        optionalProxy
        returns (bool)
    {
        address sender = messageSender;

        // Empty donations are disallowed.
        uint balance = state.balanceOf(sender);
        require(balance != 0);

        // safeSub ensures the donor has sufficient balance.
        state.setBalanceOf(sender, safeSub(balance, n));
        state.setBalanceOf(address(this), safeAdd(state.balanceOf(address(this)), n));

        emit FeesDonated(sender, sender, n);
        emit Transfer(sender, address(this), n);

        return true;
    }

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

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

    event TransferFeePaid(address indexed account, uint value);

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

    event TransferFeeRateUpdated(uint newFeeRate);

    event FeeAuthorityUpdated(address feeAuthority);

    event StateUpdated(address newState);

    event FeesWithdrawn(address account, address indexed accountIndex, uint value);

    event FeesDonated(address donor, address indexed donorIndex, uint value);
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

Ether-backed nomin stablecoin contract.

This contract issues nomins, which are tokens worth 1 USD each. They are backed
by a pool of ether collateral, so that if a user has nomins, they may
redeem them for ether from the pool, or if they want to obtain nomins,
they may pay ether into the pool in order to do so.

The supply of nomins that may be in circulation at any time is limited.
The contract owner may increase this quantity, but only if they provide
ether to back it. The backing the owner provides at issuance must
keep each nomin at least twice overcollateralised.
The owner may also destroy nomins in the pool, which is potential avenue
by which to maintain healthy collateralisation levels, as it reduces
supply without withdrawing ether collateral.

A configurable fee is charged on nomin transfers and deposited
into a common pot, which havven holders may withdraw from once per
fee period.

Ether price is continually updated by an external oracle, and the value
of the backing is computed on this basis. To ensure the integrity of
this system, if the contract's price has not been updated recently enough,
it will temporarily disable itself until it receives more price information.

The contract owner may at any time initiate contract liquidation.
During the liquidation period, most contract functions will be deactivated.
No new nomins may be issued or bought, but users may sell nomins back
to the system.
If the system's collateral falls below a specified level, then anyone
may initiate liquidation.

After the liquidation period has elapsed, which is initially 90 days,
the owner may destroy the contract, transferring any remaining collateral
to a nominated beneficiary address.
This liquidation period may be extended up to a maximum of 180 days.
If the contract is recollateralised, the owner may terminate liquidation.

-----------------------------------------------------------------
*/

contract EtherNomin is ExternStateProxyFeeToken {

    /* ========== STATE VARIABLES ========== */

    // The oracle provides price information to this contract.
    // It may only call the updatePrice() function.
    address public oracle;

    // The address of the contract which manages confiscation votes.
    Court public court;

    // Foundation wallet for funds to go to post liquidation.
    address public beneficiary;

    // Nomins in the pool ready to be sold.
    uint public nominPool;

    // Impose a 50 basis-point fee for buying from and selling to the nomin pool.
    uint public poolFeeRate = UNIT / 200;

    // The minimum purchasable quantity of nomins is 1 cent.
    uint constant MINIMUM_PURCHASE = UNIT / 100;

    // When issuing, nomins must be overcollateralised by this ratio.
    uint constant MINIMUM_ISSUANCE_RATIO =  2 * UNIT;

    // If the collateralisation ratio of the contract falls below this level,
    // immediately begin liquidation.
    uint constant AUTO_LIQUIDATION_RATIO = UNIT;

    // The liquidation period is the duration that must pass before the liquidation period is complete.
    // It can be extended up to a given duration.
    uint constant DEFAULT_LIQUIDATION_PERIOD = 14 days;
    uint constant MAX_LIQUIDATION_PERIOD = 180 days;
    uint public liquidationPeriod = DEFAULT_LIQUIDATION_PERIOD;

    // The timestamp when liquidation was activated. We initialise this to
    // uint max, so that we know that we are under liquidation if the
    // liquidation timestamp is in the past.
    uint public liquidationTimestamp = ~uint(0);

    // Ether price from oracle (fiat per ether).
    uint public etherPrice;

    // Last time the price was updated.
    uint public lastPriceUpdateTime;

    // The period it takes for the price to be considered stale.
    // If the price is stale, functions that require the price are disabled.
    uint public stalePeriod = 60 minutes;

    // Accounts which have lost the privilege to transact in nomins.
    mapping(address => bool) public frozen;


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

    function EtherNomin(address _havven, address _oracle,
                        address _beneficiary,
                        uint _initialEtherPrice,
                        address _owner, TokenState _initialState)
        ExternStateProxyFeeToken("Ether-Backed USD Nomins", "eUSD",
                                 15 * UNIT / 10000, // nomin transfers incur a 15 bp fee
                                 _havven, // the havven contract is the fee authority
                                 _initialState,
                                 _owner)
        public
    {
        oracle = _oracle;
        beneficiary = _beneficiary;

        etherPrice = _initialEtherPrice;
        lastPriceUpdateTime = now;
        emit PriceUpdated(_initialEtherPrice);

        // It should not be possible to transfer to the nomin contract itself.
        frozen[this] = true;
    }


    /* ========== FALLBACK FUNCTION ========== */

    /* Fallback function allows convenient collateralisation of the contract,
     * including by non-foundation parties. */
    function() public payable {}


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

    function setOracle(address _oracle)
        external
        optionalProxy_onlyOwner
    {
        oracle = _oracle;
        emit OracleUpdated(_oracle);
    }

    function setCourt(Court _court)
        external
        optionalProxy_onlyOwner
    {
        court = _court;
        emit CourtUpdated(_court);
    }

    function setBeneficiary(address _beneficiary)
        external
        optionalProxy_onlyOwner
    {
        beneficiary = _beneficiary;
        emit BeneficiaryUpdated(_beneficiary);
    }

    function setPoolFeeRate(uint _poolFeeRate)
        external
        optionalProxy_onlyOwner
    {
        require(_poolFeeRate <= UNIT);
        poolFeeRate = _poolFeeRate;
        emit PoolFeeRateUpdated(_poolFeeRate);
    }

    function setStalePeriod(uint _stalePeriod)
        external
        optionalProxy_onlyOwner
    {
        stalePeriod = _stalePeriod;
        emit StalePeriodUpdated(_stalePeriod);
    }
 

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

    /* Return the equivalent fiat value of the given quantity
     * of ether at the current price.
     * Reverts if the price is stale. */
    function fiatValue(uint etherWei)
        public
        view
        priceNotStale
        returns (uint)
    {
        return safeMul_dec(etherWei, etherPrice);
    }

    /* Return the current fiat value of the contract's balance.
     * Reverts if the price is stale. */
    function fiatBalance()
        public
        view
        returns (uint)
    {
        // Price staleness check occurs inside the call to fiatValue.
        return fiatValue(address(this).balance);
    }

    /* Return the equivalent ether value of the given quantity
     * of fiat at the current price.
     * Reverts if the price is stale. */
    function etherValue(uint fiat)
        public
        view
        priceNotStale
        returns (uint)
    {
        return safeDiv_dec(fiat, etherPrice);
    }

    /* The same as etherValue(), but without the stale price check. */
    function etherValueAllowStale(uint fiat) 
        internal
        view
        returns (uint)
    {
        return safeDiv_dec(fiat, etherPrice);
    }

    /* Return the units of fiat per nomin in the supply.
     * Reverts if the price is stale. */
    function collateralisationRatio()
        public
        view
        returns (uint)
    {
        return safeDiv_dec(fiatBalance(), _nominCap());
    }

    /* Return the maximum number of extant nomins,
     * equal to the nomin pool plus total (circulating) supply. */
    function _nominCap()
        internal
        view
        returns (uint)
    {
        return safeAdd(nominPool, totalSupply);
    }

    /* Return the fee charged on a purchase or sale of n nomins. */
    function poolFeeIncurred(uint n)
        public
        view
        returns (uint)
    {
        return safeMul_dec(n, poolFeeRate);
    }

    /* Return the fiat cost (including fee) of purchasing n nomins.
     * Nomins are purchased for $1, plus the fee. */
    function purchaseCostFiat(uint n)
        public
        view
        returns (uint)
    {
        return safeAdd(n, poolFeeIncurred(n));
    }

    /* Return the ether cost (including fee) of purchasing n nomins.
     * Reverts if the price is stale. */
    function purchaseCostEther(uint n)
        public
        view
        returns (uint)
    {
        // Price staleness check occurs inside the call to etherValue.
        return etherValue(purchaseCostFiat(n));
    }

    /* Return the fiat proceeds (less the fee) of selling n nomins.
     * Nomins are sold for $1, minus the fee. */
    function saleProceedsFiat(uint n)
        public
        view
        returns (uint)
    {
        return safeSub(n, poolFeeIncurred(n));
    }

    /* Return the ether proceeds (less the fee) of selling n
     * nomins.
     * Reverts if the price is stale. */
    function saleProceedsEther(uint n)
        public
        view
        returns (uint)
    {
        // Price staleness check occurs inside the call to etherValue.
        return etherValue(saleProceedsFiat(n));
    }

    /* The same as saleProceedsEther(), but without the stale price check. */
    function saleProceedsEtherAllowStale(uint n)
        internal
        view
        returns (uint)
    {
        return etherValueAllowStale(saleProceedsFiat(n));
    }

    /* True iff the current block timestamp is later than the time
     * the price was last updated, plus the stale period. */
    function priceIsStale()
        public
        view
        returns (bool)
    {
        return safeAdd(lastPriceUpdateTime, stalePeriod) < now;
    }

    function isLiquidating()
        public
        view
        returns (bool)
    {
        return liquidationTimestamp <= now;
    }

    /* True if the contract is self-destructible. 
     * This is true if either the complete liquidation period has elapsed,
     * or if all tokens have been returned to the contract and it has been
     * in liquidation for at least a week.
     * Since the contract is only destructible after the liquidationTimestamp,
     * a fortiori canSelfDestruct() implies isLiquidating(). */
    function canSelfDestruct()
        public
        view
        returns (bool)
    {
        // Not being in liquidation implies the timestamp is uint max, so it would roll over.
        // We need to check whether we're in liquidation first.
        if (isLiquidating()) {
            // These timestamps and durations have values clamped within reasonable values and
            // cannot overflow.
            bool totalPeriodElapsed = liquidationTimestamp + liquidationPeriod < now;
            // Total supply of 0 means all tokens have returned to the pool.
            bool allTokensReturned = (liquidationTimestamp + 1 weeks < now) && (totalSupply == 0);
            return totalPeriodElapsed || allTokensReturned;
        }
        return false;
    }


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

    /* Override ERC20 transfer function in order to check
     * whether the recipient account is frozen. Note that there is
     * no need to check whether the sender has a frozen account,
     * since their funds have already been confiscated,
     * and no new funds can be transferred to it.*/
    function transfer(address to, uint value)
        public
        optionalProxy
        returns (bool)
    {
        require(!frozen[to]);
        return _transfer_byProxy(messageSender, to, value);
    }

    /* Override ERC20 transferFrom function in order to check
     * whether the recipient account is frozen. */
    function transferFrom(address from, address to, uint value)
        public
        optionalProxy
        returns (bool)
    {
        require(!frozen[to]);
        return _transferFrom_byProxy(messageSender, from, to, value);
    }

    /* Update the current ether price and update the last updated time,
     * refreshing the price staleness.
     * Also checks whether the contract's collateral levels have fallen to low,
     * and initiates liquidation if that is the case.
     * Exceptional conditions:
     *     Not called by the oracle.
     *     Not the most recently sent price. */
    function updatePrice(uint price, uint timeSent)
        external
        postCheckAutoLiquidate
    {
        // Should be callable only by the oracle.
        require(msg.sender == oracle);
        // Must be the most recently sent price, but not too far in the future.
        // (so we can't lock ourselves out of updating the oracle for longer than this)
        require(lastPriceUpdateTime < timeSent && timeSent < now + 10 minutes);

        etherPrice = price;
        lastPriceUpdateTime = timeSent;
        emit PriceUpdated(price);
    }

    /* Issues n nomins into the pool available to be bought by users.
     * Must be accompanied by $n worth of ether.
     * Exceptional conditions:
     *     Not called by contract owner.
     *     Insufficient backing funds provided (post-issuance collateralisation below minimum requirement).
     *     Price is stale. */
    function replenishPool(uint n)
        external
        payable
        notLiquidating
        optionalProxy_onlyOwner
    {
        // Price staleness check occurs inside the call to fiatBalance.
        // Safe additions are unnecessary here, as either the addition is checked on the following line
        // or the overflow would cause the requirement not to be satisfied.
        require(fiatBalance() >= safeMul_dec(safeAdd(_nominCap(), n), MINIMUM_ISSUANCE_RATIO));
        nominPool = safeAdd(nominPool, n);
        emit PoolReplenished(n, msg.value);
    }

    /* Burns n nomins from the pool.
     * Exceptional conditions:
     *     Not called by contract owner.
     *     There are fewer than n nomins in the pool. */
    function diminishPool(uint n)
        external
        optionalProxy_onlyOwner
    {
        // Require that there are enough nomins in the accessible pool to burn
        require(nominPool >= n);
        nominPool = safeSub(nominPool, n);
        emit PoolDiminished(n);
    }

    /* Sends n nomins to the sender from the pool, in exchange for
     * $n plus the fee worth of ether.
     * Exceptional conditions:
     *     Insufficient or too many funds provided.
     *     More nomins requested than are in the pool.
     *     n below the purchase minimum (1 cent).
     *     contract in liquidation.
     *     Price is stale. */
    function buy(uint n)
        external
        payable
        notLiquidating
        optionalProxy
    {
        // Price staleness check occurs inside the call to purchaseEtherCost.
        require(n >= MINIMUM_PURCHASE &&
                msg.value == purchaseCostEther(n));
        address sender = messageSender;
        // sub requires that nominPool >= n
        nominPool = safeSub(nominPool, n);
        state.setBalanceOf(sender, safeAdd(state.balanceOf(sender), n));
        emit Purchased(sender, sender, n, msg.value);
        emit Transfer(0, sender, n);
        totalSupply = safeAdd(totalSupply, n);
    }

    /* Sends n nomins to the pool from the sender, in exchange for
     * $n minus the fee worth of ether.
     * Exceptional conditions:
     *     Insufficient nomins in sender's wallet.
     *     Insufficient funds in the pool to pay sender.
     *     Price is stale if not in liquidation. */
    function sell(uint n)
        external
        optionalProxy
    {

        // Price staleness check occurs inside the call to saleProceedsEther,
        // but we allow people to sell their nomins back to the system
        // if we're in liquidation, regardless.
        uint proceeds;
        if (isLiquidating()) {
            proceeds = saleProceedsEtherAllowStale(n);
        } else {
            proceeds = saleProceedsEther(n);
        }

        require(address(this).balance >= proceeds);

        address sender = messageSender;
        // sub requires that the balance is greater than n
        state.setBalanceOf(sender, safeSub(state.balanceOf(sender), n));
        nominPool = safeAdd(nominPool, n);
        emit Sold(sender, sender, n, proceeds);
        emit Transfer(sender, 0, n);
        totalSupply = safeSub(totalSupply, n);
        sender.transfer(proceeds);
    }

    /* Lock nomin purchase function in preparation for destroying the contract.
     * While the contract is under liquidation, users may sell nomins back to the system.
     * After liquidation period has terminated, the contract may be self-destructed,
     * returning all remaining ether to the beneficiary address.
     * Exceptional cases:
     *     Not called by contract owner;
     *     contract already in liquidation; */
    function forceLiquidation()
        external
        notLiquidating
        optionalProxy_onlyOwner
    {
        beginLiquidation();
    }

    function beginLiquidation()
        internal
    {
        liquidationTimestamp = now;
        emit LiquidationBegun(liquidationPeriod);
    }

    /* If the contract is liquidating, the owner may extend the liquidation period.
     * It may only get longer, not shorter, and it may not be extended past
     * the liquidation max. */
    function extendLiquidationPeriod(uint extension)
        external
        optionalProxy_onlyOwner
    {
        require(isLiquidating());
        uint sum = safeAdd(liquidationPeriod, extension);
        require(sum <= MAX_LIQUIDATION_PERIOD);
        liquidationPeriod = sum;
        emit LiquidationExtended(extension);
    }

    /* Liquidation can only be stopped if the collateralisation ratio
     * of this contract has recovered above the automatic liquidation
     * threshold, for example if the ether price has increased,
     * or by including enough ether in this transaction. */
    function terminateLiquidation()
        external
        payable
        priceNotStale
        optionalProxy_onlyOwner
    {
        require(isLiquidating());
        require(_nominCap() == 0 || collateralisationRatio() >= AUTO_LIQUIDATION_RATIO);
        liquidationTimestamp = ~uint(0);
        liquidationPeriod = DEFAULT_LIQUIDATION_PERIOD;
        emit LiquidationTerminated();
    }

    /* The owner may destroy this contract, returning all funds back to the beneficiary
     * wallet, may only be called after the contract has been in
     * liquidation for at least liquidationPeriod, or all circulating
     * nomins have been sold back into the pool. */
    function selfDestruct()
        external
        optionalProxy_onlyOwner
    {
        require(canSelfDestruct());
        emit SelfDestructed(beneficiary);
        selfdestruct(beneficiary);
    }

    /* If a confiscation court motion has passed and reached the confirmation
     * state, the court may transfer the target account's balance to the fee pool
     * and freeze its participation in further transactions. */
    function confiscateBalance(address target)
        external
    {
        // Should be callable only by the confiscation court.
        require(Court(msg.sender) == court);
        
        // A motion must actually be underway.
        uint motionID = court.targetMotionID(target);
        require(motionID != 0);

        // These checks are strictly unnecessary,
        // since they are already checked in the court contract itself.
        // I leave them in out of paranoia.
        require(court.motionConfirming(motionID));
        require(court.motionPasses(motionID));
        require(!frozen[target]);

        // Confiscate the balance in the account and freeze it.
        uint balance = state.balanceOf(target);
        state.setBalanceOf(address(this), safeAdd(state.balanceOf(address(this)), balance));
        state.setBalanceOf(target, 0);
        frozen[target] = true;
        emit AccountFrozen(target, target, balance);
        emit Transfer(target, address(this), balance);
    }

    /* The owner may allow a previously-frozen contract to once
     * again accept and transfer nomins. */
    function unfreezeAccount(address target)
        external
        optionalProxy_onlyOwner
    {
        if (frozen[target] && EtherNomin(target) != this) {
            frozen[target] = false;
            emit AccountUnfrozen(target, target);
        }
    }


    /* ========== MODIFIERS ========== */

    modifier notLiquidating
    {
        require(!isLiquidating());
        _;
    }

    modifier priceNotStale
    {
        require(!priceIsStale());
        _;
    }

    /* Any function modified by this will automatically liquidate
     * the system if the collateral levels are too low.
     * This is called on collateral-value/nomin-supply modifying functions that can
     * actually move the contract into liquidation. This is really only
     * the price update, since issuance requires that the contract is overcollateralised,
     * burning can only destroy tokens without withdrawing backing, buying from the pool can only
     * asymptote to a collateralisation level of unity, while selling into the pool can only 
     * increase the collateralisation ratio.
     * Additionally, price update checks should/will occur frequently. */
    modifier postCheckAutoLiquidate
    {
        _;
        if (!isLiquidating() && _nominCap() != 0 && collateralisationRatio() < AUTO_LIQUIDATION_RATIO) {
            beginLiquidation();
        }
    }


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

    event PoolReplenished(uint nominsCreated, uint collateralDeposited);

    event PoolDiminished(uint nominsDestroyed);

    event Purchased(address buyer, address indexed buyerIndex, uint nomins, uint etherWei);

    event Sold(address seller, address indexed sellerIndex, uint nomins, uint etherWei);

    event PriceUpdated(uint newPrice);

    event StalePeriodUpdated(uint newPeriod);

    event OracleUpdated(address newOracle);

    event CourtUpdated(address newCourt);

    event BeneficiaryUpdated(address newBeneficiary);

    event LiquidationBegun(uint duration);

    event LiquidationTerminated();

    event LiquidationExtended(uint extension);

    event PoolFeeRateUpdated(uint newFeeRate);

    event SelfDestructed(address beneficiary);

    event AccountFrozen(address target, address indexed targetIndex, uint balance);

    event AccountUnfrozen(address target, address indexed targetIndex);
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

A token interface to be overridden to produce an ERC20-compliant
token contract. It relies on being called underneath a proxy,
as described in Proxy.sol.

This contract utilises a state for upgradability purposes.

-----------------------------------------------------------------
*/

contract ExternStateProxyToken is SafeDecimalMath, Proxyable {

    /* ========== STATE VARIABLES ========== */

    // Stores balances and allowances.
    TokenState public state;

    // Other ERC20 fields
    string public name;
    string public symbol;
    uint public totalSupply;


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

    function ExternStateProxyToken(string _name, string _symbol,
                                   uint initialSupply, address initialBeneficiary,
                                   TokenState _state, address _owner)
        Proxyable(_owner)
        public
    {
        name = _name;
        symbol = _symbol;
        totalSupply = initialSupply;

        // if the state isn't set, create a new one
        if (_state == TokenState(0)) {
            state = new TokenState(_owner, address(this));
            state.setBalanceOf(initialBeneficiary, totalSupply);
            emit Transfer(address(0), initialBeneficiary, initialSupply);
        } else {
            state = _state;
        }
   }

    /* ========== VIEWS ========== */

    function allowance(address tokenOwner, address spender)
        public
        view
        returns (uint)
    {
        return state.allowance(tokenOwner, spender);
    }

    function balanceOf(address account)
        public
        view
        returns (uint)
    {
        return state.balanceOf(account);
    }

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

    function setState(TokenState _state)
        external
        optionalProxy_onlyOwner
    {
        state = _state;
        emit StateUpdated(_state);
    } 

    /* Anything calling this must apply the onlyProxy or optionalProxy modifiers.*/
    function _transfer_byProxy(address sender, address to, uint value)
        internal
        returns (bool)
    {
        require(to != address(0));

        // Insufficient balance will be handled by the safe subtraction.
        state.setBalanceOf(sender, safeSub(state.balanceOf(sender), value));
        state.setBalanceOf(to, safeAdd(state.balanceOf(to), value));

        emit Transfer(sender, to, value);

        return true;
    }

    /* Anything calling this must apply the onlyProxy or optionalProxy modifiers.*/
    function _transferFrom_byProxy(address sender, address from, address to, uint value)
        internal
        returns (bool)
    {
        require(to != address(0));

        // Insufficient balance will be handled by the safe subtraction.
        state.setBalanceOf(from, safeSub(state.balanceOf(from), value));
        state.setAllowance(from, sender, safeSub(state.allowance(from, sender), value));
        state.setBalanceOf(to, safeAdd(state.balanceOf(to), value));

        emit Transfer(from, to, value);

        return true;
    }

    function approve(address spender, uint value)
        external
        optionalProxy
        returns (bool)
    {
        address sender = messageSender;
        state.setAllowance(sender, spender, value);
        emit Approval(sender, spender, value);
        return true;
    }

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

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

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

    event StateUpdated(address newState);
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

This contract allows the foundation to apply unique vesting
schedules to havven funds sold at various discounts in the token
sale. HavvenEscrow gives users the ability to inspect their
vested funds, their quantities and vesting dates, and to withdraw
the fees that accrue on those funds.

The fees are handled by withdrawing the entire fee allocation
for all havvens inside the escrow contract, and then allowing
the contract itself to subdivide that pool up proportionally within
itself. Every time the fee period rolls over in the main Havven
contract, the HavvenEscrow fee pool is remitted back into the 
main fee pool to be redistributed in the next fee period.

-----------------------------------------------------------------
*/

contract HavvenEscrow is Owned, LimitedSetup(8 weeks), SafeDecimalMath {    
    // The corresponding Havven contract.
    Havven public havven;

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

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

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


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

    function HavvenEscrow(address _owner, Havven _havven)
        Owned(_owner)
        public
    {
        havven = _havven;
    }


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

    function setHavven(Havven _havven)
        external
        onlyOwner
    {
        havven = _havven;
        emit HavvenUpdated(_havven);
    }


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

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

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

    /* Get a particular schedule entry for an account.
     * The return value is a pair (timestamp, havven quantity) */
    function getVestingScheduleEntry(address account, uint index)
        public
        view
        returns (uint[2])
    {
        return vestingSchedules[account][index];
    }

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

    /* Get the quantity of havvens associated with a given schedule entry. */
    function getVestingQuantity(address account, uint index)
        public
        view
        returns (uint)
    {
        return vestingSchedules[account][index][1];
    }

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

    /* Obtain the next schedule entry that will vest for a given user.
     * The return value is a pair (timestamp, havven quantity) */
    function getNextVestingEntry(address account)
        external
        view
        returns (uint[2])
    {
        uint index = getNextVestingIndex(account);
        if (index == numVestingEntries(account)) {
            return [uint(0), 0];
        }
        return getVestingScheduleEntry(account, index);
    }

    /* Obtain the time at which the next schedule entry will vest for a given user. */
    function getNextVestingTime(address account)
        external
        view
        returns (uint)
    {
        uint index = getNextVestingIndex(account);
        if (index == numVestingEntries(account)) {
            return 0;
        }
        return getVestingTime(account, index);
    }

    /* Obtain the quantity which the next schedule entry will vest for a given user. */
    function getNextVestingQuantity(address account)
        external
        view
        returns (uint)
    {
        uint index = getNextVestingIndex(account);
        if (index == numVestingEntries(account)) {
            return 0;
        }
        return getVestingQuantity(account, index);
    }


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

    /* Withdraws a quantity of havvens back to the havven contract. */
    function withdrawHavvens(uint quantity)
        external
        onlyOwner
        setupFunction
    {
        havven.transfer(havven, quantity);
    }

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

    /* Add a new vesting entry at a given time and quantity to an account's schedule.
     * A call to this should be accompanied by either enough balance already available
     * in this contract, or a corresponding call to havven.endow(), to ensure that when
     * the funds are withdrawn, there is enough balance, as well as correctly calculating
     * the fees.
     * 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. */
    function appendVestingEntry(address account, uint time, uint quantity)
        public
        onlyOwner
        setupFunction
    {
        // No empty or already-passed vesting entries allowed.
        require(now < time);
        require(quantity != 0);
        totalVestedBalance = safeAdd(totalVestedBalance, quantity);
        require(totalVestedBalance <= havven.balanceOf(this));

        if (vestingSchedules[account].length == 0) {
            totalVestedAccountBalance[account] = quantity;
        } else {
            // Disallow adding new vested havvens 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);
            totalVestedAccountBalance[account] = safeAdd(totalVestedAccountBalance[account], quantity);
        }

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

    /* Construct a vesting schedule to release a quantities of havvens
     * over a series of intervals. Assumes that the quantities are nonzero
     * and that the sequence of timestamps is strictly increasing. */
    function addVestingSchedule(address account, uint[] times, uint[] quantities)
        external
        onlyOwner
        setupFunction
    {
        for (uint i = 0; i < times.length; i++) {
            appendVestingEntry(account, times[i], quantities[i]);
        }

    }

    /* Allow a user to withdraw any tokens 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) {
                continue;
            }

            vestingSchedules[msg.sender][i] = [0, 0];
            total = safeAdd(total, qty);
            totalVestedAccountBalance[msg.sender] = safeSub(totalVestedAccountBalance[msg.sender], qty);
        }

        if (total != 0) {
            totalVestedBalance = safeSub(totalVestedBalance, total);
            havven.transfer(msg.sender, total);
            emit Vested(msg.sender, msg.sender,
                   now, total);
        }
    }


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

    event HavvenUpdated(address newHavven);

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

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

This contract allows an inheriting contract to be destroyed after
its owner indicates an intention and then waits for a period
without changing their mind.

-----------------------------------------------------------------
*/

contract SelfDestructible is Owned {
	
	uint public initiationTime = ~uint(0);
	uint constant SD_DURATION = 3 days;
	address public beneficiary;

	function SelfDestructible(address _owner, address _beneficiary)
		public
		Owned(_owner)
	{
		beneficiary = _beneficiary;
	}

	function setBeneficiary(address _beneficiary)
		external
		onlyOwner
	{
		beneficiary = _beneficiary;
		emit SelfDestructBeneficiaryUpdated(_beneficiary);
	}

	function initiateSelfDestruct()
		external
		onlyOwner
	{
		initiationTime = now;
		emit SelfDestructInitiated(SD_DURATION);
	}

	function terminateSelfDestruct()
		external
		onlyOwner
	{
		initiationTime = ~uint(0);
		emit SelfDestructTerminated();
	}

	function selfDestruct()
		external
		onlyOwner
	{
		require(initiationTime + SD_DURATION < now);
		emit SelfDestructed(beneficiary);
		selfdestruct(beneficiary);
	}

	event SelfDestructBeneficiaryUpdated(address newBeneficiary);

	event SelfDestructInitiated(uint duration);

	event SelfDestructTerminated();

	event SelfDestructed(address beneficiary);
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

Havven token contract. Havvens are transferable ERC20 tokens,
and also give their holders the following privileges.
An owner of havvens is entitled to a share in the fees levied on
nomin transactions, and additionally may participate in nomin
confiscation votes.

After a fee period terminates, the duration and fees collected for that
period are computed, and the next period begins.
Thus an account may only withdraw the fees owed to them for the previous
period, and may only do so once per period.
Any unclaimed fees roll over into the common pot for the next period.

The fee entitlement of a havven holder is proportional to their average
havven balance over the last fee period. This is computed by measuring the
area under the graph of a user's balance over time, and then when fees are
distributed, dividing through by the duration of the fee period.

We need only update fee entitlement on transfer when the havven balances of the sender
and recipient are modified. This is for efficiency, and adds an implicit friction to
trading in the havven market. A havven holder pays for his own recomputation whenever
he wants to change his position, which saves the foundation having to maintain a pot
dedicated to resourcing this.

A hypothetical user's balance history over one fee period, pictorially:

      s ____
       |    |
       |    |___ p
       |____|___|___ __ _  _
       f    t   n

Here, the balance was s between times f and t, at which time a transfer
occurred, updating the balance to p, until n, when the present transfer occurs.
When a new transfer occurs at time n, the balance being p,
we must:

  - Add the area p * (n - t) to the total area recorded so far
  - Update the last transfer time to p

So if this graph represents the entire current fee period,
the average havvens held so far is ((t-f)*s + (n-t)*p) / (n-f).
The complementary computations must be performed for both sender and
recipient.

Note that a transfer keeps global supply of havvens invariant.
The sum of all balances is constant, and unmodified by any transfer.
So the sum of all balances multiplied by the duration of a fee period is also
constant, and this is equivalent to the sum of the area of every user's
time/balance graph. Dividing through by that duration yields back the total
havven supply. So, at the end of a fee period, we really do yield a user's
average share in the havven supply over that period.

A slight wrinkle is introduced if we consider the time r when the fee period
rolls over. Then the previous fee period k-1 is before r, and the current fee
period k is afterwards. If the last transfer took place before r,
but the latest transfer occurred afterwards:

k-1       |        k
      s __|_
       |  | |
       |  | |____ p
       |__|_|____|___ __ _  _
          |
       f  | t    n
          r

In this situation the area (r-f)*s contributes to fee period k-1, while
the area (t-r)*s contributes to fee period k. We will implicitly consider a
zero-value transfer to have occurred at time r. Their fee entitlement for the
previous period will be finalised at the time of their first transfer during the
current fee period, or when they query or withdraw their fee entitlement.

In the implementation, the duration of different fee periods may be slightly irregular,
as the check that they have rolled over occurs only when state-changing havven
operations are performed.

Additionally, we keep track also of the penultimate and not just the last
average balance, in order to support the voting functionality detailed in Court.sol.

-----------------------------------------------------------------
*/

contract Havven is ExternStateProxyToken, SelfDestructible {

    /* ========== STATE VARIABLES ========== */

    // Sums of balances*duration in the current fee period.
    // range: decimals; units: havven-seconds
    mapping(address => uint) public currentBalanceSum;

    // Average account balances in the last completed fee period. This is proportional
    // to that account's last period fee entitlement.
    // (i.e. currentBalanceSum for the previous period divided through by duration)
    // WARNING: This may not have been updated for the latest fee period at the
    //          time it is queried.
    // range: decimals; units: havvens
    mapping(address => uint) public lastAverageBalance;

    // The average account balances in the period before the last completed fee period.
    // This is used as a person's weight in a confiscation vote, so it implies that
    // the vote duration must be no longer than the fee period in order to guarantee that 
    // no portion of a fee period used for determining vote weights falls within the
    // duration of a vote it contributes to.
    // WARNING: This may not have been updated for the latest fee period at the
    //          time it is queried.
    mapping(address => uint) public penultimateAverageBalance;

    // The time an account last made a transfer.
    // range: naturals
    mapping(address => uint) public lastTransferTimestamp;

    // The time the current fee period began.
    uint public feePeriodStartTime = 3;
    // The actual start of the last fee period (seconds).
    // This, and the penultimate fee period can be initially set to any value
    //   0 < val < now, as everyone's individual lastTransferTime will be 0
    //   and as such, their lastAvgBal/penultimateAvgBal will be set to that value
    //   apart from the contract, which will have totalSupply
    uint public lastFeePeriodStartTime = 2;
    // The actual start of the penultimate fee period (seconds).
    uint public penultimateFeePeriodStartTime = 1;

    // Fee periods will roll over in no shorter a time than this.
    uint public targetFeePeriodDurationSeconds = 4 weeks;
    // And may not be set to be shorter than a day.
    uint constant MIN_FEE_PERIOD_DURATION_SECONDS = 1 days;
    // And may not be set to be longer than six months.
    uint constant MAX_FEE_PERIOD_DURATION_SECONDS = 26 weeks;

    // The quantity of nomins that were in the fee pot at the time
    // of the last fee rollover (feePeriodStartTime).
    uint public lastFeesCollected;

    mapping(address => bool) public hasWithdrawnLastPeriodFees;

    EtherNomin public nomin;
    HavvenEscrow public escrow;


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

    function Havven(TokenState initialState, address _owner)
        ExternStateProxyToken("Havven", "HAV", 1e8 * UNIT, address(this), initialState, _owner)
        SelfDestructible(_owner, _owner)
        // Owned is initialised in ExternStateProxyToken
        public
    {
        lastTransferTimestamp[this] = now;
        feePeriodStartTime = now;
        lastFeePeriodStartTime = now - targetFeePeriodDurationSeconds;
        penultimateFeePeriodStartTime = now - 2*targetFeePeriodDurationSeconds;
    }


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

    function setNomin(EtherNomin _nomin) 
        external
        optionalProxy_onlyOwner
    {
        nomin = _nomin;
    }

    function setEscrow(HavvenEscrow _escrow)
        external
        optionalProxy_onlyOwner
    {
        escrow = _escrow;
    }

    function setTargetFeePeriodDuration(uint duration)
        external
        postCheckFeePeriodRollover
        optionalProxy_onlyOwner
    {
        require(MIN_FEE_PERIOD_DURATION_SECONDS <= duration &&
                duration <= MAX_FEE_PERIOD_DURATION_SECONDS);
        targetFeePeriodDurationSeconds = duration;
        emit FeePeriodDurationUpdated(duration);
    }


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

    /* Allow the owner of this contract to endow any address with havvens
     * from the initial supply. Since the entire initial supply resides
     * in the havven contract, this disallows the foundation from withdrawing
     * fees on undistributed balances. This function can also be used
     * to retrieve any havvens sent to the Havven contract itself. */
    function endow(address account, uint value)
        external
        optionalProxy_onlyOwner
        returns (bool)
    {

        // Use "this" in order that the havven account is the sender.
        // That this is an explicit transfer also initialises fee entitlement information.
        return _transfer(this, account, value);
    }

    /* Allow the owner of this contract to emit transfer events for
     * contract setup purposes. */
    function emitTransferEvents(address sender, address[] recipients, uint[] values)
        external
        onlyOwner
    {
        for (uint i = 0; i < recipients.length; ++i) {
            emit Transfer(sender, recipients[i], values[i]);
        }
    }

    /* Override ERC20 transfer function in order to perform
     * fee entitlement recomputation whenever balances are updated. */
    function transfer(address to, uint value)
        external
        optionalProxy
        returns (bool)
    {
        return _transfer(messageSender, to, value);
    }

    /* Anything calling this must apply the optionalProxy or onlyProxy modifier. */
    function _transfer(address sender, address to, uint value)
        internal
        preCheckFeePeriodRollover
        returns (bool)
    {

        uint senderPreBalance = state.balanceOf(sender);
        uint recipientPreBalance = state.balanceOf(to);

        // Perform the transfer: if there is a problem,
        // an exception will be thrown in this call.
        _transfer_byProxy(sender, to, value);

        // Zero-value transfers still update fee entitlement information,
        // and may roll over the fee period.
        adjustFeeEntitlement(sender, senderPreBalance);
        adjustFeeEntitlement(to, recipientPreBalance);

        return true;
    }

    /* Override ERC20 transferFrom function in order to perform
     * fee entitlement recomputation whenever balances are updated. */
    function transferFrom(address from, address to, uint value)
        external
        preCheckFeePeriodRollover
        optionalProxy
        returns (bool)
    {
        uint senderPreBalance = state.balanceOf(from);
        uint recipientPreBalance = state.balanceOf(to);

        // Perform the transfer: if there is a problem,
        // an exception will be thrown in this call.
        _transferFrom_byProxy(messageSender, from, to, value);

        // Zero-value transfers still update fee entitlement information,
        // and may roll over the fee period.
        adjustFeeEntitlement(from, senderPreBalance);
        adjustFeeEntitlement(to, recipientPreBalance);

        return true;
    }

    /* Compute the last period's fee entitlement for the message sender
     * and then deposit it into their nomin account. */
    function withdrawFeeEntitlement()
        public
        preCheckFeePeriodRollover
        optionalProxy
    {
        address sender = messageSender;

        // Do not deposit fees into frozen accounts.
        require(!nomin.frozen(sender));

        // check the period has rolled over first
        rolloverFee(sender, lastTransferTimestamp[sender], state.balanceOf(sender));

        // Only allow accounts to withdraw fees once per period.
        require(!hasWithdrawnLastPeriodFees[sender]);

        uint feesOwed;

        if (escrow != HavvenEscrow(0)) {
            feesOwed = escrow.totalVestedAccountBalance(sender);
        }

        feesOwed = safeDiv_dec(safeMul_dec(safeAdd(feesOwed, lastAverageBalance[sender]),
                                           lastFeesCollected),
                               totalSupply);

        hasWithdrawnLastPeriodFees[sender] = true;
        if (feesOwed != 0) {
            nomin.withdrawFee(sender, feesOwed);
            emit FeesWithdrawn(sender, sender, feesOwed);
        }
    }

    /* Update the fee entitlement since the last transfer or entitlement
     * adjustment. Since this updates the last transfer timestamp, if invoked
     * consecutively, this function will do nothing after the first call. */
    function adjustFeeEntitlement(address account, uint preBalance)
        internal
    {
        // The time since the last transfer clamps at the last fee rollover time if the last transfer
        // was earlier than that.
        rolloverFee(account, lastTransferTimestamp[account], preBalance);

        currentBalanceSum[account] = safeAdd(
            currentBalanceSum[account],
            safeMul(preBalance, now - lastTransferTimestamp[account])
        );

        // Update the last time this user's balance changed.
        lastTransferTimestamp[account] = now;
    }

    /* Update the given account's previous period fee entitlement value.
     * Do nothing if the last transfer occurred since the fee period rolled over.
     * If the entitlement was updated, also update the last transfer time to be
     * at the timestamp of the rollover, so if this should do nothing if called more
     * than once during a given period.
     *
     * Consider the case where the entitlement is updated. If the last transfer
     * occurred at time t in the last period, then the starred region is added to the
     * entitlement, the last transfer timestamp is moved to r, and the fee period is
     * rolled over from k-1 to k so that the new fee period start time is at time r.
     * 
     *   k-1       |        k
     *         s __|
     *  _  _ ___|**|
     *          |**|
     *  _  _ ___|**|___ __ _  _
     *             |
     *          t  |
     *             r
     * 
     * Similar computations are performed according to the fee period in which the
     * last transfer occurred.
     */
    function rolloverFee(address account, uint lastTransferTime, uint preBalance)
        internal
    {
        if (lastTransferTime < feePeriodStartTime) {
            if (lastTransferTime < lastFeePeriodStartTime) {
                // The last transfer predated the previous two fee periods.
                if (lastTransferTime < penultimateFeePeriodStartTime) {
                    // The balance did nothing in the penultimate fee period, so the average balance
                    // in this period is their pre-transfer balance.
                    penultimateAverageBalance[account] = preBalance;
                // The last transfer occurred within the one-before-the-last fee period.
                } else {
                    // No overflow risk here: the failed guard implies (penultimateFeePeriodStartTime <= lastTransferTime).
                    penultimateAverageBalance[account] = safeDiv(
                        safeAdd(currentBalanceSum[account], safeMul(preBalance, (lastFeePeriodStartTime - lastTransferTime))),
                        (lastFeePeriodStartTime - penultimateFeePeriodStartTime)
                    );
                }

                // The balance did nothing in the last fee period, so the average balance
                // in this period is their pre-transfer balance.
                lastAverageBalance[account] = preBalance;

            // The last transfer occurred within the last fee period.
            } else {
                // The previously-last average balance becomes the penultimate balance.
                penultimateAverageBalance[account] = lastAverageBalance[account];

                // No overflow risk here: the failed guard implies (lastFeePeriodStartTime <= lastTransferTime).
                lastAverageBalance[account] = safeDiv(
                    safeAdd(currentBalanceSum[account], safeMul(preBalance, (feePeriodStartTime - lastTransferTime))),
                    (feePeriodStartTime - lastFeePeriodStartTime)
                );
            }

            // Roll over to the next fee period.
            currentBalanceSum[account] = 0;
            hasWithdrawnLastPeriodFees[account] = false;
            lastTransferTimestamp[account] = feePeriodStartTime;
        }
    }

    /* Recompute and return the given account's average balance information.
     * This also rolls over the fee period if necessary, and brings
     * the account's current balance sum up to date. */
    function _recomputeAccountLastAverageBalance(address account)
        internal
        preCheckFeePeriodRollover
        returns (uint)
    {
        adjustFeeEntitlement(account, state.balanceOf(account));
        return lastAverageBalance[account];
    }

    /* Recompute and return the sender's average balance information. */
    function recomputeLastAverageBalance()
        external
        optionalProxy
        returns (uint)
    {
        return _recomputeAccountLastAverageBalance(messageSender);
    }

    /* Recompute and return the given account's average balance information. */
    function recomputeAccountLastAverageBalance(address account)
        external
        returns (uint)
    {
        return _recomputeAccountLastAverageBalance(account);
    }

    function rolloverFeePeriod()
        public
    {
        checkFeePeriodRollover();
    }


    /* ========== MODIFIERS ========== */

    /* If the fee period has rolled over, then
     * save the start times of the last fee period,
     * as well as the penultimate fee period.
     */
    function checkFeePeriodRollover()
        internal
    {
        // If the fee period has rolled over...
        if (feePeriodStartTime + targetFeePeriodDurationSeconds <= now) {
            lastFeesCollected = nomin.feePool();

            // Shift the three period start times back one place
            penultimateFeePeriodStartTime = lastFeePeriodStartTime;
            lastFeePeriodStartTime = feePeriodStartTime;
            feePeriodStartTime = now;
            
            emit FeePeriodRollover(now);
        }
    }

    modifier postCheckFeePeriodRollover
    {
        _;
        checkFeePeriodRollover();
    }

    modifier preCheckFeePeriodRollover
    {
        checkFeePeriodRollover();
        _;
    }


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

    event FeePeriodRollover(uint timestamp);

    event FeePeriodDurationUpdated(uint duration);

    event FeesWithdrawn(address account, address indexed accountIndex, uint value);
}

/*
-----------------------------------------------------------------
CONTRACT DESCRIPTION
-----------------------------------------------------------------

A contract that holds the state of an ERC20 compliant token.

This contract is used side by side with external state token
contracts, such as Havven and EtherNomin.
It provides an easy way to upgrade contract logic while
maintaining all user balances and allowances. This is designed
to to make the changeover as easy as possible, since mappings
are not so cheap or straightforward to migrate.

The first deployed contract would create this state contract,
using it as its store of balances.
When a new contract is deployed, it links to the existing
state contract, whose owner would then change its associated
contract to the new one.

-----------------------------------------------------------------
*/

contract TokenState is Owned {

    // the address of the contract that can modify balances and allowances
    // this can only be changed by the owner of this contract
    address public associatedContract;

    // ERC20 fields.
    mapping(address => uint) public balanceOf;
    mapping(address => mapping(address => uint)) public allowance;

    function TokenState(address _owner, address _associatedContract)
        Owned(_owner)
        public
    {
        associatedContract = _associatedContract;
        emit AssociatedContractUpdated(_associatedContract);
    }

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

    // Change the associated contract to a new address
    function setAssociatedContract(address _associatedContract)
        external
        onlyOwner
    {
        associatedContract = _associatedContract;
        emit AssociatedContractUpdated(_associatedContract);
    }

    function setAllowance(address tokenOwner, address spender, uint value)
        external
        onlyAssociatedContract
    {
        allowance[tokenOwner][spender] = value;
    }

    function setBalanceOf(address account, uint value)
        external
        onlyAssociatedContract
    {
        balanceOf[account] = value;
    }


    /* ========== MODIFIERS ========== */

    modifier onlyAssociatedContract
    {
        require(msg.sender == associatedContract);
        _;
    }

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

    event AssociatedContractUpdated(address _associatedContract);
}

    Contract ABI  
[{"constant":true,"inputs":[],"name":"court","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"spender","type":"address"},{"name":"value","type":"uint256"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_beneficiary","type":"address"}],"name":"setBeneficiary","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"poolFeeRate","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"from","type":"address"},{"name":"to","type":"address"},{"name":"value","type":"uint256"}],"name":"transferFrom","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_poolFeeRate","type":"uint256"}],"name":"setPoolFeeRate","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"collateralisationRatio","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"n","type":"uint256"}],"name":"saleProceedsEther","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"canSelfDestruct","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"feeAuthority","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_state","type":"address"}],"name":"setState","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"transferFeeRate","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"beneficiary","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"value","type":"uint256"}],"name":"transferPlusFee","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"lastPriceUpdateTime","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"nominatedOwner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_owner","type":"address"}],"name":"nominateOwner","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"n","type":"uint256"}],"name":"donateToFeePool","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"fiatBalance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"n","type":"uint256"}],"name":"saleProceedsFiat","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"account","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"liquidationTimestamp","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"n","type":"uint256"}],"name":"replenishPool","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":false,"inputs":[{"name":"target","type":"address"}],"name":"unfreezeAccount","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"acceptOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_oracle","type":"address"}],"name":"setOracle","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"oracle","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"n","type":"uint256"}],"name":"diminishPool","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"price","type":"uint256"},{"name":"timeSent","type":"uint256"}],"name":"updatePrice","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"nominPool","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_feeAuthority","type":"address"}],"name":"setFeeAuthority","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_proxy","type":"address"}],"name":"setProxy","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"isLiquidating","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"forceLiquidation","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"etherWei","type":"uint256"}],"name":"fiatValue","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"selfDestruct","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"UNIT","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"etherPrice","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"extension","type":"uint256"}],"name":"extendLiquidationPeriod","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"stalePeriod","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"liquidationPeriod","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_stalePeriod","type":"uint256"}],"name":"setStalePeriod","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"to","type":"address"},{"name":"value","type":"uint256"}],"name":"transfer","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_court","type":"address"}],"name":"setCourt","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"feePool","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"n","type":"uint256"}],"name":"purchaseCostFiat","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"sender","type":"address"}],"name":"setMessageSender","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"state","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"n","type":"uint256"}],"name":"purchaseCostEther","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_transferFeeRate","type":"uint256"}],"name":"setTransferFeeRate","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"frozen","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"n","type":"uint256"}],"name":"buy","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[{"name":"value","type":"uint256"}],"name":"transferFeeIncurred","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"terminateLiquidation","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":false,"inputs":[{"name":"target","type":"address"}],"name":"confiscateBalance","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"from","type":"address"},{"name":"to","type":"address"}],"name":"allowance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"fiat","type":"uint256"}],"name":"etherValue","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"value","type":"uint256"}],"name":"priceToSpend","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"n","type":"uint256"}],"name":"sell","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"proxy","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"n","type":"uint256"}],"name":"poolFeeIncurred","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"account","type":"address"},{"name":"value","type":"uint256"}],"name":"withdrawFee","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"priceIsStale","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_havven","type":"address"},{"name":"_oracle","type":"address"},{"name":"_beneficiary","type":"address"},{"name":"_initialEtherPrice","type":"uint256"},{"name":"_owner","type":"address"},{"name":"_initialState","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":false,"name":"nominsCreated","type":"uint256"},{"indexed":false,"name":"collateralDeposited","type":"uint256"}],"name":"PoolReplenished","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"nominsDestroyed","type":"uint256"}],"name":"PoolDiminished","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"buyer","type":"address"},{"indexed":true,"name":"buyerIndex","type":"address"},{"indexed":false,"name":"nomins","type":"uint256"},{"indexed":false,"name":"etherWei","type":"uint256"}],"name":"Purchased","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"seller","type":"address"},{"indexed":true,"name":"sellerIndex","type":"address"},{"indexed":false,"name":"nomins","type":"uint256"},{"indexed":false,"name":"etherWei","type":"uint256"}],"name":"Sold","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newPrice","type":"uint256"}],"name":"PriceUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newPeriod","type":"uint256"}],"name":"StalePeriodUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newOracle","type":"address"}],"name":"OracleUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newCourt","type":"address"}],"name":"CourtUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newBeneficiary","type":"address"}],"name":"BeneficiaryUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"duration","type":"uint256"}],"name":"LiquidationBegun","type":"event"},{"anonymous":false,"inputs":[],"name":"LiquidationTerminated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"extension","type":"uint256"}],"name":"LiquidationExtended","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newFeeRate","type":"uint256"}],"name":"PoolFeeRateUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"beneficiary","type":"address"}],"name":"SelfDestructed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"target","type":"address"},{"indexed":true,"name":"targetIndex","type":"address"},{"indexed":false,"name":"balance","type":"uint256"}],"name":"AccountFrozen","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"target","type":"address"},{"indexed":true,"name":"targetIndex","type":"address"}],"name":"AccountUnfrozen","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"account","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"TransferFeePaid","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"owner","type":"address"},{"indexed":true,"name":"spender","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newFeeRate","type":"uint256"}],"name":"TransferFeeRateUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"feeAuthority","type":"address"}],"name":"FeeAuthorityUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newState","type":"address"}],"name":"StateUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"account","type":"address"},{"indexed":true,"name":"accountIndex","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"FeesWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"donor","type":"address"},{"indexed":true,"name":"donorIndex","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"FeesDonated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"proxyAddress","type":"address"}],"name":"ProxyChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newOwner","type":"address"}],"name":"OwnerNominated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"oldOwner","type":"address"},{"indexed":false,"name":"newOwner","type":"address"}],"name":"OwnerChanged","type":"event"}]

  Contract Creation Code Switch To Opcodes View
60606040526611c37937e08000600e5562127500600f55600019601055610e1060135534156200002e57600080fd5b60405160c08062003adc83398101604052808051919060200180519190602001805191906020018051919060200180519190602001805191506040905080519081016040908152601782527f45746865722d4261636b656420555344204e6f6d696e7300000000000000000060208301528051908101604052600481527f6555534400000000000000000000000000000000000000000000000000000000602082015260008054600160a060020a031916600160a060020a03868116919091179091556605543df729c00090899085908790821615156200016a578030620001156200028a565b600160a060020a0392831681529116602082015260409081019051809103906000f08015156200014457600080fd5b60048054600160a060020a031916600160a060020a039290921691909117905562000186565b60048054600160a060020a031916600160a060020a0384161790555b60058680516200019b9291602001906200029b565b506006858051620001b19291602001906200029b565b5060098054600160a060020a031916600160a060020a038516179055600a670de0b6b3a764000004841115620001e657600080fd5b5050506008555050600a8054600160a060020a03808816600160a060020a031992831617909255600c8054928716929091169190911790556011839055426012557f66cbca4f3c64fecf1dcb9ce094abcf7f68c3450a1d4e3a8e917dd621edb4ebe08360405190815260200160405180910390a1505050600160a060020a0330166000908152601460205260409020805460ff191660011790555062000340915050565b60405161054e806200358e83390190565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620002de57805160ff19168380011785556200030e565b828001600101855582156200030e579182015b828111156200030e578251825591602001919060010190620002f1565b506200031c92915062000320565b5090565b6200033d91905b808211156200031c576000815560010162000327565b90565b61323e80620003506000396000f3006060604052600436106103075763ffffffff60e060020a600035041662971a30811461030957806306fdde0314610338578063095ea7b3146103c257806318160ddd146103f85780631c31f7101461041d57806322b954f81461043c57806323b872dd1461044f57806327b4e228146104775780632c5f52341461048d5780632d68bc6e146104a05780632f3e9bc5146104b6578063313ce567146104c957806331dbd8a5146104f257806334c901af14610505578063351bf5181461052457806338af3eed1461053757806345df30d21461054a57806349b9a7af1461056057806353a47bb7146105735780635b94db271461058657806363ff6125146105a5578063649f0153146105bb578063658c55ed146105ce57806370a08231146105e457806374b874a614610603578063787ccb6114610616578063788649ea1461062157806379ba5097146106405780637adbf973146106535780637dc0d1d014610672578063820267ff1461068557806382367b2d1461069b57806387b9e310146106b45780638a957929146106c75780638da5cb5b146106e657806395d89b41146106f957806397107d6d1461070c57806397f58e911461072b5780639a819e5e1461073e5780639b67bfa3146107515780639cb8a26a146107675780639d8e21771461077a5780639e3079551461078d578063a3d658dc146107a0578063a5b36a36146107b6578063a6eea7f3146107c9578063a6f4ab2e146107dc578063a9059cbb146107f2578063abf15bb314610814578063ae2e933b14610833578063ba9ea41314610846578063bc67f8321461085c578063c19d93fb1461087b578063c794ef101461088e578063c894e1e5146108a4578063d0516650146108ba578063d96a094a146108d9578063da46e6c4146108e4578063dca92eb5146108fa578063dd1bb3d114610902578063dd62ed3e14610921578063e0179e6c14610946578063e3f310c71461095c578063e4849b3214610972578063ec55688914610988578063f43bac531461099b578063fd9be522146109b1578063ffb1a06d146109d3575b005b341561031457600080fd5b61031c6109e6565b604051600160a060020a03909116815260200160405180910390f35b341561034357600080fd5b61034b6109f5565b60405160208082528190810183818151815260200191508051906020019080838360005b8381101561038757808201518382015260200161036f565b50505050905090810190601f1680156103b45780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34156103cd57600080fd5b6103e4600160a060020a0360043516602435610a93565b604051901515815260200160405180910390f35b341561040357600080fd5b61040b610b98565b60405190815260200160405180910390f35b341561042857600080fd5b610307600160a060020a0360043516610b9e565b341561044757600080fd5b61040b610c48565b341561045a57600080fd5b6103e4600160a060020a0360043581169060243516604435610c4e565b341561048257600080fd5b610307600435610cc9565b341561049857600080fd5b61040b610d68565b34156104ab57600080fd5b61040b600435610d87565b34156104c157600080fd5b6103e4610da0565b34156104d457600080fd5b6104dc610def565b60405160ff909116815260200160405180910390f35b34156104fd57600080fd5b61031c610df4565b341561051057600080fd5b610307600160a060020a0360043516610e03565b341561052f57600080fd5b61040b610ead565b341561054257600080fd5b61031c610eb3565b341561055557600080fd5b61040b600435610ec2565b341561056b57600080fd5b61040b610ed6565b341561057e57600080fd5b61031c610edc565b341561059157600080fd5b610307600160a060020a0360043516610eeb565b34156105b057600080fd5b6103e4600435610f61565b34156105c657600080fd5b61040b6111dd565b34156105d957600080fd5b61040b6004356111f2565b34156105ef57600080fd5b61040b600160a060020a0360043516611206565b341561060e57600080fd5b61040b611275565b61030760043561127b565b341561062c57600080fd5b610307600160a060020a036004351661135d565b341561064b57600080fd5b61030761144e565b341561065e57600080fd5b610307600160a060020a03600435166114e8565b341561067d57600080fd5b61031c611592565b341561069057600080fd5b6103076004356115a1565b34156106a657600080fd5b610307600435602435611645565b34156106bf57600080fd5b61040b611702565b34156106d257600080fd5b610307600160a060020a0360043516611708565b34156106f157600080fd5b61031c6117b2565b341561070457600080fd5b61034b6117c1565b341561071757600080fd5b610307600160a060020a036004351661182c565b341561073657600080fd5b6103e46118a2565b341561074957600080fd5b6103076118ac565b341561075c57600080fd5b61040b600435611917565b341561077257600080fd5b610307611937565b341561078557600080fd5b61040b6119f0565b341561079857600080fd5b61040b6119fc565b34156107ab57600080fd5b610307600435611a02565b34156107c157600080fd5b61040b611ac1565b34156107d457600080fd5b61040b611ac7565b34156107e757600080fd5b610307600435611acd565b34156107fd57600080fd5b6103e4600160a060020a0360043516602435611b57565b341561081f57600080fd5b610307600160a060020a0360043516611bd0565b341561083e57600080fd5b61040b611c7a565b341561085157600080fd5b61040b600435611ce8565b341561086757600080fd5b610307600160a060020a0360043516611cf7565b341561088657600080fd5b61031c611d34565b341561089957600080fd5b61040b600435611d43565b34156108af57600080fd5b610307600435611d51565b34156108c557600080fd5b6103e4600160a060020a0360043516611df0565b610307600435611e05565b34156108ef57600080fd5b61040b600435612001565b61030761200f565b341561090d57600080fd5b610307600160a060020a03600435166120ec565b341561092c57600080fd5b61040b600160a060020a03600435811690602435166124ba565b341561095157600080fd5b61040b600435612532565b341561096757600080fd5b61040b600435612552565b341561097d57600080fd5b61030760043561256b565b341561099357600080fd5b61031c612799565b34156109a657600080fd5b61040b6004356127a8565b34156109bc57600080fd5b6103e4600160a060020a03600435166024356127b6565b34156109de57600080fd5b6103e46129fd565b600b54600160a060020a031681565b60058054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610a8b5780601f10610a6057610100808354040283529160200191610a8b565b820191906000526020600020905b815481529060010190602001808311610a6e57829003601f168201915b505050505081565b600254600090819033600160a060020a03908116911614610aca5760038054600160a060020a03191633600160a060020a03161790555b50600354600454600160a060020a03918216911663da46098c82868660405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401600060405180830381600087803b1515610b3557600080fd5b5af11515610b4257600080fd5b50505083600160a060020a031681600160a060020a03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258560405190815260200160405180910390a3600191505b5092915050565b60075481565b60025433600160a060020a03908116911614610bd05760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a03908116911614610bed57600080fd5b600c8054600160a060020a031916600160a060020a0383161790557feee59a71c694e68368a1cb0d135c448051bbfb12289e6c2223b0ceb100c2321d81604051600160a060020a03909116815260200160405180910390a150565b600e5481565b60025460009033600160a060020a03908116911614610c835760038054600160a060020a03191633600160a060020a03161790555b600160a060020a03831660009081526014602052604090205460ff1615610ca957600080fd5b600354610cc190600160a060020a0316858585612a14565b949350505050565b60025433600160a060020a03908116911614610cfb5760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a03908116911614610d1857600080fd5b670de0b6b3a7640000811115610d2d57600080fd5b600e8190557f4248f834b143cf7683c8c31bb764ab12332813d7673c0206f6c704631dda9da98160405190815260200160405180910390a150565b6000610d82610d756111dd565b610d7d612de2565b612df2565b905090565b6000610d9a610d95836111f2565b612532565b92915050565b6000806000610dad6118a2565b15610de55742600f54601054011091504260105462093a8001108015610dd35750600754155b90508180610dde5750805b9250610dea565b600092505b505090565b601281565b600954600160a060020a031681565b60025433600160a060020a03908116911614610e355760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a03908116911614610e5257600080fd5b60048054600160a060020a031916600160a060020a0383161790557f3f7c5904943ad21b9256174ea1f6c00b1785c4a181ffe526f8bba2ac0ad2a06d81604051600160a060020a03909116815260200160405180910390a150565b60085481565b600c54600160a060020a031681565b6000610d9a82610ed184612001565b612e0f565b60125481565b600154600160a060020a031681565b60005433600160a060020a03908116911614610f0657600080fd5b60018054600160a060020a031916600160a060020a0383161790557f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce2281604051600160a060020a03909116815260200160405180910390a150565b6002546000908190819033600160a060020a03908116911614610f9a5760038054600160a060020a03191633600160a060020a03161790555b600354600454600160a060020a039182169350166370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515610ff257600080fd5b5af11515610fff57600080fd5b505050604051805191505080151561101657600080fd5b600454600160a060020a031663b46310f6836110328488612e26565b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b151561107557600080fd5b5af1151561108257600080fd5b5050600454600160a060020a0316905063b46310f6306110fd836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156110e057600080fd5b5af115156110ed57600080fd5b5050506040518051905088612e0f565b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b151561114057600080fd5b5af1151561114d57600080fd5b50505081600160a060020a03167f7c2a76b2c053ee4836cd3b69cf3bc72cfd559c7f45b0ff3634fc82570a9c6d318386604051600160a060020a03909216825260208201526040908101905180910390a230600160a060020a031682600160a060020a03166000805160206131f38339815191528660405190815260200160405180910390a35060019392505050565b6000610d8230600160a060020a031631611917565b6000610d9a82611201846127a8565b612e26565b600454600090600160a060020a03166370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b151561125957600080fd5b5af1151561126657600080fd5b50505060405180519392505050565b60105481565b6112836118a2565b1561128d57600080fd5b60025433600160a060020a039081169116146112bf5760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a039081169116146112dc57600080fd5b6112fe6112f06112ea612de2565b83612e0f565b671bc16d674ec80000612e3b565b6113066111dd565b101561131157600080fd5b61131d600d5482612e0f565b600d557f0e620d27acb9f93e5e62c85454b079d64cd082517f67f03f0d230501c2a7f9d8813460405191825260208201526040908101905180910390a150565b60025433600160a060020a0390811691161461138f5760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a039081169116146113ac57600080fd5b600160a060020a03811660009081526014602052604090205460ff1680156113e6575030600160a060020a031681600160a060020a031614155b1561144b57600160a060020a03811660008181526014602052604090819020805460ff191690557fe19c610e04dba2019efcfb0f9455fad3af646853bb02abad2a452db1fd47c32790839051600160a060020a03909116815260200160405180910390a25b50565b60015433600160a060020a0390811691161461146957600080fd5b6000546001547fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c91600160a060020a039081169116604051600160a060020a039283168152911660208201526040908101905180910390a16001805460008054600160a060020a0319908116600160a060020a03841617909155169055565b60025433600160a060020a0390811691161461151a5760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a0390811691161461153757600080fd5b600a8054600160a060020a031916600160a060020a0383161790557f3df77beb5db05fcdd70a30fc8adf3f83f9501b68579455adbd100b818094039481604051600160a060020a03909116815260200160405180910390a150565b600a54600160a060020a031681565b60025433600160a060020a039081169116146115d35760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a039081169116146115f057600080fd5b600d548190101561160057600080fd5b61160c600d5482612e26565b600d557f4b76def2e56dd5daabeaae56d34887cc5073cf50f563b13954ca5fc7f2a95a7c8160405190815260200160405180910390a150565b600a5433600160a060020a0390811691161461166057600080fd5b806012541080156116745750426102580181105b151561167f57600080fd5b601182905560128190557f66cbca4f3c64fecf1dcb9ce094abcf7f68c3450a1d4e3a8e917dd621edb4ebe08260405190815260200160405180910390a16116c46118a2565b1580156116d757506116d4612de2565b15155b80156116f15750670de0b6b3a76400006116ef610d68565b105b156116fe576116fe612e61565b5050565b600d5481565b60025433600160a060020a0390811691161461173a5760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a0390811691161461175757600080fd5b60098054600160a060020a031916600160a060020a0383161790557feb54700789b1b422a4c425a3586e928427c0fa693cb1d37146c9b3153ca701dd81604051600160a060020a03909116815260200160405180910390a150565b600054600160a060020a031681565b60068054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610a8b5780601f10610a6057610100808354040283529160200191610a8b565b60005433600160a060020a0390811691161461184757600080fd5b60028054600160a060020a031916600160a060020a0383161790557ff0cd76016a4ee33fe62814f8afd5492f47062ea7615bcc094f2f6fe71b62d1c481604051600160a060020a03909116815260200160405180910390a150565b6010544290111590565b6118b46118a2565b156118be57600080fd5b60025433600160a060020a039081169116146118f05760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a0390811691161461190d57600080fd5b611915612e61565b565b60006119216129fd565b1561192b57600080fd5b610d9a82601154612e3b565b60025433600160a060020a039081169116146119695760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a0390811691161461198657600080fd5b61198e610da0565b151561199957600080fd5b600c547f8a09e1677ced846cb537dc2b172043bd05a1a81ad7e0033a7ef8ba762df990b790600160a060020a0316604051600160a060020a03909116815260200160405180910390a1600c54600160a060020a0316ff5b670de0b6b3a764000081565b60115481565b60025460009033600160a060020a03908116911614611a375760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a03908116911614611a5457600080fd5b611a5c6118a2565b1515611a6757600080fd5b611a73600f5483612e0f565b905062ed4e00811115611a8557600080fd5b600f8190557f8a86a80c4104f219f26eaad482ccd6338083a19e4b2d96c2c2c6ea7225868b868260405190815260200160405180910390a15050565b60135481565b600f5481565b60025433600160a060020a03908116911614611aff5760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a03908116911614611b1c57600080fd5b60138190557f8e163815dacf2204ab589790672a86e421041804acc4cb85a7caebac33be1b2b8160405190815260200160405180910390a150565b60025460009033600160a060020a03908116911614611b8c5760038054600160a060020a03191633600160a060020a03161790555b600160a060020a03831660009081526014602052604090205460ff1615611bb257600080fd5b600354611bc990600160a060020a03168484612e9d565b9392505050565b60025433600160a060020a03908116911614611c025760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a03908116911614611c1f57600080fd5b600b8054600160a060020a031916600160a060020a0383161790557f37f0104bb744a510b6d9827b3bfdf4828cdbdb5f02fb7868916d8bafefdd607c81604051600160a060020a03909116815260200160405180910390a150565b600454600090600160a060020a03166370a082313060405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515611ccd57600080fd5b5af11515611cda57600080fd5b505050604051805191505090565b6000610d9a82610ed1846127a8565b60025433600160a060020a03908116911614611d1257600080fd5b60038054600160a060020a031916600160a060020a0392909216919091179055565b600454600160a060020a031681565b6000610d9a610d9583611ce8565b60025433600160a060020a03908116911614611d835760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a03908116911614611da057600080fd5b67016345785d8a0000811115611db557600080fd5b60088190557f1723c194c108df281b957a5141ed3ebce4571635c93643f26ae09f0b153b4a9e8160405190815260200160405180910390a150565b60146020526000908152604090205460ff1681565b6000611e0f6118a2565b15611e1957600080fd5b60025433600160a060020a03908116911614611e4b5760038054600160a060020a03191633600160a060020a03161790555b662386f26fc100008210801590611e695750611e6682611d43565b34145b1515611e7457600080fd5b50600354600d54600160a060020a0390911690611e919083612e26565b600d55600454600160a060020a031663b46310f682611f0b836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515611eee57600080fd5b5af11515611efb57600080fd5b5050506040518051905086612e0f565b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b1515611f4e57600080fd5b5af11515611f5b57600080fd5b50505080600160a060020a03167fa326259ec721617acd3cb2a00bcbeac91eefe409880e49aa2bbf473ed648da498284346040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a280600160a060020a031660006000805160206131f38339815191528460405190815260200160405180910390a3611ffa60075483612e0f565b6007555050565b6000610d9a82600854612e3b565b6120176129fd565b1561202157600080fd5b60025433600160a060020a039081169116146120535760038054600160a060020a03191633600160a060020a03161790555b600054600354600160a060020a0390811691161461207057600080fd5b6120786118a2565b151561208357600080fd5b61208b612de2565b15806120a65750670de0b6b3a76400006120a3610d68565b10155b15156120b157600080fd5b60001960105562127500600f557ff256503eab0513973b08c23f99f0ae7cd40d6e9311a798e8f8c210e86a8a467860405160405180910390a1565b600b54600090819033600160a060020a0390811691161461210c57600080fd5b600b54600160a060020a0316632a136e688460405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b151561215c57600080fd5b5af1151561216957600080fd5b505050604051805192505081151561218057600080fd5b600b54600160a060020a03166363cdcc578360405160e060020a63ffffffff84160281526004810191909152602401602060405180830381600087803b15156121c857600080fd5b5af115156121d557600080fd5b5050506040518051905015156121ea57600080fd5b600b54600160a060020a0316630495cad98360405160e060020a63ffffffff84160281526004810191909152602401602060405180830381600087803b151561223257600080fd5b5af1151561223f57600080fd5b50505060405180519050151561225457600080fd5b600160a060020a03831660009081526014602052604090205460ff161561227a57600080fd5b600454600160a060020a03166370a082318460405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156122ca57600080fd5b5af115156122d757600080fd5b5050506040518051600454909250600160a060020a0316905063b46310f63061235b836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b151561233e57600080fd5b5af1151561234b57600080fd5b5050506040518051905085612e0f565b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b151561239e57600080fd5b5af115156123ab57600080fd5b5050600454600160a060020a0316905063b46310f684600060405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b151561240657600080fd5b5af1151561241357600080fd5b505050600160a060020a03831660008181526014602052604090819020805460ff191660011790557f3d2b452a7a7d93059f9babed9978721395c90406833a7865cb2f04716d00539a908590849051600160a060020a03909216825260208201526040908101905180910390a230600160a060020a031683600160a060020a03166000805160206131f38339815191528360405190815260200160405180910390a3505050565b600454600090600160a060020a031663dd62ed3e848460405160e060020a63ffffffff8516028152600160a060020a03928316600482015291166024820152604401602060405180830381600087803b151561251557600080fd5b5af1151561252257600080fd5b5050506040518051949350505050565b600061253c6129fd565b1561254657600080fd5b610d9a82601154612df2565b6000610d9a82610d7d601260ff16600a0a600854612e0f565b600254600090819033600160a060020a039081169116146125a25760038054600160a060020a03191633600160a060020a03161790555b6125aa6118a2565b156125bf576125b88361318a565b91506125cb565b6125c883610d87565b91505b600160a060020a03301631829010156125e357600080fd5b50600354600454600160a060020a03918216911663b46310f682612662836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b151561264557600080fd5b5af1151561265257600080fd5b5050506040518051905087612e26565b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b15156126a557600080fd5b5af115156126b257600080fd5b5050506126c1600d5484612e0f565b600d55600160a060020a0381167f16dd16959a056953a63cf14bf427881e762e54f03d86b864efea8238dd3b822f8285856040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a2600081600160a060020a03166000805160206131f38339815191528560405190815260200160405180910390a361276060075484612e26565b600755600160a060020a03811682156108fc0283604051600060405180830381858888f19350505050151561279457600080fd5b505050565b600254600160a060020a031681565b6000610d9a82600e54612e3b565b60095460009033600160a060020a0390811691161480156127df5750600160a060020a03831615155b15156127ea57600080fd5b8115156127f957506000610d9a565b600454600160a060020a031663b46310f630612870836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b151561285357600080fd5b5af1151561286057600080fd5b5050506040518051905086612e26565b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b15156128b357600080fd5b5af115156128c057600080fd5b5050600454600160a060020a0316905063b46310f68461291e836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515611eee57600080fd5b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b151561296157600080fd5b5af1151561296e57600080fd5b50505082600160a060020a03167f5e110f8bc8a20b65dcc87f224bdf1cc039346e267118bae2739847f07321ffa88484604051600160a060020a03909216825260208201526040908101905180910390a282600160a060020a031630600160a060020a03166000805160206131f38339815191528460405190815260200160405180910390a350600192915050565b600042612a0e601254601354612e0f565b10905090565b60008080600160a060020a0385161515612a2d57600080fd5b612a3684612001565b9150612a428483612e0f565b600454909150600160a060020a031663b46310f687612abc836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515612a9f57600080fd5b5af11515612aac57600080fd5b5050506040518051905085612e26565b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b1515612aff57600080fd5b5af11515612b0c57600080fd5b5050600454600160a060020a0316905063da46098c8789612b738463dd62ed3e848460405160e060020a63ffffffff8516028152600160a060020a03928316600482015291166024820152604401602060405180830381600087803b151561285357600080fd5b60405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401600060405180830381600087803b1515612bc257600080fd5b5af11515612bcf57600080fd5b5050600454600160a060020a0316905063b46310f686612c2d836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156110e057600080fd5b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b1515612c7057600080fd5b5af11515612c7d57600080fd5b5050600454600160a060020a0316905063b46310f630612cdb836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515611eee57600080fd5b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b1515612d1e57600080fd5b5af11515612d2b57600080fd5b50505084600160a060020a031686600160a060020a03166000805160206131f38339815191528660405190815260200160405180910390a385600160a060020a03167f74e89c97bb87f1ef082e7ef8570fe4be758365c8d2e11835b39ff809b4133cf88360405190815260200160405180910390a230600160a060020a031686600160a060020a03166000805160206131f38339815191528460405190815260200160405180910390a35060019695505050505050565b6000610d82600d54600754612e0f565b6000611bc9612e0984670de0b6b3a764000061319d565b836131cb565b600082820182901015612e2157600080fd5b500190565b600082821115612e3557600080fd5b50900390565b6000670de0b6b3a7640000612e50848461319d565b811515612e5957fe5b049392505050565b42601055600f547f3ac0f9ec6629314b92a7cf784cb5a8030d35f18be5382665bb306ade26e26f139060405190815260200160405180910390a1565b60008080600160a060020a0385161515612eb657600080fd5b612ebf84612001565b9150612ecb8483612e0f565b600454909150600160a060020a031663b46310f687612f28836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515612a9f57600080fd5b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b1515612f6b57600080fd5b5af11515612f7857600080fd5b5050600454600160a060020a0316905063b46310f686612fd6836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156110e057600080fd5b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b151561301957600080fd5b5af1151561302657600080fd5b5050600454600160a060020a0316905063b46310f630613084836370a082318360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b1515611eee57600080fd5b60405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401600060405180830381600087803b15156130c757600080fd5b5af115156130d457600080fd5b50505084600160a060020a031686600160a060020a03166000805160206131f38339815191528660405190815260200160405180910390a385600160a060020a03167f74e89c97bb87f1ef082e7ef8570fe4be758365c8d2e11835b39ff809b4133cf88360405190815260200160405180910390a230600160a060020a031686600160a060020a03166000805160206131f38339815191528460405190815260200160405180910390a350600195945050505050565b6000610d9a613198836111f2565b6131e4565b6000808315156131b05760009150610b91565b508282028284828115156131c057fe5b0414611bc957600080fd5b60008115156131d957600080fd5b8183811515612e5957fe5b6000610d9a82601154612df25600ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa165627a7a723058202dd86f34284df472c372486a66a920da09d836f4360458619ab89ab2bc5956b900296060604052341561000f57600080fd5b60405160408061054e833981016040528080519190602001805160008054600160a060020a03808716600160a060020a031992831617909255600280549284169290911691909117905591507f73f20cff579e8a4086fa607db83867595f1b6a798e718c0bfa0b94a404128e03905081604051600160a060020a03909116815260200160405180910390a150506104a3806100ab6000396000f3006060604052600436106100a35763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166352f445ca81146100a857806353a47bb7146100c95780635b94db27146100f857806370a082311461011757806379ba5097146101485780638da5cb5b1461015b578063aefc4ccb1461016e578063b46310f614610181578063da46098c146101a3578063dd62ed3e146101cb575b600080fd5b34156100b357600080fd5b6100c7600160a060020a03600435166101f0565b005b34156100d457600080fd5b6100dc610273565b604051600160a060020a03909116815260200160405180910390f35b341561010357600080fd5b6100c7600160a060020a0360043516610282565b341561012257600080fd5b610136600160a060020a0360043516610305565b60405190815260200160405180910390f35b341561015357600080fd5b6100c7610317565b341561016657600080fd5b6100dc6103be565b341561017957600080fd5b6100dc6103cd565b341561018c57600080fd5b6100c7600160a060020a03600435166024356103dc565b34156101ae57600080fd5b6100c7600160a060020a0360043581169060243516604435610413565b34156101d657600080fd5b610136600160a060020a036004358116906024351661045a565b60005433600160a060020a0390811691161461020b57600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790557f73f20cff579e8a4086fa607db83867595f1b6a798e718c0bfa0b94a404128e0381604051600160a060020a03909116815260200160405180910390a150565b600154600160a060020a031681565b60005433600160a060020a0390811691161461029d57600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790557f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce2281604051600160a060020a03909116815260200160405180910390a150565b60036020526000908152604090205481565b60015433600160a060020a0390811691161461033257600080fd5b6000546001547fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c91600160a060020a039081169116604051600160a060020a039283168152911660208201526040908101905180910390a1600180546000805473ffffffffffffffffffffffffffffffffffffffff19908116600160a060020a03841617909155169055565b600054600160a060020a031681565b600254600160a060020a031681565b60025433600160a060020a039081169116146103f757600080fd5b600160a060020a03909116600090815260036020526040902055565b60025433600160a060020a0390811691161461042e57600080fd5b600160a060020a0392831660009081526004602090815260408083209490951682529290925291902055565b6004602090815260009283526040808420909152908252902054815600a165627a7a7230582044a5ac85fb2d68ff813fbafcb54f31fb21f08e71c140891734ee5d014bfb4bc90029000000000000000000000000f244176246168f24e3187f7288edbca29267739b000000000000000000000000b10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b000000000000000000000000b10c85274d2a58ddec72c1d826e75256ff93dead000000000000000000000000000000000000000000000015c4744d3b4e100000000000000000000000000000b10c85274d2a58ddec72c1d826e75256ff93dead0000000000000000000000000000000000000000000000000000000000000000

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

-----Encoded View---------------
6 Constructor Arguments found :
Arg [0] : 000000000000000000000000f244176246168f24e3187f7288edbca29267739b
Arg [1] : 000000000000000000000000b10c8f6d5a3a99267fa2a34fbb66c94ba913ee0b
Arg [2] : 000000000000000000000000b10c85274d2a58ddec72c1d826e75256ff93dead
Arg [3] : 000000000000000000000000000000000000000000000015c4744d3b4e100000
Arg [4] : 000000000000000000000000b10c85274d2a58ddec72c1d826e75256ff93dead
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000000


   Swarm Source:
bzzr://44a5ac85fb2d68ff813fbafcb54f31fb21f08e71c140891734ee5d014bfb4bc9

 

View All
Block Age transaction Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.