Overview
ETH Balance
0 ETH
Eth Value
$0.00Token Holdings
More Info
Private Name Tags
ContractCreator
Latest 1 from a total of 1 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
0x60086101 | 12792553 | 1188 days ago | IN | 0 ETH | 0.03656889 |
Latest 25 internal transactions (View All)
Advanced mode:
Parent Transaction Hash | Block | From | To | |||
---|---|---|---|---|---|---|
20927216 | 28 mins ago | 2 ETH | ||||
20927216 | 28 mins ago | 2 ETH | ||||
20927190 | 33 mins ago | 3.16611253 ETH | ||||
20927190 | 33 mins ago | 3.16611253 ETH | ||||
20926048 | 4 hrs ago | 0.5 ETH | ||||
20926048 | 4 hrs ago | 0.5 ETH | ||||
20925820 | 5 hrs ago | 0.1917 ETH | ||||
20925820 | 5 hrs ago | 0.1917 ETH | ||||
20925748 | 5 hrs ago | 0.2013 ETH | ||||
20925748 | 5 hrs ago | 0.2013 ETH | ||||
20925723 | 5 hrs ago | 0.42990812 ETH | ||||
20925723 | 5 hrs ago | 0.42990812 ETH | ||||
20925674 | 5 hrs ago | 0.26518858 ETH | ||||
20925674 | 5 hrs ago | 0.26518858 ETH | ||||
20925518 | 6 hrs ago | 0.26450524 ETH | ||||
20925518 | 6 hrs ago | 0.26450524 ETH | ||||
20925055 | 7 hrs ago | 0.5 ETH | ||||
20925055 | 7 hrs ago | 0.5 ETH | ||||
20924950 | 8 hrs ago | 0.4016703 ETH | ||||
20924950 | 8 hrs ago | 0.4016703 ETH | ||||
20924797 | 8 hrs ago | 0.10843558 ETH | ||||
20924797 | 8 hrs ago | 0.10843558 ETH | ||||
20924769 | 8 hrs ago | 0.387 ETH | ||||
20924769 | 8 hrs ago | 0.387 ETH | ||||
20924675 | 8 hrs ago | 4.25 ETH |
Loading...
Loading
Contract Name:
RFQ
Compiler Version
v0.6.12+commit.27d51765
Optimization Enabled:
Yes with 1000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
pragma solidity ^0.6.0; pragma experimental ABIEncoderV2; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/token/ERC20/SafeERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/utils/ReentrancyGuard.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "./interfaces/ISpender.sol"; import "./interfaces/IWeth.sol"; import "./interfaces/IRFQ.sol"; import "./interfaces/IPermanentStorage.sol"; import "./interfaces/IERC1271Wallet.sol"; import "./utils/RFQLibEIP712.sol"; contract RFQ is ReentrancyGuard, IRFQ, RFQLibEIP712, SignatureValidator { using SafeMath for uint256; using SafeERC20 for IERC20; using Address for address; // Constants do not have storage slot. string public constant version = "5.2.0"; uint256 private constant MAX_UINT = 2**256 - 1; string public constant SOURCE = "RFQ v1"; uint256 private constant BPS_MAX = 10000; address public immutable userProxy; IPermanentStorage public immutable permStorage; IWETH public immutable weth; // Below are the variables which consume storage slots. address public operator; ISpender public spender; struct GroupedVars { bytes32 orderHash; bytes32 transactionHash; } // Operator events event TransferOwnership(address newOperator); event UpgradeSpender(address newSpender); event AllowTransfer(address spender); event DisallowTransfer(address spender); event DepositETH(uint256 ethBalance); event FillOrder( string source, bytes32 indexed transactionHash, bytes32 indexed orderHash, address indexed userAddr, address takerAssetAddr, uint256 takerAssetAmount, address makerAddr, address makerAssetAddr, uint256 makerAssetAmount, address receiverAddr, uint256 settleAmount, uint16 feeFactor ); receive() external payable {} /************************************************************ * Access control and ownership management * *************************************************************/ modifier onlyOperator { require(operator == msg.sender, "RFQ: not operator"); _; } modifier onlyUserProxy() { require(address(userProxy) == msg.sender, "RFQ: not the UserProxy contract"); _; } function transferOwnership(address _newOperator) external onlyOperator { require(_newOperator != address(0), "RFQ: operator can not be zero address"); operator = _newOperator; emit TransferOwnership(_newOperator); } /************************************************************ * Constructor and init functions * *************************************************************/ constructor ( address _operator, address _userProxy, ISpender _spender, IPermanentStorage _permStorage, IWETH _weth ) public { operator = _operator; userProxy = _userProxy; spender = _spender; permStorage = _permStorage; weth = _weth; } /************************************************************ * Management functions for Operator * *************************************************************/ /** * @dev set new Spender */ function upgradeSpender(address _newSpender) external onlyOperator { require(_newSpender != address(0), "RFQ: spender can not be zero address"); spender = ISpender(_newSpender); emit UpgradeSpender(_newSpender); } /** * @dev approve spender to transfer tokens from this contract. This is used to collect fee. */ function setAllowance(address[] calldata _tokenList, address _spender) override external onlyOperator { for (uint256 i = 0 ; i < _tokenList.length; i++) { IERC20(_tokenList[i]).safeApprove(_spender, MAX_UINT); emit AllowTransfer(_spender); } } function closeAllowance(address[] calldata _tokenList, address _spender) override external onlyOperator { for (uint256 i = 0 ; i < _tokenList.length; i++) { IERC20(_tokenList[i]).safeApprove(_spender, 0); emit DisallowTransfer(_spender); } } /** * @dev convert collected ETH to WETH */ function depositETH() external onlyOperator { uint256 balance = address(this).balance; if (balance > 0) { weth.deposit{value: balance}(); emit DepositETH(balance); } } /************************************************************ * External functions * *************************************************************/ function fill( RFQLibEIP712.Order memory _order, bytes memory _mmSignature, bytes memory _userSignature ) override payable external nonReentrant onlyUserProxy returns (uint256) { // check the order deadline and fee factor require(_order.deadline >= block.timestamp, "RFQ: expired order"); require(_order.feeFactor < BPS_MAX, "RFQ: invalid fee factor"); GroupedVars memory vars; // Validate signatures vars.orderHash = _getOrderHash(_order); require( isValidSignature( _order.makerAddr, _getOrderSignDigestFromHash(vars.orderHash), bytes(""), _mmSignature ), "RFQ: invalid MM signature" ); vars.transactionHash = _getTransactionHash(_order); require( isValidSignature( _order.takerAddr, _getTransactionSignDigestFromHash(vars.transactionHash), bytes(""), _userSignature ), "RFQ: invalid user signature" ); // Set transaction as seen, PermanentStorage would throw error if transaction already seen. permStorage.setRFQTransactionSeen(vars.transactionHash); // Deposit to WETH if taker asset is ETH, else transfer from user if (address(weth) == _order.takerAssetAddr) { require( msg.value == _order.takerAssetAmount, "RFQ: insufficient ETH" ); weth.deposit{value: msg.value}(); } else { spender.spendFromUser(_order.takerAddr, _order.takerAssetAddr, _order.takerAssetAmount); } // Transfer from maker spender.spendFromUser(_order.makerAddr, _order.makerAssetAddr, _order.makerAssetAmount); // settle token/ETH to user return _settle(_order, vars); } // settle function _settle( RFQLibEIP712.Order memory _order, GroupedVars memory _vars ) internal returns(uint256) { // Transfer taker asset to maker IERC20(_order.takerAssetAddr).safeTransfer(_order.makerAddr, _order.takerAssetAmount); // Transfer maker asset to taker, sub fee uint256 settleAmount = _order.makerAssetAmount; if (_order.feeFactor > 0) { // settleAmount = settleAmount * (10000 - feeFactor) / 10000 settleAmount = settleAmount.mul((BPS_MAX).sub(_order.feeFactor)).div(BPS_MAX); } // Transfer token/Eth to receiver if (_order.makerAssetAddr == address(weth)){ weth.withdraw(settleAmount); payable(_order.receiverAddr).transfer(settleAmount); } else { IERC20(_order.makerAssetAddr).safeTransfer(_order.receiverAddr, settleAmount); } emit FillOrder( SOURCE, _vars.transactionHash, _vars.orderHash, _order.takerAddr, _order.takerAssetAddr, _order.takerAssetAmount, _order.makerAddr, _order.makerAssetAddr, _order.makerAssetAmount, _order.receiverAddr, settleAmount, uint16(_order.feeFactor) ); return settleAmount; } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; import "./IERC20.sol"; import "../../math/SafeMath.sol"; import "../../utils/Address.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 IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using SafeMath for uint256; using Address for address; 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)); } /** * @dev Deprecated. This function has issues similar to the ones found in * {IERC20-approve}, and its usage is discouraged. * * Whenever possible, use {safeIncreaseAllowance} and * {safeDecreaseAllowance} instead. */ 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)); } function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 newAllowance = token.allowance(address(this), spender).add(value); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeERC20: decreased allowance below zero"); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } /** * @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. We use {Address.functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data, "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"); } } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; /** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming languages. * `SafeMath` restores this intuition by reverting the transaction when an * operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { if (b > a) return (false, 0); return (true, a - b); } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { if (b == 0) return (false, 0); return (true, a / b); } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { if (b == 0) return (false, 0); return (true, a % b); } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "SafeMath: addition overflow"); return c; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { require(b <= a, "SafeMath: subtraction overflow"); return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { if (a == 0) return 0; uint256 c = a * b; require(c / a == b, "SafeMath: multiplication overflow"); return c; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { require(b > 0, "SafeMath: division by zero"); return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { require(b > 0, "SafeMath: modulo by zero"); return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b <= a, errorMessage); return a - b; } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryDiv}. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b > 0, errorMessage); return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b > 0, errorMessage); return a % b; } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor () internal { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and make it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.2 <0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; // solhint-disable-next-line no-inline-assembly assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); // solhint-disable-next-line avoid-low-level-calls, avoid-call-value (bool success, ) = recipient.call{ value: amount }(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain`call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returndata) = target.call{ value: value }(data); return _verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returndata) = target.staticcall(data); return _verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returndata) = target.delegatecall(data); return _verifyCallResult(success, returndata, errorMessage); } function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly // solhint-disable-next-line no-inline-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
pragma solidity ^0.6.0; interface ISpender { function spendFromUser(address _user, address _tokenAddr, uint256 _amount) external; function spendFromUserTo(address _user, address _tokenAddr, address _receiverAddr, uint256 _amount) external; }
pragma solidity ^0.6.0; interface IWETH { function balanceOf(address account) external view returns (uint256); function deposit() external payable; function withdraw(uint256 amount) external; function transferFrom(address src, address dst, uint wad) external returns (bool); }
pragma solidity ^0.6.0; pragma experimental ABIEncoderV2; import "../utils/RFQLibEIP712.sol"; import "./ISetAllowance.sol"; interface IRFQ is ISetAllowance { function fill( RFQLibEIP712.Order memory _order, bytes memory _mmSignature, bytes memory _userSignature ) external payable returns (uint256); }
pragma solidity ^0.6.0; interface IPermanentStorage { function wethAddr() external view returns (address); function getCurvePoolInfo(address _makerAddr, address _takerAssetAddr, address _makerAssetAddr) external view returns (int128 takerAssetIndex, int128 makerAssetIndex, uint16 swapMethod, bool supportGetDx); function setCurvePoolInfo(address _makerAddr, address[] calldata _underlyingCoins, address[] calldata _coins, bool _supportGetDx) external; function isTransactionSeen(bytes32 _transactionHash) external view returns (bool); // Kept for backward compatability. Should be removed from AMM 5.2.1 upward function isAMMTransactionSeen(bytes32 _transactionHash) external view returns (bool); function isRFQTransactionSeen(bytes32 _transactionHash) external view returns (bool); function isRelayerValid(address _relayer) external view returns (bool); function setTransactionSeen(bytes32 _transactionHash) external; // Kept for backward compatability. Should be removed from AMM 5.2.1 upward function setAMMTransactionSeen(bytes32 _transactionHash) external; function setRFQTransactionSeen(bytes32 _transactionHash) external; function setRelayersValid(address[] memory _relayers, bool[] memory _isValids) external; }
pragma solidity ^0.6.0; interface IERC1271Wallet { /** * @notice Verifies whether the provided signature is valid with respect to the provided data * @dev MUST return the correct magic value if the signature provided is valid for the provided data * > The bytes4 magic value to return when signature is valid is 0x20c13b0b : bytes4(keccak256("isValidSignature(bytes,bytes)") * > This function MAY modify Ethereum's state * @param _data Arbitrary length data signed on the behalf of address(this) * @param _signature Signature byte array associated with _data * @return magicValue Magic value 0x20c13b0b if the signature is valid and 0x0 otherwise * */ function isValidSignature( bytes calldata _data, bytes calldata _signature) external view returns (bytes4 magicValue); /** * @notice Verifies whether the provided signature is valid with respect to the provided hash * @dev MUST return the correct magic value if the signature provided is valid for the provided hash * > The bytes4 magic value to return when signature is valid is 0x20c13b0b : bytes4(keccak256("isValidSignature(bytes,bytes)") * > This function MAY modify Ethereum's state * @param _hash keccak256 hash that was signed * @param _signature Signature byte array associated with _data * @return magicValue Magic value 0x20c13b0b if the signature is valid and 0x0 otherwise */ function isValidSignature( bytes32 _hash, bytes calldata _signature) external view returns (bytes4 magicValue); }
pragma solidity ^0.6.0; import "./BaseLibEIP712.sol"; import "./SignatureValidator.sol"; contract RFQLibEIP712 is BaseLibEIP712 { /***********************************| | Constants | |__________________________________*/ struct Order { address takerAddr; address makerAddr; address takerAssetAddr; address makerAssetAddr; uint256 takerAssetAmount; uint256 makerAssetAmount; address receiverAddr; uint256 salt; uint256 deadline; uint256 feeFactor; } bytes32 public constant ORDER_TYPEHASH = keccak256( abi.encodePacked( "Order(", "address takerAddr,", "address makerAddr,", "address takerAssetAddr,", "address makerAssetAddr,", "uint256 takerAssetAmount,", "uint256 makerAssetAmount,", "uint256 salt,", "uint256 deadline,", "uint256 feeFactor", ")" ) ); function _getOrderHash(Order memory _order) internal pure returns (bytes32 orderHash) { orderHash = keccak256( abi.encode( ORDER_TYPEHASH, _order.takerAddr, _order.makerAddr, _order.takerAssetAddr, _order.makerAssetAddr, _order.takerAssetAmount, _order.makerAssetAmount, _order.salt, _order.deadline, _order.feeFactor ) ); } function _getOrderSignDigest(Order memory _order) internal view returns (bytes32 orderSignDigest) { orderSignDigest = keccak256( abi.encodePacked( EIP191_HEADER, EIP712_DOMAIN_SEPARATOR, _getOrderHash(_order) ) ); } function _getOrderSignDigestFromHash(bytes32 _orderHash) internal view returns (bytes32 orderSignDigest) { orderSignDigest = keccak256( abi.encodePacked( EIP191_HEADER, EIP712_DOMAIN_SEPARATOR, _orderHash ) ); } bytes32 public constant FILL_WITH_PERMIT_TYPEHASH = keccak256( abi.encodePacked( "fillWithPermit(", "address makerAddr,", "address takerAssetAddr,", "address makerAssetAddr,", "uint256 takerAssetAmount,", "uint256 makerAssetAmount,", "address takerAddr,", "address receiverAddr,", "uint256 salt,", "uint256 deadline,", "uint256 feeFactor", ")" ) ); function _getTransactionHash(Order memory _order) internal pure returns(bytes32 transactionHash) { transactionHash = keccak256( abi.encode( FILL_WITH_PERMIT_TYPEHASH, _order.makerAddr, _order.takerAssetAddr, _order.makerAssetAddr, _order.takerAssetAmount, _order.makerAssetAmount, _order.takerAddr, _order.receiverAddr, _order.salt, _order.deadline, _order.feeFactor ) ); } function _getTransactionSignDigest(Order memory _order) internal view returns (bytes32 transactionSignDigest) { transactionSignDigest = keccak256( abi.encodePacked( EIP191_HEADER, EIP712_DOMAIN_SEPARATOR, _getTransactionHash(_order) ) ); } function _getTransactionSignDigestFromHash(bytes32 _txHash) internal view returns (bytes32 transactionSignDigest) { transactionSignDigest = keccak256( abi.encodePacked( EIP191_HEADER, EIP712_DOMAIN_SEPARATOR, _txHash ) ); } }
pragma solidity ^0.6.0; interface ISetAllowance { function setAllowance(address[] memory tokenList, address spender) external; function closeAllowance(address[] memory tokenList, address spender) external; }
pragma solidity ^0.6.0; contract BaseLibEIP712 { /***********************************| | Constants | |__________________________________*/ // EIP-191 Header string public constant EIP191_HEADER = "\x19\x01"; // EIP712Domain string public constant EIP712_DOMAIN_NAME = "Tokenlon"; string public constant EIP712_DOMAIN_VERSION = "v5"; // EIP712Domain Separator bytes32 public immutable EIP712_DOMAIN_SEPARATOR = keccak256( abi.encode( keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"), keccak256(bytes(EIP712_DOMAIN_NAME)), keccak256(bytes(EIP712_DOMAIN_VERSION)), getChainID(), address(this) ) ); /** * @dev Return `chainId` */ function getChainID() internal pure returns (uint) { uint chainId; assembly { chainId := chainid() } return chainId; } }
pragma solidity ^0.6.0; import "../interfaces/IERC1271Wallet.sol"; import "./LibBytes.sol"; interface IWallet { /// @dev Verifies that a signature is valid. /// @param hash Message hash that is signed. /// @param signature Proof of signing. /// @return isValid Validity of order signature. function isValidSignature( bytes32 hash, bytes memory signature ) external view returns (bool isValid); } /** * @dev Contains logic for signature validation. * Signatures from wallet contracts assume ERC-1271 support (https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1271.md) * Notes: Methods are strongly inspired by contracts in https://github.com/0xProject/0x-monorepo/blob/development/ */ contract SignatureValidator { using LibBytes for bytes; /***********************************| | Variables | |__________________________________*/ // bytes4(keccak256("isValidSignature(bytes,bytes)")) bytes4 constant internal ERC1271_MAGICVALUE = 0x20c13b0b; // bytes4(keccak256("isValidSignature(bytes32,bytes)")) bytes4 constant internal ERC1271_MAGICVALUE_BYTES32 = 0x1626ba7e; // keccak256("isValidWalletSignature(bytes32,address,bytes)") bytes4 constant internal ERC1271_FALLBACK_MAGICVALUE_BYTES32 = 0xb0671381; // Allowed signature types. enum SignatureType { Illegal, // 0x00, default value Invalid, // 0x01 EIP712, // 0x02 EthSign, // 0x03 WalletBytes, // 0x04 standard 1271 wallet type WalletBytes32, // 0x05 standard 1271 wallet type Wallet, // 0x06 0x wallet type for signature compatibility NSignatureTypes // 0x07, number of signature types. Always leave at end. } /***********************************| | Signature Functions | |__________________________________*/ /** * @dev Verifies that a hash has been signed by the given signer. * @param _signerAddress Address that should have signed the given hash. * @param _hash Hash of the EIP-712 encoded data * @param _data Full EIP-712 data structure that was hashed and signed * @param _sig Proof that the hash has been signed by signer. * For non wallet signatures, _sig is expected to be an array tightly encoded as * (bytes32 r, bytes32 s, uint8 v, uint256 nonce, SignatureType sigType) * @return isValid True if the address recovered from the provided signature matches the input signer address. */ function isValidSignature( address _signerAddress, bytes32 _hash, bytes memory _data, bytes memory _sig ) public view returns (bool isValid) { require( _sig.length > 0, "SignatureValidator#isValidSignature: length greater than 0 required" ); require( _signerAddress != address(0x0), "SignatureValidator#isValidSignature: invalid signer" ); // Pop last byte off of signature byte array. uint8 signatureTypeRaw = uint8(_sig.popLastByte()); // Ensure signature is supported require( signatureTypeRaw < uint8(SignatureType.NSignatureTypes), "SignatureValidator#isValidSignature: unsupported signature" ); // Extract signature type SignatureType signatureType = SignatureType(signatureTypeRaw); // Variables are not scoped in Solidity. uint8 v; bytes32 r; bytes32 s; address recovered; // Always illegal signature. // This is always an implicit option since a signer can create a // signature array with invalid type or length. We may as well make // it an explicit option. This aids testing and analysis. It is // also the initialization value for the enum type. if (signatureType == SignatureType.Illegal) { revert("SignatureValidator#isValidSignature: illegal signature"); // Signature using EIP712 } else if (signatureType == SignatureType.EIP712) { require( _sig.length == 97, "SignatureValidator#isValidSignature: length 97 required" ); r = _sig.readBytes32(0); s = _sig.readBytes32(32); v = uint8(_sig[64]); recovered = ecrecover(_hash, v, r, s); isValid = _signerAddress == recovered; return isValid; // Signed using web3.eth_sign() or Ethers wallet.signMessage() } else if (signatureType == SignatureType.EthSign) { require( _sig.length == 97, "SignatureValidator#isValidSignature: length 97 required" ); r = _sig.readBytes32(0); s = _sig.readBytes32(32); v = uint8(_sig[64]); recovered = ecrecover( keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", _hash)), v, r, s ); isValid = _signerAddress == recovered; return isValid; // Signature verified by wallet contract with data validation. } else if (signatureType == SignatureType.WalletBytes) { isValid = ERC1271_MAGICVALUE == IERC1271Wallet(_signerAddress).isValidSignature(_data, _sig); return isValid; // Signature verified by wallet contract without data validation. } else if (signatureType == SignatureType.WalletBytes32) { isValid = ERC1271_MAGICVALUE_BYTES32 == IERC1271Wallet(_signerAddress).isValidSignature(_hash, _sig); return isValid; } else if (signatureType == SignatureType.Wallet) { isValid = isValidWalletSignature( _hash, _signerAddress, _sig ); return isValid; } // Anything else is illegal (We do not return false because // the signature may actually be valid, just not in a format // that we currently support. In this case returning false // may lead the caller to incorrectly believe that the // signature was invalid.) revert("SignatureValidator#isValidSignature: unsupported signature"); } /// @dev Verifies signature using logic defined by Wallet contract. /// @param hash Any 32 byte hash. /// @param walletAddress Address that should have signed the given hash /// and defines its own signature verification method. /// @param signature Proof that the hash has been signed by signer. /// @return isValid True if signature is valid for given wallet.. function isValidWalletSignature( bytes32 hash, address walletAddress, bytes memory signature ) internal view returns (bool isValid) { bytes memory _calldata = abi.encodeWithSelector( IWallet(walletAddress).isValidSignature.selector, hash, signature ); bytes32 magic_salt = bytes32(bytes4(keccak256("isValidWalletSignature(bytes32,address,bytes)"))); assembly { if iszero(extcodesize(walletAddress)) { // Revert with `Error("WALLET_ERROR")` mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) mstore(64, 0x0000000c57414c4c45545f4552524f5200000000000000000000000000000000) mstore(96, 0) revert(0, 100) } let cdStart := add(_calldata, 32) let success := staticcall( gas(), // forward all gas walletAddress, // address of Wallet contract cdStart, // pointer to start of input mload(_calldata), // length of input cdStart, // write output over input 32 // output size is 32 bytes ) if iszero(eq(returndatasize(), 32)) { // Revert with `Error("WALLET_ERROR")` mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) mstore(64, 0x0000000c57414c4c45545f4552524f5200000000000000000000000000000000) mstore(96, 0) revert(0, 100) } switch success case 0 { // Revert with `Error("WALLET_ERROR")` mstore(0, 0x08c379a000000000000000000000000000000000000000000000000000000000) mstore(32, 0x0000002000000000000000000000000000000000000000000000000000000000) mstore(64, 0x0000000c57414c4c45545f4552524f5200000000000000000000000000000000) mstore(96, 0) revert(0, 100) } case 1 { // Signature is valid if call did not revert and returned true isValid := eq( and(mload(cdStart), 0xffffffff00000000000000000000000000000000000000000000000000000000), and(magic_salt, 0xffffffff00000000000000000000000000000000000000000000000000000000) ) } } return isValid; } }
/* Copyright 2018 ZeroEx Intl. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. This is a truncated version of the original LibBytes.sol library from ZeroEx. */ pragma solidity ^0.6.0; library LibBytes { using LibBytes for bytes; /***********************************| | Pop Bytes Functions | |__________________________________*/ /** * @dev Pops the last byte off of a byte array by modifying its length. * @param b Byte array that will be modified. * @return result The byte that was popped off. */ function popLastByte(bytes memory b) internal pure returns (bytes1 result) { require( b.length > 0, "LibBytes#popLastByte: greater than zero length required" ); // Store last byte. result = b[b.length - 1]; assembly { // Decrement length of byte array. let newLen := sub(mload(b), 1) mstore(b, newLen) } return result; } /// @dev Reads an address from a position in a byte array. /// @param b Byte array containing an address. /// @param index Index in byte array of address. /// @return result address from byte array. function readAddress( bytes memory b, uint256 index ) internal pure returns (address result) { require( b.length >= index + 20, // 20 is length of address "LibBytes#readAddress greater or equal to 20 length required" ); // Add offset to index: // 1. Arrays are prefixed by 32-byte length parameter (add 32 to index) // 2. Account for size difference between address length and 32-byte storage word (subtract 12 from index) index += 20; // Read address from array memory assembly { // 1. Add index to address of bytes array // 2. Load 32-byte word from memory // 3. Apply 20-byte mask to obtain address result := and(mload(add(b, index)), 0xffffffffffffffffffffffffffffffffffffffff) } return result; } /***********************************| | Read Bytes Functions | |__________________________________*/ /** * @dev Reads a bytes32 value from a position in a byte array. * @param b Byte array containing a bytes32 value. * @param index Index in byte array of bytes32 value. * @return result bytes32 value from byte array. */ function readBytes32( bytes memory b, uint256 index ) internal pure returns (bytes32 result) { require( b.length >= index + 32, "LibBytes#readBytes32 greater or equal to 32 length required" ); // Arrays are prefixed by a 256 bit length parameter index += 32; // Read the bytes32 from array memory assembly { result := mload(add(b, index)) } return result; } /// @dev Reads an unpadded bytes4 value from a position in a byte array. /// @param b Byte array containing a bytes4 value. /// @param index Index in byte array of bytes4 value. /// @return result bytes4 value from byte array. function readBytes4( bytes memory b, uint256 index ) internal pure returns (bytes4 result) { require( b.length >= index + 4, "LibBytes#readBytes4 greater or equal to 4 length required" ); // Arrays are prefixed by a 32 byte length field index += 32; // Read the bytes4 from array memory assembly { result := mload(add(b, index)) // Solidity does not require us to clean the trailing bytes. // We do it anyway result := and(result, 0xFFFFFFFF00000000000000000000000000000000000000000000000000000000) } return result; } function readBytes2( bytes memory b, uint256 index ) internal pure returns (bytes2 result) { require( b.length >= index + 2, "LibBytes#readBytes2 greater or equal to 2 length required" ); // Arrays are prefixed by a 32 byte length field index += 32; // Read the bytes4 from array memory assembly { result := mload(add(b, index)) // Solidity does not require us to clean the trailing bytes. // We do it anyway result := and(result, 0xFFFF000000000000000000000000000000000000000000000000000000000000) } return result; } }
{ "optimizer": { "enabled": true, "runs": 1000 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "abi" ] } }, "metadata": { "useLiteralContent": true }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_operator","type":"address"},{"internalType":"address","name":"_userProxy","type":"address"},{"internalType":"contract ISpender","name":"_spender","type":"address"},{"internalType":"contract IPermanentStorage","name":"_permStorage","type":"address"},{"internalType":"contract IWETH","name":"_weth","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"spender","type":"address"}],"name":"AllowTransfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"ethBalance","type":"uint256"}],"name":"DepositETH","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"spender","type":"address"}],"name":"DisallowTransfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"source","type":"string"},{"indexed":true,"internalType":"bytes32","name":"transactionHash","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"orderHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"userAddr","type":"address"},{"indexed":false,"internalType":"address","name":"takerAssetAddr","type":"address"},{"indexed":false,"internalType":"uint256","name":"takerAssetAmount","type":"uint256"},{"indexed":false,"internalType":"address","name":"makerAddr","type":"address"},{"indexed":false,"internalType":"address","name":"makerAssetAddr","type":"address"},{"indexed":false,"internalType":"uint256","name":"makerAssetAmount","type":"uint256"},{"indexed":false,"internalType":"address","name":"receiverAddr","type":"address"},{"indexed":false,"internalType":"uint256","name":"settleAmount","type":"uint256"},{"indexed":false,"internalType":"uint16","name":"feeFactor","type":"uint16"}],"name":"FillOrder","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newOperator","type":"address"}],"name":"TransferOwnership","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newSpender","type":"address"}],"name":"UpgradeSpender","type":"event"},{"inputs":[],"name":"EIP191_HEADER","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EIP712_DOMAIN_NAME","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EIP712_DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EIP712_DOMAIN_VERSION","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FILL_WITH_PERMIT_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ORDER_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SOURCE","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"_tokenList","type":"address[]"},{"internalType":"address","name":"_spender","type":"address"}],"name":"closeAllowance","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"depositETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"takerAddr","type":"address"},{"internalType":"address","name":"makerAddr","type":"address"},{"internalType":"address","name":"takerAssetAddr","type":"address"},{"internalType":"address","name":"makerAssetAddr","type":"address"},{"internalType":"uint256","name":"takerAssetAmount","type":"uint256"},{"internalType":"uint256","name":"makerAssetAmount","type":"uint256"},{"internalType":"address","name":"receiverAddr","type":"address"},{"internalType":"uint256","name":"salt","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint256","name":"feeFactor","type":"uint256"}],"internalType":"struct RFQLibEIP712.Order","name":"_order","type":"tuple"},{"internalType":"bytes","name":"_mmSignature","type":"bytes"},{"internalType":"bytes","name":"_userSignature","type":"bytes"}],"name":"fill","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"_signerAddress","type":"address"},{"internalType":"bytes32","name":"_hash","type":"bytes32"},{"internalType":"bytes","name":"_data","type":"bytes"},{"internalType":"bytes","name":"_sig","type":"bytes"}],"name":"isValidSignature","outputs":[{"internalType":"bool","name":"isValid","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"operator","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"permStorage","outputs":[{"internalType":"contract IPermanentStorage","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"_tokenList","type":"address[]"},{"internalType":"address","name":"_spender","type":"address"}],"name":"setAllowance","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"spender","outputs":[{"internalType":"contract ISpender","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_newOperator","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newSpender","type":"address"}],"name":"upgradeSpender","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"userProxy","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"weth","outputs":[{"internalType":"contract IWETH","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
600861010052672a37b5b2b73637b760c11b6101205261018060405260026101405261763560f01b610160527f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f7f4428669f887e7f6a6e361e218ee42308201bdbacbf601211fc38b8b2ec6961817f7d6f66f923317ceee1bd9447053fb8a64c76979d436a723b87aff2899feaa6c36200009862000157565b30604051602001620000af959493929190620001da565b60408051601f198184030181529190528051602090910120608052348015620000d757600080fd5b5060405162002c7438038062002c74833981016040819052620000fa916200015b565b6001600081905580546001600160a01b03199081166001600160a01b0397881617909155606094851b6001600160601b031990811660a052600280549092169490961693909317909255821b831660c052901b1660e0526200021f565b4690565b600080600080600060a0868803121562000173578081fd5b8551620001808162000206565b6020870151909550620001938162000206565b6040870151909450620001a68162000206565b6060870151909350620001b98162000206565b6080870151909250620001cc8162000206565b809150509295509295909350565b9485526020850193909352604084019190915260608301526001600160a01b0316608082015260a00190565b6001600160a01b03811681146200021c57600080fd5b50565b60805160a05160601c60c05160601c60e05160601c6129ee620002866000398061048e52806108f152806109445280610bb3528061138952806113f552508061066d528061087b52508061046a528061070c525080610691528061127152506129ee6000f3fe6080604052600436106101625760003560e01c8063dab400f3116100c0578063f2fde38b11610074578063f973a20911610059578063f973a2091461032f578063fa4e12d714610344578063fd0702961461037157610169565b8063f2fde38b146102fa578063f6326fb31461031a57610169565b8063e8edc816116100a5578063e8edc816146102bd578063eba80bce146102d2578063f230b4c2146102e557610169565b8063dab400f314610293578063e0c05c24146102a857610169565b806354fd4d50116101175780635cc33321116100fc5780635cc333211461024957806382fdaf581461025e578063c49e4fd91461027e57610169565b806354fd4d5014610212578063570ca7351461023457610169565b80633ec63216116101485780633ec63216146101bb5780633fc8cef3146101dd57806346920bad146101f257610169565b8062ac9ec51461016e57806330db45801461019957610169565b3661016957005b600080fd5b34801561017a57600080fd5b50610183610386565b60405161019091906120e2565b60405180910390f35b3480156101a557600080fd5b506101b96101b4366004611ac9565b6103ae565b005b3480156101c757600080fd5b506101d0610468565b604051610190919061206c565b3480156101e957600080fd5b506101d061048c565b3480156101fe57600080fd5b506101b961020d366004611ac9565b6104b0565b34801561021e57600080fd5b50610227610537565b6040516101909190612208565b34801561024057600080fd5b506101d0610570565b34801561025557600080fd5b5061022761057f565b34801561026a57600080fd5b506101b9610279366004611a32565b6105b8565b34801561028a57600080fd5b506101d061066b565b34801561029f57600080fd5b5061018361068f565b3480156102b457600080fd5b506102276106b3565b3480156102c957600080fd5b506101d06106d1565b6101836102e0366004611b90565b6106e0565b3480156102f157600080fd5b50610227610ab6565b34801561030657600080fd5b506101b9610315366004611a32565b610ad8565b34801561032657600080fd5b506101b9610b80565b34801561033b57600080fd5b50610183610c57565b34801561035057600080fd5b5061036461035f366004611a4d565b610c66565b60405161019091906120d7565b34801561037d57600080fd5b50610227611060565b60405160200161039590611d54565b6040516020818303038152906040528051906020012081565b6001546001600160a01b031633146103e15760405162461bcd60e51b81526004016103d89061239d565b60405180910390fd5b60005b82811015610462576104238260008686858181106103fe57fe5b90506020020160208101906104139190611a32565b6001600160a01b03169190611099565b7f7c22b5f0390808135dc69153cbe5633a868bb389d20d7e2071500f3c8e49017e82604051610452919061206c565b60405180910390a16001016103e4565b50505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b6001546001600160a01b031633146104da5760405162461bcd60e51b81526004016103d89061239d565b60005b82811015610462576104f8826000198686858181106103fe57fe5b7fcc25b8a957df0a0b6c4413850c122a29ee10048018cd63f00e453e1bba64943a82604051610527919061206c565b60405180910390a16001016104dd565b6040518060400160405280600581526020017f352e322e3000000000000000000000000000000000000000000000000000000081525081565b6001546001600160a01b031681565b6040518060400160405280600281526020017f763500000000000000000000000000000000000000000000000000000000000081525081565b6001546001600160a01b031633146105e25760405162461bcd60e51b81526004016103d89061239d565b6001600160a01b0381166106085760405162461bcd60e51b81526004016103d8906122e3565b6002805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0383161790556040517fbd4e916c3e5390ed2ffaf01ea6c14195c3e174811b8ad55bca06034e89bbd0bb9061066090839061206c565b60405180910390a150565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b60405180604001604052806002815260200161190160f01b81525081565b6002546001600160a01b031681565b6000600260005414156107055760405162461bcd60e51b81526004016103d8906128d1565b60026000557f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031633146107525760405162461bcd60e51b81526004016103d890612544565b4284610100015110156107775760405162461bcd60e51b81526004016103d8906127cf565b6127108461012001511061079d5760405162461bcd60e51b81526004016103d89061240b565b6107a561199b565b6107ae856111c6565b80825260208601516107d9916107c390611252565b6040518060200160405280600081525087610c66565b6107f55760405162461bcd60e51b81526004016103d8906124b0565b6107fe856112a3565b60208201819052855161082a9161081490611252565b6040518060200160405280600081525086610c66565b6108465760405162461bcd60e51b81526004016103d89061289a565b60208101516040517fa276b0a30000000000000000000000000000000000000000000000000000000081526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000169163a276b0a3916108af91906004016120e2565b600060405180830381600087803b1580156108c957600080fd5b505af11580156108dd573d6000803e3d6000fd5b5050505084604001516001600160a01b03167f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031614156109bb57846080015134146109425760405162461bcd60e51b81526004016103d8906123d4565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b15801561099d57600080fd5b505af11580156109b1573d6000803e3d6000fd5b5050505050610a2b565b600254855160408088015160808901519151631a3a568d60e11b81526001600160a01b0390941693633474ad1a936109f89390929160040161209a565b600060405180830381600087803b158015610a1257600080fd5b505af1158015610a26573d6000803e3d6000fd5b505050505b6002546020860151606087015160a0880151604051631a3a568d60e11b81526001600160a01b0390941693633474ad1a93610a6c939092909160040161209a565b600060405180830381600087803b158015610a8657600080fd5b505af1158015610a9a573d6000803e3d6000fd5b50505050610aa88582611318565b600160005595945050505050565b6040518060400160405280600681526020016552465120763160d01b81525081565b6001546001600160a01b03163314610b025760405162461bcd60e51b81526004016103d89061239d565b6001600160a01b038116610b285760405162461bcd60e51b81526004016103d8906124e7565b6001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0383161790556040517fcfaaa26691e16e66e73290fc725eee1a6b4e0e693a1640484937aac25ffb55a49061066090839061206c565b6001546001600160a01b03163314610baa5760405162461bcd60e51b81526004016103d89061239d565b478015610c54577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b158015610c0c57600080fd5b505af1158015610c20573d6000803e3d6000fd5b50505050507ff21b64ad26683e79854b8f088d254ef4e123df84bdb91d1f7f4356d772716a398160405161066091906120e2565b50565b60405160200161039590611ef3565b600080825111610c885760405162461bcd60e51b81526004016103d8906125d8565b6001600160a01b038516610cae5760405162461bcd60e51b81526004016103d890612340565b6000610cb983611568565b60f81c905060078110610cde5760405162461bcd60e51b81526004016103d89061265b565b60008160ff166007811115610cef57fe5b9050600080808080856007811115610d0357fe5b1415610d215760405162461bcd60e51b81526004016103d890612715565b6002856007811115610d2f57fe5b1415610df9578751606114610d565760405162461bcd60e51b81526004016103d890612286565b610d618860006115ce565b9250610d6e8860206115ce565b915087604081518110610d7d57fe5b602001015160f81c60f81b60f81c935060018a85858560405160008152602001604052604051610db094939291906121bc565b6020604051602081039080840390855afa158015610dd2573d6000803e3d6000fd5b5050604051601f1901516001600160a01b038d811691161497506110589650505050505050565b6003856007811115610e0757fe5b1415610eae578751606114610e2e5760405162461bcd60e51b81526004016103d890612286565b610e398860006115ce565b9250610e468860206115ce565b915087604081518110610e5557fe5b602001015160f81c60f81b60f81c935060018a604051602001610e789190611d23565b6040516020818303038152906040528051906020012085858560405160008152602001604052604051610db094939291906121bc565b6004856007811115610ebc57fe5b1415610f61576040516320c13b0b60e01b81526001600160a01b038c16906320c13b0b90610ef0908c908c906004016121da565b60206040518083038186803b158015610f0857600080fd5b505afa158015610f1c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f409190611b68565b6001600160e01b0319166320c13b0b60e01b14965061105895505050505050565b6005856007811115610f6f57fe5b141561101457604051630b135d3f60e11b81526001600160a01b038c1690631626ba7e90610fa3908d908c906004016121a3565b60206040518083038186803b158015610fbb57600080fd5b505afa158015610fcf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ff39190611b68565b6001600160e01b031916630b135d3f60e11b14965061105895505050505050565b600685600781111561102257fe5b1415611040576110338a8c8a6115fd565b9650505050505050611058565b60405162461bcd60e51b81526004016103d89061265b565b949350505050565b6040518060400160405280600881526020017f546f6b656e6c6f6e00000000000000000000000000000000000000000000000081525081565b80158061113a57506040517fdd62ed3e0000000000000000000000000000000000000000000000000000000081526001600160a01b0384169063dd62ed3e906110e89030908690600401612080565b60206040518083038186803b15801561110057600080fd5b505afa158015611114573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111389190611c9c565b155b6111565760405162461bcd60e51b81526004016103d890612908565b6111c18363095ea7b360e01b84846040516024016111759291906120be565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990931692909217909152611770565b505050565b60006040516020016111d790611ef3565b60405160208183030381529060405280519060200120826000015183602001518460400151856060015186608001518760a001518860e001518961010001518a61012001516040516020016112359a999897969594939291906120eb565b604051602081830303815290604052805190602001209050919050565b600060405180604001604052806002815260200161190160f01b8152507f00000000000000000000000000000000000000000000000000000000000000008360405160200161123593929190611cfc565b60006040516020016112b490611d54565b6040516020818303038152906040528051906020012082602001518360400151846060015185608001518660a0015187600001518860c001518960e001518a61010001518b61012001516040516020016112359b9a99989796959493929190612142565b60006113448360200151846080015185604001516001600160a01b03166117ff9092919063ffffffff16565b60a0830151610120840151156113875761138461271061137e61137787610120015161271061181e90919063ffffffff16565b8490611846565b90611880565b90505b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031684606001516001600160a01b0316141561149f576040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001690632e1a7d4d9061142a9084906004016120e2565b600060405180830381600087803b15801561144457600080fd5b505af1158015611458573d6000803e3d6000fd5b505050508360c001516001600160a01b03166108fc829081150290604051600060405180830381858888f19350505050158015611499573d6000803e3d6000fd5b506114c5565b6114c58460c001518286606001516001600160a01b03166117ff9092919063ffffffff16565b83600001516001600160a01b0316836000015184602001517f75d58426b26ab641a6a6a46f12fe35e17c570a1cd264c7248a73d90e3a8682ff6040518060400160405280600681526020016552465120763160d01b815250886040015189608001518a602001518b606001518c60a001518d60c001518b8f61012001516040516115579998979695949392919061221b565b60405180910390a490505b92915050565b60008082511161158a5760405162461bcd60e51b81526004016103d890612772565b8160018351038151811061159a57fe5b0160200151825160001901909252507fff000000000000000000000000000000000000000000000000000000000000001690565b600081602001835110156115f45760405162461bcd60e51b81526004016103d8906126b8565b50016020015190565b60006060631626ba7e60e01b858460405160240161161c9291906121a3565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915290507fb067138100000000000000000000000000000000000000000000000000000000843b6116bd5762461bcd60e51b600052600160e51b6020526c062ba0a62622aa2fa2a92927a960811b604052600060605260646000fd5b60208201602081845183895afa60203d146117035762461bcd60e51b600052600160e51b6020526c062ba0a62622aa2fa2a92927a960811b604052600060605260646000fd5b808015611717576001811461174857611763565b62461bcd60e51b600052600160e51b6020526c062ba0a62622aa2fa2a92927a960811b604052600060605260646000fd5b6001600160e01b031984166001600160e01b03198451161495505b50505050505b9392505050565b60606117c5826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166118b29092919063ffffffff16565b8051909150156111c157808060200190518101906117e39190611b48565b6111c15760405162461bcd60e51b81526004016103d89061283d565b6111c18363a9059cbb60e01b84846040516024016111759291906120be565b6000828211156118405760405162461bcd60e51b81526004016103d890612442565b50900390565b60008261185557506000611562565b8282028284828161186257fe5b04146117695760405162461bcd60e51b81526004016103d89061257b565b60008082116118a15760405162461bcd60e51b81526004016103d890612479565b8183816118aa57fe5b049392505050565b60606110588484600085856118c68561195c565b6118e25760405162461bcd60e51b81526004016103d890612806565b60006060866001600160a01b031685876040516118ff9190611ce0565b60006040518083038185875af1925050503d806000811461193c576040519150601f19603f3d011682016040523d82523d6000602084013e611941565b606091505b5091509150611951828286611962565b979650505050505050565b3b151590565b60608315611971575081611769565b8251156119815782518084602001fd5b8160405162461bcd60e51b81526004016103d89190612208565b604080518082019091526000808252602082015290565b80356001600160a01b038116811461156257600080fd5b600082601f8301126119d9578081fd5b813567ffffffffffffffff8111156119ef578182fd5b611a02601f8201601f1916602001612965565b9150808252836020828501011115611a1957600080fd5b8060208401602084013760009082016020015292915050565b600060208284031215611a43578081fd5b61176983836119b2565b60008060008060808587031215611a62578283fd5b611a6c86866119b2565b935060208501359250604085013567ffffffffffffffff80821115611a8f578384fd5b611a9b888389016119c9565b93506060870135915080821115611ab0578283fd5b50611abd878288016119c9565b91505092959194509250565b600080600060408486031215611add578283fd5b833567ffffffffffffffff80821115611af4578485fd5b818601915086601f830112611b07578485fd5b813581811115611b15578586fd5b8760208083028501011115611b28578586fd5b602092830195509350611b3f9187915086016119b2565b90509250925092565b600060208284031215611b59578081fd5b81518015158114611769578182fd5b600060208284031215611b79578081fd5b81516001600160e01b031981168114611769578182fd5b6000806000838503610180811215611ba6578384fd5b61014080821215611bb5578485fd5b611bbe81612965565b9150611bca87876119b2565b8252611bd987602088016119b2565b6020830152611beb87604088016119b2565b6040830152611bfd87606088016119b2565b60608301526080860135608083015260a086013560a0830152611c238760c088016119b2565b60c083015260e086810135908301526101008087013590830152610120808701359083015290935084013567ffffffffffffffff80821115611c63578384fd5b611c6f878388016119c9565b9350610160860135915080821115611c85578283fd5b50611c92868287016119c9565b9150509250925092565b600060208284031215611cad578081fd5b5051919050565b60008151808452611ccc81602086016020860161298c565b601f01601f19169290920160200192915050565b60008251611cf281846020870161298c565b9190910192915050565b60008451611d0e81846020890161298c565b91909101928352506020820152604001919050565b7f19457468657265756d205369676e6564204d6573736167653a0a3332000000008152601c810191909152603c0190565b7f66696c6c576974685065726d697428000000000000000000000000000000000081527f61646472657373206d616b6572416464722c0000000000000000000000000000600f8201527f616464726573732074616b65724173736574416464722c00000000000000000060218201527f61646472657373206d616b65724173736574416464722c00000000000000000060388201527f75696e743235362074616b65724173736574416d6f756e742c00000000000000604f8201527f75696e74323536206d616b65724173736574416d6f756e742c0000000000000060688201527f616464726573732074616b6572416464722c000000000000000000000000000060818201527f61646472657373207265636569766572416464722c000000000000000000000060938201526c1d5a5b9d0c8d4d881cd85b1d0b609a1b60a88201527f75696e7432353620646561646c696e652c00000000000000000000000000000060b58201527f75696e7432353620666565466163746f7200000000000000000000000000000060c6820152602960f81b60d782015260d80190565b7f4f7264657228000000000000000000000000000000000000000000000000000081527f616464726573732074616b6572416464722c000000000000000000000000000060068201527f61646472657373206d616b6572416464722c000000000000000000000000000060188201527f616464726573732074616b65724173736574416464722c000000000000000000602a8201527f61646472657373206d616b65724173736574416464722c00000000000000000060418201527f75696e743235362074616b65724173736574416d6f756e742c0000000000000060588201527f75696e74323536206d616b65724173736574416d6f756e742c0000000000000060718201526c1d5a5b9d0c8d4d881cd85b1d0b609a1b608a8201527f75696e7432353620646561646c696e652c00000000000000000000000000000060978201527f75696e7432353620666565466163746f7200000000000000000000000000000060a8820152602960f81b60b982015260ba0190565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b03929092168252602082015260400190565b901515815260200190565b90815260200190565b998a526001600160a01b0398891660208b015296881660408a0152948716606089015292909516608087015260a086015260c085019390935260e08401929092526101008301919091526101208201526101400190565b9a8b526001600160a01b03998a1660208c015297891660408b015295881660608a0152608089019490945260a0880192909252851660c087015290931660e08501526101008401929092526101208301919091526101408201526101600190565b6000838252604060208301526110586040830184611cb4565b93845260ff9290921660208401526040830152606082015260800190565b6000604082526121ed6040830185611cb4565b82810360208401526121ff8185611cb4565b95945050505050565b6000602082526117696020830184611cb4565b600061012080835261222f8184018d611cb4565b9150506001600160a01b03808b166020840152896040840152808916606084015280881660808401528660a084015280861660c0840152508360e083015261ffff83166101008301529a9950505050505050505050565b60208082526037908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a206c656e677468203937207265717569726564000000000000000000606082015260800190565b60208082526024908201527f5246513a207370656e6465722063616e206e6f74206265207a65726f2061646460408201527f7265737300000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526033908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a20696e76616c6964207369676e657200000000000000000000000000606082015260800190565b60208082526011908201527f5246513a206e6f74206f70657261746f72000000000000000000000000000000604082015260600190565b60208082526015908201527f5246513a20696e73756666696369656e74204554480000000000000000000000604082015260600190565b60208082526017908201527f5246513a20696e76616c69642066656520666163746f72000000000000000000604082015260600190565b6020808252601e908201527f536166654d6174683a207375627472616374696f6e206f766572666c6f770000604082015260600190565b6020808252601a908201527f536166654d6174683a206469766973696f6e206279207a65726f000000000000604082015260600190565b60208082526019908201527f5246513a20696e76616c6964204d4d207369676e617475726500000000000000604082015260600190565b60208082526025908201527f5246513a206f70657261746f722063616e206e6f74206265207a65726f20616460408201527f6472657373000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252601f908201527f5246513a206e6f7420746865205573657250726f787920636f6e747261637400604082015260600190565b60208082526021908201527f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f60408201527f7700000000000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526043908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a206c656e6774682067726561746572207468616e203020726571756960608201527f7265640000000000000000000000000000000000000000000000000000000000608082015260a00190565b6020808252603a908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a20756e737570706f72746564207369676e6174757265000000000000606082015260800190565b6020808252603b908201527f4c696242797465732372656164427974657333322067726561746572206f722060408201527f657175616c20746f203332206c656e6774682072657175697265640000000000606082015260800190565b60208082526036908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a20696c6c6567616c207369676e617475726500000000000000000000606082015260800190565b60208082526037908201527f4c6962427974657323706f704c617374427974653a206772656174657220746860408201527f616e207a65726f206c656e677468207265717569726564000000000000000000606082015260800190565b60208082526012908201527f5246513a2065787069726564206f726465720000000000000000000000000000604082015260600190565b6020808252601d908201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60408201527f6f74207375636365656400000000000000000000000000000000000000000000606082015260800190565b6020808252601b908201527f5246513a20696e76616c69642075736572207369676e61747572650000000000604082015260600190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b60208082526036908201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60408201527f20746f206e6f6e2d7a65726f20616c6c6f77616e636500000000000000000000606082015260800190565b60405181810167ffffffffffffffff8111828210171561298457600080fd5b604052919050565b60005b838110156129a757818101518382015260200161298f565b83811115610462575050600091015256fea2646970667358221220f26632dafe87e3c8aa58a5e213100d091fa2fc9f29134c87cfdfd2ffd162f5b564736f6c634300060c00330000000000000000000000009afc226dc049b99342ad6774eeb08bfa2f87446500000000000000000000000003f34be1bf910116595db1b11e9d1b2ca5d596590000000000000000000000003c68dfc45dc92c9c605d92b49858073e10b857a60000000000000000000000006d9cc14a1d36e6ff13fc6efa9e9326fcd12e7903000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
Deployed Bytecode
0x6080604052600436106101625760003560e01c8063dab400f3116100c0578063f2fde38b11610074578063f973a20911610059578063f973a2091461032f578063fa4e12d714610344578063fd0702961461037157610169565b8063f2fde38b146102fa578063f6326fb31461031a57610169565b8063e8edc816116100a5578063e8edc816146102bd578063eba80bce146102d2578063f230b4c2146102e557610169565b8063dab400f314610293578063e0c05c24146102a857610169565b806354fd4d50116101175780635cc33321116100fc5780635cc333211461024957806382fdaf581461025e578063c49e4fd91461027e57610169565b806354fd4d5014610212578063570ca7351461023457610169565b80633ec63216116101485780633ec63216146101bb5780633fc8cef3146101dd57806346920bad146101f257610169565b8062ac9ec51461016e57806330db45801461019957610169565b3661016957005b600080fd5b34801561017a57600080fd5b50610183610386565b60405161019091906120e2565b60405180910390f35b3480156101a557600080fd5b506101b96101b4366004611ac9565b6103ae565b005b3480156101c757600080fd5b506101d0610468565b604051610190919061206c565b3480156101e957600080fd5b506101d061048c565b3480156101fe57600080fd5b506101b961020d366004611ac9565b6104b0565b34801561021e57600080fd5b50610227610537565b6040516101909190612208565b34801561024057600080fd5b506101d0610570565b34801561025557600080fd5b5061022761057f565b34801561026a57600080fd5b506101b9610279366004611a32565b6105b8565b34801561028a57600080fd5b506101d061066b565b34801561029f57600080fd5b5061018361068f565b3480156102b457600080fd5b506102276106b3565b3480156102c957600080fd5b506101d06106d1565b6101836102e0366004611b90565b6106e0565b3480156102f157600080fd5b50610227610ab6565b34801561030657600080fd5b506101b9610315366004611a32565b610ad8565b34801561032657600080fd5b506101b9610b80565b34801561033b57600080fd5b50610183610c57565b34801561035057600080fd5b5061036461035f366004611a4d565b610c66565b60405161019091906120d7565b34801561037d57600080fd5b50610227611060565b60405160200161039590611d54565b6040516020818303038152906040528051906020012081565b6001546001600160a01b031633146103e15760405162461bcd60e51b81526004016103d89061239d565b60405180910390fd5b60005b82811015610462576104238260008686858181106103fe57fe5b90506020020160208101906104139190611a32565b6001600160a01b03169190611099565b7f7c22b5f0390808135dc69153cbe5633a868bb389d20d7e2071500f3c8e49017e82604051610452919061206c565b60405180910390a16001016103e4565b50505050565b7f00000000000000000000000003f34be1bf910116595db1b11e9d1b2ca5d5965981565b7f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc281565b6001546001600160a01b031633146104da5760405162461bcd60e51b81526004016103d89061239d565b60005b82811015610462576104f8826000198686858181106103fe57fe5b7fcc25b8a957df0a0b6c4413850c122a29ee10048018cd63f00e453e1bba64943a82604051610527919061206c565b60405180910390a16001016104dd565b6040518060400160405280600581526020017f352e322e3000000000000000000000000000000000000000000000000000000081525081565b6001546001600160a01b031681565b6040518060400160405280600281526020017f763500000000000000000000000000000000000000000000000000000000000081525081565b6001546001600160a01b031633146105e25760405162461bcd60e51b81526004016103d89061239d565b6001600160a01b0381166106085760405162461bcd60e51b81526004016103d8906122e3565b6002805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0383161790556040517fbd4e916c3e5390ed2ffaf01ea6c14195c3e174811b8ad55bca06034e89bbd0bb9061066090839061206c565b60405180910390a150565b7f0000000000000000000000006d9cc14a1d36e6ff13fc6efa9e9326fcd12e790381565b7fddb7153eed2d5dbcdf70a45b3c2fc5848306695d595a4488cfafc192777cf03e81565b60405180604001604052806002815260200161190160f01b81525081565b6002546001600160a01b031681565b6000600260005414156107055760405162461bcd60e51b81526004016103d8906128d1565b60026000557f00000000000000000000000003f34be1bf910116595db1b11e9d1b2ca5d596596001600160a01b031633146107525760405162461bcd60e51b81526004016103d890612544565b4284610100015110156107775760405162461bcd60e51b81526004016103d8906127cf565b6127108461012001511061079d5760405162461bcd60e51b81526004016103d89061240b565b6107a561199b565b6107ae856111c6565b80825260208601516107d9916107c390611252565b6040518060200160405280600081525087610c66565b6107f55760405162461bcd60e51b81526004016103d8906124b0565b6107fe856112a3565b60208201819052855161082a9161081490611252565b6040518060200160405280600081525086610c66565b6108465760405162461bcd60e51b81526004016103d89061289a565b60208101516040517fa276b0a30000000000000000000000000000000000000000000000000000000081526001600160a01b037f0000000000000000000000006d9cc14a1d36e6ff13fc6efa9e9326fcd12e7903169163a276b0a3916108af91906004016120e2565b600060405180830381600087803b1580156108c957600080fd5b505af11580156108dd573d6000803e3d6000fd5b5050505084604001516001600160a01b03167f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b031614156109bb57846080015134146109425760405162461bcd60e51b81526004016103d8906123d4565b7f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b15801561099d57600080fd5b505af11580156109b1573d6000803e3d6000fd5b5050505050610a2b565b600254855160408088015160808901519151631a3a568d60e11b81526001600160a01b0390941693633474ad1a936109f89390929160040161209a565b600060405180830381600087803b158015610a1257600080fd5b505af1158015610a26573d6000803e3d6000fd5b505050505b6002546020860151606087015160a0880151604051631a3a568d60e11b81526001600160a01b0390941693633474ad1a93610a6c939092909160040161209a565b600060405180830381600087803b158015610a8657600080fd5b505af1158015610a9a573d6000803e3d6000fd5b50505050610aa88582611318565b600160005595945050505050565b6040518060400160405280600681526020016552465120763160d01b81525081565b6001546001600160a01b03163314610b025760405162461bcd60e51b81526004016103d89061239d565b6001600160a01b038116610b285760405162461bcd60e51b81526004016103d8906124e7565b6001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0383161790556040517fcfaaa26691e16e66e73290fc725eee1a6b4e0e693a1640484937aac25ffb55a49061066090839061206c565b6001546001600160a01b03163314610baa5760405162461bcd60e51b81526004016103d89061239d565b478015610c54577f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b031663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b158015610c0c57600080fd5b505af1158015610c20573d6000803e3d6000fd5b50505050507ff21b64ad26683e79854b8f088d254ef4e123df84bdb91d1f7f4356d772716a398160405161066091906120e2565b50565b60405160200161039590611ef3565b600080825111610c885760405162461bcd60e51b81526004016103d8906125d8565b6001600160a01b038516610cae5760405162461bcd60e51b81526004016103d890612340565b6000610cb983611568565b60f81c905060078110610cde5760405162461bcd60e51b81526004016103d89061265b565b60008160ff166007811115610cef57fe5b9050600080808080856007811115610d0357fe5b1415610d215760405162461bcd60e51b81526004016103d890612715565b6002856007811115610d2f57fe5b1415610df9578751606114610d565760405162461bcd60e51b81526004016103d890612286565b610d618860006115ce565b9250610d6e8860206115ce565b915087604081518110610d7d57fe5b602001015160f81c60f81b60f81c935060018a85858560405160008152602001604052604051610db094939291906121bc565b6020604051602081039080840390855afa158015610dd2573d6000803e3d6000fd5b5050604051601f1901516001600160a01b038d811691161497506110589650505050505050565b6003856007811115610e0757fe5b1415610eae578751606114610e2e5760405162461bcd60e51b81526004016103d890612286565b610e398860006115ce565b9250610e468860206115ce565b915087604081518110610e5557fe5b602001015160f81c60f81b60f81c935060018a604051602001610e789190611d23565b6040516020818303038152906040528051906020012085858560405160008152602001604052604051610db094939291906121bc565b6004856007811115610ebc57fe5b1415610f61576040516320c13b0b60e01b81526001600160a01b038c16906320c13b0b90610ef0908c908c906004016121da565b60206040518083038186803b158015610f0857600080fd5b505afa158015610f1c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f409190611b68565b6001600160e01b0319166320c13b0b60e01b14965061105895505050505050565b6005856007811115610f6f57fe5b141561101457604051630b135d3f60e11b81526001600160a01b038c1690631626ba7e90610fa3908d908c906004016121a3565b60206040518083038186803b158015610fbb57600080fd5b505afa158015610fcf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ff39190611b68565b6001600160e01b031916630b135d3f60e11b14965061105895505050505050565b600685600781111561102257fe5b1415611040576110338a8c8a6115fd565b9650505050505050611058565b60405162461bcd60e51b81526004016103d89061265b565b949350505050565b6040518060400160405280600881526020017f546f6b656e6c6f6e00000000000000000000000000000000000000000000000081525081565b80158061113a57506040517fdd62ed3e0000000000000000000000000000000000000000000000000000000081526001600160a01b0384169063dd62ed3e906110e89030908690600401612080565b60206040518083038186803b15801561110057600080fd5b505afa158015611114573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111389190611c9c565b155b6111565760405162461bcd60e51b81526004016103d890612908565b6111c18363095ea7b360e01b84846040516024016111759291906120be565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990931692909217909152611770565b505050565b60006040516020016111d790611ef3565b60405160208183030381529060405280519060200120826000015183602001518460400151856060015186608001518760a001518860e001518961010001518a61012001516040516020016112359a999897969594939291906120eb565b604051602081830303815290604052805190602001209050919050565b600060405180604001604052806002815260200161190160f01b8152507fddb7153eed2d5dbcdf70a45b3c2fc5848306695d595a4488cfafc192777cf03e8360405160200161123593929190611cfc565b60006040516020016112b490611d54565b6040516020818303038152906040528051906020012082602001518360400151846060015185608001518660a0015187600001518860c001518960e001518a61010001518b61012001516040516020016112359b9a99989796959493929190612142565b60006113448360200151846080015185604001516001600160a01b03166117ff9092919063ffffffff16565b60a0830151610120840151156113875761138461271061137e61137787610120015161271061181e90919063ffffffff16565b8490611846565b90611880565b90505b7f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b031684606001516001600160a01b0316141561149f576040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526001600160a01b037f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc21690632e1a7d4d9061142a9084906004016120e2565b600060405180830381600087803b15801561144457600080fd5b505af1158015611458573d6000803e3d6000fd5b505050508360c001516001600160a01b03166108fc829081150290604051600060405180830381858888f19350505050158015611499573d6000803e3d6000fd5b506114c5565b6114c58460c001518286606001516001600160a01b03166117ff9092919063ffffffff16565b83600001516001600160a01b0316836000015184602001517f75d58426b26ab641a6a6a46f12fe35e17c570a1cd264c7248a73d90e3a8682ff6040518060400160405280600681526020016552465120763160d01b815250886040015189608001518a602001518b606001518c60a001518d60c001518b8f61012001516040516115579998979695949392919061221b565b60405180910390a490505b92915050565b60008082511161158a5760405162461bcd60e51b81526004016103d890612772565b8160018351038151811061159a57fe5b0160200151825160001901909252507fff000000000000000000000000000000000000000000000000000000000000001690565b600081602001835110156115f45760405162461bcd60e51b81526004016103d8906126b8565b50016020015190565b60006060631626ba7e60e01b858460405160240161161c9291906121a3565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915290507fb067138100000000000000000000000000000000000000000000000000000000843b6116bd5762461bcd60e51b600052600160e51b6020526c062ba0a62622aa2fa2a92927a960811b604052600060605260646000fd5b60208201602081845183895afa60203d146117035762461bcd60e51b600052600160e51b6020526c062ba0a62622aa2fa2a92927a960811b604052600060605260646000fd5b808015611717576001811461174857611763565b62461bcd60e51b600052600160e51b6020526c062ba0a62622aa2fa2a92927a960811b604052600060605260646000fd5b6001600160e01b031984166001600160e01b03198451161495505b50505050505b9392505050565b60606117c5826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166118b29092919063ffffffff16565b8051909150156111c157808060200190518101906117e39190611b48565b6111c15760405162461bcd60e51b81526004016103d89061283d565b6111c18363a9059cbb60e01b84846040516024016111759291906120be565b6000828211156118405760405162461bcd60e51b81526004016103d890612442565b50900390565b60008261185557506000611562565b8282028284828161186257fe5b04146117695760405162461bcd60e51b81526004016103d89061257b565b60008082116118a15760405162461bcd60e51b81526004016103d890612479565b8183816118aa57fe5b049392505050565b60606110588484600085856118c68561195c565b6118e25760405162461bcd60e51b81526004016103d890612806565b60006060866001600160a01b031685876040516118ff9190611ce0565b60006040518083038185875af1925050503d806000811461193c576040519150601f19603f3d011682016040523d82523d6000602084013e611941565b606091505b5091509150611951828286611962565b979650505050505050565b3b151590565b60608315611971575081611769565b8251156119815782518084602001fd5b8160405162461bcd60e51b81526004016103d89190612208565b604080518082019091526000808252602082015290565b80356001600160a01b038116811461156257600080fd5b600082601f8301126119d9578081fd5b813567ffffffffffffffff8111156119ef578182fd5b611a02601f8201601f1916602001612965565b9150808252836020828501011115611a1957600080fd5b8060208401602084013760009082016020015292915050565b600060208284031215611a43578081fd5b61176983836119b2565b60008060008060808587031215611a62578283fd5b611a6c86866119b2565b935060208501359250604085013567ffffffffffffffff80821115611a8f578384fd5b611a9b888389016119c9565b93506060870135915080821115611ab0578283fd5b50611abd878288016119c9565b91505092959194509250565b600080600060408486031215611add578283fd5b833567ffffffffffffffff80821115611af4578485fd5b818601915086601f830112611b07578485fd5b813581811115611b15578586fd5b8760208083028501011115611b28578586fd5b602092830195509350611b3f9187915086016119b2565b90509250925092565b600060208284031215611b59578081fd5b81518015158114611769578182fd5b600060208284031215611b79578081fd5b81516001600160e01b031981168114611769578182fd5b6000806000838503610180811215611ba6578384fd5b61014080821215611bb5578485fd5b611bbe81612965565b9150611bca87876119b2565b8252611bd987602088016119b2565b6020830152611beb87604088016119b2565b6040830152611bfd87606088016119b2565b60608301526080860135608083015260a086013560a0830152611c238760c088016119b2565b60c083015260e086810135908301526101008087013590830152610120808701359083015290935084013567ffffffffffffffff80821115611c63578384fd5b611c6f878388016119c9565b9350610160860135915080821115611c85578283fd5b50611c92868287016119c9565b9150509250925092565b600060208284031215611cad578081fd5b5051919050565b60008151808452611ccc81602086016020860161298c565b601f01601f19169290920160200192915050565b60008251611cf281846020870161298c565b9190910192915050565b60008451611d0e81846020890161298c565b91909101928352506020820152604001919050565b7f19457468657265756d205369676e6564204d6573736167653a0a3332000000008152601c810191909152603c0190565b7f66696c6c576974685065726d697428000000000000000000000000000000000081527f61646472657373206d616b6572416464722c0000000000000000000000000000600f8201527f616464726573732074616b65724173736574416464722c00000000000000000060218201527f61646472657373206d616b65724173736574416464722c00000000000000000060388201527f75696e743235362074616b65724173736574416d6f756e742c00000000000000604f8201527f75696e74323536206d616b65724173736574416d6f756e742c0000000000000060688201527f616464726573732074616b6572416464722c000000000000000000000000000060818201527f61646472657373207265636569766572416464722c000000000000000000000060938201526c1d5a5b9d0c8d4d881cd85b1d0b609a1b60a88201527f75696e7432353620646561646c696e652c00000000000000000000000000000060b58201527f75696e7432353620666565466163746f7200000000000000000000000000000060c6820152602960f81b60d782015260d80190565b7f4f7264657228000000000000000000000000000000000000000000000000000081527f616464726573732074616b6572416464722c000000000000000000000000000060068201527f61646472657373206d616b6572416464722c000000000000000000000000000060188201527f616464726573732074616b65724173736574416464722c000000000000000000602a8201527f61646472657373206d616b65724173736574416464722c00000000000000000060418201527f75696e743235362074616b65724173736574416d6f756e742c0000000000000060588201527f75696e74323536206d616b65724173736574416d6f756e742c0000000000000060718201526c1d5a5b9d0c8d4d881cd85b1d0b609a1b608a8201527f75696e7432353620646561646c696e652c00000000000000000000000000000060978201527f75696e7432353620666565466163746f7200000000000000000000000000000060a8820152602960f81b60b982015260ba0190565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b03929092168252602082015260400190565b901515815260200190565b90815260200190565b998a526001600160a01b0398891660208b015296881660408a0152948716606089015292909516608087015260a086015260c085019390935260e08401929092526101008301919091526101208201526101400190565b9a8b526001600160a01b03998a1660208c015297891660408b015295881660608a0152608089019490945260a0880192909252851660c087015290931660e08501526101008401929092526101208301919091526101408201526101600190565b6000838252604060208301526110586040830184611cb4565b93845260ff9290921660208401526040830152606082015260800190565b6000604082526121ed6040830185611cb4565b82810360208401526121ff8185611cb4565b95945050505050565b6000602082526117696020830184611cb4565b600061012080835261222f8184018d611cb4565b9150506001600160a01b03808b166020840152896040840152808916606084015280881660808401528660a084015280861660c0840152508360e083015261ffff83166101008301529a9950505050505050505050565b60208082526037908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a206c656e677468203937207265717569726564000000000000000000606082015260800190565b60208082526024908201527f5246513a207370656e6465722063616e206e6f74206265207a65726f2061646460408201527f7265737300000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526033908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a20696e76616c6964207369676e657200000000000000000000000000606082015260800190565b60208082526011908201527f5246513a206e6f74206f70657261746f72000000000000000000000000000000604082015260600190565b60208082526015908201527f5246513a20696e73756666696369656e74204554480000000000000000000000604082015260600190565b60208082526017908201527f5246513a20696e76616c69642066656520666163746f72000000000000000000604082015260600190565b6020808252601e908201527f536166654d6174683a207375627472616374696f6e206f766572666c6f770000604082015260600190565b6020808252601a908201527f536166654d6174683a206469766973696f6e206279207a65726f000000000000604082015260600190565b60208082526019908201527f5246513a20696e76616c6964204d4d207369676e617475726500000000000000604082015260600190565b60208082526025908201527f5246513a206f70657261746f722063616e206e6f74206265207a65726f20616460408201527f6472657373000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252601f908201527f5246513a206e6f7420746865205573657250726f787920636f6e747261637400604082015260600190565b60208082526021908201527f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f60408201527f7700000000000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526043908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a206c656e6774682067726561746572207468616e203020726571756960608201527f7265640000000000000000000000000000000000000000000000000000000000608082015260a00190565b6020808252603a908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a20756e737570706f72746564207369676e6174757265000000000000606082015260800190565b6020808252603b908201527f4c696242797465732372656164427974657333322067726561746572206f722060408201527f657175616c20746f203332206c656e6774682072657175697265640000000000606082015260800190565b60208082526036908201527f5369676e617475726556616c696461746f7223697356616c69645369676e617460408201527f7572653a20696c6c6567616c207369676e617475726500000000000000000000606082015260800190565b60208082526037908201527f4c6962427974657323706f704c617374427974653a206772656174657220746860408201527f616e207a65726f206c656e677468207265717569726564000000000000000000606082015260800190565b60208082526012908201527f5246513a2065787069726564206f726465720000000000000000000000000000604082015260600190565b6020808252601d908201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60408201527f6f74207375636365656400000000000000000000000000000000000000000000606082015260800190565b6020808252601b908201527f5246513a20696e76616c69642075736572207369676e61747572650000000000604082015260600190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b60208082526036908201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60408201527f20746f206e6f6e2d7a65726f20616c6c6f77616e636500000000000000000000606082015260800190565b60405181810167ffffffffffffffff8111828210171561298457600080fd5b604052919050565b60005b838110156129a757818101518382015260200161298f565b83811115610462575050600091015256fea2646970667358221220f26632dafe87e3c8aa58a5e213100d091fa2fc9f29134c87cfdfd2ffd162f5b564736f6c634300060c0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000009afc226dc049b99342ad6774eeb08bfa2f87446500000000000000000000000003f34be1bf910116595db1b11e9d1b2ca5d596590000000000000000000000003c68dfc45dc92c9c605d92b49858073e10b857a60000000000000000000000006d9cc14a1d36e6ff13fc6efa9e9326fcd12e7903000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
-----Decoded View---------------
Arg [0] : _operator (address): 0x9aFc226Dc049B99342Ad6774Eeb08BfA2F874465
Arg [1] : _userProxy (address): 0x03f34bE1BF910116595dB1b11E9d1B2cA5D59659
Arg [2] : _spender (address): 0x3c68dfc45dc92C9c605d92B49858073e10b857A6
Arg [3] : _permStorage (address): 0x6D9Cc14a1d36E6fF13fc6efA9e9326FcD12E7903
Arg [4] : _weth (address): 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2
-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 0000000000000000000000009afc226dc049b99342ad6774eeb08bfa2f874465
Arg [1] : 00000000000000000000000003f34be1bf910116595db1b11e9d1b2ca5d59659
Arg [2] : 0000000000000000000000003c68dfc45dc92c9c605d92b49858073e10b857a6
Arg [3] : 0000000000000000000000006d9cc14a1d36e6ff13fc6efa9e9326fcd12e7903
Arg [4] : 000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 27 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|---|---|---|---|---|
ETH | 87.99% | $2,432.02 | 6.8423 | $16,640.62 | |
ETH | 4.54% | $62,068 | 0.0138 | $859.18 | |
ETH | 4.19% | $0.999441 | 792.3857 | $791.94 | |
ETH | 1.69% | $0.852857 | 375.7338 | $320.45 | |
ETH | 1.07% | $0.699224 | 290.1759 | $202.9 | |
ETH | 0.27% | $0.738558 | 68.4548 | $50.56 | |
ETH | 0.14% | $0.224286 | 120.1303 | $26.94 | |
ETH | 0.10% | $0.460459 | 41.6245 | $19.17 | |
ETH | <0.01% | $0.082285 | 9.7107 | $0.799 | |
ETH | <0.01% | $0.452069 | 0.2682 | $0.1212 | |
POL | <0.01% | $0.375811 | 0.0002 | $0.000075 |
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.