Source Code
Latest 25 from a total of 70 transactions
| Transaction Hash |
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Close Deal | 35666082 | 525 days ago | IN | 0 XDAI | 0.00010174 | ||||
| Create Deal With... | 35665787 | 525 days ago | IN | 0.5 XDAI | 0.00017857 | ||||
| Create Deal With... | 35665411 | 525 days ago | IN | 0.5 XDAI | 0.00014596 | ||||
| Close Deal | 31915389 | 751 days ago | IN | 0 XDAI | 0.00012717 | ||||
| Create Deal With... | 31915362 | 751 days ago | IN | 5 XDAI | 0.00022322 | ||||
| Close Deal | 30921822 | 812 days ago | IN | 0 XDAI | 0.00063571 | ||||
| Make Claim | 30889641 | 814 days ago | IN | 15 XDAI | 0.00110656 | ||||
| Create Deal With... | 30826303 | 818 days ago | IN | 1 XDAI | 0.00214056 | ||||
| Create Deal With... | 30778615 | 821 days ago | IN | 1 XDAI | 0.00022321 | ||||
| Create Deal With... | 30778017 | 821 days ago | IN | 1 XDAI | 0.00022316 | ||||
| Create Deal With... | 29722592 | 886 days ago | IN | 0.02 XDAI | 0.00037143 | ||||
| Create Deal With... | 29524720 | 898 days ago | IN | 5 XDAI | 0.00037143 | ||||
| Close Deal | 29524711 | 898 days ago | IN | 0 XDAI | 0.00021196 | ||||
| Create Deal With... | 29524461 | 898 days ago | IN | 5 XDAI | 0.00037143 | ||||
| Change Settings | 29237839 | 916 days ago | IN | 0 XDAI | 0.00007095 | ||||
| Challenge Claim | 29218670 | 917 days ago | IN | 15 XDAI | 0.00128865 | ||||
| Make Claim | 29218141 | 917 days ago | IN | 15 XDAI | 0.00030202 | ||||
| Create Deal With... | 29199939 | 918 days ago | IN | 5 XDAI | 0.00037143 | ||||
| Close Deal | 28484665 | 961 days ago | IN | 0 XDAI | 0.0001691 | ||||
| Close Deal | 28469597 | 962 days ago | IN | 0 XDAI | 0.00021185 | ||||
| Close Deal | 27841296 | 1000 days ago | IN | 0 XDAI | 0.00021196 | ||||
| Create Deal With... | 27841254 | 1000 days ago | IN | 1 XDAI | 0.00037143 | ||||
| Close Deal | 27841158 | 1000 days ago | IN | 0 XDAI | 0.00016921 | ||||
| Create Deal With... | 27841129 | 1000 days ago | IN | 1 XDAI | 0.00037143 | ||||
| Close Deal | 27553161 | 1018 days ago | IN | 0 XDAI | 0.00016921 |
Latest 25 internal transactions (View All)
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 35665787 | 525 days ago | 0.5 XDAI | ||||
| 35665411 | 525 days ago | 0.5 XDAI | ||||
| 31915362 | 751 days ago | 5 XDAI | ||||
| 31087759 | 802 days ago | 13 XDAI | ||||
| 30902143 | 813 days ago | 13 XDAI | ||||
| 30902143 | 813 days ago | 15 XDAI | ||||
| 30840057 | 817 days ago | 1 XDAI | ||||
| 30840057 | 817 days ago | 1 XDAI | ||||
| 30840004 | 817 days ago | 1 XDAI | ||||
| 30840004 | 817 days ago | 1 XDAI | ||||
| 30826303 | 818 days ago | 1 XDAI | ||||
| 30778615 | 821 days ago | 1 XDAI | ||||
| 30778420 | 821 days ago | 1 XDAI | ||||
| 30778420 | 821 days ago | 1 XDAI | ||||
| 30778017 | 821 days ago | 1 XDAI | ||||
| 29722592 | 886 days ago | 0.02 XDAI | ||||
| 29524720 | 898 days ago | 5 XDAI | ||||
| 29524461 | 898 days ago | 5 XDAI | ||||
| 29420389 | 905 days ago | 13 XDAI | ||||
| 29218670 | 917 days ago | 13 XDAI | ||||
| 29199939 | 918 days ago | 5 XDAI | ||||
| 27841254 | 1000 days ago | 1 XDAI | ||||
| 27841129 | 1000 days ago | 1 XDAI | ||||
| 27818406 | 1002 days ago | 15 XDAI | ||||
| 27728993 | 1007 days ago | 15 XDAI |
Cross-Chain Transactions
Loading...
Loading
Similar Match Source Code This contract matches the deployed Bytecode of the Source Code for Contract 0x4dd7b894...345fbac86 The constructor portion of the code might be different and could alter the actual behaviour of the contract
Contract Name:
Yubiai
Compiler Version
v0.8.17+commit.8df45f5f
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED
/**
* @authors: [@greenlucid]
* @reviewers: []
* @auditors: []
* @bounties: []
* @deployments: []
*/
pragma solidity ^0.8.16;
import "@kleros/erc-792/contracts/IArbitrable.sol";
import "@kleros/erc-792/contracts/IArbitrator.sol";
import "@kleros/erc-792/contracts/erc-1497/IEvidence.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@kleros/dispute-resolver-interface-contract/contracts/IDisputeResolver.sol";
interface WXDAI is IERC20 {
function deposit() external payable;
}
contract Yubiai is IDisputeResolver {
// None: Deal hasn't even begun.
// Ongoing: Exists, it's not currently being claimed.
// Claimed: The seller made a claim to obtain a refund.
// Disputed: A claim on this deal is being disputed.
// Finished: It's over.
enum DealState {
None,
Ongoing,
Claimed,
Disputed,
Finished
}
enum ClaimResult {
Rejected,
Accepted
}
// Round struct stores the contributions made to particular rulings.
struct Round {
mapping(uint256 => uint256) paidFees; // Tracks the fees paid in this round in the form paidFees[ruling].
mapping(uint256 => bool) hasPaid; // True if the fees for this particular ruling have been fully paid in the form hasPaid[ruling].
mapping(address => mapping(uint256 => uint256)) contributions; // Maps contributors to their contributions for each ruling in the form contributions[address][answer].
uint256 feeRewards; // Sum of reimbursable appeal fees available to the parties that made contributions to the ruling that ultimately wins a dispute.
uint256[] fundedAnswers; // Stores the choices that are fully funded.
}
struct Claim {
uint256 disputeId;
uint256 amount;
uint256 arbFees;
//
uint64 dealId;
uint32 createdAt;
uint32 solvedAt; // if zero, unsolved yet.
uint8 ruling;
uint64 arbSettingsId;
uint56 freeSpace;
//
Round[] rounds;
}
struct Deal {
uint256 amount;
//
address buyer;
DealState state;
uint32 extraBurnFee;
uint32 claimCount;
uint24 freeSpace;
//
address seller;
uint32 createdAt;
uint32 timeForService;
uint32 timeForClaim;
//
IERC20 token;
uint64 currentClaim;
uint32 freeSpace2;
}
struct YubiaiSettings {
address admin;
uint32 maxClaims; // max n claims per deal. a deal is automatically closed if last claim fails.
uint32 timeForReclaim; // time the buyer has to create new claim after losing prev
uint32 timeForChallenge; // time the seller has to challenge a claim, and accepted otherwise.
//
address ubiBurner;
// fees are in basis points
uint32 adminFee;
uint32 ubiFee;
uint32 maxExtraFee; // this must be at all times under 10000 to prevent drain attacks.
// ---
// enforce timespans for prevent attacks
uint32 minTimeForService;
uint32 maxTimeForService;
uint32 minTimeForClaim;
uint32 maxTimeForClaim;
}
struct Counters {
uint64 dealCount;
uint64 claimCount;
uint64 currentArbSettingId;
}
event DealCreated(uint64 indexed dealId, Deal deal, string terms);
event ClaimCreated(uint64 indexed dealId, uint64 indexed claimId, uint256 amount, string evidence);
event ClaimClosed(uint64 indexed claimId, ClaimResult indexed result);
event DealClosed(uint64 indexed dealId, uint256 payment, uint256 refund, uint256 ubiFee, uint256 adminFee);
/// 0: Refuse to Arbitrate (Don't refund)
/// 1: Don't refund
/// 2: Refund
uint256 constant NUMBER_OF_RULINGS = 2;
uint256 constant BASIS_POINTS = 10_000;
// hardcoded the multipliers for efficiency. they've been shown to work fine.
uint256 constant WINNER_STAKE_MULTIPLIER = 5_000;
uint256 constant LOSER_STAKE_MULTIPLIER = 10_000;
uint256 constant LOSER_APPEAL_PERIOD_MULTIPLIER = 5_000;
// used for automatically creating deals with wrapped value
WXDAI constant wxdai = WXDAI(0xe91D153E0b41518A2Ce8Dd3D7944Fa863463a97d);
Counters public counters;
YubiaiSettings public settings;
address public governor;
mapping(uint64 => Deal) public deals;
mapping(uint64 => Claim) public claims;
IArbitrator public arbitrator;
mapping(uint256 => uint64) public disputeIdToClaim;
mapping(uint64 => bytes) public extraDatas;
mapping(IERC20 => bool) public tokenValidity;
/**
* @dev Initializes the contract.
* @param _settings Initial settings of Yubiai.
* @param _governor Governor of Yubiai, can change settings.
* @param _metaEvidence The immutable metaEvidence.
*/
constructor(
YubiaiSettings memory _settings,
address _governor,
IArbitrator _arbitrator,
bytes memory _extraData,
string memory _metaEvidence
) {
settings = _settings;
governor = _governor;
arbitrator = _arbitrator;
extraDatas[0] = _extraData;
emit MetaEvidence(0, _metaEvidence);
}
/**
* @dev Change settings of Yubiai, only governor.
* @param _settings New settings.
*/
function changeSettings(YubiaiSettings memory _settings) external {
require(msg.sender == governor, "Only governor");
settings = _settings;
}
/**
* @dev Change governor of Yubiai, only governor.
* @param _governor New governor.
*/
function changeGovernor(address _governor) external {
require(msg.sender == governor, "Only governor");
governor = _governor;
}
/**
* @dev Change arbSettings of Yubiai, only governor.
* @param _extraData New arbitratorExtraData
* @param _metaEvidence New MetaEvidence
*/
function newArbSettings(bytes calldata _extraData, string calldata _metaEvidence) external {
require(msg.sender == governor, "Only governor");
counters.currentArbSettingId++;
extraDatas[counters.currentArbSettingId] = _extraData;
emit MetaEvidence(counters.currentArbSettingId, _metaEvidence);
}
/**
* @dev Toggle validity on an ERC20 token, only governor.
* @param _token Token to change validity of.
* @param _validity Whether if it's valid or not.
*/
function setTokenValidity(IERC20 _token, bool _validity) external {
require(msg.sender == governor, "Only governor");
tokenValidity[_token] = _validity;
}
/**
* @dev Creates a deal, an agreement between buyer and seller.
* @param _deal The deal that is to be created. Some properties may be mutated.
* @param _terms An IPFS link giving extra context of the terms of the deal.
*/
function createDeal(Deal memory _deal, string memory _terms) public {
require(_deal.token.transferFrom(msg.sender, address(this), _deal.amount), "Token transfer failed");
// offering received. that's all you need.
_deal.createdAt = uint32(block.timestamp);
_deal.state = DealState.Ongoing;
_deal.claimCount = 0;
_deal.currentClaim = 0;
// additional validation could take place here:
// verify max extra fee
require(_deal.extraBurnFee <= settings.maxExtraFee, "Extra fee too large");
// only allowed tokens
require(tokenValidity[_deal.token], "Invalid token");
// only allowed time spans
require(_deal.timeForService >= settings.minTimeForService, "Too little time for service");
require(_deal.timeForClaim >= settings.minTimeForClaim, "Too little time for claim");
require(_deal.timeForService <= settings.maxTimeForService, "Too much time for service");
require(_deal.timeForClaim <= settings.maxTimeForClaim, "Too much time for claim");
deals[counters.dealCount] = _deal;
emit DealCreated(counters.dealCount, _deal, _terms);
counters.dealCount++;
}
/**
* @dev Like createDeal, but with msg.value, allowing users to not need to wrap xDAI.
* The seller (or buyer, in case refunds occur) will receive WXDAI, though.
* @param _deal The deal that is to be created. Some properties may be mutated.
* @param _terms An IPFS link giving extra context of the terms of the deal.
*/
function createDealWithValue(Deal memory _deal, string memory _terms) public payable {
// wrap the value
wxdai.deposit{value: msg.value}();
_deal.amount = msg.value;
_deal.token = wxdai;
// the rest of the function is pretty much a copy of the regular createDeal
_deal.createdAt = uint32(block.timestamp);
_deal.state = DealState.Ongoing;
_deal.claimCount = 0;
_deal.currentClaim = 0;
// verify max extra fee
require(_deal.extraBurnFee <= settings.maxExtraFee, "Extra fee too large");
// only allowed time spans
require(_deal.timeForService >= settings.minTimeForService, "Too little time for service");
require(_deal.timeForClaim >= settings.minTimeForClaim, "Too little time for claim");
require(_deal.timeForService <= settings.maxTimeForService, "Too much time for service");
require(_deal.timeForClaim <= settings.maxTimeForClaim, "Too much time for claim");
deals[counters.dealCount] = _deal;
emit DealCreated(counters.dealCount, _deal, _terms);
counters.dealCount++;
}
/**
* @dev Closes a deal. Different actors can close the deal, depending on some conditions.
* @param _dealId The ID of the deal to be closed.
*/
function closeDeal(uint64 _dealId) public {
Deal storage deal = deals[_dealId];
require(deal.state == DealState.Ongoing, "Deal is not ongoing");
// 1. if over the time for service + claim, anyone can close it.
if (isOver(_dealId)) {
_closeDeal(_dealId, deal.amount);
} else {
// 2. if under, the buyer can decide to pay the seller.
require(deal.buyer == msg.sender, "Only buyer can forward payment");
_closeDeal(_dealId, deal.amount);
}
}
/**
* @dev Make a claim on an existing deal. Only the buyer can claim.
* @param _dealId The ID of the deal to make a claim on.
* @param _amount Amount to be refunded.
* @param _evidence Rationale behind the requested refund.
*/
function makeClaim(uint64 _dealId, uint256 _amount, string calldata _evidence) external payable {
Deal storage deal = deals[_dealId];
require(msg.sender == deal.buyer, "Only buyer");
require(deal.amount >= _amount, "Refund cannot be greater than deal");
require(
deal.state == DealState.Ongoing &&
block.timestamp >= (deal.createdAt + deal.timeForService) &&
!isOver(_dealId),
"Deal cannot be claimed"
);
uint256 arbFees = arbitrator.arbitrationCost(extraDatas[counters.currentArbSettingId]);
require(msg.value >= arbFees, "Not enough to cover fees");
Claim storage claim = claims[counters.claimCount];
claim.dealId = _dealId;
claim.amount = _amount;
claim.createdAt = uint32(block.timestamp);
claim.arbSettingsId = counters.currentArbSettingId;
deal.state = DealState.Claimed;
deal.claimCount++;
deal.currentClaim = counters.claimCount;
emit ClaimCreated(_dealId, counters.claimCount, _amount, _evidence);
counters.claimCount++;
}
/**
* @dev Accept the claim and pay the refund, only by seller.
* @param _claimId The ID of the claim to accept.
*/
function acceptClaim(uint64 _claimId) public {
Claim storage claim = claims[_claimId];
Deal storage deal = deals[claim.dealId];
require(deal.state == DealState.Claimed, "Deal is not Claimed");
if (block.timestamp >= claim.createdAt + settings.timeForChallenge) {
// anyone can force a claim that went over the period
} else {
// only the seller can accept it
require(deal.seller == msg.sender, "Only seller");
}
uint256 arbFees = arbitrator.arbitrationCost(extraDatas[claim.arbSettingsId]);
_closeDeal(claim.dealId, deal.amount - claim.amount);
claim.solvedAt = uint32(block.timestamp);
deal.token.transfer(deal.buyer, claim.amount);
emit ClaimClosed(_claimId, ClaimResult.Accepted);
payable(deal.buyer).send(arbFees); // it is the buyer responsibility to accept eth.
}
/**
* @dev Challenge a refund claim, only by seller. A dispute will be created.
* @param _claimId The ID of the claim to challenge.
*/
function challengeClaim(uint64 _claimId) public payable {
Claim storage claim = claims[_claimId];
Deal storage deal = deals[claim.dealId];
require(msg.sender == deal.seller, "Only seller");
require(deal.state == DealState.Claimed, "Deal is not Claimed");
require(block.timestamp < claim.createdAt + settings.timeForChallenge, "Too late for challenge");
// if arbFees are updated between the period the claim is created and challenged:
// 1. they rise, so someone should cover the difference so that arbFees are returned
// to winner on rule(...), and prevent contract from halting.
// 2. they are lowered, so someone should send the difference to the claimer
// whether they win or lose.
uint256 arbFees = arbitrator.arbitrationCost(extraDatas[claim.arbSettingsId]);
require(msg.value >= arbFees, "Not enough to cover fees");
// all good now.
uint256 disputeId = arbitrator.createDispute{value: arbFees}(
NUMBER_OF_RULINGS,
extraDatas[claim.arbSettingsId]
);
disputeIdToClaim[disputeId] = _claimId;
claim.disputeId = disputeId;
claim.arbFees = arbFees;
deal.state = DealState.Disputed;
// initializes the round array
claim.rounds.push();
emit Dispute(arbitrator, disputeId, claim.arbSettingsId, _claimId);
}
/**
* @dev Rule on a claim, only by arbitrator.
* @param _disputeId The external ID of the dispute.
* @param _ruling The ruling. 0 and 1 will not refund, 2 will refund.
*/
function rule(uint256 _disputeId, uint256 _ruling) external {
require(msg.sender == address(arbitrator), "Only arbitrator rules");
uint64 claimId = disputeIdToClaim[_disputeId];
Claim storage claim = claims[claimId];
Deal storage deal = deals[claim.dealId];
require(deal.state == DealState.Disputed, "Deal is not Disputed");
claim.solvedAt = uint32(block.timestamp);
claim.ruling = uint8(_ruling);
deal.state = DealState.Ongoing; // will be overwritten if needed.
// if 0 (RtA) or 1 (Don't refund)...
if (_ruling < 2) {
// was this the last claim? if so, close deal with everything
if (deal.claimCount >= settings.maxClaims) {
_closeDeal(claim.dealId, deal.amount);
}
payable(deal.seller).send(claim.arbFees);
emit ClaimClosed(claimId, ClaimResult.Rejected);
} else {
deal.token.transfer(deal.buyer, claim.amount);
_closeDeal(claim.dealId, deal.amount - claim.amount);
// refund buyer
payable(deal.buyer).send(claim.arbFees);
emit ClaimClosed(claimId, ClaimResult.Accepted);
}
emit Ruling(arbitrator, _disputeId, _ruling);
}
/**
* @dev Read whether if a deal is over or not.
* @param _dealId Id of the deal to check.
*/
function isOver(uint64 _dealId) public view returns (bool) {
Deal memory deal = deals[_dealId];
// if finished, then it's "over"
if (deal.state == DealState.Finished) return (true);
// if none, it hasn't even begun. if claimed or disputed, it can't be over yet.
if (deal.state != DealState.Ongoing) return (false);
// so, it's Ongoing. if no claims, then createdAt is the reference
if (deal.claimCount == 0) {
return (block.timestamp >= (deal.createdAt + deal.timeForService + deal.timeForClaim));
} else {
// if was ever claimed, the date of the last claim being solved is the reference.
return (block.timestamp >= (claims[deal.currentClaim].solvedAt + settings.timeForReclaim));
}
}
/**
* @dev Internal function to close the deal. It will process the fees
* @param _dealId Id of the deal to check.
*/
function _closeDeal(uint64 _dealId, uint256 _amount) internal {
Deal storage deal = deals[_dealId];
uint256 ubiFee = (_amount * (settings.ubiFee + deal.extraBurnFee)) / BASIS_POINTS;
uint256 adminFee = (_amount * settings.adminFee) / BASIS_POINTS;
uint256 toSeller = _amount - ubiFee - adminFee;
deal.state = DealState.Finished;
deal.token.transfer(deal.seller, toSeller);
deal.token.transfer(settings.admin, adminFee);
deal.token.transfer(settings.ubiBurner, ubiFee);
emit DealClosed(_dealId, toSeller, deal.amount - _amount, ubiFee, adminFee);
}
// IDisputeResolver VIEWS
/** @dev Maps external (arbitrator side) dispute id to local (arbitrable) dispute id.
* @param _externalDisputeID Dispute id as in arbitrator contract.
* @return localDisputeID Dispute id as in arbitrable contract.
*/
function externalIDtoLocalID(uint256 _externalDisputeID) external view override returns (uint256 localDisputeID) {
localDisputeID = disputeIdToClaim[_externalDisputeID];
}
/** @dev Returns number of possible ruling options. Valid rulings are [0, return value].
* @return count The number of ruling options.
*/
function numberOfRulingOptions(uint256) external pure override returns (uint256 count) {
count = NUMBER_OF_RULINGS;
}
/** @dev Allows to submit evidence for a given dispute.
* @param _claimId Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _evidenceURI IPFS path to evidence, example: '/ipfs/Qmarwkf7C9RuzDEJNnarT3WZ7kem5bk8DZAzx78acJjMFH/evidence.json'
*/
function submitEvidence(uint256 _claimId, string calldata _evidenceURI) external override {
emit Evidence(arbitrator, _claimId, msg.sender, _evidenceURI);
}
/** @dev Returns appeal multipliers.
* @return winnerStakeMultiplier Winners stake multiplier.
* @return loserStakeMultiplier Losers stake multiplier.
* @return loserAppealPeriodMultiplier Losers appeal period multiplier. The loser is given less time to fund its appeal to defend against last minute appeal funding attacks.
* @return denominator Multiplier denominator in basis points.
*/
function getMultipliers() external pure override returns (uint256, uint256, uint256, uint256) {
return (WINNER_STAKE_MULTIPLIER, LOSER_STAKE_MULTIPLIER, LOSER_APPEAL_PERIOD_MULTIPLIER, BASIS_POINTS);
}
// IDisputeResolver APPEALS
/** @dev Manages contributions and calls appeal function of the specified arbitrator to appeal a dispute. This function lets appeals be crowdfunded.
* @param _claimId Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _ruling The ruling option to which the caller wants to contribute.
* @return fullyFunded True if the ruling option got fully funded as a result of this contribution.
*/
function fundAppeal(uint256 _claimId, uint256 _ruling) external payable override returns (bool fullyFunded) {
Claim storage claim = claims[uint64(_claimId)];
Deal storage deal = deals[claim.dealId];
require(deal.state == DealState.Disputed, "No dispute to appeal.");
require(_ruling < 3, "Invalid ruling");
uint256 disputeId = claim.disputeId;
(uint256 appealPeriodStart, uint256 appealPeriodEnd) = arbitrator.appealPeriod(disputeId);
require(block.timestamp >= appealPeriodStart && block.timestamp < appealPeriodEnd, "Appeal period is over.");
uint256 multiplier;
{
uint256 winner = arbitrator.currentRuling(disputeId);
if (winner == _ruling) {
multiplier = WINNER_STAKE_MULTIPLIER;
} else {
require(
block.timestamp - appealPeriodStart <
((appealPeriodEnd - appealPeriodStart) * LOSER_APPEAL_PERIOD_MULTIPLIER) / BASIS_POINTS,
"Appeal period is over for loser"
);
multiplier = LOSER_STAKE_MULTIPLIER;
}
}
uint256 lastRoundID = claim.rounds.length - 1;
Round storage round = claim.rounds[lastRoundID];
require(!round.hasPaid[_ruling], "Appeal fee is already paid.");
uint256 appealCost = arbitrator.appealCost(disputeId, extraDatas[claim.arbSettingsId]);
uint256 totalCost = appealCost + ((appealCost * multiplier) / BASIS_POINTS);
// Take up to the amount necessary to fund the current round at the current costs.
uint256 contribution = (totalCost - round.paidFees[_ruling]) > msg.value
? msg.value
: totalCost - round.paidFees[_ruling];
emit Contribution(_claimId, lastRoundID, _ruling, msg.sender, contribution);
round.contributions[msg.sender][_ruling] += contribution;
round.paidFees[_ruling] += contribution;
if (round.paidFees[_ruling] >= totalCost) {
round.feeRewards += round.paidFees[_ruling];
round.fundedAnswers.push(_ruling);
round.hasPaid[_ruling] = true;
emit RulingFunded(_claimId, lastRoundID, _ruling);
}
if (round.fundedAnswers.length > 1) {
// At least two sides are fully funded.
claim.rounds.push();
round.feeRewards = round.feeRewards - appealCost;
arbitrator.appeal{value: appealCost}(disputeId, extraDatas[claim.arbSettingsId]);
}
if (contribution < msg.value) payable(msg.sender).send(msg.value - contribution); // Sending extra value back to contributor. It is the user's responsibility to accept ETH.
return round.hasPaid[_ruling];
}
/**
* @notice Sends the fee stake rewards and reimbursements proportional to the contributions made to the winner of a dispute. Reimburses contributions if there is no winner.
* @param _claimId The ID of the claim.
* @param _beneficiary The address to send reward to.
* @param _round The round from which to withdraw.
* @param _ruling The ruling to request the reward from.
* @return reward The withdrawn amount.
*/
function withdrawFeesAndRewards(
uint256 _claimId,
address payable _beneficiary,
uint256 _round,
uint256 _ruling
) public override returns (uint256 reward) {
Claim storage claim = claims[uint64(_claimId)];
Round storage round = claim.rounds[_round];
require(claim.solvedAt != 0, "Claim not resolved");
// Allow to reimburse if funding of the round was unsuccessful.
if (!round.hasPaid[_ruling]) {
reward = round.contributions[_beneficiary][_ruling];
} else if (!round.hasPaid[claim.ruling]) {
// Reimburse unspent fees proportionally if the ultimate winner didn't pay appeal fees fully.
// Note that if only one side is funded it will become a winner and this part of the condition won't be reached.
reward = round.fundedAnswers.length > 1
? (round.contributions[_beneficiary][_ruling] * round.feeRewards) /
(round.paidFees[round.fundedAnswers[0]] + round.paidFees[round.fundedAnswers[1]])
: 0;
} else if (claim.ruling == _ruling) {
uint256 paidFees = round.paidFees[_ruling];
// Reward the winner.
reward = paidFees > 0 ? (round.contributions[_beneficiary][_ruling] * round.feeRewards) / paidFees : 0;
}
if (reward != 0) {
round.contributions[_beneficiary][_ruling] = 0;
_beneficiary.send(reward); // It is the user's responsibility to accept ETH.
emit Withdrawal(_claimId, _round, _ruling, _beneficiary, reward);
}
}
/**
* @notice Allows to withdraw any rewards or reimbursable fees for all rounds at once.
* @dev This function is O(n) where n is the total number of rounds. Arbitration cost of subsequent rounds is `A(n) = 2A(n-1) + 1`.
* So because of this exponential growth of costs, you can assume n is less than 10 at all times.
* @param _claimId The ID of the arbitration.
* @param _beneficiary The address that made contributions.
* @param _contributedTo Answer that received contributions from contributor.
*/
function withdrawFeesAndRewardsForAllRounds(
uint256 _claimId,
address payable _beneficiary,
uint256 _contributedTo
) external override {
uint256 numberOfRounds = claims[uint64(_claimId)].rounds.length;
for (uint256 roundNumber = 0; roundNumber < numberOfRounds; roundNumber++) {
withdrawFeesAndRewards(_claimId, _beneficiary, roundNumber, _contributedTo);
}
}
/**
* @notice Returns the sum of withdrawable amount.
* @dev This function is O(n) where n is the total number of rounds.
* @dev This could exceed the gas limit, therefore this function should be used only as a utility and not be relied upon by other contracts.
* @param _claimId The ID of the arbitration.
* @param _beneficiary The contributor for which to query.
* @param _contributedTo Answer that received contributions from contributor.
* @return sum The total amount available to withdraw.
*/
function getTotalWithdrawableAmount(
uint256 _claimId,
address payable _beneficiary,
uint256 _contributedTo
) external view override returns (uint256 sum) {
if (claims[uint64(_claimId)].solvedAt == 0) return sum;
uint256 finalAnswer = claims[uint64(_claimId)].ruling;
uint256 noOfRounds = claims[uint64(_claimId)].rounds.length;
for (uint256 roundNumber = 0; roundNumber < noOfRounds; roundNumber++) {
Round storage round = claims[uint64(_claimId)].rounds[roundNumber];
if (!round.hasPaid[_contributedTo]) {
// Allow to reimburse if funding was unsuccessful for this answer option.
sum += round.contributions[_beneficiary][_contributedTo];
} else if (!round.hasPaid[finalAnswer]) {
// Reimburse unspent fees proportionally if the ultimate winner didn't pay appeal fees fully.
// Note that if only one side is funded it will become a winner and this part of the condition won't be reached.
sum += round.fundedAnswers.length > 1
? (round.contributions[_beneficiary][_contributedTo] * round.feeRewards) /
(round.paidFees[round.fundedAnswers[0]] + round.paidFees[round.fundedAnswers[1]])
: 0;
} else if (finalAnswer == _contributedTo) {
uint256 paidFees = round.paidFees[_contributedTo];
// Reward the winner.
sum += paidFees > 0
? (round.contributions[_beneficiary][_contributedTo] * round.feeRewards) / paidFees
: 0;
}
}
}
}// SPDX-License-Identifier: MIT
/**
* @authors: [@ferittuncer]
* @reviewers: [@mtsalenc*, @hbarcelos*, @unknownunknown1, @MerlinEgalite, @fnanni-0*, @shalzz]
* @auditors: []
* @bounties: []
* @deployments: []
*/
pragma solidity ^0.8.0;
import "@kleros/erc-792/contracts/IArbitrable.sol";
import "@kleros/erc-792/contracts/erc-1497/IEvidence.sol";
import "@kleros/erc-792/contracts/IArbitrator.sol";
/**
* @title This serves as a standard interface for crowdfunded appeals and evidence submission, which aren't a part of the arbitration (erc-792 and erc-1497) standard yet.
This interface is used in Dispute Resolver (resolve.kleros.io).
*/
abstract contract IDisputeResolver is IArbitrable, IEvidence {
string public constant VERSION = "2.0.0"; // Can be used to distinguish between multiple deployed versions, if necessary.
/** @dev Raised when a contribution is made, inside fundAppeal function.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _round The round number the contribution was made to.
* @param ruling Indicates the ruling option which got the contribution.
* @param _contributor Caller of fundAppeal function.
* @param _amount Contribution amount.
*/
event Contribution(uint256 indexed _localDisputeID, uint256 indexed _round, uint256 ruling, address indexed _contributor, uint256 _amount);
/** @dev Raised when a contributor withdraws non-zero value.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _round The round number the withdrawal was made from.
* @param _ruling Indicates the ruling option which contributor gets rewards from.
* @param _contributor The beneficiary of withdrawal.
* @param _reward Total amount of withdrawal, consists of reimbursed deposits plus rewards.
*/
event Withdrawal(uint256 indexed _localDisputeID, uint256 indexed _round, uint256 _ruling, address indexed _contributor, uint256 _reward);
/** @dev To be raised when a ruling option is fully funded for appeal.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _round Number of the round this ruling option was fully funded in.
* @param _ruling The ruling option which just got fully funded.
*/
event RulingFunded(uint256 indexed _localDisputeID, uint256 indexed _round, uint256 indexed _ruling);
/** @dev Maps external (arbitrator side) dispute id to local (arbitrable) dispute id.
* @param _externalDisputeID Dispute id as in arbitrator contract.
* @return localDisputeID Dispute id as in arbitrable contract.
*/
function externalIDtoLocalID(uint256 _externalDisputeID) external virtual returns (uint256 localDisputeID);
/** @dev Returns number of possible ruling options. Valid rulings are [0, return value].
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @return count The number of ruling options.
*/
function numberOfRulingOptions(uint256 _localDisputeID) external view virtual returns (uint256 count);
/** @dev Allows to submit evidence for a given dispute.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _evidenceURI IPFS path to evidence, example: '/ipfs/Qmarwkf7C9RuzDEJNnarT3WZ7kem5bk8DZAzx78acJjMFH/evidence.json'
*/
function submitEvidence(uint256 _localDisputeID, string calldata _evidenceURI) external virtual;
/** @dev Manages contributions and calls appeal function of the specified arbitrator to appeal a dispute. This function lets appeals be crowdfunded.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _ruling The ruling option to which the caller wants to contribute.
* @return fullyFunded True if the ruling option got fully funded as a result of this contribution.
*/
function fundAppeal(uint256 _localDisputeID, uint256 _ruling) external payable virtual returns (bool fullyFunded);
/** @dev Returns appeal multipliers.
* @return winnerStakeMultiplier Winners stake multiplier.
* @return loserStakeMultiplier Losers stake multiplier.
* @return loserAppealPeriodMultiplier Losers appeal period multiplier. The loser is given less time to fund its appeal to defend against last minute appeal funding attacks.
* @return denominator Multiplier denominator in basis points.
*/
function getMultipliers()
external
view
virtual
returns (
uint256 winnerStakeMultiplier,
uint256 loserStakeMultiplier,
uint256 loserAppealPeriodMultiplier,
uint256 denominator
);
/** @dev Allows to withdraw any reimbursable fees or rewards after the dispute gets resolved.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _contributor Beneficiary of withdraw operation.
* @param _round Number of the round that caller wants to execute withdraw on.
* @param _ruling A ruling option that caller wants to execute withdraw on.
* @return sum The amount that is going to be transferred to contributor as a result of this function call.
*/
function withdrawFeesAndRewards(
uint256 _localDisputeID,
address payable _contributor,
uint256 _round,
uint256 _ruling
) external virtual returns (uint256 sum);
/** @dev Allows to withdraw any rewards or reimbursable fees after the dispute gets resolved for all rounds at once.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _contributor Beneficiary of withdraw operation.
* @param _ruling Ruling option that caller wants to execute withdraw on.
*/
function withdrawFeesAndRewardsForAllRounds(
uint256 _localDisputeID,
address payable _contributor,
uint256 _ruling
) external virtual;
/** @dev Returns the sum of withdrawable amount.
* @param _localDisputeID Identifier of a dispute in scope of arbitrable contract. Arbitrator ids can be translated to local ids via externalIDtoLocalID.
* @param _contributor Beneficiary of withdraw operation.
* @param _ruling Ruling option that caller wants to get withdrawable amount from.
* @return sum The total amount available to withdraw.
*/
function getTotalWithdrawableAmount(
uint256 _localDisputeID,
address payable _contributor,
uint256 _ruling
) external view virtual returns (uint256 sum);
}/**
* @authors: [@ferittuncer, @hbarcelos]
* @reviewers: [@remedcu]
* @auditors: []
* @bounties: []
* @deployments: []
* SPDX-License-Identifier: MIT
*/
pragma solidity ^0.8.0;
import "./IArbitrator.sol";
/**
* @title IArbitrable
* Arbitrable interface.
* When developing arbitrable contracts, we need to:
* - Define the action taken when a ruling is received by the contract.
* - Allow dispute creation. For this a function must call arbitrator.createDispute{value: _fee}(_choices,_extraData);
*/
interface IArbitrable {
/**
* @dev To be raised when a ruling is given.
* @param _arbitrator The arbitrator giving the ruling.
* @param _disputeID ID of the dispute in the Arbitrator contract.
* @param _ruling The ruling which was given.
*/
event Ruling(IArbitrator indexed _arbitrator, uint256 indexed _disputeID, uint256 _ruling);
/**
* @dev Give a ruling for a dispute. Must be called by the arbitrator.
* The purpose of this function is to ensure that the address calling it has the right to rule on the contract.
* @param _disputeID ID of the dispute in the Arbitrator contract.
* @param _ruling Ruling given by the arbitrator. Note that 0 is reserved for "Not able/wanting to make a decision".
*/
function rule(uint256 _disputeID, uint256 _ruling) external;
}/**
* @authors: [@ferittuncer, @hbarcelos]
* @reviewers: [@remedcu]
* @auditors: []
* @bounties: []
* @deployments: []
* SPDX-License-Identifier: MIT
*/
pragma solidity ^0.8.0;
import "./IArbitrable.sol";
/**
* @title Arbitrator
* Arbitrator abstract contract.
* When developing arbitrator contracts we need to:
* - Define the functions for dispute creation (createDispute) and appeal (appeal). Don't forget to store the arbitrated contract and the disputeID (which should be unique, may nbDisputes).
* - Define the functions for cost display (arbitrationCost and appealCost).
* - Allow giving rulings. For this a function must call arbitrable.rule(disputeID, ruling).
*/
interface IArbitrator {
enum DisputeStatus {
Waiting,
Appealable,
Solved
}
/**
* @dev To be emitted when a dispute is created.
* @param _disputeID ID of the dispute.
* @param _arbitrable The contract which created the dispute.
*/
event DisputeCreation(uint256 indexed _disputeID, IArbitrable indexed _arbitrable);
/**
* @dev To be emitted when a dispute can be appealed.
* @param _disputeID ID of the dispute.
* @param _arbitrable The contract which created the dispute.
*/
event AppealPossible(uint256 indexed _disputeID, IArbitrable indexed _arbitrable);
/**
* @dev To be emitted when the current ruling is appealed.
* @param _disputeID ID of the dispute.
* @param _arbitrable The contract which created the dispute.
*/
event AppealDecision(uint256 indexed _disputeID, IArbitrable indexed _arbitrable);
/**
* @dev Create a dispute. Must be called by the arbitrable contract.
* Must be paid at least arbitrationCost(_extraData).
* @param _choices Amount of choices the arbitrator can make in this dispute.
* @param _extraData Can be used to give additional info on the dispute to be created.
* @return disputeID ID of the dispute created.
*/
function createDispute(uint256 _choices, bytes calldata _extraData) external payable returns (uint256 disputeID);
/**
* @dev Compute the cost of arbitration. It is recommended not to increase it often, as it can be highly time and gas consuming for the arbitrated contracts to cope with fee augmentation.
* @param _extraData Can be used to give additional info on the dispute to be created.
* @return cost Amount to be paid.
*/
function arbitrationCost(bytes calldata _extraData) external view returns (uint256 cost);
/**
* @dev Appeal a ruling. Note that it has to be called before the arbitrator contract calls rule.
* @param _disputeID ID of the dispute to be appealed.
* @param _extraData Can be used to give extra info on the appeal.
*/
function appeal(uint256 _disputeID, bytes calldata _extraData) external payable;
/**
* @dev Compute the cost of appeal. It is recommended not to increase it often, as it can be higly time and gas consuming for the arbitrated contracts to cope with fee augmentation.
* @param _disputeID ID of the dispute to be appealed.
* @param _extraData Can be used to give additional info on the dispute to be created.
* @return cost Amount to be paid.
*/
function appealCost(uint256 _disputeID, bytes calldata _extraData) external view returns (uint256 cost);
/**
* @dev Compute the start and end of the dispute's current or next appeal period, if possible. If not known or appeal is impossible: should return (0, 0).
* @param _disputeID ID of the dispute.
* @return start The start of the period.
* @return end The end of the period.
*/
function appealPeriod(uint256 _disputeID) external view returns (uint256 start, uint256 end);
/**
* @dev Return the status of a dispute.
* @param _disputeID ID of the dispute to rule.
* @return status The status of the dispute.
*/
function disputeStatus(uint256 _disputeID) external view returns (DisputeStatus status);
/**
* @dev Return the current ruling of a dispute. This is useful for parties to know if they should appeal.
* @param _disputeID ID of the dispute.
* @return ruling The ruling which has been given or the one which will be given if there is no appeal.
*/
function currentRuling(uint256 _disputeID) external view returns (uint256 ruling);
}/**
* @authors: [@ferittuncer, @hbarcelos]
* @reviewers: []
* @auditors: []
* @bounties: []
* @deployments: []
* SPDX-License-Identifier: MIT
*/
pragma solidity ^0.8.0;
import "../IArbitrator.sol";
/** @title IEvidence
* ERC-1497: Evidence Standard
*/
interface IEvidence {
/**
* @dev To be emitted when meta-evidence is submitted.
* @param _metaEvidenceID Unique identifier of meta-evidence.
* @param _evidence IPFS path to metaevidence, example: '/ipfs/Qmarwkf7C9RuzDEJNnarT3WZ7kem5bk8DZAzx78acJjMFH/metaevidence.json'
*/
event MetaEvidence(uint256 indexed _metaEvidenceID, string _evidence);
/**
* @dev To be raised when evidence is submitted. Should point to the resource (evidences are not to be stored on chain due to gas considerations).
* @param _arbitrator The arbitrator of the contract.
* @param _evidenceGroupID Unique identifier of the evidence group the evidence belongs to.
* @param _party The address of the party submiting the evidence. Note that 0x0 refers to evidence not submitted by any party.
* @param _evidence IPFS path to evidence, example: '/ipfs/Qmarwkf7C9RuzDEJNnarT3WZ7kem5bk8DZAzx78acJjMFH/evidence.json'
*/
event Evidence(
IArbitrator indexed _arbitrator,
uint256 indexed _evidenceGroupID,
address indexed _party,
string _evidence
);
/**
* @dev To be emitted when a dispute is created to link the correct meta-evidence to the disputeID.
* @param _arbitrator The arbitrator of the contract.
* @param _disputeID ID of the dispute in the Arbitrator contract.
* @param _metaEvidenceID Unique identifier of meta-evidence.
* @param _evidenceGroupID Unique identifier of the evidence group that is linked to this dispute.
*/
event Dispute(
IArbitrator indexed _arbitrator,
uint256 indexed _disputeID,
uint256 _metaEvidenceID,
uint256 _evidenceGroupID
);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC20 standard as defined in the EIP.
*/
interface IERC20 {
/**
* @dev Emitted when `value` tokens are moved from one account (`from`) to
* another (`to`).
*
* Note that `value` may be zero.
*/
event Transfer(address indexed from, address indexed to, uint256 value);
/**
* @dev Emitted when the allowance of a `spender` for an `owner` is set by
* a call to {approve}. `value` is the new allowance.
*/
event Approval(address indexed owner, address indexed spender, uint256 value);
/**
* @dev Returns the 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 `to`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address to, 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 `from` to `to` 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 from,
address to,
uint256 amount
) external returns (bool);
}{
"evmVersion": "london",
"libraries": {},
"metadata": {
"bytecodeHash": "ipfs",
"useLiteralContent": true
},
"optimizer": {
"enabled": true,
"runs": 200
},
"remappings": [],
"viaIR": true,
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"components":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint32","name":"maxClaims","type":"uint32"},{"internalType":"uint32","name":"timeForReclaim","type":"uint32"},{"internalType":"uint32","name":"timeForChallenge","type":"uint32"},{"internalType":"address","name":"ubiBurner","type":"address"},{"internalType":"uint32","name":"adminFee","type":"uint32"},{"internalType":"uint32","name":"ubiFee","type":"uint32"},{"internalType":"uint32","name":"maxExtraFee","type":"uint32"},{"internalType":"uint32","name":"minTimeForService","type":"uint32"},{"internalType":"uint32","name":"maxTimeForService","type":"uint32"},{"internalType":"uint32","name":"minTimeForClaim","type":"uint32"},{"internalType":"uint32","name":"maxTimeForClaim","type":"uint32"}],"internalType":"struct Yubiai.YubiaiSettings","name":"_settings","type":"tuple"},{"internalType":"address","name":"_governor","type":"address"},{"internalType":"contract IArbitrator","name":"_arbitrator","type":"address"},{"internalType":"bytes","name":"_extraData","type":"bytes"},{"internalType":"string","name":"_metaEvidence","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint64","name":"claimId","type":"uint64"},{"indexed":true,"internalType":"enum Yubiai.ClaimResult","name":"result","type":"uint8"}],"name":"ClaimClosed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint64","name":"dealId","type":"uint64"},{"indexed":true,"internalType":"uint64","name":"claimId","type":"uint64"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"string","name":"evidence","type":"string"}],"name":"ClaimCreated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"_localDisputeID","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"_round","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"ruling","type":"uint256"},{"indexed":true,"internalType":"address","name":"_contributor","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"Contribution","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint64","name":"dealId","type":"uint64"},{"indexed":false,"internalType":"uint256","name":"payment","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"refund","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"ubiFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"adminFee","type":"uint256"}],"name":"DealClosed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint64","name":"dealId","type":"uint64"},{"components":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"buyer","type":"address"},{"internalType":"enum Yubiai.DealState","name":"state","type":"uint8"},{"internalType":"uint32","name":"extraBurnFee","type":"uint32"},{"internalType":"uint32","name":"claimCount","type":"uint32"},{"internalType":"uint24","name":"freeSpace","type":"uint24"},{"internalType":"address","name":"seller","type":"address"},{"internalType":"uint32","name":"createdAt","type":"uint32"},{"internalType":"uint32","name":"timeForService","type":"uint32"},{"internalType":"uint32","name":"timeForClaim","type":"uint32"},{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint64","name":"currentClaim","type":"uint64"},{"internalType":"uint32","name":"freeSpace2","type":"uint32"}],"indexed":false,"internalType":"struct Yubiai.Deal","name":"deal","type":"tuple"},{"indexed":false,"internalType":"string","name":"terms","type":"string"}],"name":"DealCreated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract IArbitrator","name":"_arbitrator","type":"address"},{"indexed":true,"internalType":"uint256","name":"_disputeID","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_metaEvidenceID","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_evidenceGroupID","type":"uint256"}],"name":"Dispute","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract IArbitrator","name":"_arbitrator","type":"address"},{"indexed":true,"internalType":"uint256","name":"_evidenceGroupID","type":"uint256"},{"indexed":true,"internalType":"address","name":"_party","type":"address"},{"indexed":false,"internalType":"string","name":"_evidence","type":"string"}],"name":"Evidence","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"_metaEvidenceID","type":"uint256"},{"indexed":false,"internalType":"string","name":"_evidence","type":"string"}],"name":"MetaEvidence","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract IArbitrator","name":"_arbitrator","type":"address"},{"indexed":true,"internalType":"uint256","name":"_disputeID","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_ruling","type":"uint256"}],"name":"Ruling","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"_localDisputeID","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"_round","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"_ruling","type":"uint256"}],"name":"RulingFunded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"_localDisputeID","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"_round","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_ruling","type":"uint256"},{"indexed":true,"internalType":"address","name":"_contributor","type":"address"},{"indexed":false,"internalType":"uint256","name":"_reward","type":"uint256"}],"name":"Withdrawal","type":"event"},{"inputs":[],"name":"VERSION","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"_claimId","type":"uint64"}],"name":"acceptClaim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"arbitrator","outputs":[{"internalType":"contract IArbitrator","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"_claimId","type":"uint64"}],"name":"challengeClaim","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"_governor","type":"address"}],"name":"changeGovernor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint32","name":"maxClaims","type":"uint32"},{"internalType":"uint32","name":"timeForReclaim","type":"uint32"},{"internalType":"uint32","name":"timeForChallenge","type":"uint32"},{"internalType":"address","name":"ubiBurner","type":"address"},{"internalType":"uint32","name":"adminFee","type":"uint32"},{"internalType":"uint32","name":"ubiFee","type":"uint32"},{"internalType":"uint32","name":"maxExtraFee","type":"uint32"},{"internalType":"uint32","name":"minTimeForService","type":"uint32"},{"internalType":"uint32","name":"maxTimeForService","type":"uint32"},{"internalType":"uint32","name":"minTimeForClaim","type":"uint32"},{"internalType":"uint32","name":"maxTimeForClaim","type":"uint32"}],"internalType":"struct Yubiai.YubiaiSettings","name":"_settings","type":"tuple"}],"name":"changeSettings","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"claims","outputs":[{"internalType":"uint256","name":"disputeId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"arbFees","type":"uint256"},{"internalType":"uint64","name":"dealId","type":"uint64"},{"internalType":"uint32","name":"createdAt","type":"uint32"},{"internalType":"uint32","name":"solvedAt","type":"uint32"},{"internalType":"uint8","name":"ruling","type":"uint8"},{"internalType":"uint64","name":"arbSettingsId","type":"uint64"},{"internalType":"uint56","name":"freeSpace","type":"uint56"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"_dealId","type":"uint64"}],"name":"closeDeal","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"counters","outputs":[{"internalType":"uint64","name":"dealCount","type":"uint64"},{"internalType":"uint64","name":"claimCount","type":"uint64"},{"internalType":"uint64","name":"currentArbSettingId","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"buyer","type":"address"},{"internalType":"enum Yubiai.DealState","name":"state","type":"uint8"},{"internalType":"uint32","name":"extraBurnFee","type":"uint32"},{"internalType":"uint32","name":"claimCount","type":"uint32"},{"internalType":"uint24","name":"freeSpace","type":"uint24"},{"internalType":"address","name":"seller","type":"address"},{"internalType":"uint32","name":"createdAt","type":"uint32"},{"internalType":"uint32","name":"timeForService","type":"uint32"},{"internalType":"uint32","name":"timeForClaim","type":"uint32"},{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint64","name":"currentClaim","type":"uint64"},{"internalType":"uint32","name":"freeSpace2","type":"uint32"}],"internalType":"struct Yubiai.Deal","name":"_deal","type":"tuple"},{"internalType":"string","name":"_terms","type":"string"}],"name":"createDeal","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"buyer","type":"address"},{"internalType":"enum Yubiai.DealState","name":"state","type":"uint8"},{"internalType":"uint32","name":"extraBurnFee","type":"uint32"},{"internalType":"uint32","name":"claimCount","type":"uint32"},{"internalType":"uint24","name":"freeSpace","type":"uint24"},{"internalType":"address","name":"seller","type":"address"},{"internalType":"uint32","name":"createdAt","type":"uint32"},{"internalType":"uint32","name":"timeForService","type":"uint32"},{"internalType":"uint32","name":"timeForClaim","type":"uint32"},{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint64","name":"currentClaim","type":"uint64"},{"internalType":"uint32","name":"freeSpace2","type":"uint32"}],"internalType":"struct Yubiai.Deal","name":"_deal","type":"tuple"},{"internalType":"string","name":"_terms","type":"string"}],"name":"createDealWithValue","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"deals","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"buyer","type":"address"},{"internalType":"enum Yubiai.DealState","name":"state","type":"uint8"},{"internalType":"uint32","name":"extraBurnFee","type":"uint32"},{"internalType":"uint32","name":"claimCount","type":"uint32"},{"internalType":"uint24","name":"freeSpace","type":"uint24"},{"internalType":"address","name":"seller","type":"address"},{"internalType":"uint32","name":"createdAt","type":"uint32"},{"internalType":"uint32","name":"timeForService","type":"uint32"},{"internalType":"uint32","name":"timeForClaim","type":"uint32"},{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"uint64","name":"currentClaim","type":"uint64"},{"internalType":"uint32","name":"freeSpace2","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"disputeIdToClaim","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_externalDisputeID","type":"uint256"}],"name":"externalIDtoLocalID","outputs":[{"internalType":"uint256","name":"localDisputeID","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"extraDatas","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_claimId","type":"uint256"},{"internalType":"uint256","name":"_ruling","type":"uint256"}],"name":"fundAppeal","outputs":[{"internalType":"bool","name":"fullyFunded","type":"bool"}],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"getMultipliers","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"_claimId","type":"uint256"},{"internalType":"address payable","name":"_beneficiary","type":"address"},{"internalType":"uint256","name":"_contributedTo","type":"uint256"}],"name":"getTotalWithdrawableAmount","outputs":[{"internalType":"uint256","name":"sum","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"governor","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"_dealId","type":"uint64"}],"name":"isOver","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"_dealId","type":"uint64"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"string","name":"_evidence","type":"string"}],"name":"makeClaim","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes","name":"_extraData","type":"bytes"},{"internalType":"string","name":"_metaEvidence","type":"string"}],"name":"newArbSettings","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"numberOfRulingOptions","outputs":[{"internalType":"uint256","name":"count","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"_disputeId","type":"uint256"},{"internalType":"uint256","name":"_ruling","type":"uint256"}],"name":"rule","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"_token","type":"address"},{"internalType":"bool","name":"_validity","type":"bool"}],"name":"setTokenValidity","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"settings","outputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint32","name":"maxClaims","type":"uint32"},{"internalType":"uint32","name":"timeForReclaim","type":"uint32"},{"internalType":"uint32","name":"timeForChallenge","type":"uint32"},{"internalType":"address","name":"ubiBurner","type":"address"},{"internalType":"uint32","name":"adminFee","type":"uint32"},{"internalType":"uint32","name":"ubiFee","type":"uint32"},{"internalType":"uint32","name":"maxExtraFee","type":"uint32"},{"internalType":"uint32","name":"minTimeForService","type":"uint32"},{"internalType":"uint32","name":"maxTimeForService","type":"uint32"},{"internalType":"uint32","name":"minTimeForClaim","type":"uint32"},{"internalType":"uint32","name":"maxTimeForClaim","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_claimId","type":"uint256"},{"internalType":"string","name":"_evidenceURI","type":"string"}],"name":"submitEvidence","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"name":"tokenValidity","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_claimId","type":"uint256"},{"internalType":"address payable","name":"_beneficiary","type":"address"},{"internalType":"uint256","name":"_round","type":"uint256"},{"internalType":"uint256","name":"_ruling","type":"uint256"}],"name":"withdrawFeesAndRewards","outputs":[{"internalType":"uint256","name":"reward","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_claimId","type":"uint256"},{"internalType":"address payable","name":"_beneficiary","type":"address"},{"internalType":"uint256","name":"_contributedTo","type":"uint256"}],"name":"withdrawFeesAndRewardsForAllRounds","outputs":[],"stateMutability":"nonpayable","type":"function"}]Contract Creation Code
0x608060405234620004a55762003b7080380390816200001e81620004c0565b91823980828101036102008112620004a557610180809112620004a557604051918183016001600160401b03811184821017620004aa576040526200006381620004e6565b83526200007360208201620004fb565b60208401526200008660408201620004fb565b60408401526200009960608201620004fb565b6060840152620000ac60808201620004e6565b6080840152620000bf60a08201620004fb565b60a0840152620000d260c08201620004fb565b60c0840152620000e560e08201620004fb565b60e084015261010092620000fb848301620004fb565b848201526101209062000110828401620004fb565b8282015261014062000124818501620004fb565b8183015262000149610160956200013d878701620004fb565b878501528501620004e6565b6101a0850151909590946001600160a01b0386168603620004a5576101c08101516001600160401b038111620004a557898201601f828401011215620004a55781018051620001a091838c01919060200162000532565b6101e08201519099906001600160401b038111620004a557820191818101601f84011215620004a5576fffffffff0000000000000000000000009263ffffffff92620001f492019060208151910162000532565b9860018060a01b038651168260a01b602088015160a01b16908360c01b604089015160c01b16908460e01b60608a015160e01b169217171760015560018060a01b036080870151168260a01b60a088015160a01b16908360c01b60c089015160c01b16908460e01b60e08a015160e01b169217171760025585015116916bffffffff000000000000000067ffffffff000000006003549787015160201b169486015160401b1694015160601b169360018060801b0319161717171760035560018060a01b03199160018060a01b031682600454161760045560018060a01b0316906007541617600755600090818052600960205260408220835160018060401b03811162000491578154600181811c9116801562000486575b60208210146200047257601f811162000428575b506020601f8211600114620003af578190859660008051602062003b508339815191529692620003a3575b50508160011b916000199060031b1c19161790555b604080518092602082526200038681518092816020860152602086860191016200050d565b601f01601f19168101030190a26040516135d690816200057a8239f35b0151905038806200034c565b8285526020852095601f198316865b8181106200040f57509160008051602062003b50833981519152969791846001959410620003f5575b505050811b01905562000361565b015160001960f88460031b161c19169055388080620003e7565b83830151895560019098019760209384019301620003be565b82855260208520601f830160051c8101916020841062000467575b601f0160051c01905b8181106200045b575062000321565b8581556001016200044c565b909150819062000443565b634e487b7160e01b85526022600452602485fd5b90607f16906200030d565b634e487b7160e01b84526041600452602484fd5b600080fd5b634e487b7160e01b600052604160045260246000fd5b6040519190601f01601f191682016001600160401b03811183821017620004aa57604052565b51906001600160a01b0382168203620004a557565b519063ffffffff82168203620004a557565b60005b838110620005215750506000910152565b818101518382015260200162000510565b919291906001600160401b038111620004aa576200055a601f8201601f1916602001620004c0565b9381855281830111620004a557620005779160208501906200050d565b56fe608080604052600436101561001357600080fd5b600090813560e01c9081630c340a241461250c575080630c5179201461082057806310a8c211146122e95780631159739c1461203c57806327adb7d714611fa2578063311a6c5614611ca0578063362c347914611c665780634857346a146119fd5780634b2f0ea01461136c57806354342cc4146112675780636663d20a146111855780636cc6cde11461115c57806379873f8a1461112a5780637a0efe2c14610edb5780638b4d68a214610e9c5780638d8b2d7e14610e7f578063a4a0baf314610e51578063a6a7f0eb14610dd3578063b84b043114610ae1578063bece85f014610a7f578063c073f24f14610853578063c21ae06114610820578063da53a90a14610455578063dbfca4c01461037d578063e06174e4146102d9578063e4c0aaf414610290578063ec85635b1461026e578063f721063314610231578063fe2dddeb146101df5763ffa1ad741461016b57600080fd5b346101dc57806003193601126101dc5760405160408101908082106001600160401b038311176101c6576101c29160405260058152640322e302e360dc1b60208201526040519182916020835260208301906125f8565b0390f35b634e487b7160e01b600052604160045260246000fd5b80fd5b50346101dc576101ee366127f1565b906001600160401b03831684526006602052600460408520015492845b848110610216578580f35b806102268561022c93868661310e565b5061336f565b61020b565b50346101dc57806003193601126101dc5760609054604051906001600160401b03908181168352818160401c16602084015260801c166040820152f35b50346101dc576020610288610282366127f1565b9161337e565b604051908152f35b50346101dc5760203660031901126101dc576102aa612638565b600454906001600160a01b03906102c4338385161461281b565b16906001600160601b0360a01b161760045580f35b50346101dc57806003193601126101dc57610180600154600254906003546040519260018060a01b03808416855263ffffffff93848160a01c166020870152848160c01c16604087015260e01c606086015281166080850152828160a01c1660a0850152828160c01c1660c085015260e01c60e0840152818116610100840152818160201c16610120840152818160401c1661014084015260601c16610160820152f35b50346101dc5760203660031901126101dc576101a09060406001600160401b0391826103a761255e565b1681526005602052208054916001820154600360028401549301549260405194855260018060a01b039182811660208701526103ec6040870160ff8360a01c166127ce565b63ffffffff90818160a81c166060880152818160c81c16608088015260e81c60a087015282821660c0870152808260a01c1660e08701528160c01c1661010086015260e01c61012085015282166101408401528160a01c1661016083015260e01c610180820152f35b5060603660031901126101dc5761046a61255e565b6001600160401b039060248035919060443584811161081c57610491903690600401612531565b92909385821692838852602092600584526040892091600183019182549060018060a01b039182811633036107eb578686541061079c5760a01c60ff16600581101561078957600114908161075e575b8161074d575b50156107105789868c604061052c9460075416918054948560801c168152600984522090604051808096819463f7434ea960e01b835286600484015289830190612b3b565b03915afa8015610705578b928d916106cc575b5061054c90341015612bd1565b60401c168a526006855260408a206003810190856001835492015563ffffffff60401b4260401b1680896001600160601b0319841617178355888d6001600160401b0360881b905460081b169278ffffffffffffffff0000000000ffffffffffffffffffffffff19161717179055600160a11b60ff60a01b19835416179081835563ffffffff809260c81c169182146106ba5750815463ffffffff60c81b1916600190910160c81b63ffffffff60c81b1617905567ffffffffffffffff60401b956106a1959094909390927f4c91dc5dedd6c0cc4b0ea60c714b360687f4d41a8ebd1188ae35cf2d9372c21e92610675908b54600391909101805467ffffffffffffffff60a01b191660409290921c8c1660a01b67ffffffffffffffff60a01b16919091179055565b6106998a54998a60401c169687966040805195869586528501526040840191612885565b0390a3612857565b60401b169067ffffffffffffffff60401b191617815580f35b634e487b7160e01b8b5260116004528afd5b809350888092503d83116106fe575b6106e581836125d7565b810103126106f95761054c8b92519061053f565b600080fd5b503d6106db565b6040513d8e823e3d90fd5b60405162461bcd60e51b815260048101879052601681840152751119585b0818d85b9b9bdd0818994818db185a5b595960521b6044820152606490fd5b6107579150612cf9565b15386104e7565b9050600285015461077f63ffffffff9182808260c01c169160a01c16612b23565b16421015906104e1565b634e487b7160e01b8d526021600452838dfd5b60405162461bcd60e51b8152600481018990526022818601527f526566756e642063616e6e6f742062652067726561746572207468616e206465604482015261185b60f21b6064820152608490fd5b60405162461bcd60e51b815260048101899052600a818601526927b7363c90313abcb2b960b11b6044820152606490fd5b8580fd5b50346101dc5760203660031901126101dc576001600160401b036040602092600435815260088452205416604051908152f35b50346101dc5761018080600319360112610a7b576040519081018181106001600160401b038211176101c65760405261088a612638565b815260243563ffffffff811681036106f957602082015260443563ffffffff811681036106f957604082015260643563ffffffff811681036106f95760608201526084356001600160a01b03811681036106f957608082015260a43563ffffffff811681036106f95760a082015260c43563ffffffff811681036106f95760c082015260e43563ffffffff811681036106f95760e08201526101043563ffffffff811681036106f957610100820152610124359063ffffffff821682036106f95761012081019182526101443563ffffffff811681036106f95761014082015263ffffffff610164351661016435036106f9576101643561016082015261099c60018060a01b0360045416331461281b565b60018060a01b0381511663ffffffff60a01b9081602084015160a01b169163ffffffff60c01b9283604086015160c01b1663ffffffff60e01b9384606088015160e01b169217171760015560018060a01b036080850151169060a085015160a01b169260c085015160c01b169160e085015160e01b169217171760025563ffffffff6101008201511667ffffffff00000000600354935160201b169063ffffffff60401b61014084015160401b169261016063ffffffff60601b91015160601b16936fffffffffffffffffffffffffffffffff19161717171760035580f35b5080fd5b50346101dc5760403660031901126101dc57610a99612638565b60243590811515809203610add576004546001600160a01b039190610ac1908316331461281b565b168252600a602052604082209060ff8019835416911617905580f35b8280fd5b50610aeb3661264e565b73e91d153e0b41518a2ce8dd3d7944fa863463a97d803b15610dc457604051630d0e30db60e41b81528490818160048134875af18015610dc857610db0575b505034835261014083015263ffffffff421660e0830152604082016001815283608084015283610160840152610b7163ffffffff60608501511660025460e01c10156128be565b610bee63ffffffff61010085015116610b956003549163ffffffff83161115612900565b610bb563ffffffff6101208701511663ffffffff8360401c16111561294c565b610bd563ffffffff6101008701511663ffffffff8360201c161015612998565b63ffffffff80610120870151169160601c1610156129e4565b6001600160401b038454168452600560205260408420908351825560018060a01b036020850151166001600160601b0360a01b600184015416176001830155516005811015610d9c5791610d49600383610c566001600160401b03966001610d8a9701612a30565b606087015160018201805460808a015160a0808c015160c89290921b63ffffffff60c81b1660a89590951b63ffffffff60a81b166001600160a81b03909316929092179390931760e89390931b6001600160e81b03191692909217905560c08089015160e0808b01516101008c01516101208d0151941b63ffffffff60c01b166001600160a01b03909316941b63ffffffff60a01b1693909317176001600160e01b03199190921b1617600282015561014087015161016088015161018089015160e01b6001600160e01b0319166001600160a01b0390921690881660a01b67ffffffffffffffff60a01b161717910155565b8454937f537c5c2e4e27a7bf3012bc5a481136d771a6cc8a7d879cca12eab9135e071dce848616928392610d8260405192839283612a54565b0390a2612857565b16906001600160401b03191617815580f35b634e487b7160e01b85526021600452602485fd5b610db9906125c4565b610dc4578338610b2a565b8380fd5b6040513d84823e3d90fd5b50346101dc5760403660031901126101dc576024356001600160401b038111610a7b57610e04903690600401612531565b60018060a01b03600754167fdccf2f8b2cc26eafcd61905cba744cff4b81d14740725f6376390dc6298a6a3c6040516020815280610e4b3396600435966020840191612885565b0390a480f35b50346101dc5760203660031901126101dc576020610e75610e7061255e565b612cf9565b6040519015158152f35b50346101dc5760203660031901126101dc57602060405160028152f35b50346101dc5760203660031901126101dc5760209060ff906040906001600160a01b03610ec7612638565b168152600a84522054166040519015158152f35b50346101dc57610eea3661264e565b82602060018060a01b03610140850151166064855160405194859384926323b872dd60e01b845233600485015230602485015260448401525af190811561111f5784916110f0575b50156110b35763ffffffff421660e08301526001604083015282608083015282610160830152610f7363ffffffff60608401511660025460e01c10156128be565b6101408201516001600160a01b03168352600a602052604083205460ff161561107e5761101363ffffffff61010084015116610fba6003549163ffffffff83161115612900565b610fda63ffffffff6101208601511663ffffffff8360401c16111561294c565b610ffa63ffffffff6101008601511663ffffffff8360201c161015612998565b63ffffffff80610120860151169160601c1610156129e4565b6001600160401b0383541683526005602052604083208251815560018060a01b036020840151166001600160601b0360a01b60018301541617600182015560408301516005811015610d9c5791610d49600383610c566001600160401b03966001610d8a9701612a30565b60405162461bcd60e51b815260206004820152600d60248201526c24b73b30b634b2103a37b5b2b760991b6044820152606490fd5b60405162461bcd60e51b8152602060048201526015602482015274151bdad95b881d1c985b9cd9995c8819985a5b1959605a1b6044820152606490fd5b611112915060203d602011611118575b61110a81836125d7565b8101906128a6565b38610f32565b503d611100565b6040513d86823e3d90fd5b50346101dc57806003193601126101dc5760806040516113888082526127109081602084015260408301526060820152f35b50346101dc57806003193601126101dc576007546040516001600160a01b039091168152602090f35b50346101dc57602080600319360112610a7b576001600160401b036111a861255e565b1682526009815260408220604051838194908354906111c68261258a565b94858552600192878482169182600014611243575050600114611207575b5050506111f3925003836125d7565b6101c26040519282849384528301906125f8565b869350819291528282205b85831061122b5750506111f393508201013880806111e4565b80548389018501528794508693909201918101611212565b9350945050506111f394915060ff191682840152151560051b8201013880806111e4565b50346101dc5760203660031901126101dc5761128161255e565b6001600160401b038116825260056020526040822090600182015460ff8160a01c166005811015610d9c57600103611331576112bc82612cf9565b156112d057506112cd915490612eb3565b80f35b336001600160a01b03909116036112ec576112cd915490612eb3565b60405162461bcd60e51b815260206004820152601e60248201527f4f6e6c792062757965722063616e20666f7277617264207061796d656e7400006044820152606490fd5b60405162461bcd60e51b81526020600482015260136024820152724465616c206973206e6f74206f6e676f696e6760681b6044820152606490fd5b5061137636612574565b6001600160401b0382168352600660205260408320916003830154926001600160401b0384168552600560205260ff600160408720015460a01c1660058110156119e9576003036119ac57600383101561197657805460018060a01b03600754169160405163afe15cfb60e01b8152826004820152604081602481875afa90811561196b578890899261192d575b508042101580611924575b156118e657604051631c3db16d60e01b815260048101859052602081602481895afa80156117d45788918b916118b1575b50036118385750506113885b600482015494856000198101116118245761146e600019870160048501612ca6565b5091878a5260018301988960205260ff60408c2054166117df576114cf966001600160401b0360209260881c168c526009825260408c209060405180809a819463791f8b7360e11b83528b6004840152604060248401526044830190612b3b565b03915afa9586156117d4578a9661179a575b506127106114f26114f99288612e80565b04866130d1565b95878a528260205261150f60408b205488612c99565b34101561177f5734965b6040518981528860208201523390847fcae597f39a3ad75c2e10d46b031f023c5c2babcd58ca0491b122acda3968d4c06040600019870193a4338b526002840160205260408b20898c5260205260408b206115758982546130d1565b9055888b528360205260408b2061158d8982546130d1565b9055888b528360205260408b205410156116c8575b50506001600482015411611602575b505050509260ff92604092826020963481106115d9575b505284522054166040519015158152f35b81806115e6819334612c99565b8181156115f9575b3390f15082386115c8565b506108fc6115ee565b90600388939261161460048401612cd8565b505001611622858254612c99565b90556001600160401b03600360018060a01b036007541692015460881c16835260096020526040832091813b15610dc4576116809460405180968195829463093225f160e31b84526004840152604060248401526044830190612b3b565b03925af180156116bd57926020959260ff95926040956116aa575b819497508396508295506115b1565b6116b6909491946125c4565b923861169b565b6040513d87823e3d90fd5b60408a20546116dc600385019182546130d1565b90556004830154600160401b81101561176b5760018101806004860155811015611757579088809392600486018d5260208d200155828b528960205260408b20600160ff1982541617905560001901907f39493c1b78d9a13bcc9e1d532fc7faed3889248d93affa811416ce3c6bcb1a688b80a438806115a2565b634e487b7160e01b8b52603260045260248bfd5b634e487b7160e01b8b52604160045260248bfd5b878a528260205261179460408b205488612c99565b96611519565b9095506020813d6020116117cc575b816117b6602093836125d7565b810103126117c85751946127106114e1565b8980fd5b3d91506117a9565b6040513d8c823e3d90fd5b60405162461bcd60e51b815260206004820152601b60248201527f41707065616c2066656520697320616c726561647920706169642e00000000006044820152606490fd5b634e487b7160e01b89526011600452602489fd5b8061184661184c9242612c99565b92612c99565b9061138891828102928184041490151715611824576127108092041161144c5760405162461bcd60e51b815260206004820152601f60248201527f41707065616c20706572696f64206973206f76657220666f72206c6f736572006044820152606490fd5b9150506020813d6020116118de575b816118cd602093836125d7565b810103126117c85787905138611440565b3d91506118c0565b60405162461bcd60e51b815260206004820152601660248201527520b83832b0b6103832b934b7b21034b99037bb32b91760511b6044820152606490fd5b5081421061140f565b9150506040813d604011611963575b81611949604093836125d7565b8101031261195f57602081519101519038611404565b8780fd5b3d915061193c565b6040513d8a823e3d90fd5b60405162461bcd60e51b815260206004820152600e60248201526d496e76616c69642072756c696e6760901b6044820152606490fd5b60405162461bcd60e51b81526020600482015260156024820152742737903234b9b83aba32903a379030b83832b0b61760591b6044820152606490fd5b634e487b7160e01b86526021600452602486fd5b50346101dc57602090816003193601126101dc576001600160401b039182611a2361255e565b1690818352600681526040832093600385019081549080821691828752600585526040872093600185019160ff835460a01c166005811015611c525791899a91611a726002611ad59514612c1d565b8863ffffffff9182611a8e60015460e01c828460401c16612b23565b164210611c36575b60018060a01b039788600754169160881c168d526009825260408d2090604051808098819463f7434ea960e01b83528660048401526024830190612b3b565b03915afa968715611c2b5789948c98611bf2575b5097611b348793600393611b12611b739c611b0c600187549a01998a5490612c99565b90612eb3565b815463ffffffff60601b1916429190911660601b63ffffffff60601b16179055565b01548454925460405163a9059cbb60e01b81529387166001600160a01b03166004850152602484015291968792919091169082908b9082906044820190565b03925af18015611be757879687968796600193611bc9575b50507fee8c537f848ec4aabbc511bb8ca43e4887d376dc18d9725fe693d6fd30f8c05c8680a35416828215611bc0575bf15080f35b506108fc611bbb565b81611bdf92903d106111185761110a81836125d7565b503880611b8b565b6040513d89823e3d90fd5b8581969299503d8311611c24575b611c0a81836125d7565b81010312611c2057925195889390611b34611ae9565b8a80fd5b503d611c00565b6040513d8d823e3d90fd5b611c4d60018060a01b0360028c0154163314612c5f565b611a96565b634e487b7160e01b8a52602160045260248afd5b50346101dc5760803660031901126101dc57602435906001600160a01b03821682036101dc5760206102886064356044358560043561310e565b50346101dc57611caf36612574565b6007546001600160a01b039081163303611f655782845260086020526001600160401b0390816040862054169182865260066020526040862092600384018281541688526005602052604088209060ff600183015460a01c166005811015611c5257600303611f2957805460ff60801b608089901b1664ffffffffff60601b1990911663ffffffff60601b4260601b1617178155600182018054600160a01b60ff60a01b1982161790915589949063ffffffff9060028a1015611e20575094807f394027a5fa6e098a1191094d1719d6929b9abc535fcc0c8f448d6a4e75622276986002898188859a99988699988d60209f9e60018a9c015460c81c169060015460a01c161115611e0b575b505001541691015490828215611e02575bf1507fee8c537f848ec4aabbc511bb8ca43e4887d376dc18d9725fe693d6fd30f8c05c8280a35b6007541692604051908152a380f35b506108fc611dcc565b611e19915416825490612eb3565b3880611dbb565b600385015460018a015460405163a9059cbb60e01b8152928a166001600160a01b0316600484015260248301529297969395949092909150602090839088168186816044810103925af18015611f1e577f394027a5fa6e098a1191094d1719d6929b9abc535fcc0c8f448d6a4e75622276986002886001879695611ebd60209d839c8a998a99611f00575b505416611b0c83548589015490612c99565b01541691015490828215611ef7575bf1507fee8c537f848ec4aabbc511bb8ca43e4887d376dc18d9725fe693d6fd30f8c05c8880a3611df3565b506108fc611ecc565b611f179060203d81116111185761110a81836125d7565b5038611eab565b6040513d85823e3d90fd5b60405162461bcd60e51b81526020600482015260146024820152731119585b081a5cc81b9bdd08111a5cdc1d5d195960621b6044820152606490fd5b60405162461bcd60e51b81526020600482015260156024820152744f6e6c792061726269747261746f722072756c657360581b6044820152606490fd5b50346101dc5760203660031901126101dc576101209060406001600160401b039182611fcc61255e565b168152600660205220805491600182015491600360028201549101549260405194855260208501526040840152808216606084015263ffffffff808360401c1660808501528260601c1660a084015260ff8260801c1660c08401528160881c1660e083015260c81c610100820152f35b5060203660031901126101dc576001600160401b0361205961255e565b168082526006602052604082206003810154916001600160401b03831684526005602052600160408520612099828060a01b036002830154163314612c5f565b0160ff815460a01c1660058110156119e95760026120b79114612c1d565b63ffffffff6120d060015460e01c828760401c16612b23565b164210156122ab57612123936001600160401b0360018060a01b03600754169160881c1680875260096020526020604088206040518098819263f7434ea960e01b83528460048401526024830190612b3b565b0381855afa958615611be757879661226f575b50612180869260209261214b85341015612bd1565b8952600983526040892060405198898094819363c13517e160e01b835260026004840152604060248401526044830190612b3b565b03925af1948515612264578695612229575b5084865260086020526040808720805467ffffffffffffffff1916851790558585556002850191909155815460ff60a01b1916600360a01b179091557f74baab670a4015ab2f1b467c5252a96141a2573f2908e58a92081e80d3cfde3d916121fc60048501612cd8565b50506001600160401b03600360018060a01b036007541695015460881c169082519182526020820152a380f35b91929094506020823d60201161225c575b81612247602093836125d7565b8101031261081c579051939091906040612192565b3d915061223a565b6040513d88823e3d90fd5b909195506020813d6020116122a3575b8161228c602093836125d7565b8101031261229f57519490612180612136565b8680fd5b3d915061227f565b60405162461bcd60e51b8152602060048201526016602482015275546f6f206c61746520666f72206368616c6c656e676560501b6044820152606490fd5b50346101dc5760403660031901126101dc576001600160401b0390600435828111610a7b5761231c903690600401612531565b602493919335828111610dc457612337903690600401612531565b91909261234f60018060a01b0360045416331461281b565b8085546001600160401b0360801b61236b838360801c16612857565b60801b16906001600160401b0360801b19161780875560801c1685526020916009835260408620908281116124f8576123a4825461258a565b601f81116124b5575b5086601f821160011461242b57908061241a949392899a7f61606860eb6c87306811e2695215385101daab53bd6ab4e9f9049aead9363c7d999a92612420575b50508160011b916000199060031b1c19161790555b865460801c1694604051938385948552840191612885565b0390a280f35b0135905038806123ed565b82885284882090601f198316895b81811061249e5750917f61606860eb6c87306811e2695215385101daab53bd6ab4e9f9049aead9363c7d98999a849261241a97969560019510612484575b505050811b019055612402565b0135600019600384901b60f8161c19169055388080612477565b91928760018192868f013581550194019201612439565b828852848820601f830160051c8101918684106124ee575b601f0160051c01905b8181106124e357506123ad565b8881556001016124d6565b90915081906124cd565b634e487b7160e01b87526041600452602487fd5b905034610a7b5781600319360112610a7b576004546001600160a01b03168152602090f35b9181601f840112156106f9578235916001600160401b0383116106f957602083818601950101116106f957565b600435906001600160401b03821682036106f957565b60409060031901126106f9576004359060243590565b90600182811c921680156125ba575b60208310146125a457565b634e487b7160e01b600052602260045260246000fd5b91607f1691612599565b6001600160401b0381116101c657604052565b90601f801991011681019081106001600160401b038211176101c657604052565b919082519283825260005b848110612624575050826000602080949584010152601f8019910116010190565b602081830181015184830182015201612603565b600435906001600160a01b03821682036106f957565b600319810191906101c083126106f9576101a08093126106f9576040516001600160401b03938101848111828210176101c65760405260043581526001600160a01b0360243581811681036106f957602083015260443560058110156106f957604083015263ffffffff9060643582811681036106f957606084015260843582811681036106f957608084015260a43562ffffff811681036106f95760a084015260c43581811681036106f95760c084015260e43582811681036106f95760e08401526101043582811681036106f9576101008401526101243582811681036106f9576101208401526101443590811681036106f9576101408301526101643585811681036106f9576101608301526101843590811681036106f957610180820152926101a4358181116106f957826023820112156106f95780600401359182116101c657604051926127ab601f8401601f1916602001856125d7565b828452602483830101116106f95781600092602460209301838601378301015290565b9060058210156127db5752565b634e487b7160e01b600052602160045260246000fd5b60609060031901126106f957600435906024356001600160a01b03811681036106f9579060443590565b1561282257565b60405162461bcd60e51b815260206004820152600d60248201526c27b7363c9033b7bb32b93737b960991b6044820152606490fd5b6001600160401b0380911690811461286f5760010190565b634e487b7160e01b600052601160045260246000fd5b908060209392818452848401376000828201840152601f01601f1916010190565b908160209103126106f9575180151581036106f95790565b156128c557565b60405162461bcd60e51b815260206004820152601360248201527245787472612066656520746f6f206c6172676560681b6044820152606490fd5b1561290757565b60405162461bcd60e51b815260206004820152601b60248201527f546f6f206c6974746c652074696d6520666f72207365727669636500000000006044820152606490fd5b1561295357565b60405162461bcd60e51b815260206004820152601960248201527f546f6f206c6974746c652074696d6520666f7220636c61696d000000000000006044820152606490fd5b1561299f57565b60405162461bcd60e51b815260206004820152601960248201527f546f6f206d7563682074696d6520666f722073657276696365000000000000006044820152606490fd5b156129eb57565b60405162461bcd60e51b815260206004820152601760248201527f546f6f206d7563682074696d6520666f7220636c61696d0000000000000000006044820152606490fd5b9060058110156127db57815460ff60a01b191660a09190911b60ff60a01b16179055565b612b2092918051825260018060a01b03806020830151166020840152612a82604083015160408501906127ce565b63ffffffff9081606084015116606085015281608084015116608085015262ffffff60a08401511660a08501528060c08401511660c08501528160e08401511660e08501526101008281850151169085015261012082818501511690850152610140908184015116908401526101606001600160401b038184015116908401526101808092015116908201526101c090816101a082015201906125f8565b90565b91909163ffffffff8080941691160191821161286f57565b9060009291805491612b4c8361258a565b918282526001938481169081600014612bae5750600114612b6e575b50505050565b90919394506000526020928360002092846000945b838610612b9a575050505001019038808080612b68565b805485870183015294019385908201612b83565b9294505050602093945060ff191683830152151560051b01019038808080612b68565b15612bd857565b60405162461bcd60e51b815260206004820152601860248201527f4e6f7420656e6f75676820746f20636f766572206665657300000000000000006044820152606490fd5b15612c2457565b60405162461bcd60e51b81526020600482015260136024820152721119585b081a5cc81b9bdd0810db185a5b5959606a1b6044820152606490fd5b15612c6657565b60405162461bcd60e51b815260206004820152600b60248201526a27b7363c9039b2b63632b960a91b6044820152606490fd5b9190820391821161286f57565b8054821015612cc2576000526005602060002091020190600090565b634e487b7160e01b600052603260045260246000fd5b8054600160401b8110156101c657612cf591600182018155612ca6565b9091565b6001600160401b038060009216825260056020526040822090604051906101a0820182811082821117612e6c576040528254825260018301546001600160a01b03808216602085015260a082901c60ff1695916005871015612e585786604086015263ffffffff96878260a81c166060870152878260c81c169182608088015260e81c60a087015260028701549583871660c082015261018060e08201968a8960a01c168852600361010084019a8c8b60c01c168c5261012085019a60e01c8b5201549586166101408401528560a01c16948561016084015260e01c91015260048114612e4b57600103612e41578693929190612e17575050612e10938280612e0793511691511690612b23565b91511690612b23565b1642101590565b612e1095506003939450604092508152600660205220015460601c168260015460c01c1690612b23565b5050935050505090565b5050505050505050600190565b634e487b7160e01b83526021600452602483fd5b634e487b7160e01b85526041600452602485fd5b8181029291811591840414171561286f57565b8115612e9d570490565b634e487b7160e01b600052601260045260246000fd5b6001600160401b03169060009082825260209060058252604080842092600254926001850194855496612710612f168782612f0a8c612f0363ffffffff948580809460a81c169160c01c16612b23565b1688612e80565b049860a01c1685612e80565b0496612f2b88612f268987612c99565b612c99565b60ff60a01b19909916600160a21b1790556003820180546002840154875163a9059cbb60e01b8082526001600160a01b039283166004830152602482018d9052919391928890829086168188816044810103925af180156130aa576130b4575b50805460015489518481529085166001600160a01b03166004820152602481018c9052908890829086168188816044810103925af180156130aa579285858c9461300a9897948c9761308d575b5054169260025416918b519788958694859384526004840160209093929193604081019460018060a01b031681520152565b03925af19081156130825750927fe6b7def5a215a9d43d5b0cd0f8556040c6f28322706a7fe159b143f98b62f9e198969492613051926080999795613065575b5054612c99565b9082519586528501528301526060820152a2565b61307b90853d87116111185761110a81836125d7565b503861304a565b8651903d90823e3d90fd5b6130a390883d8a116111185761110a81836125d7565b5038612fd8565b89513d87823e3d90fd5b6130ca90883d8a116111185761110a81836125d7565b5038612f8b565b9190820180921161286f57565b805415612cc257600052602060002090600090565b805460011015612cc257600052600160206000200190600090565b93929391909160009260006001600160401b0383168152602096600688526040918281209660036131428860048b01612ca6565b5098015463ffffffff8160601c161561333657838352600189018b528483205460ff1661321c5750506001600160a01b03841681526002870189528281208282528952828120549889915b82159586156131a3575b50505050505050505050565b6001600160a01b0316808252600299909901825284812084825282528481208190557f54b3cab3cb5c4aca3209db1151caff092e878011202e43a36782d4ebe0b963ae9581908a9082908690613212575b83928392f1508351928352820152a438808080808087818080613197565b6108fc91506131f4565b60ff9060801c1680835260ff8584205416156000146132ca5750506004870160018154116000146132c3576001600160a01b0385168252600288018a528382208383528a528382205460038901546132bb92916132b59161327c91612e80565b91613286816130de565b90549060031b1c85528a8d5261329f87862054916130f3565b90549060031b1c85528a8d5286852054906130d1565b90612e93565b98899161318d565b50806132bb565b9099919083146132dd575b90899161318d565b8281528782528381205491995090801561332f576001600160a01b0385168252600288018a528382208383528a5283822054600389015461332892916133239190612e80565b612e93565b98906132d5565b5080613328565b845162461bcd60e51b8152600481018c9052601260248201527110db185a5b481b9bdd081c995cdbdb1d995960721b6044820152606490fd5b600019811461286f5760010190565b909291926000936001600160401b036000931692838152600691602083815260039360409463ffffffff81878720015460601c16156135945760ff96959493929196908181878720015460801c169060049283888820015499879b5b8b8d106133f05750505050505050505050505050565b909192939495969798999a9b9d6134118f838c52848a52888d8d2001612ca6565b50898b5260018181018a528c8c20548c918f91881661346c57506001600160a01b0316905260020188528a8a20898b5288528a8a205461345b9161345591906130d1565b9e61336f565b9b9a999897969594939291906133da565b929189915052858d8d2054161560001461351857918a878f8f948f95613455968f988f9961345b9a82019485541160001461350a57613504976132b59660018060a01b0316845260028301825284842090845281526134d2848420548884015490612e80565b966134dc866130de565b905490821b1c84528282526134f485852054966130f3565b9054911b1c8352522054906130d1565b906130d1565b5050945050505050906130d1565b9050909e9089871461352f575b5061345b9061336f565b61345b919f898b8f8f948f61357f9681858e9352838752818120549586151560001461358657613504976133239660018060a01b0316835260028601815283832091835252205491015490612e80565b9e90613525565b5095505050505050906130d1565b5092975050505050505056fea2646970667358221220cb106d65c37d7b93d9cfbac46479afa0716d75aa9e613f7416d1e980037fc2e864736f6c6343000811003361606860eb6c87306811e2695215385101daab53bd6ab4e9f9049aead9363c7d000000000000000000000000a2c51fc0d268cca1ee0ca00dd0d6b616028fb6090000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000003f480000000000000000000000000000000000000000000000000000000000003f480000000000000000000000000a2c51fc0d268cca1ee0ca00dd0d6b616028fb6090000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007d0000000000000000000000000000000000000000000000000000000000001518000000000000000000000000000000000000000000000000000000000000d2f00000000000000000000000000000000000000000000000000000000000001518000000000000000000000000000000000000000000000000000000000000d2f00000000000000000000000000a2c51fc0d268cca1ee0ca00dd0d6b616028fb6090000000000000000000000009c1da9a04925bdfdedf0f6421bc7eea8305f90020000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000026000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000462f697066732f516d59374d7a33556e6f3167584263557a4a6741776368643569384e464333764d725248465558797279556d334c2f6d65746145766964656e63652e6a736f6e0000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x608080604052600436101561001357600080fd5b600090813560e01c9081630c340a241461250c575080630c5179201461082057806310a8c211146122e95780631159739c1461203c57806327adb7d714611fa2578063311a6c5614611ca0578063362c347914611c665780634857346a146119fd5780634b2f0ea01461136c57806354342cc4146112675780636663d20a146111855780636cc6cde11461115c57806379873f8a1461112a5780637a0efe2c14610edb5780638b4d68a214610e9c5780638d8b2d7e14610e7f578063a4a0baf314610e51578063a6a7f0eb14610dd3578063b84b043114610ae1578063bece85f014610a7f578063c073f24f14610853578063c21ae06114610820578063da53a90a14610455578063dbfca4c01461037d578063e06174e4146102d9578063e4c0aaf414610290578063ec85635b1461026e578063f721063314610231578063fe2dddeb146101df5763ffa1ad741461016b57600080fd5b346101dc57806003193601126101dc5760405160408101908082106001600160401b038311176101c6576101c29160405260058152640322e302e360dc1b60208201526040519182916020835260208301906125f8565b0390f35b634e487b7160e01b600052604160045260246000fd5b80fd5b50346101dc576101ee366127f1565b906001600160401b03831684526006602052600460408520015492845b848110610216578580f35b806102268561022c93868661310e565b5061336f565b61020b565b50346101dc57806003193601126101dc5760609054604051906001600160401b03908181168352818160401c16602084015260801c166040820152f35b50346101dc576020610288610282366127f1565b9161337e565b604051908152f35b50346101dc5760203660031901126101dc576102aa612638565b600454906001600160a01b03906102c4338385161461281b565b16906001600160601b0360a01b161760045580f35b50346101dc57806003193601126101dc57610180600154600254906003546040519260018060a01b03808416855263ffffffff93848160a01c166020870152848160c01c16604087015260e01c606086015281166080850152828160a01c1660a0850152828160c01c1660c085015260e01c60e0840152818116610100840152818160201c16610120840152818160401c1661014084015260601c16610160820152f35b50346101dc5760203660031901126101dc576101a09060406001600160401b0391826103a761255e565b1681526005602052208054916001820154600360028401549301549260405194855260018060a01b039182811660208701526103ec6040870160ff8360a01c166127ce565b63ffffffff90818160a81c166060880152818160c81c16608088015260e81c60a087015282821660c0870152808260a01c1660e08701528160c01c1661010086015260e01c61012085015282166101408401528160a01c1661016083015260e01c610180820152f35b5060603660031901126101dc5761046a61255e565b6001600160401b039060248035919060443584811161081c57610491903690600401612531565b92909385821692838852602092600584526040892091600183019182549060018060a01b039182811633036107eb578686541061079c5760a01c60ff16600581101561078957600114908161075e575b8161074d575b50156107105789868c604061052c9460075416918054948560801c168152600984522090604051808096819463f7434ea960e01b835286600484015289830190612b3b565b03915afa8015610705578b928d916106cc575b5061054c90341015612bd1565b60401c168a526006855260408a206003810190856001835492015563ffffffff60401b4260401b1680896001600160601b0319841617178355888d6001600160401b0360881b905460081b169278ffffffffffffffff0000000000ffffffffffffffffffffffff19161717179055600160a11b60ff60a01b19835416179081835563ffffffff809260c81c169182146106ba5750815463ffffffff60c81b1916600190910160c81b63ffffffff60c81b1617905567ffffffffffffffff60401b956106a1959094909390927f4c91dc5dedd6c0cc4b0ea60c714b360687f4d41a8ebd1188ae35cf2d9372c21e92610675908b54600391909101805467ffffffffffffffff60a01b191660409290921c8c1660a01b67ffffffffffffffff60a01b16919091179055565b6106998a54998a60401c169687966040805195869586528501526040840191612885565b0390a3612857565b60401b169067ffffffffffffffff60401b191617815580f35b634e487b7160e01b8b5260116004528afd5b809350888092503d83116106fe575b6106e581836125d7565b810103126106f95761054c8b92519061053f565b600080fd5b503d6106db565b6040513d8e823e3d90fd5b60405162461bcd60e51b815260048101879052601681840152751119585b0818d85b9b9bdd0818994818db185a5b595960521b6044820152606490fd5b6107579150612cf9565b15386104e7565b9050600285015461077f63ffffffff9182808260c01c169160a01c16612b23565b16421015906104e1565b634e487b7160e01b8d526021600452838dfd5b60405162461bcd60e51b8152600481018990526022818601527f526566756e642063616e6e6f742062652067726561746572207468616e206465604482015261185b60f21b6064820152608490fd5b60405162461bcd60e51b815260048101899052600a818601526927b7363c90313abcb2b960b11b6044820152606490fd5b8580fd5b50346101dc5760203660031901126101dc576001600160401b036040602092600435815260088452205416604051908152f35b50346101dc5761018080600319360112610a7b576040519081018181106001600160401b038211176101c65760405261088a612638565b815260243563ffffffff811681036106f957602082015260443563ffffffff811681036106f957604082015260643563ffffffff811681036106f95760608201526084356001600160a01b03811681036106f957608082015260a43563ffffffff811681036106f95760a082015260c43563ffffffff811681036106f95760c082015260e43563ffffffff811681036106f95760e08201526101043563ffffffff811681036106f957610100820152610124359063ffffffff821682036106f95761012081019182526101443563ffffffff811681036106f95761014082015263ffffffff610164351661016435036106f9576101643561016082015261099c60018060a01b0360045416331461281b565b60018060a01b0381511663ffffffff60a01b9081602084015160a01b169163ffffffff60c01b9283604086015160c01b1663ffffffff60e01b9384606088015160e01b169217171760015560018060a01b036080850151169060a085015160a01b169260c085015160c01b169160e085015160e01b169217171760025563ffffffff6101008201511667ffffffff00000000600354935160201b169063ffffffff60401b61014084015160401b169261016063ffffffff60601b91015160601b16936fffffffffffffffffffffffffffffffff19161717171760035580f35b5080fd5b50346101dc5760403660031901126101dc57610a99612638565b60243590811515809203610add576004546001600160a01b039190610ac1908316331461281b565b168252600a602052604082209060ff8019835416911617905580f35b8280fd5b50610aeb3661264e565b73e91d153e0b41518a2ce8dd3d7944fa863463a97d803b15610dc457604051630d0e30db60e41b81528490818160048134875af18015610dc857610db0575b505034835261014083015263ffffffff421660e0830152604082016001815283608084015283610160840152610b7163ffffffff60608501511660025460e01c10156128be565b610bee63ffffffff61010085015116610b956003549163ffffffff83161115612900565b610bb563ffffffff6101208701511663ffffffff8360401c16111561294c565b610bd563ffffffff6101008701511663ffffffff8360201c161015612998565b63ffffffff80610120870151169160601c1610156129e4565b6001600160401b038454168452600560205260408420908351825560018060a01b036020850151166001600160601b0360a01b600184015416176001830155516005811015610d9c5791610d49600383610c566001600160401b03966001610d8a9701612a30565b606087015160018201805460808a015160a0808c015160c89290921b63ffffffff60c81b1660a89590951b63ffffffff60a81b166001600160a81b03909316929092179390931760e89390931b6001600160e81b03191692909217905560c08089015160e0808b01516101008c01516101208d0151941b63ffffffff60c01b166001600160a01b03909316941b63ffffffff60a01b1693909317176001600160e01b03199190921b1617600282015561014087015161016088015161018089015160e01b6001600160e01b0319166001600160a01b0390921690881660a01b67ffffffffffffffff60a01b161717910155565b8454937f537c5c2e4e27a7bf3012bc5a481136d771a6cc8a7d879cca12eab9135e071dce848616928392610d8260405192839283612a54565b0390a2612857565b16906001600160401b03191617815580f35b634e487b7160e01b85526021600452602485fd5b610db9906125c4565b610dc4578338610b2a565b8380fd5b6040513d84823e3d90fd5b50346101dc5760403660031901126101dc576024356001600160401b038111610a7b57610e04903690600401612531565b60018060a01b03600754167fdccf2f8b2cc26eafcd61905cba744cff4b81d14740725f6376390dc6298a6a3c6040516020815280610e4b3396600435966020840191612885565b0390a480f35b50346101dc5760203660031901126101dc576020610e75610e7061255e565b612cf9565b6040519015158152f35b50346101dc5760203660031901126101dc57602060405160028152f35b50346101dc5760203660031901126101dc5760209060ff906040906001600160a01b03610ec7612638565b168152600a84522054166040519015158152f35b50346101dc57610eea3661264e565b82602060018060a01b03610140850151166064855160405194859384926323b872dd60e01b845233600485015230602485015260448401525af190811561111f5784916110f0575b50156110b35763ffffffff421660e08301526001604083015282608083015282610160830152610f7363ffffffff60608401511660025460e01c10156128be565b6101408201516001600160a01b03168352600a602052604083205460ff161561107e5761101363ffffffff61010084015116610fba6003549163ffffffff83161115612900565b610fda63ffffffff6101208601511663ffffffff8360401c16111561294c565b610ffa63ffffffff6101008601511663ffffffff8360201c161015612998565b63ffffffff80610120860151169160601c1610156129e4565b6001600160401b0383541683526005602052604083208251815560018060a01b036020840151166001600160601b0360a01b60018301541617600182015560408301516005811015610d9c5791610d49600383610c566001600160401b03966001610d8a9701612a30565b60405162461bcd60e51b815260206004820152600d60248201526c24b73b30b634b2103a37b5b2b760991b6044820152606490fd5b60405162461bcd60e51b8152602060048201526015602482015274151bdad95b881d1c985b9cd9995c8819985a5b1959605a1b6044820152606490fd5b611112915060203d602011611118575b61110a81836125d7565b8101906128a6565b38610f32565b503d611100565b6040513d86823e3d90fd5b50346101dc57806003193601126101dc5760806040516113888082526127109081602084015260408301526060820152f35b50346101dc57806003193601126101dc576007546040516001600160a01b039091168152602090f35b50346101dc57602080600319360112610a7b576001600160401b036111a861255e565b1682526009815260408220604051838194908354906111c68261258a565b94858552600192878482169182600014611243575050600114611207575b5050506111f3925003836125d7565b6101c26040519282849384528301906125f8565b869350819291528282205b85831061122b5750506111f393508201013880806111e4565b80548389018501528794508693909201918101611212565b9350945050506111f394915060ff191682840152151560051b8201013880806111e4565b50346101dc5760203660031901126101dc5761128161255e565b6001600160401b038116825260056020526040822090600182015460ff8160a01c166005811015610d9c57600103611331576112bc82612cf9565b156112d057506112cd915490612eb3565b80f35b336001600160a01b03909116036112ec576112cd915490612eb3565b60405162461bcd60e51b815260206004820152601e60248201527f4f6e6c792062757965722063616e20666f7277617264207061796d656e7400006044820152606490fd5b60405162461bcd60e51b81526020600482015260136024820152724465616c206973206e6f74206f6e676f696e6760681b6044820152606490fd5b5061137636612574565b6001600160401b0382168352600660205260408320916003830154926001600160401b0384168552600560205260ff600160408720015460a01c1660058110156119e9576003036119ac57600383101561197657805460018060a01b03600754169160405163afe15cfb60e01b8152826004820152604081602481875afa90811561196b578890899261192d575b508042101580611924575b156118e657604051631c3db16d60e01b815260048101859052602081602481895afa80156117d45788918b916118b1575b50036118385750506113885b600482015494856000198101116118245761146e600019870160048501612ca6565b5091878a5260018301988960205260ff60408c2054166117df576114cf966001600160401b0360209260881c168c526009825260408c209060405180809a819463791f8b7360e11b83528b6004840152604060248401526044830190612b3b565b03915afa9586156117d4578a9661179a575b506127106114f26114f99288612e80565b04866130d1565b95878a528260205261150f60408b205488612c99565b34101561177f5734965b6040518981528860208201523390847fcae597f39a3ad75c2e10d46b031f023c5c2babcd58ca0491b122acda3968d4c06040600019870193a4338b526002840160205260408b20898c5260205260408b206115758982546130d1565b9055888b528360205260408b2061158d8982546130d1565b9055888b528360205260408b205410156116c8575b50506001600482015411611602575b505050509260ff92604092826020963481106115d9575b505284522054166040519015158152f35b81806115e6819334612c99565b8181156115f9575b3390f15082386115c8565b506108fc6115ee565b90600388939261161460048401612cd8565b505001611622858254612c99565b90556001600160401b03600360018060a01b036007541692015460881c16835260096020526040832091813b15610dc4576116809460405180968195829463093225f160e31b84526004840152604060248401526044830190612b3b565b03925af180156116bd57926020959260ff95926040956116aa575b819497508396508295506115b1565b6116b6909491946125c4565b923861169b565b6040513d87823e3d90fd5b60408a20546116dc600385019182546130d1565b90556004830154600160401b81101561176b5760018101806004860155811015611757579088809392600486018d5260208d200155828b528960205260408b20600160ff1982541617905560001901907f39493c1b78d9a13bcc9e1d532fc7faed3889248d93affa811416ce3c6bcb1a688b80a438806115a2565b634e487b7160e01b8b52603260045260248bfd5b634e487b7160e01b8b52604160045260248bfd5b878a528260205261179460408b205488612c99565b96611519565b9095506020813d6020116117cc575b816117b6602093836125d7565b810103126117c85751946127106114e1565b8980fd5b3d91506117a9565b6040513d8c823e3d90fd5b60405162461bcd60e51b815260206004820152601b60248201527f41707065616c2066656520697320616c726561647920706169642e00000000006044820152606490fd5b634e487b7160e01b89526011600452602489fd5b8061184661184c9242612c99565b92612c99565b9061138891828102928184041490151715611824576127108092041161144c5760405162461bcd60e51b815260206004820152601f60248201527f41707065616c20706572696f64206973206f76657220666f72206c6f736572006044820152606490fd5b9150506020813d6020116118de575b816118cd602093836125d7565b810103126117c85787905138611440565b3d91506118c0565b60405162461bcd60e51b815260206004820152601660248201527520b83832b0b6103832b934b7b21034b99037bb32b91760511b6044820152606490fd5b5081421061140f565b9150506040813d604011611963575b81611949604093836125d7565b8101031261195f57602081519101519038611404565b8780fd5b3d915061193c565b6040513d8a823e3d90fd5b60405162461bcd60e51b815260206004820152600e60248201526d496e76616c69642072756c696e6760901b6044820152606490fd5b60405162461bcd60e51b81526020600482015260156024820152742737903234b9b83aba32903a379030b83832b0b61760591b6044820152606490fd5b634e487b7160e01b86526021600452602486fd5b50346101dc57602090816003193601126101dc576001600160401b039182611a2361255e565b1690818352600681526040832093600385019081549080821691828752600585526040872093600185019160ff835460a01c166005811015611c525791899a91611a726002611ad59514612c1d565b8863ffffffff9182611a8e60015460e01c828460401c16612b23565b164210611c36575b60018060a01b039788600754169160881c168d526009825260408d2090604051808098819463f7434ea960e01b83528660048401526024830190612b3b565b03915afa968715611c2b5789948c98611bf2575b5097611b348793600393611b12611b739c611b0c600187549a01998a5490612c99565b90612eb3565b815463ffffffff60601b1916429190911660601b63ffffffff60601b16179055565b01548454925460405163a9059cbb60e01b81529387166001600160a01b03166004850152602484015291968792919091169082908b9082906044820190565b03925af18015611be757879687968796600193611bc9575b50507fee8c537f848ec4aabbc511bb8ca43e4887d376dc18d9725fe693d6fd30f8c05c8680a35416828215611bc0575bf15080f35b506108fc611bbb565b81611bdf92903d106111185761110a81836125d7565b503880611b8b565b6040513d89823e3d90fd5b8581969299503d8311611c24575b611c0a81836125d7565b81010312611c2057925195889390611b34611ae9565b8a80fd5b503d611c00565b6040513d8d823e3d90fd5b611c4d60018060a01b0360028c0154163314612c5f565b611a96565b634e487b7160e01b8a52602160045260248afd5b50346101dc5760803660031901126101dc57602435906001600160a01b03821682036101dc5760206102886064356044358560043561310e565b50346101dc57611caf36612574565b6007546001600160a01b039081163303611f655782845260086020526001600160401b0390816040862054169182865260066020526040862092600384018281541688526005602052604088209060ff600183015460a01c166005811015611c5257600303611f2957805460ff60801b608089901b1664ffffffffff60601b1990911663ffffffff60601b4260601b1617178155600182018054600160a01b60ff60a01b1982161790915589949063ffffffff9060028a1015611e20575094807f394027a5fa6e098a1191094d1719d6929b9abc535fcc0c8f448d6a4e75622276986002898188859a99988699988d60209f9e60018a9c015460c81c169060015460a01c161115611e0b575b505001541691015490828215611e02575bf1507fee8c537f848ec4aabbc511bb8ca43e4887d376dc18d9725fe693d6fd30f8c05c8280a35b6007541692604051908152a380f35b506108fc611dcc565b611e19915416825490612eb3565b3880611dbb565b600385015460018a015460405163a9059cbb60e01b8152928a166001600160a01b0316600484015260248301529297969395949092909150602090839088168186816044810103925af18015611f1e577f394027a5fa6e098a1191094d1719d6929b9abc535fcc0c8f448d6a4e75622276986002886001879695611ebd60209d839c8a998a99611f00575b505416611b0c83548589015490612c99565b01541691015490828215611ef7575bf1507fee8c537f848ec4aabbc511bb8ca43e4887d376dc18d9725fe693d6fd30f8c05c8880a3611df3565b506108fc611ecc565b611f179060203d81116111185761110a81836125d7565b5038611eab565b6040513d85823e3d90fd5b60405162461bcd60e51b81526020600482015260146024820152731119585b081a5cc81b9bdd08111a5cdc1d5d195960621b6044820152606490fd5b60405162461bcd60e51b81526020600482015260156024820152744f6e6c792061726269747261746f722072756c657360581b6044820152606490fd5b50346101dc5760203660031901126101dc576101209060406001600160401b039182611fcc61255e565b168152600660205220805491600182015491600360028201549101549260405194855260208501526040840152808216606084015263ffffffff808360401c1660808501528260601c1660a084015260ff8260801c1660c08401528160881c1660e083015260c81c610100820152f35b5060203660031901126101dc576001600160401b0361205961255e565b168082526006602052604082206003810154916001600160401b03831684526005602052600160408520612099828060a01b036002830154163314612c5f565b0160ff815460a01c1660058110156119e95760026120b79114612c1d565b63ffffffff6120d060015460e01c828760401c16612b23565b164210156122ab57612123936001600160401b0360018060a01b03600754169160881c1680875260096020526020604088206040518098819263f7434ea960e01b83528460048401526024830190612b3b565b0381855afa958615611be757879661226f575b50612180869260209261214b85341015612bd1565b8952600983526040892060405198898094819363c13517e160e01b835260026004840152604060248401526044830190612b3b565b03925af1948515612264578695612229575b5084865260086020526040808720805467ffffffffffffffff1916851790558585556002850191909155815460ff60a01b1916600360a01b179091557f74baab670a4015ab2f1b467c5252a96141a2573f2908e58a92081e80d3cfde3d916121fc60048501612cd8565b50506001600160401b03600360018060a01b036007541695015460881c169082519182526020820152a380f35b91929094506020823d60201161225c575b81612247602093836125d7565b8101031261081c579051939091906040612192565b3d915061223a565b6040513d88823e3d90fd5b909195506020813d6020116122a3575b8161228c602093836125d7565b8101031261229f57519490612180612136565b8680fd5b3d915061227f565b60405162461bcd60e51b8152602060048201526016602482015275546f6f206c61746520666f72206368616c6c656e676560501b6044820152606490fd5b50346101dc5760403660031901126101dc576001600160401b0390600435828111610a7b5761231c903690600401612531565b602493919335828111610dc457612337903690600401612531565b91909261234f60018060a01b0360045416331461281b565b8085546001600160401b0360801b61236b838360801c16612857565b60801b16906001600160401b0360801b19161780875560801c1685526020916009835260408620908281116124f8576123a4825461258a565b601f81116124b5575b5086601f821160011461242b57908061241a949392899a7f61606860eb6c87306811e2695215385101daab53bd6ab4e9f9049aead9363c7d999a92612420575b50508160011b916000199060031b1c19161790555b865460801c1694604051938385948552840191612885565b0390a280f35b0135905038806123ed565b82885284882090601f198316895b81811061249e5750917f61606860eb6c87306811e2695215385101daab53bd6ab4e9f9049aead9363c7d98999a849261241a97969560019510612484575b505050811b019055612402565b0135600019600384901b60f8161c19169055388080612477565b91928760018192868f013581550194019201612439565b828852848820601f830160051c8101918684106124ee575b601f0160051c01905b8181106124e357506123ad565b8881556001016124d6565b90915081906124cd565b634e487b7160e01b87526041600452602487fd5b905034610a7b5781600319360112610a7b576004546001600160a01b03168152602090f35b9181601f840112156106f9578235916001600160401b0383116106f957602083818601950101116106f957565b600435906001600160401b03821682036106f957565b60409060031901126106f9576004359060243590565b90600182811c921680156125ba575b60208310146125a457565b634e487b7160e01b600052602260045260246000fd5b91607f1691612599565b6001600160401b0381116101c657604052565b90601f801991011681019081106001600160401b038211176101c657604052565b919082519283825260005b848110612624575050826000602080949584010152601f8019910116010190565b602081830181015184830182015201612603565b600435906001600160a01b03821682036106f957565b600319810191906101c083126106f9576101a08093126106f9576040516001600160401b03938101848111828210176101c65760405260043581526001600160a01b0360243581811681036106f957602083015260443560058110156106f957604083015263ffffffff9060643582811681036106f957606084015260843582811681036106f957608084015260a43562ffffff811681036106f95760a084015260c43581811681036106f95760c084015260e43582811681036106f95760e08401526101043582811681036106f9576101008401526101243582811681036106f9576101208401526101443590811681036106f9576101408301526101643585811681036106f9576101608301526101843590811681036106f957610180820152926101a4358181116106f957826023820112156106f95780600401359182116101c657604051926127ab601f8401601f1916602001856125d7565b828452602483830101116106f95781600092602460209301838601378301015290565b9060058210156127db5752565b634e487b7160e01b600052602160045260246000fd5b60609060031901126106f957600435906024356001600160a01b03811681036106f9579060443590565b1561282257565b60405162461bcd60e51b815260206004820152600d60248201526c27b7363c9033b7bb32b93737b960991b6044820152606490fd5b6001600160401b0380911690811461286f5760010190565b634e487b7160e01b600052601160045260246000fd5b908060209392818452848401376000828201840152601f01601f1916010190565b908160209103126106f9575180151581036106f95790565b156128c557565b60405162461bcd60e51b815260206004820152601360248201527245787472612066656520746f6f206c6172676560681b6044820152606490fd5b1561290757565b60405162461bcd60e51b815260206004820152601b60248201527f546f6f206c6974746c652074696d6520666f72207365727669636500000000006044820152606490fd5b1561295357565b60405162461bcd60e51b815260206004820152601960248201527f546f6f206c6974746c652074696d6520666f7220636c61696d000000000000006044820152606490fd5b1561299f57565b60405162461bcd60e51b815260206004820152601960248201527f546f6f206d7563682074696d6520666f722073657276696365000000000000006044820152606490fd5b156129eb57565b60405162461bcd60e51b815260206004820152601760248201527f546f6f206d7563682074696d6520666f7220636c61696d0000000000000000006044820152606490fd5b9060058110156127db57815460ff60a01b191660a09190911b60ff60a01b16179055565b612b2092918051825260018060a01b03806020830151166020840152612a82604083015160408501906127ce565b63ffffffff9081606084015116606085015281608084015116608085015262ffffff60a08401511660a08501528060c08401511660c08501528160e08401511660e08501526101008281850151169085015261012082818501511690850152610140908184015116908401526101606001600160401b038184015116908401526101808092015116908201526101c090816101a082015201906125f8565b90565b91909163ffffffff8080941691160191821161286f57565b9060009291805491612b4c8361258a565b918282526001938481169081600014612bae5750600114612b6e575b50505050565b90919394506000526020928360002092846000945b838610612b9a575050505001019038808080612b68565b805485870183015294019385908201612b83565b9294505050602093945060ff191683830152151560051b01019038808080612b68565b15612bd857565b60405162461bcd60e51b815260206004820152601860248201527f4e6f7420656e6f75676820746f20636f766572206665657300000000000000006044820152606490fd5b15612c2457565b60405162461bcd60e51b81526020600482015260136024820152721119585b081a5cc81b9bdd0810db185a5b5959606a1b6044820152606490fd5b15612c6657565b60405162461bcd60e51b815260206004820152600b60248201526a27b7363c9039b2b63632b960a91b6044820152606490fd5b9190820391821161286f57565b8054821015612cc2576000526005602060002091020190600090565b634e487b7160e01b600052603260045260246000fd5b8054600160401b8110156101c657612cf591600182018155612ca6565b9091565b6001600160401b038060009216825260056020526040822090604051906101a0820182811082821117612e6c576040528254825260018301546001600160a01b03808216602085015260a082901c60ff1695916005871015612e585786604086015263ffffffff96878260a81c166060870152878260c81c169182608088015260e81c60a087015260028701549583871660c082015261018060e08201968a8960a01c168852600361010084019a8c8b60c01c168c5261012085019a60e01c8b5201549586166101408401528560a01c16948561016084015260e01c91015260048114612e4b57600103612e41578693929190612e17575050612e10938280612e0793511691511690612b23565b91511690612b23565b1642101590565b612e1095506003939450604092508152600660205220015460601c168260015460c01c1690612b23565b5050935050505090565b5050505050505050600190565b634e487b7160e01b83526021600452602483fd5b634e487b7160e01b85526041600452602485fd5b8181029291811591840414171561286f57565b8115612e9d570490565b634e487b7160e01b600052601260045260246000fd5b6001600160401b03169060009082825260209060058252604080842092600254926001850194855496612710612f168782612f0a8c612f0363ffffffff948580809460a81c169160c01c16612b23565b1688612e80565b049860a01c1685612e80565b0496612f2b88612f268987612c99565b612c99565b60ff60a01b19909916600160a21b1790556003820180546002840154875163a9059cbb60e01b8082526001600160a01b039283166004830152602482018d9052919391928890829086168188816044810103925af180156130aa576130b4575b50805460015489518481529085166001600160a01b03166004820152602481018c9052908890829086168188816044810103925af180156130aa579285858c9461300a9897948c9761308d575b5054169260025416918b519788958694859384526004840160209093929193604081019460018060a01b031681520152565b03925af19081156130825750927fe6b7def5a215a9d43d5b0cd0f8556040c6f28322706a7fe159b143f98b62f9e198969492613051926080999795613065575b5054612c99565b9082519586528501528301526060820152a2565b61307b90853d87116111185761110a81836125d7565b503861304a565b8651903d90823e3d90fd5b6130a390883d8a116111185761110a81836125d7565b5038612fd8565b89513d87823e3d90fd5b6130ca90883d8a116111185761110a81836125d7565b5038612f8b565b9190820180921161286f57565b805415612cc257600052602060002090600090565b805460011015612cc257600052600160206000200190600090565b93929391909160009260006001600160401b0383168152602096600688526040918281209660036131428860048b01612ca6565b5098015463ffffffff8160601c161561333657838352600189018b528483205460ff1661321c5750506001600160a01b03841681526002870189528281208282528952828120549889915b82159586156131a3575b50505050505050505050565b6001600160a01b0316808252600299909901825284812084825282528481208190557f54b3cab3cb5c4aca3209db1151caff092e878011202e43a36782d4ebe0b963ae9581908a9082908690613212575b83928392f1508351928352820152a438808080808087818080613197565b6108fc91506131f4565b60ff9060801c1680835260ff8584205416156000146132ca5750506004870160018154116000146132c3576001600160a01b0385168252600288018a528382208383528a528382205460038901546132bb92916132b59161327c91612e80565b91613286816130de565b90549060031b1c85528a8d5261329f87862054916130f3565b90549060031b1c85528a8d5286852054906130d1565b90612e93565b98899161318d565b50806132bb565b9099919083146132dd575b90899161318d565b8281528782528381205491995090801561332f576001600160a01b0385168252600288018a528382208383528a5283822054600389015461332892916133239190612e80565b612e93565b98906132d5565b5080613328565b845162461bcd60e51b8152600481018c9052601260248201527110db185a5b481b9bdd081c995cdbdb1d995960721b6044820152606490fd5b600019811461286f5760010190565b909291926000936001600160401b036000931692838152600691602083815260039360409463ffffffff81878720015460601c16156135945760ff96959493929196908181878720015460801c169060049283888820015499879b5b8b8d106133f05750505050505050505050505050565b909192939495969798999a9b9d6134118f838c52848a52888d8d2001612ca6565b50898b5260018181018a528c8c20548c918f91881661346c57506001600160a01b0316905260020188528a8a20898b5288528a8a205461345b9161345591906130d1565b9e61336f565b9b9a999897969594939291906133da565b929189915052858d8d2054161560001461351857918a878f8f948f95613455968f988f9961345b9a82019485541160001461350a57613504976132b59660018060a01b0316845260028301825284842090845281526134d2848420548884015490612e80565b966134dc866130de565b905490821b1c84528282526134f485852054966130f3565b9054911b1c8352522054906130d1565b906130d1565b5050945050505050906130d1565b9050909e9089871461352f575b5061345b9061336f565b61345b919f898b8f8f948f61357f9681858e9352838752818120549586151560001461358657613504976133239660018060a01b0316835260028601815283832091835252205491015490612e80565b9e90613525565b5095505050505050906130d1565b5092975050505050505056fea2646970667358221220cb106d65c37d7b93d9cfbac46479afa0716d75aa9e613f7416d1e980037fc2e864736f6c63430008110033
Loading...
Loading
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.