This nametag was submitted by Kleros Curate.
Latest 25 from a total of 11,527 transactions
| Transaction Hash |
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Swap No Split | 426502605 | 2 days ago | IN | 0 ETH | 0.00000842 | ||||
| Swap No Split | 425175385 | 6 days ago | IN | 0 ETH | 0.00001114 | ||||
| Swap No Split | 425076136 | 6 days ago | IN | 0 ETH | 0.00000957 | ||||
| Swap No Split | 424490391 | 8 days ago | IN | 0 ETH | 0.00000501 | ||||
| Swap No Split | 419693956 | 22 days ago | IN | 0 ETH | 0.00000957 | ||||
| Swap No Split | 418390991 | 26 days ago | IN | 0 ETH | 0.0000023 | ||||
| Swap No Split | 417088651 | 29 days ago | IN | 0 ETH | 0.0000052 | ||||
| Swap No Split | 414901765 | 36 days ago | IN | 0 ETH | 0.0000031 | ||||
| Swap No Split Fr... | 413228173 | 40 days ago | IN | 0.00022 ETH | 0.00000153 | ||||
| Swap No Split | 412591829 | 42 days ago | IN | 0 ETH | 0.00000371 | ||||
| Swap No Split Fr... | 411524313 | 45 days ago | IN | 0.00004 ETH | 0.00000153 | ||||
| Swap No Split Fr... | 411506589 | 45 days ago | IN | 0.00019 ETH | 0.00000153 | ||||
| Swap No Split Fr... | 410818487 | 47 days ago | IN | 0.00018 ETH | 0.00000153 | ||||
| Swap No Split Fr... | 410423535 | 49 days ago | IN | 0.00018 ETH | 0.00000153 | ||||
| Swap No Split Fr... | 410171005 | 49 days ago | IN | 0.000185 ETH | 0.00000162 | ||||
| Swap No Split Fr... | 410170099 | 49 days ago | IN | 0.00018 ETH | 0.00000176 | ||||
| Swap No Split | 409603215 | 51 days ago | IN | 0 ETH | 0.0000053 | ||||
| Swap No Split | 409602794 | 51 days ago | IN | 0 ETH | 0.0000059 | ||||
| Swap No Split | 409602245 | 51 days ago | IN | 0 ETH | 0.00001457 | ||||
| Swap No Split | 409601751 | 51 days ago | IN | 0 ETH | 0.00001291 | ||||
| Swap No Split | 409601187 | 51 days ago | IN | 0 ETH | 0.00003238 | ||||
| Swap No Split | 409600347 | 51 days ago | IN | 0 ETH | 0.0000159 | ||||
| Swap No Split | 409599803 | 51 days ago | IN | 0 ETH | 0.00002367 | ||||
| Swap No Split | 409594294 | 51 days ago | IN | 0 ETH | 0.00000636 | ||||
| Swap No Split | 409592506 | 51 days ago | IN | 0 ETH | 0.00000655 |
Latest 25 internal transactions (View All)
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 413228173 | 40 days ago | 0.00022 ETH | ||||
| 411524313 | 45 days ago | 0.00004 ETH | ||||
| 411506589 | 45 days ago | 0.00019 ETH | ||||
| 410818487 | 47 days ago | 0.00018 ETH | ||||
| 410423535 | 49 days ago | 0.00018 ETH | ||||
| 410171005 | 49 days ago | 0.000185 ETH | ||||
| 410170099 | 49 days ago | 0.00018 ETH | ||||
| 409380874 | 52 days ago | 0.0002 ETH | ||||
| 408666602 | 54 days ago | 0.00003 ETH | ||||
| 408500530 | 54 days ago | 0.000171 ETH | ||||
| 407041002 | 58 days ago | 0.00013 ETH | ||||
| 406591103 | 60 days ago | 0.00014 ETH | ||||
| 406385334 | 60 days ago | 0.00354 ETH | ||||
| 406246122 | 61 days ago | 0.0002 ETH | ||||
| 405590410 | 63 days ago | 0.0002 ETH | ||||
| 405523526 | 63 days ago | 0.00019 ETH | ||||
| 405217684 | 64 days ago | 0.00019 ETH | ||||
| 405217129 | 64 days ago | 0.0002 ETH | ||||
| 405215052 | 64 days ago | 0.0002 ETH | ||||
| 404953972 | 64 days ago | 0.000185 ETH | ||||
| 404849450 | 65 days ago | 0.00019 ETH | ||||
| 404176795 | 67 days ago | 0.000185 ETH | ||||
| 403793730 | 68 days ago | 0.00014 ETH | ||||
| 402101423 | 73 days ago | 0.00024 ETH | ||||
| 402086654 | 73 days ago | 0.00023 ETH |
Cross-Chain Transactions
Loading...
Loading
This contract contains unverified libraries: BytesManipulation
This contract may be a proxy contract. Click on More Options and select Is this a proxy? to confirm and enable the "Read as Proxy" & "Write as Proxy" tabs.
Contract Name:
YakRouter
Compiler Version
v0.8.0+commit.c7dfd78e
Optimization Enabled:
Yes with 999 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// ╟╗ ╔╬
// ╞╬╬ ╬╠╬
// ╔╣╬╬╬ ╠╠╠╠╦
// ╬╬╬╬╬╩ ╘╠╠╠╠╬
// ║╬╬╬╬╬ ╘╠╠╠╠╬
// ╣╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬ ╒╬╬╬╬╬╬╬╜ ╠╠╬╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬ ╬╬╬╬╬╬╬╬╠╠╠╠╠╠╠╠
// ╙╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╕ ╬╬╬╬╬╬╬╜ ╣╠╠╬╬╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬ ╬╬╬╬╬╬╬╬╬╠╠╠╠╠╠╠╩
// ╙╣╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬ ╔╬╬╬╬╬╬╬ ╔╠╠╠╬╬╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬ ╣╬╬╬╬╬╬╬╬╬╬╬╠╠╠╠╝╙
// ╘╣╬╬╬╬╬╬╬╬╬╬╬╬╬╬ ╒╠╠╠╬╠╬╩╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬╣╬╬╬╬╬╬╬╙
// ╣╬╬╬╬╬╬╬╬╬╬╠╣ ╣╬╠╠╠╬╩ ╚╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬╬╬╬╬╬╬╬
// ╣╬╬╬╬╬╬╬╬╬╣ ╣╬╠╠╠╬╬ ╣╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬╬╬╬╬╬╬╬
// ╟╬╬╬╬╬╬╬╩ ╬╬╠╠╠╠╬╬╬╬╬╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬╠╬╬╬╬╬╬╬
// ╬╬╬╬╬╬╬ ╒╬╬╠╠╬╠╠╬╬╬╬╬╬╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬ ╣╬╬╬╬╬╬╬
// ╬╬╬╬╬╬╬ ╬╬╬╠╠╠╠╝╝╝╝╝╝╝╠╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬ ╚╬╬╬╬╬╬╬╬
// ╬╬╬╬╬╬╬ ╣╬╬╬╬╠╠╩ ╘╬╬╬╬╬╬╬ ╠╬╬╬╬╬╬╬ ╙╬╬╬╬╬╬╬╬
//
// SPDX-License-Identifier: GPL-3.0-only
pragma solidity ^0.8.0;
pragma experimental ABIEncoderV2;
import "./lib/BytesManipulation.sol";
import "./interface/IAdapter.sol";
import "./interface/IERC20.sol";
import "./interface/IWETH.sol";
import "./lib/SafeERC20.sol";
import "./lib/Maintainable.sol";
contract YakRouter is Maintainable {
using SafeERC20 for IERC20;
address public immutable WNATIVE;
address public constant NATIVE = address(0);
string public constant NAME = "YakRouter";
uint256 public constant FEE_DENOMINATOR = 1e4;
uint256 public MIN_FEE = 0;
address public FEE_CLAIMER;
address[] public TRUSTED_TOKENS;
address[] public ADAPTERS;
event Recovered(address indexed _asset, uint256 amount);
event UpdatedTrustedTokens(address[] _newTrustedTokens);
event UpdatedAdapters(address[] _newAdapters);
event UpdatedMinFee(uint256 _oldMinFee, uint256 _newMinFee);
event UpdatedFeeClaimer(address _oldFeeClaimer, address _newFeeClaimer);
event YakSwap(address indexed _tokenIn, address indexed _tokenOut, uint256 _amountIn, uint256 _amountOut);
struct Query {
address adapter;
address tokenIn;
address tokenOut;
uint256 amountOut;
}
struct Offer {
bytes amounts;
bytes adapters;
bytes path;
uint256 gasEstimate;
}
struct FormattedOffer {
uint256[] amounts;
address[] adapters;
address[] path;
uint256 gasEstimate;
}
struct Trade {
uint256 amountIn;
uint256 amountOut;
address[] path;
address[] adapters;
}
constructor(
address[] memory _adapters,
address[] memory _trustedTokens,
address _feeClaimer,
address _wrapped_native
) {
setAllowanceForWrapping(_wrapped_native);
setTrustedTokens(_trustedTokens);
setFeeClaimer(_feeClaimer);
setAdapters(_adapters);
WNATIVE = _wrapped_native;
}
// -- SETTERS --
function setAllowanceForWrapping(address _wnative) public onlyMaintainer {
IERC20(_wnative).safeApprove(_wnative, type(uint256).max);
}
function setTrustedTokens(address[] memory _trustedTokens) public onlyMaintainer {
emit UpdatedTrustedTokens(_trustedTokens);
TRUSTED_TOKENS = _trustedTokens;
}
function setAdapters(address[] memory _adapters) public onlyMaintainer {
emit UpdatedAdapters(_adapters);
ADAPTERS = _adapters;
}
function setMinFee(uint256 _fee) external onlyMaintainer {
emit UpdatedMinFee(MIN_FEE, _fee);
MIN_FEE = _fee;
}
function setFeeClaimer(address _claimer) public onlyMaintainer {
emit UpdatedFeeClaimer(FEE_CLAIMER, _claimer);
FEE_CLAIMER = _claimer;
}
// -- GENERAL --
function trustedTokensCount() external view returns (uint256) {
return TRUSTED_TOKENS.length;
}
function adaptersCount() external view returns (uint256) {
return ADAPTERS.length;
}
function recoverERC20(address _tokenAddress, uint256 _tokenAmount) external onlyMaintainer {
require(_tokenAmount > 0, "YakRouter: Nothing to recover");
IERC20(_tokenAddress).safeTransfer(msg.sender, _tokenAmount);
emit Recovered(_tokenAddress, _tokenAmount);
}
function recoverAVAX(uint256 _amount) external onlyMaintainer {
require(_amount > 0, "YakRouter: Nothing to recover");
payable(msg.sender).transfer(_amount);
emit Recovered(address(0), _amount);
}
// Fallback
receive() external payable {}
// -- HELPERS --
function _applyFee(uint256 _amountIn, uint256 _fee) internal view returns (uint256) {
require(_fee >= MIN_FEE, "YakRouter: Insufficient fee");
return (_amountIn * (FEE_DENOMINATOR - _fee)) / FEE_DENOMINATOR;
}
function _wrap(uint256 _amount) internal {
IWETH(WNATIVE).deposit{ value: _amount }();
}
function _unwrap(uint256 _amount) internal {
IWETH(WNATIVE).withdraw(_amount);
}
/**
* @notice Return tokens to user
* @dev Pass address(0) for AVAX
* @param _token address
* @param _amount tokens to return
* @param _to address where funds should be sent to
*/
function _returnTokensTo(
address _token,
uint256 _amount,
address _to
) internal {
if (address(this) != _to) {
if (_token == NATIVE) {
payable(_to).transfer(_amount);
} else {
IERC20(_token).safeTransfer(_to, _amount);
}
}
}
function _transferFrom(address token, address _from, address _to, uint _amount) internal {
if (_from != address(this))
IERC20(token).safeTransferFrom(_from, _to, _amount);
else
IERC20(token).safeTransfer(_to, _amount);
}
/**
* Makes a deep copy of Offer struct
*/
function _cloneOffer(Offer memory _queries) internal pure returns (Offer memory) {
return Offer(_queries.amounts, _queries.adapters, _queries.path, _queries.gasEstimate);
}
/**
* Appends Query elements to Offer struct
*/
function _addQuery(
Offer memory _queries,
uint256 _amount,
address _adapter,
address _tokenOut,
uint256 _gasEstimate
) internal pure {
_queries.path = BytesManipulation.mergeBytes(_queries.path, BytesManipulation.toBytes(_tokenOut));
_queries.amounts = BytesManipulation.mergeBytes(_queries.amounts, BytesManipulation.toBytes(_amount));
_queries.adapters = BytesManipulation.mergeBytes(_queries.adapters, BytesManipulation.toBytes(_adapter));
_queries.gasEstimate += _gasEstimate;
}
/**
* Converts byte-arrays to an array of integers
*/
function _formatAmounts(bytes memory _amounts) internal pure returns (uint256[] memory) {
// Format amounts
uint256 chunks = _amounts.length / 32;
uint256[] memory amountsFormatted = new uint256[](chunks);
for (uint256 i = 0; i < chunks; i++) {
amountsFormatted[i] = BytesManipulation.bytesToUint256(i * 32 + 32, _amounts);
}
return amountsFormatted;
}
/**
* Converts byte-array to an array of addresses
*/
function _formatAddresses(bytes memory _addresses) internal pure returns (address[] memory) {
uint256 chunks = _addresses.length / 32;
address[] memory addressesFormatted = new address[](chunks);
for (uint256 i = 0; i < chunks; i++) {
addressesFormatted[i] = BytesManipulation.bytesToAddress(i * 32 + 32, _addresses);
}
return addressesFormatted;
}
/**
* Formats elements in the Offer object from byte-arrays to integers and addresses
*/
function _formatOffer(Offer memory _queries) internal pure returns (FormattedOffer memory) {
return
FormattedOffer(
_formatAmounts(_queries.amounts),
_formatAddresses(_queries.adapters),
_formatAddresses(_queries.path),
_queries.gasEstimate
);
}
// -- QUERIES --
/**
* Query single adapter
*/
function queryAdapter(
uint256 _amountIn,
address _tokenIn,
address _tokenOut,
uint8 _index
) external view returns (uint256) {
IAdapter _adapter = IAdapter(ADAPTERS[_index]);
uint256 amountOut = _adapter.query(_amountIn, _tokenIn, _tokenOut);
return amountOut;
}
/**
* Query specified adapters
*/
function queryNoSplit(
uint256 _amountIn,
address _tokenIn,
address _tokenOut,
uint8[] calldata _options
) public view returns (Query memory) {
Query memory bestQuery;
for (uint8 i; i < _options.length; i++) {
address _adapter = ADAPTERS[_options[i]];
uint256 amountOut = IAdapter(_adapter).query(_amountIn, _tokenIn, _tokenOut);
if (i == 0 || amountOut > bestQuery.amountOut) {
bestQuery = Query(_adapter, _tokenIn, _tokenOut, amountOut);
}
}
return bestQuery;
}
/**
* Query all adapters
*/
function queryNoSplit(
uint256 _amountIn,
address _tokenIn,
address _tokenOut
) public view returns (Query memory) {
Query memory bestQuery;
for (uint8 i; i < ADAPTERS.length; i++) {
address _adapter = ADAPTERS[i];
uint256 amountOut = IAdapter(_adapter).query(_amountIn, _tokenIn, _tokenOut);
if (i == 0 || amountOut > bestQuery.amountOut) {
bestQuery = Query(_adapter, _tokenIn, _tokenOut, amountOut);
}
}
return bestQuery;
}
/**
* Return path with best returns between two tokens
* Takes gas-cost into account
*/
function findBestPathWithGas(
uint256 _amountIn,
address _tokenIn,
address _tokenOut,
uint256 _maxSteps,
uint256 _gasPrice
) external view returns (FormattedOffer memory) {
require(_maxSteps > 0 && _maxSteps < 5, "YakRouter: Invalid max-steps");
Offer memory queries;
queries.amounts = BytesManipulation.toBytes(_amountIn);
queries.path = BytesManipulation.toBytes(_tokenIn);
uint256 gasPriceInExitTkn = _gasPrice > 0 ? getGasPriceInExitTkn(_gasPrice, _tokenOut) : 0;
queries = _findBestPath(_amountIn, _tokenIn, _tokenOut, _maxSteps, queries, gasPriceInExitTkn);
if (queries.adapters.length == 0) {
queries.amounts = "";
queries.path = "";
}
return _formatOffer(queries);
}
// Find the market price between gas-asset(native) and token-out and express gas price in token-out
function getGasPriceInExitTkn(uint256 _gasPrice, address _tokenOut) internal view returns (uint256 price) {
// Avoid low-liquidity price appreciation (https://github.com/yieldyak/yak-aggregator/issues/20)
FormattedOffer memory gasQuery = findBestPath(1e18, WNATIVE, _tokenOut, 2);
if (gasQuery.path.length != 0) {
// Leave result in nWei to preserve precision for assets with low decimal places
price = (gasQuery.amounts[gasQuery.amounts.length - 1] * _gasPrice) / 1e9;
}
}
/**
* Return path with best returns between two tokens
*/
function findBestPath(
uint256 _amountIn,
address _tokenIn,
address _tokenOut,
uint256 _maxSteps
) public view returns (FormattedOffer memory) {
require(_maxSteps > 0 && _maxSteps < 5, "YakRouter: Invalid max-steps");
Offer memory queries;
queries.amounts = BytesManipulation.toBytes(_amountIn);
queries.path = BytesManipulation.toBytes(_tokenIn);
queries = _findBestPath(_amountIn, _tokenIn, _tokenOut, _maxSteps, queries, 0);
// If no paths are found return empty struct
if (queries.adapters.length == 0) {
queries.amounts = "";
queries.path = "";
}
return _formatOffer(queries);
}
function _findBestPath(
uint256 _amountIn,
address _tokenIn,
address _tokenOut,
uint256 _maxSteps,
Offer memory _queries,
uint256 _tknOutPriceNwei
) internal view returns (Offer memory) {
Offer memory bestOption = _cloneOffer(_queries);
uint256 bestAmountOut;
uint256 gasEstimate;
bool withGas = _tknOutPriceNwei != 0;
// First check if there is a path directly from tokenIn to tokenOut
Query memory queryDirect = queryNoSplit(_amountIn, _tokenIn, _tokenOut);
if (queryDirect.amountOut != 0) {
if (withGas) {
gasEstimate = IAdapter(queryDirect.adapter).swapGasEstimate();
}
_addQuery(bestOption, queryDirect.amountOut, queryDirect.adapter, queryDirect.tokenOut, gasEstimate);
bestAmountOut = queryDirect.amountOut;
}
// Only check the rest if they would go beyond step limit (Need at least 2 more steps)
if (_maxSteps > 1 && _queries.adapters.length / 32 <= _maxSteps - 2) {
// Check for paths that pass through trusted tokens
for (uint256 i = 0; i < TRUSTED_TOKENS.length; i++) {
if (_tokenIn == TRUSTED_TOKENS[i]) {
continue;
}
// Loop through all adapters to find the best one for swapping tokenIn for one of the trusted tokens
Query memory bestSwap = queryNoSplit(_amountIn, _tokenIn, TRUSTED_TOKENS[i]);
if (bestSwap.amountOut == 0) {
continue;
}
// Explore options that connect the current path to the tokenOut
Offer memory newOffer = _cloneOffer(_queries);
if (withGas) {
gasEstimate = IAdapter(bestSwap.adapter).swapGasEstimate();
}
_addQuery(newOffer, bestSwap.amountOut, bestSwap.adapter, bestSwap.tokenOut, gasEstimate);
newOffer = _findBestPath(
bestSwap.amountOut,
TRUSTED_TOKENS[i],
_tokenOut,
_maxSteps,
newOffer,
_tknOutPriceNwei
); // Recursive step
address tokenOut = BytesManipulation.bytesToAddress(newOffer.path.length, newOffer.path);
uint256 amountOut = BytesManipulation.bytesToUint256(newOffer.amounts.length, newOffer.amounts);
// Check that the last token in the path is the tokenOut and update the new best option if neccesary
if (_tokenOut == tokenOut && amountOut > bestAmountOut) {
if (newOffer.gasEstimate > bestOption.gasEstimate) {
uint256 gasCostDiff = (_tknOutPriceNwei * (newOffer.gasEstimate - bestOption.gasEstimate)) /
1e9;
uint256 priceDiff = amountOut - bestAmountOut;
if (gasCostDiff > priceDiff) {
continue;
}
}
bestAmountOut = amountOut;
bestOption = newOffer;
}
}
}
return bestOption;
}
// -- SWAPPERS --
function _swapNoSplit(
Trade calldata _trade,
address _from,
address _to,
uint256 _fee
) internal returns (uint256) {
uint256[] memory amounts = new uint256[](_trade.path.length);
if (_fee > 0 || MIN_FEE > 0) {
// Transfer fees to the claimer account and decrease initial amount
amounts[0] = _applyFee(_trade.amountIn, _fee);
_transferFrom(_trade.path[0], _from, FEE_CLAIMER, _trade.amountIn - amounts[0]);
} else {
amounts[0] = _trade.amountIn;
}
_transferFrom(_trade.path[0], _from, _trade.adapters[0], amounts[0]);
// Get amounts that will be swapped
for (uint256 i = 0; i < _trade.adapters.length; i++) {
amounts[i + 1] = IAdapter(_trade.adapters[i]).query(amounts[i], _trade.path[i], _trade.path[i + 1]);
}
require(amounts[amounts.length - 1] >= _trade.amountOut, "YakRouter: Insufficient output amount");
for (uint256 i = 0; i < _trade.adapters.length; i++) {
// All adapters should transfer output token to the following target
// All targets are the adapters, expect for the last swap where tokens are sent out
address targetAddress = i < _trade.adapters.length - 1 ? _trade.adapters[i + 1] : _to;
IAdapter(_trade.adapters[i]).swap(
amounts[i],
amounts[i + 1],
_trade.path[i],
_trade.path[i + 1],
targetAddress
);
}
emit YakSwap(_trade.path[0], _trade.path[_trade.path.length - 1], _trade.amountIn, amounts[amounts.length - 1]);
return amounts[amounts.length - 1];
}
function swapNoSplit(
Trade calldata _trade,
address _to,
uint256 _fee
) public {
_swapNoSplit(_trade, msg.sender, _to, _fee);
}
function swapNoSplitFromAVAX(
Trade calldata _trade,
address _to,
uint256 _fee
) external payable {
require(_trade.path[0] == WNATIVE, "YakRouter: Path needs to begin with WAVAX");
_wrap(_trade.amountIn);
_swapNoSplit(_trade, address(this), _to, _fee);
}
function swapNoSplitToAVAX(
Trade calldata _trade,
address _to,
uint256 _fee
) public {
require(_trade.path[_trade.path.length - 1] == WNATIVE, "YakRouter: Path needs to end with WAVAX");
uint256 returnAmount = _swapNoSplit(_trade, msg.sender, address(this), _fee);
_unwrap(returnAmount);
_returnTokensTo(NATIVE, returnAmount, _to);
}
/**
* Swap token to token without the need to approve the first token
*/
function swapNoSplitWithPermit(
Trade calldata _trade,
address _to,
uint256 _fee,
uint256 _deadline,
uint8 _v,
bytes32 _r,
bytes32 _s
) external {
IERC20(_trade.path[0]).permit(msg.sender, address(this), _trade.amountIn, _deadline, _v, _r, _s);
swapNoSplit(_trade, _to, _fee);
}
/**
* Swap token to AVAX without the need to approve the first token
*/
function swapNoSplitToAVAXWithPermit(
Trade calldata _trade,
address _to,
uint256 _fee,
uint256 _deadline,
uint8 _v,
bytes32 _r,
bytes32 _s
) external {
IERC20(_trade.path[0]).permit(msg.sender, address(this), _trade.amountIn, _deadline, _v, _r, _s);
swapNoSplitToAVAX(_trade, _to, _fee);
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/AccessControl.sol)
pragma solidity ^0.8.0;
import "./IAccessControl.sol";
import "../utils/Context.sol";
import "../utils/Strings.sol";
import "../utils/introspection/ERC165.sol";
/**
* @dev Contract module that allows children to implement role-based access
* control mechanisms. This is a lightweight version that doesn't allow enumerating role
* members except through off-chain means by accessing the contract event logs. Some
* applications may benefit from on-chain enumerability, for those cases see
* {AccessControlEnumerable}.
*
* Roles are referred to by their `bytes32` identifier. These should be exposed
* in the external API and be unique. The best way to achieve this is by
* using `public constant` hash digests:
*
* ```
* bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
* ```
*
* Roles can be used to represent a set of permissions. To restrict access to a
* function call, use {hasRole}:
*
* ```
* function foo() public {
* require(hasRole(MY_ROLE, msg.sender));
* ...
* }
* ```
*
* Roles can be granted and revoked dynamically via the {grantRole} and
* {revokeRole} functions. Each role has an associated admin role, and only
* accounts that have a role's admin role can call {grantRole} and {revokeRole}.
*
* By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
* that only accounts with this role will be able to grant or revoke other
* roles. More complex role relationships can be created by using
* {_setRoleAdmin}.
*
* WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
* grant and revoke this role. Extra precautions should be taken to secure
* accounts that have been granted it.
*/
abstract contract AccessControl is Context, IAccessControl, ERC165 {
struct RoleData {
mapping(address => bool) members;
bytes32 adminRole;
}
mapping(bytes32 => RoleData) private _roles;
bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;
/**
* @dev Modifier that checks that an account has a specific role. Reverts
* with a standardized message including the required role.
*
* The format of the revert reason is given by the following regular expression:
*
* /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
*
* _Available since v4.1._
*/
modifier onlyRole(bytes32 role) {
_checkRole(role);
_;
}
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);
}
/**
* @dev Returns `true` if `account` has been granted `role`.
*/
function hasRole(bytes32 role, address account) public view virtual override returns (bool) {
return _roles[role].members[account];
}
/**
* @dev Revert with a standard message if `_msgSender()` is missing `role`.
* Overriding this function changes the behavior of the {onlyRole} modifier.
*
* Format of the revert message is described in {_checkRole}.
*
* _Available since v4.6._
*/
function _checkRole(bytes32 role) internal view virtual {
_checkRole(role, _msgSender());
}
/**
* @dev Revert with a standard message if `account` is missing `role`.
*
* The format of the revert reason is given by the following regular expression:
*
* /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
*/
function _checkRole(bytes32 role, address account) internal view virtual {
if (!hasRole(role, account)) {
revert(
string(
abi.encodePacked(
"AccessControl: account ",
Strings.toHexString(uint160(account), 20),
" is missing role ",
Strings.toHexString(uint256(role), 32)
)
)
);
}
}
/**
* @dev Returns the admin role that controls `role`. See {grantRole} and
* {revokeRole}.
*
* To change a role's admin, use {_setRoleAdmin}.
*/
function getRoleAdmin(bytes32 role) public view virtual override returns (bytes32) {
return _roles[role].adminRole;
}
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*
* May emit a {RoleGranted} event.
*/
function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
_grantRole(role, account);
}
/**
* @dev Revokes `role` from `account`.
*
* If `account` had been granted `role`, emits a {RoleRevoked} event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*
* May emit a {RoleRevoked} event.
*/
function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
_revokeRole(role, account);
}
/**
* @dev Revokes `role` from the calling account.
*
* Roles are often managed via {grantRole} and {revokeRole}: this function's
* purpose is to provide a mechanism for accounts to lose their privileges
* if they are compromised (such as when a trusted device is misplaced).
*
* If the calling account had been revoked `role`, emits a {RoleRevoked}
* event.
*
* Requirements:
*
* - the caller must be `account`.
*
* May emit a {RoleRevoked} event.
*/
function renounceRole(bytes32 role, address account) public virtual override {
require(account == _msgSender(), "AccessControl: can only renounce roles for self");
_revokeRole(role, account);
}
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event. Note that unlike {grantRole}, this function doesn't perform any
* checks on the calling account.
*
* May emit a {RoleGranted} event.
*
* [WARNING]
* ====
* This function should only be called from the constructor when setting
* up the initial roles for the system.
*
* Using this function in any other way is effectively circumventing the admin
* system imposed by {AccessControl}.
* ====
*
* NOTE: This function is deprecated in favor of {_grantRole}.
*/
function _setupRole(bytes32 role, address account) internal virtual {
_grantRole(role, account);
}
/**
* @dev Sets `adminRole` as ``role``'s admin role.
*
* Emits a {RoleAdminChanged} event.
*/
function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
bytes32 previousAdminRole = getRoleAdmin(role);
_roles[role].adminRole = adminRole;
emit RoleAdminChanged(role, previousAdminRole, adminRole);
}
/**
* @dev Grants `role` to `account`.
*
* Internal function without access restriction.
*
* May emit a {RoleGranted} event.
*/
function _grantRole(bytes32 role, address account) internal virtual {
if (!hasRole(role, account)) {
_roles[role].members[account] = true;
emit RoleGranted(role, account, _msgSender());
}
}
/**
* @dev Revokes `role` from `account`.
*
* Internal function without access restriction.
*
* May emit a {RoleRevoked} event.
*/
function _revokeRole(bytes32 role, address account) internal virtual {
if (hasRole(role, account)) {
_roles[role].members[account] = false;
emit RoleRevoked(role, account, _msgSender());
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol)
pragma solidity ^0.8.0;
/**
* @dev External interface of AccessControl declared to support ERC165 detection.
*/
interface IAccessControl {
/**
* @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
*
* `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
* {RoleAdminChanged} not being emitted signaling this.
*
* _Available since v3.1._
*/
event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);
/**
* @dev Emitted when `account` is granted `role`.
*
* `sender` is the account that originated the contract call, an admin role
* bearer except when using {AccessControl-_setupRole}.
*/
event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);
/**
* @dev Emitted when `account` is revoked `role`.
*
* `sender` is the account that originated the contract call:
* - if using `revokeRole`, it is the admin role bearer
* - if using `renounceRole`, it is the role bearer (i.e. `account`)
*/
event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);
/**
* @dev Returns `true` if `account` has been granted `role`.
*/
function hasRole(bytes32 role, address account) external view returns (bool);
/**
* @dev Returns the admin role that controls `role`. See {grantRole} and
* {revokeRole}.
*
* To change a role's admin, use {AccessControl-_setRoleAdmin}.
*/
function getRoleAdmin(bytes32 role) external view returns (bytes32);
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*/
function grantRole(bytes32 role, address account) external;
/**
* @dev Revokes `role` from `account`.
*
* If `account` had been granted `role`, emits a {RoleRevoked} event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*/
function revokeRole(bytes32 role, address account) external;
/**
* @dev Revokes `role` from the calling account.
*
* Roles are often managed via {grantRole} and {revokeRole}: this function's
* purpose is to provide a mechanism for accounts to lose their privileges
* if they are compromised (such as when a trusted device is misplaced).
*
* If the calling account had been granted `role`, emits a {RoleRevoked}
* event.
*
* Requirements:
*
* - the caller must be `account`.
*/
function renounceRole(bytes32 role, address account) external;
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)
pragma solidity ^0.8.0;
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)
pragma solidity ^0.8.0;
import "./IERC165.sol";
/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
* for the additional interface id that will be supported. For example:
*
* ```solidity
* function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
* return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
* }
* ```
*
* Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
*/
abstract contract ERC165 is IERC165 {
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IERC165).interfaceId;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol)
pragma solidity ^0.8.0;
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";
uint8 private constant _ADDRESS_LENGTH = 20;
/**
* @dev Converts a `uint256` to its ASCII `string` decimal representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
// Inspired by OraclizeAPI's implementation - MIT licence
// https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol
if (value == 0) {
return "0";
}
uint256 temp = value;
uint256 digits;
while (temp != 0) {
digits++;
temp /= 10;
}
bytes memory buffer = new bytes(digits);
while (value != 0) {
digits -= 1;
buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
value /= 10;
}
return string(buffer);
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
*/
function toHexString(uint256 value) internal pure returns (string memory) {
if (value == 0) {
return "0x00";
}
uint256 temp = value;
uint256 length = 0;
while (temp != 0) {
length++;
temp >>= 8;
}
return toHexString(value, length);
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
*/
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
bytes memory buffer = new bytes(2 * length + 2);
buffer[0] = "0";
buffer[1] = "x";
for (uint256 i = 2 * length + 1; i > 1; --i) {
buffer[i] = _HEX_SYMBOLS[value & 0xf];
value >>= 4;
}
require(value == 0, "Strings: hex length insufficient");
return string(buffer);
}
/**
* @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
*/
function toHexString(address addr) internal pure returns (string memory) {
return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
}
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
interface IAdapter {
function name() external view returns (string memory);
function swapGasEstimate() external view returns (uint256);
function swap(
uint256,
uint256,
address,
address,
address
) external;
function query(
uint256,
address,
address
) external view returns (uint256);
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
interface IERC20 {
event Approval(address, address, uint256);
event Transfer(address, address, uint256);
function name() external view returns (string memory);
function decimals() external view returns (uint8);
function transferFrom(
address,
address,
uint256
) external returns (bool);
function allowance(address, address) external view returns (uint256);
function approve(address, uint256) external returns (bool);
function transfer(address, uint256) external returns (bool);
function balanceOf(address) external view returns (uint256);
function nonces(address) external view returns (uint256); // Only tokens that support permit
function permit(
address,
address,
uint256,
uint256,
uint8,
bytes32,
bytes32
) external; // Only tokens that support permit
function swap(address, uint256) external; // Only Avalanche bridge tokens
function swapSupply(address) external view returns (uint256); // Only Avalanche bridge tokens
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "./IERC20.sol";
interface IWETH is IERC20 {
function withdraw(uint256 amount) external;
function deposit() external payable;
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "./BytesToTypes.sol";
library BytesManipulation {
function toBytes(uint256 x) internal pure returns (bytes memory b) {
b = new bytes(32);
assembly {
mstore(add(b, 32), x)
}
}
function toBytes(address x) internal pure returns (bytes memory b) {
b = new bytes(32);
assembly {
mstore(add(b, 32), x)
}
}
function mergeBytes(bytes memory a, bytes memory b) public pure returns (bytes memory c) {
// From https://ethereum.stackexchange.com/a/40456
uint256 alen = a.length;
uint256 totallen = alen + b.length;
uint256 loopsa = (a.length + 31) / 32;
uint256 loopsb = (b.length + 31) / 32;
assembly {
let m := mload(0x40)
mstore(m, totallen)
for {
let i := 0
} lt(i, loopsa) {
i := add(1, i)
} {
mstore(add(m, mul(32, add(1, i))), mload(add(a, mul(32, add(1, i)))))
}
for {
let i := 0
} lt(i, loopsb) {
i := add(1, i)
} {
mstore(add(m, add(mul(32, add(1, i)), alen)), mload(add(b, mul(32, add(1, i)))))
}
mstore(0x40, add(m, add(32, totallen)))
c := m
}
}
function bytesToAddress(uint256 _offst, bytes memory _input) internal pure returns (address) {
return BytesToTypes.bytesToAddress(_offst, _input);
}
function bytesToUint256(uint256 _offst, bytes memory _input) internal pure returns (uint256) {
return BytesToTypes.bytesToUint256(_offst, _input);
}
}// From https://github.com/pouladzade/Seriality/blob/master/src/BytesToTypes.sol (Licensed under Apache2.0)
// SPDX-License-Identifier: Apache2.0
pragma solidity ^0.8.0;
library BytesToTypes {
function bytesToAddress(uint256 _offst, bytes memory _input) internal pure returns (address _output) {
assembly {
_output := mload(add(_input, _offst))
}
}
function bytesToUint256(uint256 _offst, bytes memory _input) internal pure returns (uint256 _output) {
assembly {
_output := mload(add(_input, _offst))
}
}
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "@openzeppelin/contracts/access/AccessControl.sol";
/**
* @dev Contract module which extends the basic access control mechanism of Ownable
* to include many maintainers, whom only the owner (DEFAULT_ADMIN_ROLE) may add and
* remove.
*
* By default, the owner account will be the one that deploys the contract. This can
* later be changed with {transferOwnership}.
*
* This module is used through inheritance. It will make available this modifier:
* `onlyMaintainer`, which can be applied to your functions to restrict their use to
* the accounts with the role of maintainer.
*/
abstract contract Maintainable is Context, AccessControl {
bytes32 public constant MAINTAINER_ROLE = keccak256("MAINTAINER_ROLE");
constructor() {
address msgSender = _msgSender();
// members of the DEFAULT_ADMIN_ROLE alone may revoke and grant role membership
_setupRole(DEFAULT_ADMIN_ROLE, msgSender);
_setupRole(MAINTAINER_ROLE, msgSender);
}
function addMaintainer(address addedMaintainer) public virtual {
grantRole(MAINTAINER_ROLE, addedMaintainer);
}
function removeMaintainer(address removedMaintainer) public virtual {
revokeRole(MAINTAINER_ROLE, removedMaintainer);
}
function renounceRole(bytes32 role) public virtual {
address msgSender = _msgSender();
renounceRole(role, msgSender);
}
function transferOwnership(address newOwner) public virtual {
address msgSender = _msgSender();
grantRole(DEFAULT_ADMIN_ROLE, newOwner);
renounceRole(DEFAULT_ADMIN_ROLE, msgSender);
}
modifier onlyMaintainer() {
address msgSender = _msgSender();
require(hasRole(MAINTAINER_ROLE, msgSender), "Maintainable: Caller is not a maintainer");
_;
}
}// This is a simplified version of OpenZepplin's SafeERC20 library
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
pragma experimental ABIEncoderV2;
import "../interface/IERC20.sol";
/**
* @title SafeERC20
* @dev Wrappers around ERC20 operations that throw on failure (when the token
* contract returns false). Tokens that return no value (and instead revert or
* throw on failure) are also supported, non-reverting calls are assumed to be
* successful.
* To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract,
* which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
*/
library SafeERC20 {
function safeTransfer(
IERC20 token,
address to,
uint256 value
) internal {
_callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
}
function safeTransferFrom(
IERC20 token,
address from,
address to,
uint256 value
) internal {
_callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
}
function safeApprove(
IERC20 token,
address spender,
uint256 value
) internal {
// safeApprove should only be called when setting an initial allowance,
// or when resetting it to zero. To increase and decrease it, use
// 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
// solhint-disable-next-line max-line-length
require(
(value == 0) || (token.allowance(address(this), spender) == 0),
"SafeERC20: approve from non-zero to non-zero allowance"
);
_callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
}
/**
* @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
* on the return value: the return value is optional (but if data is returned, it must not be false).
* @param token The token targeted by the call.
* @param data The call data (encoded using abi.encode or one of its variants).
*/
function _callOptionalReturn(IERC20 token, bytes memory data) private {
// We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
// we're implementing it ourselves.
// A Solidity high level call has three parts:
// 1. The target address is checked to verify it contains contract code
// 2. The call itself is made, and success asserted
// 3. The return value is decoded, which in turn checks the size of the returned data.
// solhint-disable-next-line max-line-length
// solhint-disable-next-line avoid-low-level-calls
(bool success, bytes memory returndata) = address(token).call(data);
require(success, "SafeERC20: low-level call failed");
if (returndata.length > 0) {
// Return data is optional
// solhint-disable-next-line max-line-length
require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
}
}
}{
"optimizer": {
"enabled": true,
"runs": 999
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"metadata": {
"useLiteralContent": true
},
"libraries": {
"src/contracts/lib/BytesManipulation.sol": {
"BytesManipulation": "0xa479b3af0476a9e605133975c1f0c414d0654d12"
}
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address[]","name":"_adapters","type":"address[]"},{"internalType":"address[]","name":"_trustedTokens","type":"address[]"},{"internalType":"address","name":"_feeClaimer","type":"address"},{"internalType":"address","name":"_wrapped_native","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_asset","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Recovered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"_newAdapters","type":"address[]"}],"name":"UpdatedAdapters","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_oldFeeClaimer","type":"address"},{"indexed":false,"internalType":"address","name":"_newFeeClaimer","type":"address"}],"name":"UpdatedFeeClaimer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_oldMinFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_newMinFee","type":"uint256"}],"name":"UpdatedMinFee","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"_newTrustedTokens","type":"address[]"}],"name":"UpdatedTrustedTokens","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_tokenIn","type":"address"},{"indexed":true,"internalType":"address","name":"_tokenOut","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amountIn","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_amountOut","type":"uint256"}],"name":"YakSwap","type":"event"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"ADAPTERS","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FEE_CLAIMER","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FEE_DENOMINATOR","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAINTAINER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_FEE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NAME","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"TRUSTED_TOKENS","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WNATIVE","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"adaptersCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addedMaintainer","type":"address"}],"name":"addMaintainer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"address","name":"_tokenIn","type":"address"},{"internalType":"address","name":"_tokenOut","type":"address"},{"internalType":"uint256","name":"_maxSteps","type":"uint256"}],"name":"findBestPath","outputs":[{"components":[{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"address[]","name":"adapters","type":"address[]"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"uint256","name":"gasEstimate","type":"uint256"}],"internalType":"struct YakRouter.FormattedOffer","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"address","name":"_tokenIn","type":"address"},{"internalType":"address","name":"_tokenOut","type":"address"},{"internalType":"uint256","name":"_maxSteps","type":"uint256"},{"internalType":"uint256","name":"_gasPrice","type":"uint256"}],"name":"findBestPathWithGas","outputs":[{"components":[{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"address[]","name":"adapters","type":"address[]"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"uint256","name":"gasEstimate","type":"uint256"}],"internalType":"struct YakRouter.FormattedOffer","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"address","name":"_tokenIn","type":"address"},{"internalType":"address","name":"_tokenOut","type":"address"},{"internalType":"uint8","name":"_index","type":"uint8"}],"name":"queryAdapter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"address","name":"_tokenIn","type":"address"},{"internalType":"address","name":"_tokenOut","type":"address"},{"internalType":"uint8[]","name":"_options","type":"uint8[]"}],"name":"queryNoSplit","outputs":[{"components":[{"internalType":"address","name":"adapter","type":"address"},{"internalType":"address","name":"tokenIn","type":"address"},{"internalType":"address","name":"tokenOut","type":"address"},{"internalType":"uint256","name":"amountOut","type":"uint256"}],"internalType":"struct YakRouter.Query","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amountIn","type":"uint256"},{"internalType":"address","name":"_tokenIn","type":"address"},{"internalType":"address","name":"_tokenOut","type":"address"}],"name":"queryNoSplit","outputs":[{"components":[{"internalType":"address","name":"adapter","type":"address"},{"internalType":"address","name":"tokenIn","type":"address"},{"internalType":"address","name":"tokenOut","type":"address"},{"internalType":"uint256","name":"amountOut","type":"uint256"}],"internalType":"struct YakRouter.Query","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"recoverAVAX","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenAddress","type":"address"},{"internalType":"uint256","name":"_tokenAmount","type":"uint256"}],"name":"recoverERC20","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"removedMaintainer","type":"address"}],"name":"removeMaintainer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_adapters","type":"address[]"}],"name":"setAdapters","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_wnative","type":"address"}],"name":"setAllowanceForWrapping","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_claimer","type":"address"}],"name":"setFeeClaimer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"setMinFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_trustedTokens","type":"address[]"}],"name":"setTrustedTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"amountOut","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address[]","name":"adapters","type":"address[]"}],"internalType":"struct YakRouter.Trade","name":"_trade","type":"tuple"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"swapNoSplit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"amountOut","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address[]","name":"adapters","type":"address[]"}],"internalType":"struct YakRouter.Trade","name":"_trade","type":"tuple"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"swapNoSplitFromAVAX","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"amountOut","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address[]","name":"adapters","type":"address[]"}],"internalType":"struct YakRouter.Trade","name":"_trade","type":"tuple"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"swapNoSplitToAVAX","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"amountOut","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address[]","name":"adapters","type":"address[]"}],"internalType":"struct YakRouter.Trade","name":"_trade","type":"tuple"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_fee","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"uint8","name":"_v","type":"uint8"},{"internalType":"bytes32","name":"_r","type":"bytes32"},{"internalType":"bytes32","name":"_s","type":"bytes32"}],"name":"swapNoSplitToAVAXWithPermit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"amountOut","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address[]","name":"adapters","type":"address[]"}],"internalType":"struct YakRouter.Trade","name":"_trade","type":"tuple"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_fee","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"uint8","name":"_v","type":"uint8"},{"internalType":"bytes32","name":"_r","type":"bytes32"},{"internalType":"bytes32","name":"_s","type":"bytes32"}],"name":"swapNoSplitWithPermit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"trustedTokensCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]Contract Creation Code
60a060405260006001553480156200001657600080fd5b5060405162004780380380620047808339810160408190526200003991620006f4565b600062000045620000b6565b905062000054600082620000ba565b6200006f6000805160206200476083398151915282620000ba565b506200007b81620000ca565b620000868362000142565b6200009182620001dd565b6200009c8462000291565b60601b6001600160601b03191660805250620009ba915050565b3390565b620000c6828262000327565b5050565b6000620000d6620000b6565b9050620000f36000805160206200476083398151915282620003b1565b6200011b5760405162461bcd60e51b8152600401620001129062000880565b60405180910390fd5b620000c682600019846001600160a01b0316620003da60201b620016a0179092919060201c565b60006200014e620000b6565b90506200016b6000805160206200476083398151915282620003b1565b6200018a5760405162461bcd60e51b8152600401620001129062000880565b7f658ff1688002926d8f426cb10c052ec29003f50042df9652d8613484c1a5864782604051620001bb919062000831565b60405180910390a18151620001d8906003906020850190620005ac565b505050565b6000620001e9620000b6565b9050620002066000805160206200476083398151915282620003b1565b620002255760405162461bcd60e51b8152600401620001129062000880565b6002546040517fb2c853ac4d80d18d058c43d8018d077a036e542a79acae1647f5ad2a8c76f4e29162000266916001600160a01b03909116908590620007fe565b60405180910390a150600280546001600160a01b0319166001600160a01b0392909216919091179055565b60006200029d620000b6565b9050620002ba6000805160206200476083398151915282620003b1565b620002d95760405162461bcd60e51b8152600401620001129062000880565b7febf7325f48e05e5e38809c69f8b02a7c907ed31d8768e6c2d841b1296a9225fe826040516200030a919062000831565b60405180910390a18151620001d8906004906020850190620005ac565b620003338282620003b1565b620000c6576000828152602081815260408083206001600160a01b03851684529091529020805460ff191660011790556200036d620000b6565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b801580620004695750604051636eb1769f60e11b81526001600160a01b0384169063dd62ed3e90620004139030908690600401620007fe565b60206040518083038186803b1580156200042c57600080fd5b505afa15801562000441573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620004679190620007a9565b155b620004885760405162461bcd60e51b8152600401620001129062000947565b620001d88363095ea7b360e01b8484604051602401620004aa92919062000818565b60408051808303601f190181529190526020810180516001600160e01b0319939093166001600160e01b0393841617905290620004e316565b600080836001600160a01b031683604051620005009190620007c2565b6000604051808303816000865af19150503d80600081146200053f576040519150601f19603f3d011682016040523d82523d6000602084013e62000544565b606091505b509150915081620005695760405162461bcd60e51b81526004016200011290620008c8565b805115620005a6578080602001905181019062000587919062000780565b620005a65760405162461bcd60e51b81526004016200011290620008fd565b50505050565b82805482825590600052602060002090810192821562000604579160200282015b828111156200060457825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190620005cd565b506200061292915062000616565b5090565b5b8082111562000612576000815560010162000617565b80516001600160a01b03811681146200064557600080fd5b919050565b600082601f8301126200065b578081fd5b815160206001600160401b03808311156200067a576200067a620009a4565b818302604051838282010181811084821117156200069c576200069c620009a4565b60405284815283810192508684018288018501891015620006bb578687fd5b8692505b85831015620006e857620006d3816200062d565b845292840192600192909201918401620006bf565b50979650505050505050565b600080600080608085870312156200070a578384fd5b84516001600160401b038082111562000721578586fd5b6200072f888389016200064a565b9550602087015191508082111562000745578485fd5b5062000754878288016200064a565b93505062000765604086016200062d565b915062000775606086016200062d565b905092959194509250565b60006020828403121562000792578081fd5b81518015158114620007a2578182fd5b9392505050565b600060208284031215620007bb578081fd5b5051919050565b60008251815b81811015620007e45760208186018101518583015201620007c8565b81811115620007f35782828501525b509190910192915050565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b03929092168252602082015260400190565b6020808252825182820181905260009190848201906040850190845b81811015620008745783516001600160a01b0316835292840192918401916001016200084d565b50909695505050505050565b60208082526028908201527f4d61696e7461696e61626c653a2043616c6c6572206973206e6f742061206d6160408201526734b73a30b4b732b960c11b606082015260800190565b6020808252818101527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6040820152691bdd081cdd58d8d9595960b21b606082015260800190565b60208082526036908201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60408201527f20746f206e6f6e2d7a65726f20616c6c6f77616e636500000000000000000000606082015260800190565b634e487b7160e01b600052604160045260246000fd5b60805160601c613d64620009fc6000396000818161115e015281816114ef0152818161160301528181611835015281816125e901526126c30152613d646000f3fe6080604052600436106102a35760003560e01c80638980f11f1161016e578063c8a3a5c6116100cb578063dede7f151161007f578063f2fde38b11610064578063f2fde38b14610725578063f874225414610745578063fe38c5e61461075a576102aa565b8063dede7f15146106e5578063f035038214610705576102aa565b8063d73792a9116100b0578063d73792a914610690578063d8baf7cf146106a5578063dd8544b3146106c5576102aa565b8063c8a3a5c614610650578063d547741f14610670576102aa565b8063a0cf0aea11610122578063a3f4df7e11610107578063a3f4df7e146105f9578063b381cf401461061b578063c3accd4814610630576102aa565b8063a0cf0aea146105cf578063a217fddf146105e4576102aa565b806391d148541161015357806391d148541461056257806392f5d88a14610582578063952e9012146105af576102aa565b80638980f11f146105225780638bb9c5bf14610542576102aa565b80634c09cf4e1161021c57806375d19947116101d057806376ebe69c116101b557806376ebe69c146104d85780637c7a561b146104ed578063809356aa14610502576102aa565b806375d19947146104a357806376c7a3c7146104c3576102aa565b806352a52ab01161020157806352a52ab0146104435780636b453c1f146104635780636bf2df8614610483576102aa565b80634c09cf4e146104035780634ebb791614610423576102aa565b8063248a9ca31161027357806331ac99201161025857806331ac9920146103a357806336568abe146103c35780633a9a4081146103e3576102aa565b8063248a9ca3146103565780632f2ff15d14610383576102aa565b8062b99e36146102af57806301ffc9a7146102da578063061b15e7146103075780631e189dc214610334576102aa565b366102aa57005b600080fd5b3480156102bb57600080fd5b506102c461076d565b6040516102d191906135bc565b60405180910390f35b3480156102e657600080fd5b506102fa6102f5366004613148565b61077c565b6040516102d1919061367b565b34801561031357600080fd5b506103276103223660046133fd565b6107c2565b6040516102d19190613a6a565b34801561034057600080fd5b5061035461034f36600461324c565b61088f565b005b34801561036257600080fd5b50610376610371366004613105565b610951565b6040516102d19190613686565b34801561038f57600080fd5b5061035461039e36600461311d565b610966565b3480156103af57600080fd5b506103546103be366004613105565b610987565b3480156103cf57600080fd5b506103546103de36600461311d565b610a1a565b3480156103ef57600080fd5b506103546103fe366004613037565b610a60565b34801561040f57600080fd5b5061032761041e3660046133ba565b610afc565b34801561042f57600080fd5b5061035461043e366004613105565b610ba5565b34801561044f57600080fd5b506102c461045e366004613105565b610c8b565b34801561046f57600080fd5b5061035461047e366004612ff4565b610cb5565b34801561048f57600080fd5b5061035461049e3660046131f7565b610ce2565b3480156104af57600080fd5b506103546104be36600461324c565b610cf4565b3480156104cf57600080fd5b50610376610dad565b3480156104e457600080fd5b50610376610db3565b3480156104f957600080fd5b50610376610db9565b34801561050e57600080fd5b5061037661051d36600461344a565b610dbf565b34801561052e57600080fd5b5061035461053d36600461300e565b610e80565b34801561054e57600080fd5b5061035461055d366004613105565b610f4c565b34801561056e57600080fd5b506102fa61057d36600461311d565b610f62565b34801561058e57600080fd5b506105a261059d366004613322565b610f8b565b6040516102d19190613b04565b3480156105bb57600080fd5b506102c46105ca366004613105565b61110e565b3480156105db57600080fd5b506102c461111e565b3480156105f057600080fd5b5061037661111e565b34801561060557600080fd5b5061060e611123565b6040516102d191906136bd565b34801561062757600080fd5b506102c461115c565b34801561063c57600080fd5b5061035461064b366004612ff4565b611180565b34801561065c57600080fd5b5061035461066b366004613037565b611249565b34801561067c57600080fd5b5061035461068b36600461311d565b6112e5565b34801561069c57600080fd5b50610376611301565b3480156106b157600080fd5b506103546106c0366004612ff4565b611307565b3480156106d157600080fd5b506103546106e0366004612ff4565b611331565b3480156106f157600080fd5b506105a26107003660046132e7565b611399565b34801561071157600080fd5b506103546107203660046131f7565b6114e5565b34801561073157600080fd5b50610354610740366004612ff4565b6115b3565b34801561075157600080fd5b506103766115d5565b6103546107683660046131f7565b6115f9565b6002546001600160a01b031681565b60006001600160e01b031982167f7965db0b0000000000000000000000000000000000000000000000000000000014806107ba57506107ba826117c8565b90505b919050565b6107ca612edf565b6000831180156107da5750600583105b6107ff5760405162461bcd60e51b81526004016107f690613705565b60405180910390fd5b610807612edf565b610810876117fa565b815261081b866117fa565b604082015260008361082e576000610838565b6108388487611824565b90506108488888888886866118c7565b91508160200151516000141561087a576040805160208082018352600080835291855282519081018352908152908301525b61088382611c45565b98975050505050505050565b61089c6040880188613b9e565b60008181106108bb57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906108d09190612ff4565b60405163d505accf60e01b81526001600160a01b03919091169063d505accf9061090b90339030908c35908a908a908a908a9060040161360e565b600060405180830381600087803b15801561092557600080fd5b505af1158015610939573d6000803e3d6000fd5b505050506109488787876114e5565b50505050505050565b60009081526020819052604090206001015490565b61096f82610951565b61097881611c9d565b6109828383611cae565b505050565b6000610991611d33565b90506109bd7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b6109d95760405162461bcd60e51b81526004016107f69061373c565b7f4bb8a6184424e4bb853a4836042f5a726e4e710873989bfc6abdab19966f5b7060015483604051610a0c929190613b62565b60405180910390a150600155565b610a22611d33565b6001600160a01b0316816001600160a01b031614610a525760405162461bcd60e51b81526004016107f6906139d6565b610a5c8282611d37565b5050565b6000610a6a611d33565b9050610a967f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b610ab25760405162461bcd60e51b81526004016107f69061373c565b7febf7325f48e05e5e38809c69f8b02a7c907ed31d8768e6c2d841b1296a9225fe82604051610ae19190613668565b60405180910390a18151610982906004906020850190612f07565b610b04612edf565b600082118015610b145750600582105b610b305760405162461bcd60e51b81526004016107f690613705565b610b38612edf565b610b41866117fa565b8152610b4c856117fa565b6040820152610b60868686868560006118c7565b905080602001515160001415610b92576040805160208082018352600080835291845282519081018352908152908201525b610b9b81611c45565b9695505050505050565b6000610baf611d33565b9050610bdb7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b610bf75760405162461bcd60e51b81526004016107f69061373c565b60008211610c175760405162461bcd60e51b81526004016107f690613a33565b604051339083156108fc029084906000818181858888f19350505050158015610c44573d6000803e3d6000fd5b5060006001600160a01b03167f8c1256b8896378cd5044f80c202f9772b9d77dc85c8a6eb51967210b09bfaa2883604051610c7f9190613686565b60405180910390a25050565b60038181548110610c9b57600080fd5b6000918252602090912001546001600160a01b0316905081565b610cdf7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610966565b50565b610cee83338484611dba565b50505050565b610d016040880188613b9e565b6000818110610d2057634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610d359190612ff4565b60405163d505accf60e01b81526001600160a01b03919091169063d505accf90610d7090339030908c35908a908a908a908a9060040161360e565b600060405180830381600087803b158015610d8a57600080fd5b505af1158015610d9e573d6000803e3d6000fd5b50505050610948878787610ce2565b60015481565b60035490565b60045490565b60008060048360ff1681548110610de657634e487b7160e01b600052603260045260246000fd5b60009182526020822001546040516377ccc49d60e11b81526001600160a01b039091169250829063ef99893a90610e25908a908a908a90600401613b43565b60206040518083038186803b158015610e3d57600080fd5b505afa158015610e51573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e7591906132cf565b979650505050505050565b6000610e8a611d33565b9050610eb67f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b610ed25760405162461bcd60e51b81526004016107f69061373c565b60008211610ef25760405162461bcd60e51b81526004016107f690613a33565b610f066001600160a01b038416338461259a565b826001600160a01b03167f8c1256b8896378cd5044f80c202f9772b9d77dc85c8a6eb51967210b09bfaa2883604051610f3f9190613686565b60405180910390a2505050565b6000610f56611d33565b9050610a5c8282610a1a565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b610f93612f79565b610f9b612f79565b60005b60ff8116841115611103576000600486868460ff16818110610fd057634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610fe59190613496565b60ff168154811061100657634e487b7160e01b600052603260045260246000fd5b60009182526020822001546040516377ccc49d60e11b81526001600160a01b039091169250829063ef99893a90611045908d908d908d90600401613b43565b60206040518083038186803b15801561105d57600080fd5b505afa158015611071573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061109591906132cf565b905060ff831615806110aa5750836060015181115b156110ee576040518060800160405280836001600160a01b031681526020018a6001600160a01b03168152602001896001600160a01b031681526020018281525093505b505080806110fb90613ce2565b915050610f9e565b509695505050505050565b60048181548110610c9b57600080fd5b600081565b6040518060400160405280600981526020017f59616b526f75746572000000000000000000000000000000000000000000000081525081565b7f000000000000000000000000000000000000000000000000000000000000000081565b600061118a611d33565b90506111b67f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b6111d25760405162461bcd60e51b81526004016107f69061373c565b6002546040517fb2c853ac4d80d18d058c43d8018d077a036e542a79acae1647f5ad2a8c76f4e291611211916001600160a01b039091169085906135d0565b60405180910390a1506002805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6000611253611d33565b905061127f7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b61129b5760405162461bcd60e51b81526004016107f69061373c565b7f658ff1688002926d8f426cb10c052ec29003f50042df9652d8613484c1a58647826040516112ca9190613668565b60405180910390a18151610982906003906020850190612f07565b6112ee82610951565b6112f781611c9d565b6109828383611d37565b61271081565b610cdf7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab95826112e5565b600061133b611d33565b90506113677f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b6113835760405162461bcd60e51b81526004016107f69061373c565b610a5c6001600160a01b038316836000196116a0565b6113a1612f79565b6113a9612f79565b60005b60045460ff821610156114dc57600060048260ff16815481106113df57634e487b7160e01b600052603260045260246000fd5b60009182526020822001546040516377ccc49d60e11b81526001600160a01b039091169250829063ef99893a9061141e908b908b908b90600401613b43565b60206040518083038186803b15801561143657600080fd5b505afa15801561144a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061146e91906132cf565b905060ff831615806114835750836060015181115b156114c7576040518060800160405280836001600160a01b03168152602001886001600160a01b03168152602001876001600160a01b031681526020018281525093505b505080806114d490613ce2565b9150506113ac565b50949350505050565b6001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001661151c6040850185613b9e565b600161152b6040880188613b9e565b611536929150613c6d565b81811061155357634e487b7160e01b600052603260045260246000fd5b90506020020160208101906115689190612ff4565b6001600160a01b03161461158e5760405162461bcd60e51b81526004016107f690613799565b600061159c84333085611dba565b90506115a7816125b9565b610cee60008285612653565b60006115bd611d33565b90506115ca600083610966565b610a5c600082610a1a565b7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9581565b6001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000166116306040850185613b9e565b600081811061164f57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906116649190612ff4565b6001600160a01b03161461168a5760405162461bcd60e51b81526004016107f69061382b565b61169483356126c1565b610cee83308484611dba565b80158061174157506040517fdd62ed3e0000000000000000000000000000000000000000000000000000000081526001600160a01b0384169063dd62ed3e906116ef90309086906004016135d0565b60206040518083038186803b15801561170757600080fd5b505afa15801561171b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061173f91906132cf565b155b61175d5760405162461bcd60e51b81526004016107f690613979565b6109828363095ea7b360e01b848460405160240161177c92919061364f565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990931692909217909152612738565b6001600160e01b031981167f01ffc9a70000000000000000000000000000000000000000000000000000000014919050565b60408051602080825281830190925260609160208201818036833750505060208101929092525090565b60008061185c670de0b6b3a76400007f0000000000000000000000000000000000000000000000000000000000000000856002610afc565b90508060400151516000146118c05780518051633b9aca0091869161188390600190613c6d565b815181106118a157634e487b7160e01b600052603260045260246000fd5b60200260200101516118b39190613c4e565b6118bd9190613c2e565b91505b5092915050565b6118cf612edf565b60006118da846127ee565b9050600080841515816118ee8c8c8c611399565b9050806060015160001461199b57811561197a5780600001516001600160a01b03166369cff80d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561193f57600080fd5b505afa158015611953573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061197791906132cf565b92505b611993858260600151836000015184604001518761282e565b806060015193505b6001891180156119c657506119b160028a613c6d565b60208960200151516119c39190613c2e565b11155b15611c355760005b600354811015611c3357600381815481106119f957634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b038d811691161415611a1d57611c21565b6000611a5f8e8e60038581548110611a4557634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b0316611399565b9050806060015160001415611a745750611c21565b6000611a7f8b6127ee565b90508415611aff5781600001516001600160a01b03166369cff80d6040518163ffffffff1660e01b815260040160206040518083038186803b158015611ac457600080fd5b505afa158015611ad8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611afc91906132cf565b95505b611b18818360600151846000015185604001518a61282e565b611b5f826060015160038581548110611b4157634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b03168f8f858f6118c7565b90506000611b768260400151518360400151612a24565b82518051919250600091611b8991612a24565b9050816001600160a01b03168f6001600160a01b0316148015611bab57508881115b15611c1c57896060015183606001511115611c15576000633b9aca008b606001518560600151611bdb9190613c6d565b611be5908f613c4e565b611bef9190613c2e565b90506000611bfd8b84613c6d565b905080821115611c1257505050505050611c21565b50505b8098508299505b505050505b80611c2b81613cc7565b9150506119ce565b505b50929a9950505050505050505050565b611c4d612edf565b6040518060800160405280611c658460000151612a37565b8152602001611c778460200151612b0f565b8152602001611c898460400151612b0f565b815260200183606001518152509050919050565b610cdf81611ca9611d33565b612bdb565b611cb88282610f62565b610a5c576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055611cef611d33565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b3390565b611d418282610f62565b15610a5c576000828152602081815260408083206001600160a01b03851684529091529020805460ff19169055611d76611d33565b6001600160a01b0316816001600160a01b0316837ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b60405160405180910390a45050565b600080611dca6040870187613b9e565b905067ffffffffffffffff811115611df257634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611e1b578160200160208202803683370190505b5090506000831180611e2f57506000600154115b15611f0057611e3f863584612c3f565b81600081518110611e6057634e487b7160e01b600052603260045260246000fd5b6020908102919091010152611efb611e7b6040880188613b9e565b6000818110611e9a57634e487b7160e01b600052603260045260246000fd5b9050602002016020810190611eaf9190612ff4565b600254835188916001600160a01b0316908590600090611edf57634e487b7160e01b600052603260045260246000fd5b60200260200101518a60000135611ef69190613c6d565b612c84565b611f33565b856000013581600081518110611f2657634e487b7160e01b600052603260045260246000fd5b6020026020010181815250505b611fe7611f436040880188613b9e565b6000818110611f6257634e487b7160e01b600052603260045260246000fd5b9050602002016020810190611f779190612ff4565b86611f8560608a018a613b9e565b6000818110611fa457634e487b7160e01b600052603260045260246000fd5b9050602002016020810190611fb99190612ff4565b84600081518110611fda57634e487b7160e01b600052603260045260246000fd5b6020026020010151612c84565b60005b611ff76060880188613b9e565b90508110156121b85761200d6060880188613b9e565b8281811061202b57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906120409190612ff4565b6001600160a01b031663ef99893a83838151811061206e57634e487b7160e01b600052603260045260246000fd5b60200260200101518980604001906120869190613b9e565b858181106120a457634e487b7160e01b600052603260045260246000fd5b90506020020160208101906120b99190612ff4565b6120c660408c018c613b9e565b6120d1876001613c16565b8181106120ee57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906121039190612ff4565b6040518463ffffffff1660e01b815260040161212193929190613b43565b60206040518083038186803b15801561213957600080fd5b505afa15801561214d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061217191906132cf565b8261217d836001613c16565b8151811061219b57634e487b7160e01b600052603260045260246000fd5b6020908102919091010152806121b081613cc7565b915050611fea565b50856020013581600183516121cd9190613c6d565b815181106121eb57634e487b7160e01b600052603260045260246000fd5b602002602001015110156122115760405162461bcd60e51b81526004016107f69061391c565b60005b6122216060880188613b9e565b905081101561243c576000600161223b60608a018a613b9e565b612246929150613c6d565b8210612252578561229c565b61225f6060890189613b9e565b61226a846001613c16565b81811061228757634e487b7160e01b600052603260045260246000fd5b905060200201602081019061229c9190612ff4565b90506122ab6060890189613b9e565b838181106122c957634e487b7160e01b600052603260045260246000fd5b90506020020160208101906122de9190612ff4565b6001600160a01b031663eab90da684848151811061230c57634e487b7160e01b600052603260045260246000fd5b6020026020010151858560016123229190613c16565b8151811061234057634e487b7160e01b600052603260045260246000fd5b60200260200101518b80604001906123589190613b9e565b8781811061237657634e487b7160e01b600052603260045260246000fd5b905060200201602081019061238b9190612ff4565b61239860408e018e613b9e565b6123a3896001613c16565b8181106123c057634e487b7160e01b600052603260045260246000fd5b90506020020160208101906123d59190612ff4565b866040518663ffffffff1660e01b81526004016123f6959493929190613b70565b600060405180830381600087803b15801561241057600080fd5b505af1158015612424573d6000803e3d6000fd5b5050505050808061243490613cc7565b915050612214565b5061244a6040870187613b9e565b600161245960408a018a613b9e565b612464929150613c6d565b81811061248157634e487b7160e01b600052603260045260246000fd5b90506020020160208101906124969190612ff4565b6001600160a01b03166124ac6040880188613b9e565b60008181106124cb57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906124e09190612ff4565b6001600160a01b03167f9fc8352e52998db4087d5e6e1c1aafa38788e749e5d7a24f5cb230f7379544028860000135846001865161251e9190613c6d565b8151811061253c57634e487b7160e01b600052603260045260246000fd5b6020026020010151604051612552929190613b62565b60405180910390a380600182516125699190613c6d565b8151811061258757634e487b7160e01b600052603260045260246000fd5b6020026020010151915050949350505050565b6109828363a9059cbb60e01b848460405160240161177c92919061364f565b6040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001690632e1a7d4d9061261e908490600401613686565b600060405180830381600087803b15801561263857600080fd5b505af115801561264c573d6000803e3d6000fd5b5050505050565b306001600160a01b03821614610982576001600160a01b0383166126ad576040516001600160a01b0382169083156108fc029084906000818181858888f193505050501580156126a7573d6000803e3d6000fd5b50610982565b6109826001600160a01b038416828461259a565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b15801561271c57600080fd5b505af1158015612730573d6000803e3d6000fd5b505050505050565b600080836001600160a01b031683604051612753919061351f565b6000604051808303816000865af19150503d8060008114612790576040519150601f19603f3d011682016040523d82523d6000602084013e612795565b606091505b5091509150816127b75760405162461bcd60e51b81526004016107f6906137f6565b805115610cee57808060200190518101906127d291906130e5565b610cee5760405162461bcd60e51b81526004016107f6906138bf565b6127f6612edf565b604051806080016040528083600001518152602001836020015181526020018360400151815260200183606001518152509050919050565b73a479b3af0476a9e605133975c1f0c414d0654d12632f9680f58660400151612856856117fa565b6040518363ffffffff1660e01b815260040161287392919061368f565b60006040518083038186803b15801561288b57600080fd5b505af415801561289f573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526128c79190810190613170565b6040860152845173a479b3af0476a9e605133975c1f0c414d0654d1290632f9680f5906128f3876117fa565b6040518363ffffffff1660e01b815260040161291092919061368f565b60006040518083038186803b15801561292857600080fd5b505af415801561293c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526129649190810190613170565b8552602085015173a479b3af0476a9e605133975c1f0c414d0654d1290632f9680f590612990866117fa565b6040518363ffffffff1660e01b81526004016129ad92919061368f565b60006040518083038186803b1580156129c557600080fd5b505af41580156129d9573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612a019190810190613170565b6020860152606085018051829190612a1a908390613c16565b9052505050505050565b6000612a308383612cc2565b9392505050565b6060600060208351612a499190613c2e565b905060008167ffffffffffffffff811115612a7457634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612a9d578160200160208202803683370190505b50905060005b82811015612b0757612aca612ab9826020613c4e565b612ac4906020613c16565b86612a24565b828281518110612aea57634e487b7160e01b600052603260045260246000fd5b602090810291909101015280612aff81613cc7565b915050612aa3565b509392505050565b6060600060208351612b219190613c2e565b905060008167ffffffffffffffff811115612b4c57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612b75578160200160208202803683370190505b50905060005b82811015612b0757612b91612ab9826020613c4e565b828281518110612bb157634e487b7160e01b600052603260045260246000fd5b6001600160a01b039092166020928302919091019091015280612bd381613cc7565b915050612b7b565b612be58282610f62565b610a5c57612bfd816001600160a01b03166014612cc7565b612c08836020612cc7565b604051602001612c1992919061353b565b60408051601f198184030181529082905262461bcd60e51b82526107f6916004016136bd565b6000600154821015612c635760405162461bcd60e51b81526004016107f690613888565b612710612c708382613c6d565b612c7a9085613c4e565b612a309190613c2e565b6001600160a01b0383163014612cae57612ca96001600160a01b038516848484612ebe565b610cee565b610cee6001600160a01b038516838361259a565b015190565b60606000612cd6836002613c4e565b612ce1906002613c16565b67ffffffffffffffff811115612d0757634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612d31576020820181803683370190505b5090507f300000000000000000000000000000000000000000000000000000000000000081600081518110612d7657634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110612dcf57634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a9053506000612df3846002613c4e565b612dfe906001613c16565b90505b6001811115612e9f577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110612e4d57634e487b7160e01b600052603260045260246000fd5b1a60f81b828281518110612e7157634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535060049490941c93612e9881613cb0565b9050612e01565b508315612a305760405162461bcd60e51b81526004016107f6906136d0565b610cee846323b872dd60e01b85858560405160240161177c939291906135ea565b6040518060800160405280606081526020016060815260200160608152602001600081525090565b828054828255906000526020600020908101928215612f69579160200282015b82811115612f69578251825473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b03909116178255602090920191600190910190612f27565b50612f75929150612fa0565b5090565b60408051608081018252600080825260208201819052918101829052606081019190915290565b5b80821115612f755760008155600101612fa1565b80356001600160a01b03811681146107bd57600080fd5b600060808284031215612fdd578081fd5b50919050565b803560ff811681146107bd57600080fd5b600060208284031215613005578081fd5b612a3082612fb5565b60008060408385031215613020578081fd5b61302983612fb5565b946020939093013593505050565b60006020808385031215613049578182fd5b823567ffffffffffffffff80821115613060578384fd5b818501915085601f830112613073578384fd5b81358181111561308557613085613d18565b8381029150613095848301613bec565b8181528481019084860184860187018a10156130af578788fd5b8795505b838610156130d8576130c481612fb5565b8352600195909501949186019186016130b3565b5098975050505050505050565b6000602082840312156130f6578081fd5b81518015158114612a30578182fd5b600060208284031215613116578081fd5b5035919050565b6000806040838503121561312f578182fd5b8235915061313f60208401612fb5565b90509250929050565b600060208284031215613159578081fd5b81356001600160e01b031981168114612a30578182fd5b600060208284031215613181578081fd5b815167ffffffffffffffff80821115613198578283fd5b818401915084601f8301126131ab578283fd5b8151818111156131bd576131bd613d18565b6131d0601f8201601f1916602001613bec565b91508082528560208285010111156131e6578384fd5b6114dc816020840160208601613c84565b60008060006060848603121561320b578081fd5b833567ffffffffffffffff811115613221578182fd5b61322d86828701612fcc565b93505061323c60208501612fb5565b9150604084013590509250925092565b600080600080600080600060e0888a031215613266578283fd5b873567ffffffffffffffff81111561327c578384fd5b6132888a828b01612fcc565b97505061329760208901612fb5565b955060408801359450606088013593506132b360808901612fe3565b925060a0880135915060c0880135905092959891949750929550565b6000602082840312156132e0578081fd5b5051919050565b6000806000606084860312156132fb578081fd5b8335925061330b60208501612fb5565b915061331960408501612fb5565b90509250925092565b600080600080600060808688031215613339578283fd5b8535945061334960208701612fb5565b935061335760408701612fb5565b9250606086013567ffffffffffffffff80821115613373578283fd5b818801915088601f830112613386578283fd5b813581811115613394578384fd5b89602080830285010111156133a7578384fd5b9699959850939650602001949392505050565b600080600080608085870312156133cf578182fd5b843593506133df60208601612fb5565b92506133ed60408601612fb5565b9396929550929360600135925050565b600080600080600060a08688031215613414578283fd5b8535945061342460208701612fb5565b935061343260408701612fb5565b94979396509394606081013594506080013592915050565b6000806000806080858703121561345f578182fd5b8435935061346f60208601612fb5565b925061347d60408601612fb5565b915061348b60608601612fe3565b905092959194509250565b6000602082840312156134a7578081fd5b612a3082612fe3565b6000815180845260208085019450808401835b838110156134e85781516001600160a01b0316875295820195908201906001016134c3565b509495945050505050565b6000815180845261350b816020860160208601613c84565b601f01601f19169290920160200192915050565b60008251613531818460208701613c84565b9190910192915050565b60007f416363657373436f6e74726f6c3a206163636f756e742000000000000000000082528351613573816017850160208801613c84565b7f206973206d697373696e6720726f6c652000000000000000000000000000000060179184019182015283516135b0816028840160208801613c84565b01602801949350505050565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b0397881681529590961660208601526040850193909352606084019190915260ff16608083015260a082015260c081019190915260e00190565b6001600160a01b03929092168252602082015260400190565b600060208252612a3060208301846134b0565b901515815260200190565b90815260200190565b6000604082526136a260408301856134f3565b82810360208401526136b481856134f3565b95945050505050565b600060208252612a3060208301846134f3565b6020808252818101527f537472696e67733a20686578206c656e67746820696e73756666696369656e74604082015260600190565b6020808252601c908201527f59616b526f757465723a20496e76616c6964206d61782d737465707300000000604082015260600190565b60208082526028908201527f4d61696e7461696e61626c653a2043616c6c6572206973206e6f742061206d6160408201527f696e7461696e6572000000000000000000000000000000000000000000000000606082015260800190565b60208082526027908201527f59616b526f757465723a2050617468206e6565647320746f20656e642077697460408201527f6820574156415800000000000000000000000000000000000000000000000000606082015260800190565b6020808252818101527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604082015260600190565b60208082526029908201527f59616b526f757465723a2050617468206e6565647320746f20626567696e207760408201527f6974682057415641580000000000000000000000000000000000000000000000606082015260800190565b6020808252601b908201527f59616b526f757465723a20496e73756666696369656e74206665650000000000604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60408201527f6f74207375636365656400000000000000000000000000000000000000000000606082015260800190565b60208082526025908201527f59616b526f757465723a20496e73756666696369656e74206f7574707574206160408201527f6d6f756e74000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526036908201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60408201527f20746f206e6f6e2d7a65726f20616c6c6f77616e636500000000000000000000606082015260800190565b6020808252602f908201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560408201527f20726f6c657320666f722073656c660000000000000000000000000000000000606082015260800190565b6020808252601d908201527f59616b526f757465723a204e6f7468696e6720746f207265636f766572000000604082015260600190565b60208082528251608083830152805160a0840181905260009291820190839060c08601905b80831015613aaf5783518252928401926001929092019190840190613a8f565b50838701519350601f19925082868203016040870152613acf81856134b0565b93505050604085015181858403016060860152613aec83826134b0565b92505050606084015160808401528091505092915050565b60006080820190506001600160a01b03808451168352806020850151166020840152806040850151166040840152506060830151606083015292915050565b9283526001600160a01b03918216602084015216604082015260600190565b918252602082015260400190565b94855260208501939093526001600160a01b0391821660408501528116606084015216608082015260a00190565b6000808335601e19843603018112613bb4578283fd5b83018035915067ffffffffffffffff821115613bce578283fd5b6020908101925081023603821315613be557600080fd5b9250929050565b60405181810167ffffffffffffffff81118282101715613c0e57613c0e613d18565b604052919050565b60008219821115613c2957613c29613d02565b500190565b600082613c4957634e487b7160e01b81526012600452602481fd5b500490565b6000816000190483118215151615613c6857613c68613d02565b500290565b600082821015613c7f57613c7f613d02565b500390565b60005b83811015613c9f578181015183820152602001613c87565b83811115610cee5750506000910152565b600081613cbf57613cbf613d02565b506000190190565b6000600019821415613cdb57613cdb613d02565b5060010190565b600060ff821660ff811415613cf957613cf9613d02565b60010192915050565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052604160045260246000fdfea26469706673582212204c7a4b7fd280c461df3aa9d43d9ce97c3b1647b0631cc4f7d74c2e83c5199bc564736f6c63430008000033339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9500000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000340000000000000000000000000d22044706dea3c342f68396bedbcf6a2536d951d00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab10000000000000000000000000000000000000000000000000000000000000015000000000000000000000000cd887f78c77b36b0b541e77afd6f91c0253182a20000000000000000000000009b96595298a1ba7b6c389f217d55896960bbb4ae000000000000000000000000985d014da6e6c781ec3ff77e8fd48c30174f3d9600000000000000000000000081544acdbcffdc9c0a265cfb220408e1e85aa43d000000000000000000000000bf042126c0c0d2c658915c2d21922d3440092f48000000000000000000000000784e00cd961a994eff675e889af6ca564689bf390000000000000000000000005f030dc08eea2abfcc497f3c5351746dac971ad20000000000000000000000001d3e01bd14214fe3cd10904690dfa908c23b37a1000000000000000000000000b60ce5bf2a231eda70825f9cdcd0795102218ab00000000000000000000000004aff45ce2e48c159147fa7dd5b436cafd9688eba0000000000000000000000008fc296f44017b50ccaafb2e002d590c2e09873630000000000000000000000003b2378a29f9cbdb1f20a72611c0f000af05630cb000000000000000000000000610460dab540dae1eb84c22ea97866bfc0482c3f000000000000000000000000c5b9041f9748a9a4437ba90f9806ce8c3f9085fc000000000000000000000000fcfa6855b3e79f1c3ae4314cc0e85f37dfa14b3f0000000000000000000000000fdf64b6746ba759d120e973c85349a8b9cde8d40000000000000000000000004a6c794192831fb9f4782e61bec05d6c5cc9f3ea000000000000000000000000e483b8c8ab7659fbaa2603b963bda50fb1a8103c0000000000000000000000009f7e365a57c6baeae94870ffbb0af92209a9f4d00000000000000000000000009d609ad3c673e2ddb3047c3f3b3efa2ce14eb43600000000000000000000000019eb54ccb443aced9dcbc960ba98064a13262ef3000000000000000000000000000000000000000000000000000000000000000500000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab10000000000000000000000002f2a2543b76a4166549f7aab2e75bef0aefc5b0f000000000000000000000000ff970a61a04b1ca14834a43f5de4533ebddb5cc8000000000000000000000000fd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9000000000000000000000000da10009cbd5d07dd0cecc66161fc93d7c9000da1
Deployed Bytecode
0x6080604052600436106102a35760003560e01c80638980f11f1161016e578063c8a3a5c6116100cb578063dede7f151161007f578063f2fde38b11610064578063f2fde38b14610725578063f874225414610745578063fe38c5e61461075a576102aa565b8063dede7f15146106e5578063f035038214610705576102aa565b8063d73792a9116100b0578063d73792a914610690578063d8baf7cf146106a5578063dd8544b3146106c5576102aa565b8063c8a3a5c614610650578063d547741f14610670576102aa565b8063a0cf0aea11610122578063a3f4df7e11610107578063a3f4df7e146105f9578063b381cf401461061b578063c3accd4814610630576102aa565b8063a0cf0aea146105cf578063a217fddf146105e4576102aa565b806391d148541161015357806391d148541461056257806392f5d88a14610582578063952e9012146105af576102aa565b80638980f11f146105225780638bb9c5bf14610542576102aa565b80634c09cf4e1161021c57806375d19947116101d057806376ebe69c116101b557806376ebe69c146104d85780637c7a561b146104ed578063809356aa14610502576102aa565b806375d19947146104a357806376c7a3c7146104c3576102aa565b806352a52ab01161020157806352a52ab0146104435780636b453c1f146104635780636bf2df8614610483576102aa565b80634c09cf4e146104035780634ebb791614610423576102aa565b8063248a9ca31161027357806331ac99201161025857806331ac9920146103a357806336568abe146103c35780633a9a4081146103e3576102aa565b8063248a9ca3146103565780632f2ff15d14610383576102aa565b8062b99e36146102af57806301ffc9a7146102da578063061b15e7146103075780631e189dc214610334576102aa565b366102aa57005b600080fd5b3480156102bb57600080fd5b506102c461076d565b6040516102d191906135bc565b60405180910390f35b3480156102e657600080fd5b506102fa6102f5366004613148565b61077c565b6040516102d1919061367b565b34801561031357600080fd5b506103276103223660046133fd565b6107c2565b6040516102d19190613a6a565b34801561034057600080fd5b5061035461034f36600461324c565b61088f565b005b34801561036257600080fd5b50610376610371366004613105565b610951565b6040516102d19190613686565b34801561038f57600080fd5b5061035461039e36600461311d565b610966565b3480156103af57600080fd5b506103546103be366004613105565b610987565b3480156103cf57600080fd5b506103546103de36600461311d565b610a1a565b3480156103ef57600080fd5b506103546103fe366004613037565b610a60565b34801561040f57600080fd5b5061032761041e3660046133ba565b610afc565b34801561042f57600080fd5b5061035461043e366004613105565b610ba5565b34801561044f57600080fd5b506102c461045e366004613105565b610c8b565b34801561046f57600080fd5b5061035461047e366004612ff4565b610cb5565b34801561048f57600080fd5b5061035461049e3660046131f7565b610ce2565b3480156104af57600080fd5b506103546104be36600461324c565b610cf4565b3480156104cf57600080fd5b50610376610dad565b3480156104e457600080fd5b50610376610db3565b3480156104f957600080fd5b50610376610db9565b34801561050e57600080fd5b5061037661051d36600461344a565b610dbf565b34801561052e57600080fd5b5061035461053d36600461300e565b610e80565b34801561054e57600080fd5b5061035461055d366004613105565b610f4c565b34801561056e57600080fd5b506102fa61057d36600461311d565b610f62565b34801561058e57600080fd5b506105a261059d366004613322565b610f8b565b6040516102d19190613b04565b3480156105bb57600080fd5b506102c46105ca366004613105565b61110e565b3480156105db57600080fd5b506102c461111e565b3480156105f057600080fd5b5061037661111e565b34801561060557600080fd5b5061060e611123565b6040516102d191906136bd565b34801561062757600080fd5b506102c461115c565b34801561063c57600080fd5b5061035461064b366004612ff4565b611180565b34801561065c57600080fd5b5061035461066b366004613037565b611249565b34801561067c57600080fd5b5061035461068b36600461311d565b6112e5565b34801561069c57600080fd5b50610376611301565b3480156106b157600080fd5b506103546106c0366004612ff4565b611307565b3480156106d157600080fd5b506103546106e0366004612ff4565b611331565b3480156106f157600080fd5b506105a26107003660046132e7565b611399565b34801561071157600080fd5b506103546107203660046131f7565b6114e5565b34801561073157600080fd5b50610354610740366004612ff4565b6115b3565b34801561075157600080fd5b506103766115d5565b6103546107683660046131f7565b6115f9565b6002546001600160a01b031681565b60006001600160e01b031982167f7965db0b0000000000000000000000000000000000000000000000000000000014806107ba57506107ba826117c8565b90505b919050565b6107ca612edf565b6000831180156107da5750600583105b6107ff5760405162461bcd60e51b81526004016107f690613705565b60405180910390fd5b610807612edf565b610810876117fa565b815261081b866117fa565b604082015260008361082e576000610838565b6108388487611824565b90506108488888888886866118c7565b91508160200151516000141561087a576040805160208082018352600080835291855282519081018352908152908301525b61088382611c45565b98975050505050505050565b61089c6040880188613b9e565b60008181106108bb57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906108d09190612ff4565b60405163d505accf60e01b81526001600160a01b03919091169063d505accf9061090b90339030908c35908a908a908a908a9060040161360e565b600060405180830381600087803b15801561092557600080fd5b505af1158015610939573d6000803e3d6000fd5b505050506109488787876114e5565b50505050505050565b60009081526020819052604090206001015490565b61096f82610951565b61097881611c9d565b6109828383611cae565b505050565b6000610991611d33565b90506109bd7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b6109d95760405162461bcd60e51b81526004016107f69061373c565b7f4bb8a6184424e4bb853a4836042f5a726e4e710873989bfc6abdab19966f5b7060015483604051610a0c929190613b62565b60405180910390a150600155565b610a22611d33565b6001600160a01b0316816001600160a01b031614610a525760405162461bcd60e51b81526004016107f6906139d6565b610a5c8282611d37565b5050565b6000610a6a611d33565b9050610a967f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b610ab25760405162461bcd60e51b81526004016107f69061373c565b7febf7325f48e05e5e38809c69f8b02a7c907ed31d8768e6c2d841b1296a9225fe82604051610ae19190613668565b60405180910390a18151610982906004906020850190612f07565b610b04612edf565b600082118015610b145750600582105b610b305760405162461bcd60e51b81526004016107f690613705565b610b38612edf565b610b41866117fa565b8152610b4c856117fa565b6040820152610b60868686868560006118c7565b905080602001515160001415610b92576040805160208082018352600080835291845282519081018352908152908201525b610b9b81611c45565b9695505050505050565b6000610baf611d33565b9050610bdb7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b610bf75760405162461bcd60e51b81526004016107f69061373c565b60008211610c175760405162461bcd60e51b81526004016107f690613a33565b604051339083156108fc029084906000818181858888f19350505050158015610c44573d6000803e3d6000fd5b5060006001600160a01b03167f8c1256b8896378cd5044f80c202f9772b9d77dc85c8a6eb51967210b09bfaa2883604051610c7f9190613686565b60405180910390a25050565b60038181548110610c9b57600080fd5b6000918252602090912001546001600160a01b0316905081565b610cdf7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610966565b50565b610cee83338484611dba565b50505050565b610d016040880188613b9e565b6000818110610d2057634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610d359190612ff4565b60405163d505accf60e01b81526001600160a01b03919091169063d505accf90610d7090339030908c35908a908a908a908a9060040161360e565b600060405180830381600087803b158015610d8a57600080fd5b505af1158015610d9e573d6000803e3d6000fd5b50505050610948878787610ce2565b60015481565b60035490565b60045490565b60008060048360ff1681548110610de657634e487b7160e01b600052603260045260246000fd5b60009182526020822001546040516377ccc49d60e11b81526001600160a01b039091169250829063ef99893a90610e25908a908a908a90600401613b43565b60206040518083038186803b158015610e3d57600080fd5b505afa158015610e51573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e7591906132cf565b979650505050505050565b6000610e8a611d33565b9050610eb67f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b610ed25760405162461bcd60e51b81526004016107f69061373c565b60008211610ef25760405162461bcd60e51b81526004016107f690613a33565b610f066001600160a01b038416338461259a565b826001600160a01b03167f8c1256b8896378cd5044f80c202f9772b9d77dc85c8a6eb51967210b09bfaa2883604051610f3f9190613686565b60405180910390a2505050565b6000610f56611d33565b9050610a5c8282610a1a565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b610f93612f79565b610f9b612f79565b60005b60ff8116841115611103576000600486868460ff16818110610fd057634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610fe59190613496565b60ff168154811061100657634e487b7160e01b600052603260045260246000fd5b60009182526020822001546040516377ccc49d60e11b81526001600160a01b039091169250829063ef99893a90611045908d908d908d90600401613b43565b60206040518083038186803b15801561105d57600080fd5b505afa158015611071573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061109591906132cf565b905060ff831615806110aa5750836060015181115b156110ee576040518060800160405280836001600160a01b031681526020018a6001600160a01b03168152602001896001600160a01b031681526020018281525093505b505080806110fb90613ce2565b915050610f9e565b509695505050505050565b60048181548110610c9b57600080fd5b600081565b6040518060400160405280600981526020017f59616b526f75746572000000000000000000000000000000000000000000000081525081565b7f00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab181565b600061118a611d33565b90506111b67f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b6111d25760405162461bcd60e51b81526004016107f69061373c565b6002546040517fb2c853ac4d80d18d058c43d8018d077a036e542a79acae1647f5ad2a8c76f4e291611211916001600160a01b039091169085906135d0565b60405180910390a1506002805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6000611253611d33565b905061127f7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b61129b5760405162461bcd60e51b81526004016107f69061373c565b7f658ff1688002926d8f426cb10c052ec29003f50042df9652d8613484c1a58647826040516112ca9190613668565b60405180910390a18151610982906003906020850190612f07565b6112ee82610951565b6112f781611c9d565b6109828383611d37565b61271081565b610cdf7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab95826112e5565b600061133b611d33565b90506113677f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9582610f62565b6113835760405162461bcd60e51b81526004016107f69061373c565b610a5c6001600160a01b038316836000196116a0565b6113a1612f79565b6113a9612f79565b60005b60045460ff821610156114dc57600060048260ff16815481106113df57634e487b7160e01b600052603260045260246000fd5b60009182526020822001546040516377ccc49d60e11b81526001600160a01b039091169250829063ef99893a9061141e908b908b908b90600401613b43565b60206040518083038186803b15801561143657600080fd5b505afa15801561144a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061146e91906132cf565b905060ff831615806114835750836060015181115b156114c7576040518060800160405280836001600160a01b03168152602001886001600160a01b03168152602001876001600160a01b031681526020018281525093505b505080806114d490613ce2565b9150506113ac565b50949350505050565b6001600160a01b037f00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab11661151c6040850185613b9e565b600161152b6040880188613b9e565b611536929150613c6d565b81811061155357634e487b7160e01b600052603260045260246000fd5b90506020020160208101906115689190612ff4565b6001600160a01b03161461158e5760405162461bcd60e51b81526004016107f690613799565b600061159c84333085611dba565b90506115a7816125b9565b610cee60008285612653565b60006115bd611d33565b90506115ca600083610966565b610a5c600082610a1a565b7f339759585899103d2ace64958e37e18ccb0504652c81d4a1b8aa80fe2126ab9581565b6001600160a01b037f00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab1166116306040850185613b9e565b600081811061164f57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906116649190612ff4565b6001600160a01b03161461168a5760405162461bcd60e51b81526004016107f69061382b565b61169483356126c1565b610cee83308484611dba565b80158061174157506040517fdd62ed3e0000000000000000000000000000000000000000000000000000000081526001600160a01b0384169063dd62ed3e906116ef90309086906004016135d0565b60206040518083038186803b15801561170757600080fd5b505afa15801561171b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061173f91906132cf565b155b61175d5760405162461bcd60e51b81526004016107f690613979565b6109828363095ea7b360e01b848460405160240161177c92919061364f565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990931692909217909152612738565b6001600160e01b031981167f01ffc9a70000000000000000000000000000000000000000000000000000000014919050565b60408051602080825281830190925260609160208201818036833750505060208101929092525090565b60008061185c670de0b6b3a76400007f00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab1856002610afc565b90508060400151516000146118c05780518051633b9aca0091869161188390600190613c6d565b815181106118a157634e487b7160e01b600052603260045260246000fd5b60200260200101516118b39190613c4e565b6118bd9190613c2e565b91505b5092915050565b6118cf612edf565b60006118da846127ee565b9050600080841515816118ee8c8c8c611399565b9050806060015160001461199b57811561197a5780600001516001600160a01b03166369cff80d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561193f57600080fd5b505afa158015611953573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061197791906132cf565b92505b611993858260600151836000015184604001518761282e565b806060015193505b6001891180156119c657506119b160028a613c6d565b60208960200151516119c39190613c2e565b11155b15611c355760005b600354811015611c3357600381815481106119f957634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b038d811691161415611a1d57611c21565b6000611a5f8e8e60038581548110611a4557634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b0316611399565b9050806060015160001415611a745750611c21565b6000611a7f8b6127ee565b90508415611aff5781600001516001600160a01b03166369cff80d6040518163ffffffff1660e01b815260040160206040518083038186803b158015611ac457600080fd5b505afa158015611ad8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611afc91906132cf565b95505b611b18818360600151846000015185604001518a61282e565b611b5f826060015160038581548110611b4157634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b03168f8f858f6118c7565b90506000611b768260400151518360400151612a24565b82518051919250600091611b8991612a24565b9050816001600160a01b03168f6001600160a01b0316148015611bab57508881115b15611c1c57896060015183606001511115611c15576000633b9aca008b606001518560600151611bdb9190613c6d565b611be5908f613c4e565b611bef9190613c2e565b90506000611bfd8b84613c6d565b905080821115611c1257505050505050611c21565b50505b8098508299505b505050505b80611c2b81613cc7565b9150506119ce565b505b50929a9950505050505050505050565b611c4d612edf565b6040518060800160405280611c658460000151612a37565b8152602001611c778460200151612b0f565b8152602001611c898460400151612b0f565b815260200183606001518152509050919050565b610cdf81611ca9611d33565b612bdb565b611cb88282610f62565b610a5c576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055611cef611d33565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b3390565b611d418282610f62565b15610a5c576000828152602081815260408083206001600160a01b03851684529091529020805460ff19169055611d76611d33565b6001600160a01b0316816001600160a01b0316837ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b60405160405180910390a45050565b600080611dca6040870187613b9e565b905067ffffffffffffffff811115611df257634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611e1b578160200160208202803683370190505b5090506000831180611e2f57506000600154115b15611f0057611e3f863584612c3f565b81600081518110611e6057634e487b7160e01b600052603260045260246000fd5b6020908102919091010152611efb611e7b6040880188613b9e565b6000818110611e9a57634e487b7160e01b600052603260045260246000fd5b9050602002016020810190611eaf9190612ff4565b600254835188916001600160a01b0316908590600090611edf57634e487b7160e01b600052603260045260246000fd5b60200260200101518a60000135611ef69190613c6d565b612c84565b611f33565b856000013581600081518110611f2657634e487b7160e01b600052603260045260246000fd5b6020026020010181815250505b611fe7611f436040880188613b9e565b6000818110611f6257634e487b7160e01b600052603260045260246000fd5b9050602002016020810190611f779190612ff4565b86611f8560608a018a613b9e565b6000818110611fa457634e487b7160e01b600052603260045260246000fd5b9050602002016020810190611fb99190612ff4565b84600081518110611fda57634e487b7160e01b600052603260045260246000fd5b6020026020010151612c84565b60005b611ff76060880188613b9e565b90508110156121b85761200d6060880188613b9e565b8281811061202b57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906120409190612ff4565b6001600160a01b031663ef99893a83838151811061206e57634e487b7160e01b600052603260045260246000fd5b60200260200101518980604001906120869190613b9e565b858181106120a457634e487b7160e01b600052603260045260246000fd5b90506020020160208101906120b99190612ff4565b6120c660408c018c613b9e565b6120d1876001613c16565b8181106120ee57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906121039190612ff4565b6040518463ffffffff1660e01b815260040161212193929190613b43565b60206040518083038186803b15801561213957600080fd5b505afa15801561214d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061217191906132cf565b8261217d836001613c16565b8151811061219b57634e487b7160e01b600052603260045260246000fd5b6020908102919091010152806121b081613cc7565b915050611fea565b50856020013581600183516121cd9190613c6d565b815181106121eb57634e487b7160e01b600052603260045260246000fd5b602002602001015110156122115760405162461bcd60e51b81526004016107f69061391c565b60005b6122216060880188613b9e565b905081101561243c576000600161223b60608a018a613b9e565b612246929150613c6d565b8210612252578561229c565b61225f6060890189613b9e565b61226a846001613c16565b81811061228757634e487b7160e01b600052603260045260246000fd5b905060200201602081019061229c9190612ff4565b90506122ab6060890189613b9e565b838181106122c957634e487b7160e01b600052603260045260246000fd5b90506020020160208101906122de9190612ff4565b6001600160a01b031663eab90da684848151811061230c57634e487b7160e01b600052603260045260246000fd5b6020026020010151858560016123229190613c16565b8151811061234057634e487b7160e01b600052603260045260246000fd5b60200260200101518b80604001906123589190613b9e565b8781811061237657634e487b7160e01b600052603260045260246000fd5b905060200201602081019061238b9190612ff4565b61239860408e018e613b9e565b6123a3896001613c16565b8181106123c057634e487b7160e01b600052603260045260246000fd5b90506020020160208101906123d59190612ff4565b866040518663ffffffff1660e01b81526004016123f6959493929190613b70565b600060405180830381600087803b15801561241057600080fd5b505af1158015612424573d6000803e3d6000fd5b5050505050808061243490613cc7565b915050612214565b5061244a6040870187613b9e565b600161245960408a018a613b9e565b612464929150613c6d565b81811061248157634e487b7160e01b600052603260045260246000fd5b90506020020160208101906124969190612ff4565b6001600160a01b03166124ac6040880188613b9e565b60008181106124cb57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906124e09190612ff4565b6001600160a01b03167f9fc8352e52998db4087d5e6e1c1aafa38788e749e5d7a24f5cb230f7379544028860000135846001865161251e9190613c6d565b8151811061253c57634e487b7160e01b600052603260045260246000fd5b6020026020010151604051612552929190613b62565b60405180910390a380600182516125699190613c6d565b8151811061258757634e487b7160e01b600052603260045260246000fd5b6020026020010151915050949350505050565b6109828363a9059cbb60e01b848460405160240161177c92919061364f565b6040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526001600160a01b037f00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab11690632e1a7d4d9061261e908490600401613686565b600060405180830381600087803b15801561263857600080fd5b505af115801561264c573d6000803e3d6000fd5b5050505050565b306001600160a01b03821614610982576001600160a01b0383166126ad576040516001600160a01b0382169083156108fc029084906000818181858888f193505050501580156126a7573d6000803e3d6000fd5b50610982565b6109826001600160a01b038416828461259a565b7f00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab16001600160a01b031663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b15801561271c57600080fd5b505af1158015612730573d6000803e3d6000fd5b505050505050565b600080836001600160a01b031683604051612753919061351f565b6000604051808303816000865af19150503d8060008114612790576040519150601f19603f3d011682016040523d82523d6000602084013e612795565b606091505b5091509150816127b75760405162461bcd60e51b81526004016107f6906137f6565b805115610cee57808060200190518101906127d291906130e5565b610cee5760405162461bcd60e51b81526004016107f6906138bf565b6127f6612edf565b604051806080016040528083600001518152602001836020015181526020018360400151815260200183606001518152509050919050565b73a479b3af0476a9e605133975c1f0c414d0654d12632f9680f58660400151612856856117fa565b6040518363ffffffff1660e01b815260040161287392919061368f565b60006040518083038186803b15801561288b57600080fd5b505af415801561289f573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526128c79190810190613170565b6040860152845173a479b3af0476a9e605133975c1f0c414d0654d1290632f9680f5906128f3876117fa565b6040518363ffffffff1660e01b815260040161291092919061368f565b60006040518083038186803b15801561292857600080fd5b505af415801561293c573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526129649190810190613170565b8552602085015173a479b3af0476a9e605133975c1f0c414d0654d1290632f9680f590612990866117fa565b6040518363ffffffff1660e01b81526004016129ad92919061368f565b60006040518083038186803b1580156129c557600080fd5b505af41580156129d9573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612a019190810190613170565b6020860152606085018051829190612a1a908390613c16565b9052505050505050565b6000612a308383612cc2565b9392505050565b6060600060208351612a499190613c2e565b905060008167ffffffffffffffff811115612a7457634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612a9d578160200160208202803683370190505b50905060005b82811015612b0757612aca612ab9826020613c4e565b612ac4906020613c16565b86612a24565b828281518110612aea57634e487b7160e01b600052603260045260246000fd5b602090810291909101015280612aff81613cc7565b915050612aa3565b509392505050565b6060600060208351612b219190613c2e565b905060008167ffffffffffffffff811115612b4c57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612b75578160200160208202803683370190505b50905060005b82811015612b0757612b91612ab9826020613c4e565b828281518110612bb157634e487b7160e01b600052603260045260246000fd5b6001600160a01b039092166020928302919091019091015280612bd381613cc7565b915050612b7b565b612be58282610f62565b610a5c57612bfd816001600160a01b03166014612cc7565b612c08836020612cc7565b604051602001612c1992919061353b565b60408051601f198184030181529082905262461bcd60e51b82526107f6916004016136bd565b6000600154821015612c635760405162461bcd60e51b81526004016107f690613888565b612710612c708382613c6d565b612c7a9085613c4e565b612a309190613c2e565b6001600160a01b0383163014612cae57612ca96001600160a01b038516848484612ebe565b610cee565b610cee6001600160a01b038516838361259a565b015190565b60606000612cd6836002613c4e565b612ce1906002613c16565b67ffffffffffffffff811115612d0757634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612d31576020820181803683370190505b5090507f300000000000000000000000000000000000000000000000000000000000000081600081518110612d7657634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110612dcf57634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a9053506000612df3846002613c4e565b612dfe906001613c16565b90505b6001811115612e9f577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110612e4d57634e487b7160e01b600052603260045260246000fd5b1a60f81b828281518110612e7157634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535060049490941c93612e9881613cb0565b9050612e01565b508315612a305760405162461bcd60e51b81526004016107f6906136d0565b610cee846323b872dd60e01b85858560405160240161177c939291906135ea565b6040518060800160405280606081526020016060815260200160608152602001600081525090565b828054828255906000526020600020908101928215612f69579160200282015b82811115612f69578251825473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b03909116178255602090920191600190910190612f27565b50612f75929150612fa0565b5090565b60408051608081018252600080825260208201819052918101829052606081019190915290565b5b80821115612f755760008155600101612fa1565b80356001600160a01b03811681146107bd57600080fd5b600060808284031215612fdd578081fd5b50919050565b803560ff811681146107bd57600080fd5b600060208284031215613005578081fd5b612a3082612fb5565b60008060408385031215613020578081fd5b61302983612fb5565b946020939093013593505050565b60006020808385031215613049578182fd5b823567ffffffffffffffff80821115613060578384fd5b818501915085601f830112613073578384fd5b81358181111561308557613085613d18565b8381029150613095848301613bec565b8181528481019084860184860187018a10156130af578788fd5b8795505b838610156130d8576130c481612fb5565b8352600195909501949186019186016130b3565b5098975050505050505050565b6000602082840312156130f6578081fd5b81518015158114612a30578182fd5b600060208284031215613116578081fd5b5035919050565b6000806040838503121561312f578182fd5b8235915061313f60208401612fb5565b90509250929050565b600060208284031215613159578081fd5b81356001600160e01b031981168114612a30578182fd5b600060208284031215613181578081fd5b815167ffffffffffffffff80821115613198578283fd5b818401915084601f8301126131ab578283fd5b8151818111156131bd576131bd613d18565b6131d0601f8201601f1916602001613bec565b91508082528560208285010111156131e6578384fd5b6114dc816020840160208601613c84565b60008060006060848603121561320b578081fd5b833567ffffffffffffffff811115613221578182fd5b61322d86828701612fcc565b93505061323c60208501612fb5565b9150604084013590509250925092565b600080600080600080600060e0888a031215613266578283fd5b873567ffffffffffffffff81111561327c578384fd5b6132888a828b01612fcc565b97505061329760208901612fb5565b955060408801359450606088013593506132b360808901612fe3565b925060a0880135915060c0880135905092959891949750929550565b6000602082840312156132e0578081fd5b5051919050565b6000806000606084860312156132fb578081fd5b8335925061330b60208501612fb5565b915061331960408501612fb5565b90509250925092565b600080600080600060808688031215613339578283fd5b8535945061334960208701612fb5565b935061335760408701612fb5565b9250606086013567ffffffffffffffff80821115613373578283fd5b818801915088601f830112613386578283fd5b813581811115613394578384fd5b89602080830285010111156133a7578384fd5b9699959850939650602001949392505050565b600080600080608085870312156133cf578182fd5b843593506133df60208601612fb5565b92506133ed60408601612fb5565b9396929550929360600135925050565b600080600080600060a08688031215613414578283fd5b8535945061342460208701612fb5565b935061343260408701612fb5565b94979396509394606081013594506080013592915050565b6000806000806080858703121561345f578182fd5b8435935061346f60208601612fb5565b925061347d60408601612fb5565b915061348b60608601612fe3565b905092959194509250565b6000602082840312156134a7578081fd5b612a3082612fe3565b6000815180845260208085019450808401835b838110156134e85781516001600160a01b0316875295820195908201906001016134c3565b509495945050505050565b6000815180845261350b816020860160208601613c84565b601f01601f19169290920160200192915050565b60008251613531818460208701613c84565b9190910192915050565b60007f416363657373436f6e74726f6c3a206163636f756e742000000000000000000082528351613573816017850160208801613c84565b7f206973206d697373696e6720726f6c652000000000000000000000000000000060179184019182015283516135b0816028840160208801613c84565b01602801949350505050565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b0397881681529590961660208601526040850193909352606084019190915260ff16608083015260a082015260c081019190915260e00190565b6001600160a01b03929092168252602082015260400190565b600060208252612a3060208301846134b0565b901515815260200190565b90815260200190565b6000604082526136a260408301856134f3565b82810360208401526136b481856134f3565b95945050505050565b600060208252612a3060208301846134f3565b6020808252818101527f537472696e67733a20686578206c656e67746820696e73756666696369656e74604082015260600190565b6020808252601c908201527f59616b526f757465723a20496e76616c6964206d61782d737465707300000000604082015260600190565b60208082526028908201527f4d61696e7461696e61626c653a2043616c6c6572206973206e6f742061206d6160408201527f696e7461696e6572000000000000000000000000000000000000000000000000606082015260800190565b60208082526027908201527f59616b526f757465723a2050617468206e6565647320746f20656e642077697460408201527f6820574156415800000000000000000000000000000000000000000000000000606082015260800190565b6020808252818101527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604082015260600190565b60208082526029908201527f59616b526f757465723a2050617468206e6565647320746f20626567696e207760408201527f6974682057415641580000000000000000000000000000000000000000000000606082015260800190565b6020808252601b908201527f59616b526f757465723a20496e73756666696369656e74206665650000000000604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60408201527f6f74207375636365656400000000000000000000000000000000000000000000606082015260800190565b60208082526025908201527f59616b526f757465723a20496e73756666696369656e74206f7574707574206160408201527f6d6f756e74000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526036908201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60408201527f20746f206e6f6e2d7a65726f20616c6c6f77616e636500000000000000000000606082015260800190565b6020808252602f908201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560408201527f20726f6c657320666f722073656c660000000000000000000000000000000000606082015260800190565b6020808252601d908201527f59616b526f757465723a204e6f7468696e6720746f207265636f766572000000604082015260600190565b60208082528251608083830152805160a0840181905260009291820190839060c08601905b80831015613aaf5783518252928401926001929092019190840190613a8f565b50838701519350601f19925082868203016040870152613acf81856134b0565b93505050604085015181858403016060860152613aec83826134b0565b92505050606084015160808401528091505092915050565b60006080820190506001600160a01b03808451168352806020850151166020840152806040850151166040840152506060830151606083015292915050565b9283526001600160a01b03918216602084015216604082015260600190565b918252602082015260400190565b94855260208501939093526001600160a01b0391821660408501528116606084015216608082015260a00190565b6000808335601e19843603018112613bb4578283fd5b83018035915067ffffffffffffffff821115613bce578283fd5b6020908101925081023603821315613be557600080fd5b9250929050565b60405181810167ffffffffffffffff81118282101715613c0e57613c0e613d18565b604052919050565b60008219821115613c2957613c29613d02565b500190565b600082613c4957634e487b7160e01b81526012600452602481fd5b500490565b6000816000190483118215151615613c6857613c68613d02565b500290565b600082821015613c7f57613c7f613d02565b500390565b60005b83811015613c9f578181015183820152602001613c87565b83811115610cee5750506000910152565b600081613cbf57613cbf613d02565b506000190190565b6000600019821415613cdb57613cdb613d02565b5060010190565b600060ff821660ff811415613cf957613cf9613d02565b60010192915050565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052604160045260246000fdfea26469706673582212204c7a4b7fd280c461df3aa9d43d9ce97c3b1647b0631cc4f7d74c2e83c5199bc564736f6c63430008000033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000340000000000000000000000000d22044706dea3c342f68396bedbcf6a2536d951d00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab10000000000000000000000000000000000000000000000000000000000000015000000000000000000000000cd887f78c77b36b0b541e77afd6f91c0253182a20000000000000000000000009b96595298a1ba7b6c389f217d55896960bbb4ae000000000000000000000000985d014da6e6c781ec3ff77e8fd48c30174f3d9600000000000000000000000081544acdbcffdc9c0a265cfb220408e1e85aa43d000000000000000000000000bf042126c0c0d2c658915c2d21922d3440092f48000000000000000000000000784e00cd961a994eff675e889af6ca564689bf390000000000000000000000005f030dc08eea2abfcc497f3c5351746dac971ad20000000000000000000000001d3e01bd14214fe3cd10904690dfa908c23b37a1000000000000000000000000b60ce5bf2a231eda70825f9cdcd0795102218ab00000000000000000000000004aff45ce2e48c159147fa7dd5b436cafd9688eba0000000000000000000000008fc296f44017b50ccaafb2e002d590c2e09873630000000000000000000000003b2378a29f9cbdb1f20a72611c0f000af05630cb000000000000000000000000610460dab540dae1eb84c22ea97866bfc0482c3f000000000000000000000000c5b9041f9748a9a4437ba90f9806ce8c3f9085fc000000000000000000000000fcfa6855b3e79f1c3ae4314cc0e85f37dfa14b3f0000000000000000000000000fdf64b6746ba759d120e973c85349a8b9cde8d40000000000000000000000004a6c794192831fb9f4782e61bec05d6c5cc9f3ea000000000000000000000000e483b8c8ab7659fbaa2603b963bda50fb1a8103c0000000000000000000000009f7e365a57c6baeae94870ffbb0af92209a9f4d00000000000000000000000009d609ad3c673e2ddb3047c3f3b3efa2ce14eb43600000000000000000000000019eb54ccb443aced9dcbc960ba98064a13262ef3000000000000000000000000000000000000000000000000000000000000000500000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab10000000000000000000000002f2a2543b76a4166549f7aab2e75bef0aefc5b0f000000000000000000000000ff970a61a04b1ca14834a43f5de4533ebddb5cc8000000000000000000000000fd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9000000000000000000000000da10009cbd5d07dd0cecc66161fc93d7c9000da1
-----Decoded View---------------
Arg [0] : _adapters (address[]): 0xCd887F78c77b36B0b541E77AfD6F91C0253182A2,0x9b96595298a1Ba7b6c389f217d55896960BBB4AE,0x985d014DA6e6C781ec3FF77E8Fd48c30174F3d96,0x81544aCDBcFfdc9c0A265CFB220408E1E85AA43D,0xbf042126c0C0D2c658915C2d21922D3440092F48,0x784E00Cd961a994eff675E889AF6CA564689BF39,0x5F030dC08EeA2AbFcc497f3c5351746daC971ad2,0x1d3E01bD14214fE3cd10904690DFa908C23b37A1,0xb60CE5bF2A231EDA70825f9cdcD0795102218ab0,0x4aFF45Ce2E48C159147fa7Dd5b436CafD9688eba,0x8Fc296F44017B50ccaAfB2E002d590C2E0987363,0x3b2378a29F9CbDb1f20A72611C0f000aF05630cb,0x610460dAB540dAE1eb84C22ea97866BFc0482c3F,0xc5b9041F9748A9A4437Ba90f9806cE8c3F9085Fc,0xFCFa6855b3E79f1c3ae4314cC0e85f37DfA14B3F,0x0FdF64B6746BA759d120e973C85349a8B9CdE8D4,0x4a6c794192831fB9F4782E61Bec05d6C5cC9F3eA,0xe483B8C8ab7659FbaA2603B963bdA50FB1a8103C,0x9F7e365a57c6baeae94870ffbb0aF92209a9f4d0,0x9D609aD3c673E2ddB3047C3F3B3efa2Ce14EB436,0x19eb54ccB443aCED9dcbC960bA98064A13262Ef3
Arg [1] : _trustedTokens (address[]): 0x82aF49447D8a07e3bd95BD0d56f35241523fBab1,0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f,0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8,0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9,0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1
Arg [2] : _feeClaimer (address): 0xd22044706DeA3c342f68396bEDBCf6a2536d951D
Arg [3] : _wrapped_native (address): 0x82aF49447D8a07e3bd95BD0d56f35241523fBab1
-----Encoded View---------------
32 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000080
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000340
Arg [2] : 000000000000000000000000d22044706dea3c342f68396bedbcf6a2536d951d
Arg [3] : 00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab1
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000015
Arg [5] : 000000000000000000000000cd887f78c77b36b0b541e77afd6f91c0253182a2
Arg [6] : 0000000000000000000000009b96595298a1ba7b6c389f217d55896960bbb4ae
Arg [7] : 000000000000000000000000985d014da6e6c781ec3ff77e8fd48c30174f3d96
Arg [8] : 00000000000000000000000081544acdbcffdc9c0a265cfb220408e1e85aa43d
Arg [9] : 000000000000000000000000bf042126c0c0d2c658915c2d21922d3440092f48
Arg [10] : 000000000000000000000000784e00cd961a994eff675e889af6ca564689bf39
Arg [11] : 0000000000000000000000005f030dc08eea2abfcc497f3c5351746dac971ad2
Arg [12] : 0000000000000000000000001d3e01bd14214fe3cd10904690dfa908c23b37a1
Arg [13] : 000000000000000000000000b60ce5bf2a231eda70825f9cdcd0795102218ab0
Arg [14] : 0000000000000000000000004aff45ce2e48c159147fa7dd5b436cafd9688eba
Arg [15] : 0000000000000000000000008fc296f44017b50ccaafb2e002d590c2e0987363
Arg [16] : 0000000000000000000000003b2378a29f9cbdb1f20a72611c0f000af05630cb
Arg [17] : 000000000000000000000000610460dab540dae1eb84c22ea97866bfc0482c3f
Arg [18] : 000000000000000000000000c5b9041f9748a9a4437ba90f9806ce8c3f9085fc
Arg [19] : 000000000000000000000000fcfa6855b3e79f1c3ae4314cc0e85f37dfa14b3f
Arg [20] : 0000000000000000000000000fdf64b6746ba759d120e973c85349a8b9cde8d4
Arg [21] : 0000000000000000000000004a6c794192831fb9f4782e61bec05d6c5cc9f3ea
Arg [22] : 000000000000000000000000e483b8c8ab7659fbaa2603b963bda50fb1a8103c
Arg [23] : 0000000000000000000000009f7e365a57c6baeae94870ffbb0af92209a9f4d0
Arg [24] : 0000000000000000000000009d609ad3c673e2ddb3047c3f3b3efa2ce14eb436
Arg [25] : 00000000000000000000000019eb54ccb443aced9dcbc960ba98064a13262ef3
Arg [26] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [27] : 00000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab1
Arg [28] : 0000000000000000000000002f2a2543b76a4166549f7aab2e75bef0aefc5b0f
Arg [29] : 000000000000000000000000ff970a61a04b1ca14834a43f5de4533ebddb5cc8
Arg [30] : 000000000000000000000000fd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9
Arg [31] : 000000000000000000000000da10009cbd5d07dd0cecc66161fc93d7c9000da1
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.