Address Details
contract
token

0x08289E751817A8D27c18D81C900387105714efC3

Token
Savings CELO (sCELO)
Creator
0x4d82bf–a04757 at 0xf3b5ce–8326e3
Balance
0 CELO
Tokens
Fetching tokens...
Transactions
18 Transactions
Transfers
26 Transfers
Gas Used
2,417,914
Last Balance Update
4945768
This contract has been verified via Sourcify. View contract in Sourcify repository
Contract name:
SavingsCELO




Optimization enabled
false
Compiler version
v0.6.8+commit.0bbfe453




EVM Version
istanbul




Verified at
2021-08-09T16:45:43.612292Z

Contract source code

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/math/SafeMath.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

import "./UsingRegistry.sol";
import "./interfaces/IRegistry.sol";
import "./interfaces/ILockedGold.sol";
import "./interfaces/IElection.sol";
import "./interfaces/IVoterProxy.sol";

contract SavingsCELO is ERC20, IVoterProxy, Ownable, UsingRegistry {
	using SafeMath for uint256;

	address public _voter;

	event VoterAuthorized(address indexed previousVoter, address indexed newVoter);

	struct PendingWithdrawal {
		// The value of the pending withdrawal.
		uint256 value;
		// The timestamp at which the pending withdrawal becomes available.
		uint256 timestamp;
	}
	mapping(address => PendingWithdrawal[]) internal pendingByAddr;

	event Deposited(address indexed from, uint256 celoAmount, uint256 savingsAmount);
	event WithdrawStarted(address indexed from, uint256 savingsAmount, uint256 celoAmount);
	event WithdrawFinished(address indexed from, uint256 celoAmount);
	event WithdrawCanceled(address indexed from, uint256 celoAmount, uint256 savingsAmount);

	constructor () ERC20("Savings CELO", "sCELO") public {
		require(
			getAccounts().createAccount(),
			"createAccount failed");
	}

	/// Authorizes new vote signer that can manage voting for all of contract's locked
	/// CELO. {v, r, s} constitutes proof-of-key-possession signature of signer for this
	/// contract address.
	/// Vote Signer authorization exists only as a means of a potential escape-hatch if
	/// some sort of really unexpected issue occurs. By default, it is expected that there
	/// will be no authorized vote signer, and a voting contract will be configured using
	/// .authorizeVoterProxy call instead.
	function authorizeVoteSigner(
		address signer,
		uint8 v,
		bytes32 r,
		bytes32 s) onlyOwner external {
		getAccounts().authorizeVoteSigner(signer, v, r, s);
	}

	/// Authorizes another contract to perform voting on behalf of SavingsCELO.
	function authorizeVoterProxy(address proxy) onlyOwner external {
		_voter = proxy;
		emit VoterAuthorized(_voter, proxy);
	}

	modifier voterProxyOnly() {
		require(_voter == msg.sender, "caller must be the registered _voter");
		_;
	}

	// Proxy functions for validator election voting.
	function proxyVote(
		address group,
		uint256 value,
		address lesser,
		address greater) voterProxyOnly external override returns (bool) {
		return getElection().vote(group, value, lesser, greater);
	}
	function proxyActivate(address group) voterProxyOnly external override returns (bool) {
		return getElection().activate(group);
	}
	function proxyRevokeActive(
		address group,
		uint256 value,
		address lesser,
		address greater,
		uint256 index) voterProxyOnly external override returns (bool) {
		return getElection().revokeActive(group, value, lesser, greater, index);
	}
	function proxyRevokePending(
		address group,
		uint256 value,
		address lesser,
		address greater,
		uint256 index) voterProxyOnly external override returns (bool) {
		return getElection().revokePending(group, value, lesser, greater, index);
	}

	// Proxy functions for governance voting. It is extremely unlikely that these
	// functions will ever be used, but they are provided just in case there is some idea
	// in the future for voterProxy contract to utilize them.
	function proxyGovernanceVote(
		uint256 proposalId,
		uint256 index,
		Governance.VoteValue value) voterProxyOnly external override returns (bool) {
		return getGovernance().vote(proposalId, index, value);
	}
	function proxyGovernanceUpvote(
		uint256 proposalId,
		uint256 lesser,
		uint256 greater) voterProxyOnly external override returns (bool) {
		return getGovernance().upvote(proposalId, lesser, greater);
	}
	function proxyGovernanceRevokeUpvote(
		uint256 lesser,
		uint256 greater) voterProxyOnly external override returns (bool) {
		return getGovernance().revokeUpvote(lesser, greater);
	}

	/// Deposits CELO to the contract in exchange of SavingsCELO tokens. CELO tokens are transfered
	/// using ERC20.transferFrom call, thus caller must call .approve or .increaseAllowance first to
	/// allow for the transfer to go through.
	function deposit() external payable {
		uint256 totalCELO = totalSupplyCELO().sub(msg.value);
		uint256 totalSavingsCELO = this.totalSupply();
		uint256 toMint = savingsToMint(totalSavingsCELO, totalCELO, msg.value);
		_mint(msg.sender, toMint);

		uint256 toLock = address(this).balance;
		assert(toLock >= msg.value);
		// It is safe to call _lockedGold.lock() with 0 value.
		getLockedGold().lock{value: toLock}();
		emit Deposited(msg.sender, msg.value, toMint);
	}

	/// Starts withdraw process for savingsAmount SavingsCELO tokens. Since only nonvoting CELO can be
	/// unlocked, withdrawStart might have to call Election.revoke* calls to revoke currently cast votes.
	/// To keep this call simple, maximum amount of CELO that can be unlocked in single call is:
	/// `nonvoting locked CELO + total votes for last voted group`. This way, withdrawStart call will only
	/// revoke votes for a single group at most, making it simpler overall.
	///
	/// lesser.../greater... parameters are needed to perform Election.revokePending and Election.revokeActive
	/// calls. See Election contract for more details. lesser.../greater... arguments
	/// are for last voted group by this contract, since revoking only happens for the last voted group.
	///
	/// Note that it is possible for this call to fail due to accidental race conditions if lesser.../greater...
	/// parameters no longer match due to changes in overall voting ranking.
	function withdrawStart(
		uint256 savingsAmount,
		address lesserAfterPendingRevoke,
		address greaterAfterPendingRevoke,
		address lesserAfterActiveRevoke,
		address greaterAfterActiveRevoke
		) external {
		require(savingsAmount > 0, "withdraw amount must be positive");
		uint256 totalCELO = totalSupplyCELO();
		uint256 totalSavingsCELO = this.totalSupply();
		_burn(msg.sender, savingsAmount);
		// If there is any unlocked CELO, lock it to make rest of the logic always
		// consistent. There should never be unlocked CELO in the contract unless some
		// user explicitly donates it.
		uint256 unlocked = address(this).balance;
		ILockedGold _lockedGold = getLockedGold();
		if (unlocked > 0) {
			_lockedGold.lock{value: unlocked}();
		}
		// toUnlock formula comes from:
		// (supply / totalCELO) === (supply - savingsAmount) / (totalCELO - toUnlock)
		uint256 toUnlock = savingsAmount.mul(totalCELO).div(totalSavingsCELO);
		uint256 nonvoting = _lockedGold.getAccountNonvotingLockedGold(address(this));
		if (toUnlock > nonvoting) {
			revokeVotes(
				toUnlock.sub(nonvoting),
				lesserAfterPendingRevoke,
				greaterAfterPendingRevoke,
				lesserAfterActiveRevoke,
				greaterAfterActiveRevoke
			);
		}
		_lockedGold.unlock(toUnlock);

		(uint256[] memory pendingValues, uint256[] memory pendingTimestamps) = _lockedGold.getPendingWithdrawals(address(this));
		uint256 pendingValue = pendingValues[pendingValues.length - 1];
		assert(pendingValue == toUnlock);
		pendingByAddr[msg.sender].push(PendingWithdrawal(pendingValue, pendingTimestamps[pendingTimestamps.length - 1]));
		emit WithdrawStarted(msg.sender, savingsAmount, pendingValue);
	}

	/// Helper function to revoke cast votes. See documentation for .withdrawStart function for more
	/// information about the arguments.
	function revokeVotes(
		uint256 toRevoke,
		address lesserAfterPendingRevoke,
		address greaterAfterPendingRevoke,
		address lesserAfterActiveRevoke,
		address greaterAfterActiveRevoke
	) private {
		IElection _election = getElection();
		address[] memory votedGroups = _election.getGroupsVotedForByAccount(address(this));
		require(votedGroups.length > 0, "not enough votes to revoke");
		uint256 revokeIndex = votedGroups.length - 1;
		address revokeGroup = votedGroups[revokeIndex];
		uint256 pendingVotes = _election.getPendingVotesForGroupByAccount(revokeGroup, address(this));
		uint256 activeVotes = _election.getActiveVotesForGroupByAccount(revokeGroup, address(this));
		require(
			pendingVotes.add(activeVotes) >= toRevoke,
			"not enough unlocked CELO and revokable votes");

		uint256 toRevokePending = pendingVotes;
		if (toRevokePending > toRevoke) {
			toRevokePending = toRevoke;
		}
		uint256 toRevokeActive = toRevoke.sub(toRevokePending);
		if (toRevokePending > 0) {
			require(
				_election.revokePending(
				revokeGroup, toRevokePending, lesserAfterPendingRevoke, greaterAfterPendingRevoke, revokeIndex),
				"revokePending failed");
		}
		if (toRevokeActive > 0) {
			require(
				_election.revokeActive(
				revokeGroup, toRevokeActive, lesserAfterActiveRevoke, greaterAfterActiveRevoke, revokeIndex),
				"revokeActive failed");
		}
	}

	/// Finishes withdraw process, transfering unlocked CELO back to the caller.
	/// `index` is index of pending withdrawal to finish as returned by .pendingWithdrawals() call.
	/// `indexGlobal` is index of matching pending withdrawal as returned by lockedGold.getPendingWithdrawals() call.
	function withdrawFinish(uint256 index, uint256 indexGlobal) external {
		PendingWithdrawal memory pending = popPendingWithdrawal(msg.sender, index, indexGlobal);
		getLockedGold().withdraw(indexGlobal);
		require(
			getGoldToken().transfer(msg.sender, pending.value),
			"unexpected failure: CELO transfer has failed");
		emit WithdrawFinished(msg.sender, pending.value);
	}

	/// Cancels withdraw process, re-locking CELO back in the contract and returning SavingsCELO tokens back
	/// to the caller. At the time of re-locking, SavingsCELO can be more valuable compared to when .withdrawStart
	/// was called. Thus caller might receive less SavingsCELO compared to what was supplied to .withdrawStart.
	/// `index` is index of pending withdrawal to finish as returned by .pendingWithdrawals() call.
	/// `indexGlobal` is index of matching pending withdrawal as returned by lockedGold.getPendingWithdrawals() call.
	function withdrawCancel(uint256 index, uint256 indexGlobal) external {
		PendingWithdrawal memory pending = popPendingWithdrawal(msg.sender, index, indexGlobal);
		uint256 totalCELO = totalSupplyCELO();
		uint256 totalSavingsCELO = this.totalSupply();
		getLockedGold().relock(indexGlobal, pending.value);
		uint256 toMint = savingsToMint(totalSavingsCELO, totalCELO, pending.value);
		_mint(msg.sender, toMint);
		emit WithdrawCanceled(msg.sender, pending.value, toMint);
	}

	/// Returns (values[], timestamps[]) of all pending withdrawals for given address.
	function pendingWithdrawals(address addr)
		external
		view
		returns (uint256[] memory, uint256[] memory) {
		PendingWithdrawal[] storage pending = pendingByAddr[addr];
		uint256 length = pending.length;
		uint256[] memory values = new uint256[](length);
		uint256[] memory timestamps = new uint256[](length);
		for (uint256 i = 0; i < length; i = i.add(1)) {
			values[i] = pending[i].value;
			timestamps[i] = pending[i].timestamp;
		}
		return (values, timestamps);
	}

	/// Helper function to verify indexes and to pop specific PendingWithdrawal from the list.
	function popPendingWithdrawal(
		address addr,
		uint256 index,
		uint256 indexGlobal) private returns(PendingWithdrawal memory pending) {
		PendingWithdrawal[] storage pendings = pendingByAddr[addr];
		require(index < pendings.length, "bad pending withdrawal index");
		(uint256[] memory pendingValues, uint256[] memory pendingTimestamps) = getLockedGold().getPendingWithdrawals(address(this));
		require(indexGlobal < pendingValues.length, "bad pending withdrawal indexGlobal");
		require(pendings[index].value == pendingValues[indexGlobal], "mismatched value for index and indexGlobal");
		require(pendings[index].timestamp == pendingTimestamps[indexGlobal], "mismatched timestamp for index and indexGlobal");
		pending = pendings[index]; // This makes a copy.

		pendings[index] = pendings[pendings.length - 1];
		pendings.pop();
		return pending;
	}


	/// Returns amount of CELO that can be claimed for savingsAmount SavingsCELO tokens.
	function savingsToCELO(uint256 savingsAmount) external view returns (uint256) {
		uint256 totalSavingsCELO = this.totalSupply();
		if (totalSavingsCELO == 0) {
			return 0;
		}
		uint256 totalCELO = totalSupplyCELO();
		return savingsAmount.mul(totalCELO).div(totalSavingsCELO);
	}
	/// Returns amount of SavingsCELO tokens that can be received for depositing celoAmount CELO tokens.
	function celoToSavings(uint256 celoAmount) external view returns (uint256) {
		uint256 totalSavingsCELO = this.totalSupply();
		uint256 totalCELO = totalSupplyCELO();
		return savingsToMint(totalSavingsCELO, totalCELO, celoAmount);
	}

	function totalSupplyCELO() internal view returns(uint256) {
		uint256 locked = getLockedGold().getAccountTotalLockedGold(address(this));
		uint256 unlocked = address(this).balance;
		return locked.add(unlocked);
	}

	function savingsToMint(
		uint256 totalSavingsCELO,
		uint256 totalCELO,
		uint256 celoToAdd) private pure returns (uint256) {
		if (totalSavingsCELO == 0 || totalCELO == 0) {
			// 2^16 is chosen arbitrarily. since maximum amount of CELO is capped at 1BLN, we can afford to
			// multiply it by 2^16 without running into any overflow issues. This also makes it clear that
			// SavingsCELO and CELO don't have 1:1 relationship to avoid confusion down the line.
			return celoToAdd.mul(65536);
		}
		return celoToAdd.mul(totalSavingsCELO).div(totalCELO);
	}

	receive() external payable {}
}
        

Address.sol

// SPDX-License-Identifier: MIT

pragma solidity ^0.6.2;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies in extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // solhint-disable-next-line no-inline-assembly
        assembly { size := extcodesize(account) }
        return size > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (bool success, ) = recipient.call{ value: amount }("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain`call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
      return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        return _functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        return _functionCallWithValue(target, data, value, errorMessage);
    }

    function _functionCallWithValue(address target, bytes memory data, uint256 weiValue, string memory errorMessage) private returns (bytes memory) {
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.call{ value: weiValue }(data);
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}
          

IERC20.sol

// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

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

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

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

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

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

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

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

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

ERC20.sol

// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

import "../../GSN/Context.sol";
import "./IERC20.sol";
import "../../math/SafeMath.sol";
import "../../utils/Address.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin guidelines: functions revert instead
 * of returning `false` on failure. This behavior is nonetheless conventional
 * and does not conflict with the expectations of ERC20 applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20 {
    using SafeMath for uint256;
    using Address for address;

    mapping (address => uint256) private _balances;

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

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;
    uint8 private _decimals;

    /**
     * @dev Sets the values for {name} and {symbol}, initializes {decimals} with
     * a default value of 18.
     *
     * To select a different value for {decimals}, use {_setupDecimals}.
     *
     * All three of these values are immutable: they can only be set once during
     * construction.
     */
    constructor (string memory name, string memory symbol) public {
        _name = name;
        _symbol = symbol;
        _decimals = 18;
    }

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

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

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

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

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

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

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

    /**
     * @dev See {IERC20-approve}.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20};
     *
     * Requirements:
     * - `sender` and `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     * - the caller must have allowance for ``sender``'s tokens of at least
     * `amount`.
     */
    function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(sender, recipient, amount);
        _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance"));
        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero"));
        return true;
    }

    /**
     * @dev Moves tokens `amount` from `sender` to `recipient`.
     *
     * This is internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `sender` cannot be the zero address.
     * - `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     */
    function _transfer(address sender, address recipient, uint256 amount) internal virtual {
        require(sender != address(0), "ERC20: transfer from the zero address");
        require(recipient != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(sender, recipient, amount);

        _balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exceeds balance");
        _balances[recipient] = _balances[recipient].add(amount);
        emit Transfer(sender, recipient, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements
     *
     * - `to` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply = _totalSupply.add(amount);
        _balances[account] = _balances[account].add(amount);
        emit Transfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        _balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance");
        _totalSupply = _totalSupply.sub(amount);
        emit Transfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(address owner, address spender, uint256 amount) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Sets {decimals} to a value other than the default one of 18.
     *
     * WARNING: This function should only be called from the constructor. Most
     * applications that interact with token contracts will not expect
     * {decimals} to ever change, and may work incorrectly if it does.
     */
    function _setupDecimals(uint8 decimals_) internal {
        _decimals = decimals_;
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be to transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual { }
}
          

SafeMath.sol

// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

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

        return c;
    }

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

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

        return c;
    }

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

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

        return c;
    }

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

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

        return c;
    }

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

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

Ownable.sol

// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

import "../GSN/Context.sol";
/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
contract Ownable is Context {
    address private _owner;

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

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor () internal {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(_owner == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        emit OwnershipTransferred(_owner, address(0));
        _owner = address(0);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}
          

Context.sol

// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

/*
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with GSN meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address payable) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes memory) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}
          

IVoterProxy.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

import "./IGovernance.sol";

interface IVoterProxy {
	function proxyVote(address, uint256, address, address) external returns (bool);
	function proxyActivate(address) external returns (bool);
	function proxyRevokeActive(address, uint256, address, address, uint256) external returns (bool);
	function proxyRevokePending(address, uint256, address, address, uint256) external returns (bool);

	function proxyGovernanceVote(uint256, uint256, Governance.VoteValue) external returns (bool);
	function proxyGovernanceUpvote(uint256, uint256, uint256) external returns (bool);
	function proxyGovernanceRevokeUpvote(uint256, uint256) external returns (bool);
}
          

IRegistry.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

interface IRegistry {
	function getAddressForStringOrDie(string calldata identifier) external view returns (address);
	function getAddressForOrDie(bytes32) external view returns (address);
}
          

ILockedGold.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

interface ILockedGold {
	function incrementNonvotingAccountBalance(address, uint256) external;
	function decrementNonvotingAccountBalance(address, uint256) external;
	function getAccountTotalLockedGold(address) external view returns (uint256);
	function getAccountNonvotingLockedGold(address) external view returns (uint256);
	function getTotalLockedGold() external view returns (uint256);
	function getPendingWithdrawals(address)
		external
		view
		returns (uint256[] memory, uint256[] memory);
	function getTotalPendingWithdrawals(address) external view returns (uint256);
	function lock() external payable;
	function unlock(uint256) external;
	function relock(uint256, uint256) external;
	function withdraw(uint256) external;
	function slash(
		address account,
		uint256 penalty,
		address reporter,
		uint256 reward,
		address[] calldata lessers,
		address[] calldata greaters,
		uint256[] calldata indices
	) external;
	function isSlasher(address) external view returns (bool);
}
          

IGovernance.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

contract Governance {
	enum VoteValue { None, Abstain, No, Yes }
}

interface IGovernance {
	function vote(uint256 proposalId, uint256 index, Governance.VoteValue value) external returns (bool);
	function upvote(uint256 proposalId, uint256 lesser, uint256 greater) external returns (bool);
	function revokeUpvote(uint256 lesser, uint256 greater) external returns (bool);
}
          

IExchange.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

interface IExchange {
	function sell(uint256, uint256, bool) external returns (uint256);
}
          

IElection.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

interface IElection {
	function electValidatorSigners() external view returns (address[] memory);
	function electNValidatorSigners(uint256, uint256) external view returns (address[] memory);
	function vote(address, uint256, address, address) external returns (bool);
	function activate(address) external returns (bool);
	function revokeActive(address, uint256, address, address, uint256) external returns (bool);
	function revokeAllActive(address, address, address, uint256) external returns (bool);
	function revokePending(address, uint256, address, address, uint256) external returns (bool);
	function markGroupIneligible(address) external;
	function markGroupEligible(address, address, address) external;
	function forceDecrementVotes(
		address,
		uint256,
		address[] calldata,
		address[] calldata,
		uint256[] calldata
	) external returns (uint256);

	// view functions
	function getElectableValidators() external view returns (uint256, uint256);
	function getElectabilityThreshold() external view returns (uint256);
	function getNumVotesReceivable(address) external view returns (uint256);
	function getTotalVotes() external view returns (uint256);
	function getActiveVotes() external view returns (uint256);
	function getTotalVotesByAccount(address) external view returns (uint256);
	function getPendingVotesForGroupByAccount(address, address) external view returns (uint256);
	function getActiveVotesForGroupByAccount(address, address) external view returns (uint256);
	function getTotalVotesForGroupByAccount(address, address) external view returns (uint256);
	function getActiveVoteUnitsForGroupByAccount(address, address) external view returns (uint256);
	function getTotalVotesForGroup(address) external view returns (uint256);
	function getActiveVotesForGroup(address) external view returns (uint256);
	function getPendingVotesForGroup(address) external view returns (uint256);
	function getGroupEligibility(address) external view returns (bool);
	function getGroupEpochRewards(address, uint256, uint256[] calldata)
		external
		view
		returns (uint256);
	function getGroupsVotedForByAccount(address) external view returns (address[] memory);
	function getEligibleValidatorGroups() external view returns (address[] memory);
	function getTotalVotesForEligibleValidatorGroups()
		external
		view
		returns (address[] memory, uint256[] memory);
	function getCurrentValidatorSigners() external view returns (address[] memory);
	function canReceiveVotes(address, uint256) external view returns (bool);
	function hasActivatablePendingVotes(address, address) external view returns (bool);

	// only owner
	function setElectableValidators(uint256, uint256) external returns (bool);
	function setMaxNumGroupsVotedFor(uint256) external returns (bool);
	function setElectabilityThreshold(uint256) external returns (bool);

	// only VM
	function distributeEpochRewards(address, uint256, address, address) external;
}
          

IAccounts.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

interface IAccounts {
	function isAccount(address) external view returns (bool);
	function voteSignerToAccount(address) external view returns (address);
	function validatorSignerToAccount(address) external view returns (address);
	function attestationSignerToAccount(address) external view returns (address);
	function signerToAccount(address) external view returns (address);
	function getAttestationSigner(address) external view returns (address);
	function getValidatorSigner(address) external view returns (address);
	function getVoteSigner(address) external view returns (address);
	function hasAuthorizedVoteSigner(address) external view returns (bool);
	function hasAuthorizedValidatorSigner(address) external view returns (bool);
	function hasAuthorizedAttestationSigner(address) external view returns (bool);

	function setAccountDataEncryptionKey(bytes calldata) external;
	function setMetadataURL(string calldata) external;
	function setName(string calldata) external;
	function setWalletAddress(address, uint8, bytes32, bytes32) external;
	function setAccount(string calldata, bytes calldata, address, uint8, bytes32, bytes32) external;

	function getDataEncryptionKey(address) external view returns (bytes memory);
	function getWalletAddress(address) external view returns (address);
	function getMetadataURL(address) external view returns (string memory);
	function batchGetMetadataURL(address[] calldata)
		external
		view
		returns (uint256[] memory, bytes memory);
	function getName(address) external view returns (string memory);

	function authorizeVoteSigner(address, uint8, bytes32, bytes32) external;
	function authorizeValidatorSigner(address, uint8, bytes32, bytes32) external;
	function authorizeValidatorSignerWithPublicKey(address, uint8, bytes32, bytes32, bytes calldata)
		external;
	function authorizeValidatorSignerWithKeys(
		address,
		uint8,
		bytes32,
		bytes32,
		bytes calldata,
		bytes calldata,
		bytes calldata
	) external;
	function authorizeAttestationSigner(address, uint8, bytes32, bytes32) external;
	function createAccount() external returns (bool);
}
          

UsingRegistry.sol

//SPDX-License-Identifier: MIT
pragma solidity 0.6.8;

import "@openzeppelin/contracts/token/ERC20/IERC20.sol";

import "./interfaces/IRegistry.sol";
import "./interfaces/IAccounts.sol";
import "./interfaces/ILockedGold.sol";
import "./interfaces/IElection.sol";
import "./interfaces/IExchange.sol";
import "./interfaces/IGovernance.sol";

// This is a simplified version of Celo's: protocol/contracts/common/UsingRegistry.sol
contract UsingRegistry {

	IRegistry constant registry = IRegistry(address(0x000000000000000000000000000000000000ce10));

	bytes32 constant ACCOUNTS_REGISTRY_ID = keccak256(abi.encodePacked("Accounts"));
	bytes32 constant ELECTION_REGISTRY_ID = keccak256(abi.encodePacked("Election"));
	bytes32 constant EXCHANGE_REGISTRY_ID = keccak256(abi.encodePacked("Exchange"));
	bytes32 constant GOLD_TOKEN_REGISTRY_ID = keccak256(abi.encodePacked("GoldToken"));
	bytes32 constant GOVERNANCE_REGISTRY_ID = keccak256(abi.encodePacked("Governance"));
	bytes32 constant LOCKED_GOLD_REGISTRY_ID = keccak256(abi.encodePacked("LockedGold"));
	bytes32 constant STABLE_TOKEN_REGISTRY_ID = keccak256(abi.encodePacked("StableToken"));

	function getAccounts() internal view returns (IAccounts) {
		return IAccounts(registry.getAddressForOrDie(ACCOUNTS_REGISTRY_ID));
	}

	function getElection() internal view returns (IElection) {
		return IElection(registry.getAddressForOrDie(ELECTION_REGISTRY_ID));
	}

	function getExchange() internal view returns (IExchange) {
		return IExchange(registry.getAddressForOrDie(EXCHANGE_REGISTRY_ID));
	}

	function getGoldToken() internal view returns (IERC20) {
		return IERC20(registry.getAddressForOrDie(GOLD_TOKEN_REGISTRY_ID));
	}

	function getGovernance() internal view returns (IGovernance) {
		return IGovernance(registry.getAddressForOrDie(GOVERNANCE_REGISTRY_ID));
	}

	function getLockedGold() internal view returns (ILockedGold) {
		return ILockedGold(registry.getAddressForOrDie(LOCKED_GOLD_REGISTRY_ID));
	}

	function getStableToken() internal view returns (IERC20) {
		return IERC20(registry.getAddressForOrDie(STABLE_TOKEN_REGISTRY_ID));
	}
}
          

Contract ABI

[{"type":"constructor","stateMutability":"nonpayable","inputs":[]},{"type":"event","name":"Approval","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"spender","internalType":"address","indexed":true},{"type":"uint256","name":"value","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"Deposited","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"uint256","name":"celoAmount","internalType":"uint256","indexed":false},{"type":"uint256","name":"savingsAmount","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"Transfer","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256","name":"value","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"VoterAuthorized","inputs":[{"type":"address","name":"previousVoter","internalType":"address","indexed":true},{"type":"address","name":"newVoter","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"WithdrawCanceled","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"uint256","name":"celoAmount","internalType":"uint256","indexed":false},{"type":"uint256","name":"savingsAmount","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"WithdrawFinished","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"uint256","name":"celoAmount","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"WithdrawStarted","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"uint256","name":"savingsAmount","internalType":"uint256","indexed":false},{"type":"uint256","name":"celoAmount","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"_voter","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"allowance","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"address","name":"spender","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"approve","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"authorizeVoteSigner","inputs":[{"type":"address","name":"signer","internalType":"address"},{"type":"uint8","name":"v","internalType":"uint8"},{"type":"bytes32","name":"r","internalType":"bytes32"},{"type":"bytes32","name":"s","internalType":"bytes32"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"authorizeVoterProxy","inputs":[{"type":"address","name":"proxy","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"balanceOf","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"celoToSavings","inputs":[{"type":"uint256","name":"celoAmount","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint8","name":"","internalType":"uint8"}],"name":"decimals","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"decreaseAllowance","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"subtractedValue","internalType":"uint256"}]},{"type":"function","stateMutability":"payable","outputs":[],"name":"deposit","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"increaseAllowance","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"addedValue","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"name","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256[]","name":"","internalType":"uint256[]"},{"type":"uint256[]","name":"","internalType":"uint256[]"}],"name":"pendingWithdrawals","inputs":[{"type":"address","name":"addr","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"proxyActivate","inputs":[{"type":"address","name":"group","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"proxyGovernanceRevokeUpvote","inputs":[{"type":"uint256","name":"lesser","internalType":"uint256"},{"type":"uint256","name":"greater","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"proxyGovernanceUpvote","inputs":[{"type":"uint256","name":"proposalId","internalType":"uint256"},{"type":"uint256","name":"lesser","internalType":"uint256"},{"type":"uint256","name":"greater","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"proxyGovernanceVote","inputs":[{"type":"uint256","name":"proposalId","internalType":"uint256"},{"type":"uint256","name":"index","internalType":"uint256"},{"type":"uint8","name":"value","internalType":"enum Governance.VoteValue"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"proxyRevokeActive","inputs":[{"type":"address","name":"group","internalType":"address"},{"type":"uint256","name":"value","internalType":"uint256"},{"type":"address","name":"lesser","internalType":"address"},{"type":"address","name":"greater","internalType":"address"},{"type":"uint256","name":"index","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"proxyRevokePending","inputs":[{"type":"address","name":"group","internalType":"address"},{"type":"uint256","name":"value","internalType":"uint256"},{"type":"address","name":"lesser","internalType":"address"},{"type":"address","name":"greater","internalType":"address"},{"type":"uint256","name":"index","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"proxyVote","inputs":[{"type":"address","name":"group","internalType":"address"},{"type":"uint256","name":"value","internalType":"uint256"},{"type":"address","name":"lesser","internalType":"address"},{"type":"address","name":"greater","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"savingsToCELO","inputs":[{"type":"uint256","name":"savingsAmount","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"symbol","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSupply","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"transfer","inputs":[{"type":"address","name":"recipient","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"transferFrom","inputs":[{"type":"address","name":"sender","internalType":"address"},{"type":"address","name":"recipient","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"withdrawCancel","inputs":[{"type":"uint256","name":"index","internalType":"uint256"},{"type":"uint256","name":"indexGlobal","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"withdrawFinish","inputs":[{"type":"uint256","name":"index","internalType":"uint256"},{"type":"uint256","name":"indexGlobal","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"withdrawStart","inputs":[{"type":"uint256","name":"savingsAmount","internalType":"uint256"},{"type":"address","name":"lesserAfterPendingRevoke","internalType":"address"},{"type":"address","name":"greaterAfterPendingRevoke","internalType":"address"},{"type":"address","name":"lesserAfterActiveRevoke","internalType":"address"},{"type":"address","name":"greaterAfterActiveRevoke","internalType":"address"}]},{"type":"receive","stateMutability":"payable"}]
            

Deployed ByteCode

0x6080604052600436106101dc5760003560e01c80636479e85a11610102578063a457c2d711610095578063dd62ed3e11610064578063dd62ed3e14610d1c578063ec3e240f14610da1578063f2fde38b14610de6578063f3f4370314610e37576101e3565b8063a457c2d714610bc2578063a9059cbb14610c35578063bb6c852314610ca8578063d0e30db014610d12576101e3565b806376c41bff116100d157806376c41bff146109d9578063870f033714610a285780638da5cb5b14610adb57806395d89b4114610b32576101e3565b80636479e85a1461084f57806366282e5d1461090c57806370a082311461095d578063715018a6146109c2576101e3565b8063395093511161017a5780634550b565116101495780634550b5651461069957806347ac0cb6146106de5780635cefc85e146107455780635d55a90b14610794576101e3565b806339509351146104a05780633db9b42a146105135780634282ee6d1461056a57806342dcfe9c146105dc576101e3565b806318160ddd116101b657806318160ddd14610354578063211db49b1461037f57806323b872dd146103dc578063313ce5671461046f576101e3565b806303c4181d146101e857806306fdde0314610251578063095ea7b3146102e1576101e3565b366101e357005b600080fd5b3480156101f457600080fd5b506102376004803603602081101561020b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f25565b604051808215151515815260200191505060405180910390f35b34801561025d57600080fd5b50610266611095565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156102a657808201518184015260208101905061028b565b50505050905090810190601f1680156102d35780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156102ed57600080fd5b5061033a6004803603604081101561030457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611137565b604051808215151515815260200191505060405180910390f35b34801561036057600080fd5b50610369611155565b6040518082815260200191505060405180910390f35b34801561038b57600080fd5b506103c2600480360360408110156103a257600080fd5b81019080803590602001909291908035906020019092919050505061115f565b604051808215151515815260200191505060405180910390f35b3480156103e857600080fd5b50610455600480360360608110156103ff57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506112ac565b604051808215151515815260200191505060405180910390f35b34801561047b57600080fd5b50610484611385565b604051808260ff1660ff16815260200191505060405180910390f35b3480156104ac57600080fd5b506104f9600480360360408110156104c357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061139c565b604051808215151515815260200191505060405180910390f35b34801561051f57600080fd5b5061052861144f565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561057657600080fd5b506105da6004803603608081101561058d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803560ff1690602001909291908035906020019092919080359060200190929190505050611475565b005b3480156105e857600080fd5b5061067f600480360360a08110156105ff57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611601565b604051808215151515815260200191505060405180910390f35b3480156106a557600080fd5b506106dc600480360360408110156106bc57600080fd5b8101908080359060200190929190803590602001909291905050506117ed565b005b3480156106ea57600080fd5b5061072b6004803603606081101561070157600080fd5b81019080803590602001909291908035906020019092919080359060200190929190505050611990565b604051808215151515815260200191505060405180910390f35b34801561075157600080fd5b5061077e6004803603602081101561076857600080fd5b8101908080359060200190929190505050611ae6565b6040518082815260200191505060405180910390f35b3480156107a057600080fd5b5061084d600480360360a08110156107b757600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611b8c565b005b34801561085b57600080fd5b506108f2600480360360a081101561087257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506121b2565b604051808215151515815260200191505060405180910390f35b34801561091857600080fd5b5061095b6004803603602081101561092f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061239e565b005b34801561096957600080fd5b506109ac6004803603602081101561098057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612528565b6040518082815260200191505060405180910390f35b3480156109ce57600080fd5b506109d7612570565b005b3480156109e557600080fd5b50610a12600480360360208110156109fc57600080fd5b81019080803590602001909291905050506126fb565b6040518082815260200191505060405180910390f35b348015610a3457600080fd5b50610ac160048036036080811015610a4b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506127cf565b604051808215151515815260200191505060405180910390f35b348015610ae757600080fd5b50610af06129b2565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b348015610b3e57600080fd5b50610b476129dc565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610b87578082015181840152602081019050610b6c565b50505050905090810190601f168015610bb45780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b348015610bce57600080fd5b50610c1b60048036036040811015610be557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050612a7e565b604051808215151515815260200191505060405180910390f35b348015610c4157600080fd5b50610c8e60048036036040811015610c5857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050612b4b565b604051808215151515815260200191505060405180910390f35b348015610cb457600080fd5b50610cf860048036036060811015610ccb57600080fd5b810190808035906020019092919080359060200190929190803560ff169060200190929190505050612b69565b604051808215151515815260200191505060405180910390f35b610d1a612ccd565b005b348015610d2857600080fd5b50610d8b60048036036040811015610d3f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612e5c565b6040518082815260200191505060405180910390f35b348015610dad57600080fd5b50610de460048036036040811015610dc457600080fd5b810190808035906020019092919080359060200190929190505050612ee3565b005b348015610df257600080fd5b50610e3560048036036020811015610e0957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506130e3565b005b348015610e4357600080fd5b50610e8660048036036020811015610e5a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506132f3565b604051808060200180602001838103835285818151815260200191508051906020019060200280838360005b83811015610ecd578082015181840152602081019050610eb2565b50505050905001838103825284818151815260200191508051906020019060200280838360005b83811015610f0f578082015181840152602081019050610ef4565b5050505090500194505050505060405180910390f35b60003373ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610fcd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806152606024913960400191505060405180910390fd5b610fd561347d565b73ffffffffffffffffffffffffffffffffffffffff16631c5a9d9c836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050602060405180830381600087803b15801561105357600080fd5b505af1158015611067573d6000803e3d6000fd5b505050506040513d602081101561107d57600080fd5b81019080805190602001909291905050509050919050565b606060038054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561112d5780601f106111025761010080835404028352916020019161112d565b820191906000526020600020905b81548152906001019060200180831161111057829003601f168201915b5050505050905090565b600061114b611144613558565b8484613560565b6001905092915050565b6000600254905090565b60003373ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611207576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806152606024913960400191505060405180910390fd5b61120f613757565b73ffffffffffffffffffffffffffffffffffffffff1663af108a0e84846040518363ffffffff1660e01b81526004018083815260200182815260200192505050602060405180830381600087803b15801561126957600080fd5b505af115801561127d573d6000803e3d6000fd5b505050506040513d602081101561129357600080fd5b8101908080519060200190929190505050905092915050565b60006112b9848484613832565b61137a846112c5613558565b6113758560405180606001604052806028815260200161538660289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600061132b613558565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054613af39092919063ffffffff16565b613560565b600190509392505050565b6000600560009054906101000a900460ff16905090565b60006114456113a9613558565b8461144085600160006113ba613558565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054613bb390919063ffffffff16565b613560565b6001905092915050565b600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b61147d613558565b73ffffffffffffffffffffffffffffffffffffffff16600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461153f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b611547613c3b565b73ffffffffffffffffffffffffffffffffffffffff16634282ee6d858585856040518563ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018460ff1660ff168152602001838152602001828152602001945050505050600060405180830381600087803b1580156115e357600080fd5b505af11580156115f7573d6000803e3d6000fd5b5050505050505050565b60003373ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146116a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806152606024913960400191505060405180910390fd5b6116b161347d565b73ffffffffffffffffffffffffffffffffffffffff16639dfb608187878787876040518663ffffffff1660e01b8152600401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200195505050505050602060405180830381600087803b1580156117a757600080fd5b505af11580156117bb573d6000803e3d6000fd5b505050506040513d60208110156117d157600080fd5b8101908080519060200190929190505050905095945050505050565b6117f5615245565b611800338484613d16565b9050600061180c614203565b905060003073ffffffffffffffffffffffffffffffffffffffff166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561185657600080fd5b505afa15801561186a573d6000803e3d6000fd5b505050506040513d602081101561188057600080fd5b8101908080519060200190929190505050905061189b6142e6565b73ffffffffffffffffffffffffffffffffffffffff1663b2fb30cb8585600001516040518363ffffffff1660e01b81526004018083815260200182815260200192505050600060405180830381600087803b1580156118f957600080fd5b505af115801561190d573d6000803e3d6000fd5b505050506000611922828486600001516143c1565b905061192e3382614422565b3373ffffffffffffffffffffffffffffffffffffffff167fc4d117100433dc3e9c2d45638e275b85825b34d885843496c575b6084f4ec03f856000015183604051808381526020018281526020019250505060405180910390a2505050505050565b60003373ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611a38576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806152606024913960400191505060405180910390fd5b611a40613757565b73ffffffffffffffffffffffffffffffffffffffff1663573339788585856040518463ffffffff1660e01b8152600401808481526020018381526020018281526020019350505050602060405180830381600087803b158015611aa257600080fd5b505af1158015611ab6573d6000803e3d6000fd5b505050506040513d6020811015611acc57600080fd5b810190808051906020019092919050505090509392505050565b6000803073ffffffffffffffffffffffffffffffffffffffff166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b158015611b2f57600080fd5b505afa158015611b43573d6000803e3d6000fd5b505050506040513d6020811015611b5957600080fd5b810190808051906020019092919050505090506000611b76614203565b9050611b838282866143c1565b92505050919050565b60008511611c02576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f776974686472617720616d6f756e74206d75737420626520706f73697469766581525060200191505060405180910390fd5b6000611c0c614203565b905060003073ffffffffffffffffffffffffffffffffffffffff166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b158015611c5657600080fd5b505afa158015611c6a573d6000803e3d6000fd5b505050506040513d6020811015611c8057600080fd5b81019080805190602001909291905050509050611c9d33886145e9565b60004790506000611cac6142e6565b90506000821115611d19578073ffffffffffffffffffffffffffffffffffffffff1663f83d08ba836040518263ffffffff1660e01b81526004016000604051808303818588803b158015611cff57600080fd5b505af1158015611d13573d6000803e3d6000fd5b50505050505b6000611d4084611d32878d6147ad90919063ffffffff16565b61483390919063ffffffff16565b905060008273ffffffffffffffffffffffffffffffffffffffff16633f199b40306040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611dc157600080fd5b505afa158015611dd5573d6000803e3d6000fd5b505050506040513d6020811015611deb57600080fd5b8101908080519060200190929190505050905080821115611e2657611e25611e1c828461487d90919063ffffffff16565b8b8b8b8b6148c7565b5b8273ffffffffffffffffffffffffffffffffffffffff16636198e339836040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b158015611e7957600080fd5b505af1158015611e8d573d6000803e3d6000fd5b505050506060808473ffffffffffffffffffffffffffffffffffffffff1663f340c0d0306040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060006040518083038186803b158015611f1157600080fd5b505afa158015611f25573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052506040811015611f4f57600080fd5b8101908080516040519392919084640100000000821115611f6f57600080fd5b83820191506020820185811115611f8557600080fd5b8251866020820283011164010000000082111715611fa257600080fd5b8083526020830192505050908051906020019060200280838360005b83811015611fd9578082015181840152602081019050611fbe565b505050509050016040526020018051604051939291908464010000000082111561200257600080fd5b8382019150602082018581111561201857600080fd5b825186602082028301116401000000008211171561203557600080fd5b8083526020830192505050908051906020019060200280838360005b8381101561206c578082015181840152602081019050612051565b505050509050016040525050509150915060008260018451038151811061208f57fe5b602002602001015190508481146120a257fe5b600760003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060405180604001604052808381526020018460018651038151811061210257fe5b60200260200101518152509080600181540180825580915050600190039060005260206000209060020201600090919091909150600082015181600001556020820151816001015550503373ffffffffffffffffffffffffffffffffffffffff167f9e0bfdc780ebb366c4e3e459f4fece8e4a4bba134b1488059a416f925e1c251e8f83604051808381526020018281526020019250505060405180910390a25050505050505050505050505050565b60003373ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461225a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806152606024913960400191505060405180910390fd5b61226261347d565b73ffffffffffffffffffffffffffffffffffffffff16636e19847587878787876040518663ffffffff1660e01b8152600401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200195505050505050602060405180830381600087803b15801561235857600080fd5b505af115801561236c573d6000803e3d6000fd5b505050506040513d602081101561238257600080fd5b8101908080519060200190929190505050905095945050505050565b6123a6613558565b73ffffffffffffffffffffffffffffffffffffffff16600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612468576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b80600660006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f2a0f2e37aa533ef1b3af4e6f14e6ce19de9e9f29a5b4498f938ddd9a7a41de4460405160405180910390a350565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b612578613558565b73ffffffffffffffffffffffffffffffffffffffff16600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161461263a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff16600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a36000600560016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b6000803073ffffffffffffffffffffffffffffffffffffffff166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561274457600080fd5b505afa158015612758573d6000803e3d6000fd5b505050506040513d602081101561276e57600080fd5b8101908080519060200190929190505050905060008114156127945760009150506127ca565b600061279e614203565b90506127c5826127b783876147ad90919063ffffffff16565b61483390919063ffffffff16565b925050505b919050565b60003373ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612877576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806152606024913960400191505060405180910390fd5b61287f61347d565b73ffffffffffffffffffffffffffffffffffffffff1663580d747a868686866040518563ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018481526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b15801561296d57600080fd5b505af1158015612981573d6000803e3d6000fd5b505050506040513d602081101561299757600080fd5b81019080805190602001909291905050509050949350505050565b6000600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060048054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015612a745780601f10612a4957610100808354040283529160200191612a74565b820191906000526020600020905b815481529060010190602001808311612a5757829003601f168201915b5050505050905090565b6000612b41612a8b613558565b84612b3c856040518060600160405280602581526020016154bc6025913960016000612ab5613558565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054613af39092919063ffffffff16565b613560565b6001905092915050565b6000612b5f612b58613558565b8484613832565b6001905092915050565b60003373ffffffffffffffffffffffffffffffffffffffff16600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612c11576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806152606024913960400191505060405180910390fd5b612c19613757565b73ffffffffffffffffffffffffffffffffffffffff1663bbb2eab98585856040518463ffffffff1660e01b815260040180848152602001838152602001826003811115612c6257fe5b60ff1681526020019350505050602060405180830381600087803b158015612c8957600080fd5b505af1158015612c9d573d6000803e3d6000fd5b505050506040513d6020811015612cb357600080fd5b810190808051906020019092919050505090509392505050565b6000612ce934612cdb614203565b61487d90919063ffffffff16565b905060003073ffffffffffffffffffffffffffffffffffffffff166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b158015612d3357600080fd5b505afa158015612d47573d6000803e3d6000fd5b505050506040513d6020811015612d5d57600080fd5b810190808051906020019092919050505090506000612d7d8284346143c1565b9050612d893382614422565b600047905034811015612d9857fe5b612da06142e6565b73ffffffffffffffffffffffffffffffffffffffff1663f83d08ba826040518263ffffffff1660e01b81526004016000604051808303818588803b158015612de757600080fd5b505af1158015612dfb573d6000803e3d6000fd5b50505050503373ffffffffffffffffffffffffffffffffffffffff167f73a19dd210f1a7f902193214c0ee91dd35ee5b4d920cba8d519eca65a7b488ca3484604051808381526020018281526020019250505060405180910390a250505050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b612eeb615245565b612ef6338484613d16565b9050612f006142e6565b73ffffffffffffffffffffffffffffffffffffffff16632e1a7d4d836040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b158015612f5257600080fd5b505af1158015612f66573d6000803e3d6000fd5b50505050612f7261509f565b73ffffffffffffffffffffffffffffffffffffffff1663a9059cbb3383600001516040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b158015612ffc57600080fd5b505af1158015613010573d6000803e3d6000fd5b505050506040513d602081101561302657600080fd5b810190808051906020019092919050505061308c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001806153cf602c913960400191505060405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff167fc30674dd0fb78fbd6f76bcf2213e36dc143fad985b255420b31444f9f29f6d5c82600001516040518082815260200191505060405180910390a2505050565b6130eb613558565b73ffffffffffffffffffffffffffffffffffffffff16600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146131ad576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415613233576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806152c96026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600560016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6060806000600760008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008180549050905060608167ffffffffffffffff8111801561335b57600080fd5b5060405190808252806020026020018201604052801561338a5781602001602082028036833780820191505090505b50905060608267ffffffffffffffff811180156133a657600080fd5b506040519080825280602002602001820160405280156133d55781602001602082028036833780820191505090505b50905060008090505b8381101561346d578481815481106133f257fe5b90600052602060002090600202016000015483828151811061341057fe5b60200260200101818152505084818154811061342857fe5b90600052602060002090600202016001015482828151811061344657fe5b602002602001018181525050613466600182613bb390919063ffffffff16565b90506133de565b5081819550955050505050915091565b600061ce1073ffffffffffffffffffffffffffffffffffffffff1663dcf0aaed60405160200180807f456c656374696f6e0000000000000000000000000000000000000000000000008152506008019050604051602081830303815290604052805190602001206040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561351857600080fd5b505afa15801561352c573d6000803e3d6000fd5b505050506040513d602081101561354257600080fd5b8101908080519060200190929190505050905090565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156135e6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806154426024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561366c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806152ef6022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600061ce1073ffffffffffffffffffffffffffffffffffffffff1663dcf0aaed60405160200180807f476f7665726e616e636500000000000000000000000000000000000000000000815250600a019050604051602081830303815290604052805190602001206040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156137f257600080fd5b505afa158015613806573d6000803e3d6000fd5b505050506040513d602081101561381c57600080fd5b8101908080519060200190929190505050905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156138b8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806153fb6025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561393e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806152846023913960400191505060405180910390fd5b61394983838361517a565b6139b48160405180606001604052806026815260200161533f602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054613af39092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550613a47816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054613bb390919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290613ba0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613b65578082015181840152602081019050613b4a565b50505050905090810190601f168015613b925780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015613c31576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600061ce1073ffffffffffffffffffffffffffffffffffffffff1663dcf0aaed60405160200180807f4163636f756e74730000000000000000000000000000000000000000000000008152506008019050604051602081830303815290604052805190602001206040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015613cd657600080fd5b505afa158015613cea573d6000803e3d6000fd5b505050506040513d6020811015613d0057600080fd5b8101908080519060200190929190505050905090565b613d1e615245565b6000600760008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080805490508410613dda576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601c8152602001807f6261642070656e64696e67207769746864726177616c20696e6465780000000081525060200191505060405180910390fd5b606080613de56142e6565b73ffffffffffffffffffffffffffffffffffffffff1663f340c0d0306040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060006040518083038186803b158015613e6157600080fd5b505afa158015613e75573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052506040811015613e9f57600080fd5b8101908080516040519392919084640100000000821115613ebf57600080fd5b83820191506020820185811115613ed557600080fd5b8251866020820283011164010000000082111715613ef257600080fd5b8083526020830192505050908051906020019060200280838360005b83811015613f29578082015181840152602081019050613f0e565b5050505090500160405260200180516040519392919084640100000000821115613f5257600080fd5b83820191506020820185811115613f6857600080fd5b8251866020820283011164010000000082111715613f8557600080fd5b8083526020830192505050908051906020019060200280838360005b83811015613fbc578082015181840152602081019050613fa1565b505050509050016040525050509150915081518510614026576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806154206022913960400191505060405180910390fd5b81858151811061403257fe5b602002602001015183878154811061404657fe5b906000526020600020906002020160000154146140ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180615466602a913960400191505060405180910390fd5b8085815181106140ba57fe5b60200260200101518387815481106140ce57fe5b90600052602060002090600202016001015414614136576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e815260200180615311602e913960400191505060405180910390fd5b82868154811061414257fe5b90600052602060002090600202016040518060400160405290816000820154815260200160018201548152505093508260018480549050038154811061418457fe5b906000526020600020906002020183878154811061419e57fe5b90600052602060002090600202016000820154816000015560018201548160010155905050828054806141cd57fe5b60019003818190600052602060002090600202016000808201600090556001820160009055505090558393505050509392505050565b60008061420e6142e6565b73ffffffffffffffffffffffffffffffffffffffff166330ec70f5306040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561428a57600080fd5b505afa15801561429e573d6000803e3d6000fd5b505050506040513d60208110156142b457600080fd5b8101908080519060200190929190505050905060004790506142df8183613bb390919063ffffffff16565b9250505090565b600061ce1073ffffffffffffffffffffffffffffffffffffffff1663dcf0aaed60405160200180807f4c6f636b6564476f6c6400000000000000000000000000000000000000000000815250600a019050604051602081830303815290604052805190602001206040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561438157600080fd5b505afa158015614395573d6000803e3d6000fd5b505050506040513d60208110156143ab57600080fd5b8101908080519060200190929190505050905090565b6000808414806143d15750600083145b156143f3576143ec62010000836147ad90919063ffffffff16565b905061441b565b6144188361440a86856147ad90919063ffffffff16565b61483390919063ffffffff16565b90505b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156144c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6144d16000838361517a565b6144e681600254613bb390919063ffffffff16565b60028190555061453d816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054613bb390919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561466f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806153ae6021913960400191505060405180910390fd5b61467b8260008361517a565b6146e6816040518060600160405280602281526020016152a7602291396000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054613af39092919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061473d8160025461487d90919063ffffffff16565b600281905550600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b6000808314156147c0576000905061482d565b60008284029050828482816147d157fe5b0414614828576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806153656021913960400191505060405180910390fd5b809150505b92915050565b600061487583836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061517f565b905092915050565b60006148bf83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250613af3565b905092915050565b60006148d161347d565b905060608173ffffffffffffffffffffffffffffffffffffffff1663457578a3306040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060006040518083038186803b15801561495257600080fd5b505afa158015614966573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250602081101561499057600080fd5b81019080805160405193929190846401000000008211156149b057600080fd5b838201915060208201858111156149c657600080fd5b82518660208202830111640100000000821117156149e357600080fd5b8083526020830192505050908051906020019060200280838360005b83811015614a1a5780820151818401526020810190506149ff565b5050505090500160405250505090506000815111614aa0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f6e6f7420656e6f75676820766f74657320746f207265766f6b6500000000000081525060200191505060405180910390fd5b6000600182510390506000828281518110614ab757fe5b6020026020010151905060008473ffffffffffffffffffffffffffffffffffffffff16639b95975f83306040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015614b7457600080fd5b505afa158015614b88573d6000803e3d6000fd5b505050506040513d6020811015614b9e57600080fd5b8101908080519060200190929190505050905060008573ffffffffffffffffffffffffffffffffffffffff1663d3e242a484306040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015614c6457600080fd5b505afa158015614c78573d6000803e3d6000fd5b505050506040513d6020811015614c8e57600080fd5b810190808051906020019092919050505090508a614cb58284613bb390919063ffffffff16565b1015614d0c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c815260200180615490602c913960400191505060405180910390fd5b60008290508b811115614d1d578b90505b6000614d32828e61487d90919063ffffffff16565b90506000821115614ee2578773ffffffffffffffffffffffffffffffffffffffff16639dfb608186848f8f8b6040518663ffffffff1660e01b8152600401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200195505050505050602060405180830381600087803b158015614e3457600080fd5b505af1158015614e48573d6000803e3d6000fd5b505050506040513d6020811015614e5e57600080fd5b8101908080519060200190929190505050614ee1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260148152602001807f7265766f6b6550656e64696e67206661696c656400000000000000000000000081525060200191505060405180910390fd5b5b6000811115615090578773ffffffffffffffffffffffffffffffffffffffff16636e19847586838d8d8b6040518663ffffffff1660e01b8152600401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200195505050505050602060405180830381600087803b158015614fe257600080fd5b505af1158015614ff6573d6000803e3d6000fd5b505050506040513d602081101561500c57600080fd5b810190808051906020019092919050505061508f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f7265766f6b65416374697665206661696c65640000000000000000000000000081525060200191505060405180910390fd5b5b50505050505050505050505050565b600061ce1073ffffffffffffffffffffffffffffffffffffffff1663dcf0aaed60405160200180807f476f6c64546f6b656e00000000000000000000000000000000000000000000008152506009019050604051602081830303815290604052805190602001206040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561513a57600080fd5b505afa15801561514e573d6000803e3d6000fd5b505050506040513d602081101561516457600080fd5b8101908080519060200190929190505050905090565b505050565b6000808311829061522b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156151f05780820151818401526020810190506151d5565b50505050905090810190601f16801561521d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50600083858161523757fe5b049050809150509392505050565b60405180604001604052806000815260200160008152509056fe63616c6c6572206d757374206265207468652072656769737465726564205f766f74657245524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e63654f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f20616464726573736d69736d6174636865642074696d657374616d7020666f7220696e64657820616e6420696e646578476c6f62616c45524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a206275726e2066726f6d20746865207a65726f2061646472657373756e6578706563746564206661696c7572653a2043454c4f207472616e7366657220686173206661696c656445524332303a207472616e736665722066726f6d20746865207a65726f20616464726573736261642070656e64696e67207769746864726177616c20696e646578476c6f62616c45524332303a20617070726f76652066726f6d20746865207a65726f20616464726573736d69736d6174636865642076616c756520666f7220696e64657820616e6420696e646578476c6f62616c6e6f7420656e6f75676820756e6c6f636b65642043454c4f20616e64207265766f6b61626c6520766f74657345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa26469706673582212202044ac129fa9e373d3fad4f6a1fa5a60fc63f99ebdf8d12012040aafe6e8cdd864736f6c63430006080033