Overview
MNT Balance
MNT Value
$0.00Latest 25 from a total of 605 transactions
| Transaction Hash |
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Multicall | 90583847 | 29 hrs ago | IN | 0 MNT | 0.0092791 | ||||
| Multicall | 90583822 | 29 hrs ago | IN | 0 MNT | 0.02829594 | ||||
| Multicall | 90583809 | 29 hrs ago | IN | 0 MNT | 0.00927723 | ||||
| Multicall | 90550098 | 2 days ago | IN | 0 MNT | 0.55934805 | ||||
| Multicall | 90429312 | 4 days ago | IN | 0 MNT | 0.5655877 | ||||
| Multicall | 90351452 | 6 days ago | IN | 0 MNT | 0.74592297 | ||||
| Multicall | 90197803 | 10 days ago | IN | 0 MNT | 0.03078683 | ||||
| Multicall | 90180460 | 10 days ago | IN | 0 MNT | 0.72724014 | ||||
| Multicall | 90179585 | 10 days ago | IN | 0 MNT | 0.84340839 | ||||
| Multicall | 90129199 | 11 days ago | IN | 0 MNT | 0.03610373 | ||||
| Multicall | 90129128 | 11 days ago | IN | 0 MNT | 0.025093 | ||||
| Multicall | 90129126 | 11 days ago | IN | 0 MNT | 0.03696535 | ||||
| Multicall | 90057038 | 13 days ago | IN | 0 MNT | 0.56951251 | ||||
| Execute | 90050075 | 13 days ago | IN | 5.60520089 MNT | 0.18764166 | ||||
| Multicall | 89788987 | 19 days ago | IN | 0 MNT | 0.48401754 | ||||
| Multicall | 89615495 | 23 days ago | IN | 1.01539637 MNT | 0.6474786 | ||||
| Multicall | 89573037 | 24 days ago | IN | 1 wei | 0.6467815 | ||||
| Multicall | 89567171 | 24 days ago | IN | 666.16626105 MNT | 0.65325858 | ||||
| Multicall | 89547721 | 25 days ago | IN | 382.24078198 MNT | 0.52345459 | ||||
| Multicall | 89434441 | 27 days ago | IN | 0 MNT | 0.01639485 | ||||
| Multicall | 89434440 | 27 days ago | IN | 0 MNT | 0.02495989 | ||||
| Multicall | 89405358 | 28 days ago | IN | 0 MNT | 0.003185 | ||||
| Multicall | 89405329 | 28 days ago | IN | 0 MNT | 0.00806628 | ||||
| Multicall | 89149376 | 34 days ago | IN | 321.00000941 MNT | 0.45018539 | ||||
| Multicall | 88896905 | 40 days ago | IN | 0 MNT | 0.49210032 |
Latest 25 internal transactions (View All)
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 90050075 | 13 days ago | 5.60520089 MNT | ||||
| 89615495 | 23 days ago | 1.01539637 MNT | ||||
| 89573037 | 24 days ago | 1 wei | ||||
| 89567171 | 24 days ago | 666.16626105 MNT | ||||
| 89547721 | 25 days ago | 382.24078198 MNT | ||||
| 89149376 | 34 days ago | 321.00000941 MNT | ||||
| 88888932 | 40 days ago | 190.87118546 MNT | ||||
| 88873376 | 40 days ago | 46.18352109 MNT | ||||
| 88670240 | 45 days ago | 154.78617862 MNT | ||||
| 88670189 | 45 days ago | 186.30547096 MNT | ||||
| 88416899 | 51 days ago | 219.026675 MNT | ||||
| 88400285 | 51 days ago | 287.9815789 MNT | ||||
| 88240442 | 55 days ago | 248.89938959 MNT | ||||
| 88150787 | 57 days ago | 53.63955526 MNT | ||||
| 88140917 | 57 days ago | 281.80902394 MNT | ||||
| 88053263 | 59 days ago | 467.70413822 MNT | ||||
| 88026156 | 60 days ago | 187.06232371 MNT | ||||
| 88026118 | 60 days ago | 99.04464024 MNT | ||||
| 88026104 | 60 days ago | 284.83811297 MNT | ||||
| 88016038 | 60 days ago | 303.69161065 MNT | ||||
| 88015943 | 60 days ago | 178.37842482 MNT | ||||
| 88010641 | 60 days ago | 177.52325838 MNT | ||||
| 88010638 | 60 days ago | 239.16327866 MNT | ||||
| 88010601 | 60 days ago | 177.52325838 MNT | ||||
| 87984425 | 61 days ago | 54.73968021 MNT |
Cross-Chain Transactions
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.27;
import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
import { EIP712 } from "@openzeppelin/contracts/utils/cryptography/EIP712.sol";
import { IIntent } from "./interfaces/IIntent.sol";
import { IWETH } from "./interfaces/telecoin/IWETH.sol";
import { Whitelist } from "./libs/Whitelist.sol";
import { IntentProxy } from "./proxy/IntentProxy.sol";
/**
* @title Intent
* @notice Enables batching multiple contract calls in a single transaction
* @dev Implements IIntent interface to execute multiple calls sequentially with EIP712 signatures
*/
contract Intent is IIntent, Whitelist, EIP712 {
using ECDSA for bytes32;
using SafeERC20 for IERC20;
/**
* @notice Address of this contract instance
* @dev Used for self-calls with multicall
*/
address public immutable SELF = address(this);
/**
* @notice EIP712 type hash for execute function
* @dev Used for structured data hashing in execute and executeRaw
*/
bytes32 public constant EXECUTE_INTENT_TYPEHASH = keccak256(
"ExecuteIntent(address sender,bytes32 dataHash,bytes32 tokenID,string intent,Call[] calls,address[] refundTokens,uint256 deadline)Call(address target,bytes data,uint256 value)"
);
/**
* @notice EIP712 type hash for executeRemote function
* @dev Used for structured data hashing in executeRemote and executeRemoteRaw
*/
bytes32 public constant EXECUTE_REMOTE_INTENT_TYPEHASH = keccak256(
"ExecuteRemoteIntent(address sender,bytes32 dataHash,bytes32 tokenID,string intent,Call[] calls,address[] refundTokens,uint256 deadline)Call(address target,bytes data,uint256 value)"
);
/**
* @notice EIP712 type hash for executeSignedAddress function
* @dev Used for structured data hashing in executeSignedAddress
*/
bytes32 public constant EXECUTE_INTENT_ADDRESS_TYPEHASH =
keccak256("ExecuteIntentAddress(bytes32 delegateDataHash,uint256 deadline)");
/**
* @notice EIP712 type hash for Call struct
* @dev Used for structured data hashing
*/
bytes32 public constant CALL_TYPEHASH = keccak256("Call(address target,bytes data,uint256 value)");
/**
* @notice Mapping of used dataHashes for replay protection
* @dev Prevents replay attacks by tracking used dataHash values
*/
mapping(bytes32 => bool) public usedHashes;
/// @notice Address of the wrapped native token contract
address public immutable wrappedNativeToken;
/**
* @notice Constructor that sets up to 5 authorized signer addresses
* @dev Addresses cannot be changed after deployment, initializes EIP712 domain
* @param authorized Array of authorized addresses for signature verification
*/
constructor(
address wrappedNativeToken_,
address[] memory authorized
) Whitelist(authorized) EIP712("Intent", "1") {
wrappedNativeToken = wrappedNativeToken_;
}
/**
* @notice Checks if a dataHash has been used
* @dev Used for replay protection in signed messages
* @param dataHash The dataHash to check
* @return Whether the dataHash has been used
*/
function isHashUsed(
bytes32 dataHash
) external view returns (bool) {
return usedHashes[dataHash];
}
/**
* @notice Returns the domain separator used for EIP712 signatures
* @dev Useful for off-chain signature generation
* @return The EIP712 domain separator
*/
function domainSeparatorV4() external view returns (bytes32) {
return _domainSeparatorV4();
}
/**
* @notice Calculate the address where IntentProxy will be deployed
* @dev Uses CREATE2 to derive deterministic address
* @param signed Whether this is for a signed intent execution
* @param delegateData The delegate call data that will be used
* @return The address where the IntentProxy will be deployed
*/
function getIntentAddress(
bool signed,
bytes calldata delegateData
) external view returns (address) {
_validateIntentSelector(delegateData);
try this.decodeIntentParams(delegateData) { }
catch {
revert InvalidIntentData();
}
// Calculate CREATE2 address for IntentProxy
return address(
uint160(
uint256(
keccak256(
abi.encodePacked(
bytes1(0xff),
address(this),
signed ? bytes32(uint256(1)) : bytes32(0),
keccak256(abi.encodePacked(type(IntentProxy).creationCode, abi.encode(delegateData)))
)
)
)
)
);
}
/**
* @notice Deploy and execute IntentProxy with the given delegate data
* @dev Creates a new IntentProxy that executes the delegate call and self-destructs
* @param delegateData The delegate call data to execute
*/
function executeIntentAddress(
bytes calldata delegateData
) external {
_validateIntentSelector(delegateData);
// Extract dataHash from ABI-encoded IntentParams: skip selector(4) + offset(32) = bytes 36:68
bytes32 dataHash = bytes32(delegateData[36:68]);
// skip selector(4) + offset(32) + dataHash(32) + tokenID(32) + sender_padding(12) = bytes 112:132
address trader = address(bytes20(delegateData[112:132]));
// Deploy and execute the proxy with zero salt
address intentAddress = address(new IntentProxy{ salt: bytes32(0) }(delegateData));
emit IntentAddressDeploy(dataHash, trader, intentAddress);
}
/**
* @notice Deploy and execute IntentProxy with the given delegate data (with signature verification)
* @dev Creates a new IntentProxy that executes the delegate call and self-destructs after validating signature
* @param delegateData The delegate call data to execute
* @param deadline Expiration timestamp for the signature
* @param signature EIP-712 signature from an authorized signer
*/
function signedExecuteIntentAddress(
bytes calldata delegateData,
uint256 deadline,
bytes calldata signature
) external {
require(block.timestamp <= deadline, ExpiredDeadline());
_validateIntentSelector(delegateData);
// Create structured data hash for signature verification
bytes32 structHash = keccak256(abi.encode(EXECUTE_INTENT_ADDRESS_TYPEHASH, keccak256(delegateData), deadline));
bytes32 messageHash = _hashTypedDataV4(structHash);
address signer = messageHash.recover(signature);
require(_isWhitelisted(signer), InvalidSignature());
// Extract dataHash from ABI-encoded IntentParams: skip selector(4) + offset(32) = bytes 36:68
bytes32 dataHash = bytes32(delegateData[36:68]);
// skip selector(4) + offset(32) + dataHash(32) + tokenID(32) + sender_padding(12) = bytes 112:132
address trader = address(bytes20(delegateData[112:132]));
// Deploy and execute the proxy with signed salt
address intentAddress = address(new IntentProxy{ salt: bytes32(uint256(1)) }(delegateData));
emit SignedIntentAddressDeploy(dataHash, trader, intentAddress, signer);
}
/**
* @notice Requests execution of multiple contract calls with no signature verification
* @dev Emits intent request event and reverts if any call fails
* @param params Intent execution parameters
* @return results Array of bytes containing the return data from each call
* @custom:emits IntentRequestedRaw when request is submitted
*/
function execute(
IntentParams calldata params
) external payable virtual returns (bytes[] memory results) {
emit IntentRequested(params.dataHash, params.tokenID, params.sender, params.intent, msg.value);
results = _multicall(params.calls);
// refund any leftover ETH and tokens
_refund(params.sender, params.refundTokens);
return results;
}
/**
* @notice Executes multiple contract calls in a single transaction with no signature verification
* @dev Uses delegatecall for IntentProxy compatibility
* @param params Intent execution parameters
* @return results Array of bytes containing the return data from each call
* @custom:emits IntentExecutedRaw on successful execution
* @custom:emits IntentFailedRaw on call failure with automatic refund
*/
function remoteExecute(
IntentParams calldata params
) external payable virtual returns (bytes[] memory results) {
// Execute multicall via delegatecall
(bool success, bytes memory returnData, bytes[] memory _results) = _delegateMulticall(params.calls);
if (success) {
emit IntentExecuted(params.dataHash, params.tokenID, params.sender, params.intent, msg.value);
} else {
emit IntentFailed(params.dataHash, params.tokenID, params.sender, params.intent, msg.value, returnData);
}
// Always refund leftover ETH and tokens
_refund(params.sender, params.refundTokens);
return _results;
}
/**
* @notice Requests execution of multiple contract calls with signature verification
* @dev Emits intent request event and reverts if any call fails or signature is invalid
* @param params Intent execution parameters
* @param deadline Expiration timestamp for the signature
* @param signature EIP-712 signature from an authorized signer
* @return results Array of bytes containing the return data from each call
* @custom:emits IntentRequested when request is submitted
* @custom:throws InvalidSignature if the signature is invalid or not from an authorized signer
*/
function signedExecute(
IntentParams calldata params,
uint256 deadline,
bytes calldata signature
) external payable virtual returns (bytes[] memory results) {
require(block.timestamp <= deadline, ExpiredDeadline());
require(!usedHashes[params.dataHash], DataHashAlreadyUsed());
// Create structured data hash using EIP712
bytes32 structHash = _hashIntentParams(EXECUTE_INTENT_TYPEHASH, params, deadline);
bytes32 messageHash = _hashTypedDataV4(structHash);
address signer = messageHash.recover(signature);
require(_isWhitelisted(signer), InvalidSignature());
// Mark dataHash as used
usedHashes[params.dataHash] = true;
emit SignedIntentRequested(params.dataHash, params.tokenID, params.sender, params.intent, msg.value, signer);
results = _multicall(params.calls);
_refund(params.sender, params.refundTokens);
return results;
}
/**
* @notice Executes multiple contract calls in a single transaction with signature verification
* @dev Uses delegatecall for IntentProxy compatibility
* @param params Intent execution parameters
* @param deadline Expiration timestamp for the signature
* @param signature EIP-712 signature from an authorized signer
* @return results Array of bytes containing the return data from each call
* @custom:emits IntentExecuted on successful execution
* @custom:emits IntentFailed on call failure with automatic refund
* @custom:throws InvalidSignature if the signature is invalid or not from an authorized signer
*/
function signedRemoteExecute(
IntentParams calldata params,
uint256 deadline,
bytes calldata signature
) external payable virtual returns (bytes[] memory results) {
require(block.timestamp <= deadline, ExpiredDeadline());
require(!usedHashes[params.dataHash], DataHashAlreadyUsed());
// Create structured data hash using EIP712
bytes32 structHash = _hashIntentParams(EXECUTE_REMOTE_INTENT_TYPEHASH, params, deadline);
bytes32 messageHash = _hashTypedDataV4(structHash);
address signer = messageHash.recover(signature);
require(_isWhitelisted(signer), InvalidSignature());
// Mark dataHash as used
usedHashes[params.dataHash] = true;
// Execute multicall via delegatecall
(bool success, bytes memory returnData, bytes[] memory _results) = _delegateMulticall(params.calls);
if (success) {
emit SignedIntentExecuted(params.dataHash, params.tokenID, params.sender, params.intent, msg.value, signer);
} else {
emit SignedIntentFailed(
params.dataHash, params.tokenID, params.sender, params.intent, msg.value, returnData
);
}
// Always refund leftover ETH and tokens
_refund(params.sender, params.refundTokens);
return _results;
}
/**
* @notice Public multicall function restricted to self-calls only
* @dev This function can only be called by the contract itself (used by executeRemote functions)
* @param calls Array of Call structs containing target addresses, values, and call data
* @return results Array of bytes containing the return data from each call
* @custom:throws Unauthorized if called by any address other than this contract
* @custom:throws CallFailed if any individual call reverts
*/
function multicall(
Call[] calldata calls
) public payable virtual returns (bytes[] memory) {
return _multicall(calls);
}
/**
* @notice Decodes IntentParams from delegate call data based on the function selector
* @dev Parses the function selector and extracts IntentParams from the encoded data
* Supports both signed and public execution methods, validating signature length for signed calls
* @param delegateData The complete delegate call data including selector and encoded parameters
* @return params The decoded IntentParams struct containing sender, calls, and refund information
* @custom:throws InvalidIntentData if selector is unsupported or signature length is invalid
*/
function decodeIntentParams(
bytes calldata delegateData
) external pure returns (IntentParams memory params) {
bytes4 selector = bytes4(delegateData[:4]);
bytes calldata data = delegateData[4:];
if (selector == this.signedRemoteExecute.selector || selector == this.signedExecute.selector) {
uint256 deadline;
bytes memory signature;
(params, deadline, signature) = abi.decode(data, (IntentParams, uint256, bytes));
if (signature.length != 65) {
revert InvalidIntentData();
}
return params;
}
if (selector == this.remoteExecute.selector || selector == this.execute.selector) {
params = abi.decode(data, (IntentParams));
return params;
}
revert InvalidIntentData();
}
/**
* @notice Internal function to execute multiple contract calls in a single transaction
* @dev Reverts if any of the calls fail
* @param calls Array of Call structs containing target addresses, values, and call data
* @return results Array of bytes containing the return data from each call
* @custom:throws CallFailed if any individual call reverts
*/
function _multicall(
Call[] calldata calls
) internal virtual returns (bytes[] memory) {
uint256 length = calls.length;
bytes[] memory results = new bytes[](length);
// Execute each call sequentially
for (uint256 i = 0; i < length; ++i) {
// Perform low-level call with specified value and data
// slither-disable-next-line arbitrary-send-eth
(bool success, bytes memory result) = calls[i].target.call{ value: calls[i].value }(calls[i].data);
// Revert if the call failed
if (!success) {
revert CallFailed();
}
// Store the call result
results[i] = result;
}
return results;
}
/**
* @notice Executes multicall via delegatecall for IntentProxy compatibility
* @dev Returns success flag, raw return data, and results array
* @param calls Array of Call structs to execute
* @return success Whether the delegatecall succeeded
* @return returnData The raw return data from the delegatecall (always returned)
* @return results Array of bytes containing return data from each call (empty array on failure)
*/
function _delegateMulticall(
Call[] calldata calls
) internal returns (bool success, bytes memory returnData, bytes[] memory results) {
// Encode the multicall function call
bytes memory multicallData = abi.encodeWithSelector(this.multicall.selector, calls);
// Execute delegatecall
(success, returnData) = SELF.delegatecall(multicallData);
if (success) {
// Decode and return the results
results = abi.decode(returnData, (bytes[]));
} else {
// Return empty array on failure
results = new bytes[](0);
}
}
/**
* @notice Validates that delegate data contains a valid function selector for proxy execution
* @dev Only executeRemoteRaw selector is allowed since proxies cannot handle signature verification
* @param delegateData The delegate call data to validate
* @custom:throws OnlyRemoteMethodsAllowed if selector is not executeRemoteRaw
*/
function _validateIntentSelector(
bytes calldata delegateData
) internal pure {
bytes4 selector = bytes4(delegateData[:4]);
if (selector != this.remoteExecute.selector) {
revert OnlyRemoteExecute();
}
}
/**
* @notice Refunds leftover ETH and tokens to the sender
* @dev Handles refunding of any remaining ETH and specified ERC20 tokens
* @param sender The address to refund to
* @param refundTokens Array of token addresses to refund (if any)
* @custom:throws RefundFailed if ETH refund fails
*/
function _refund(
address sender,
address[] memory refundTokens
) internal {
// Refund any leftover ETH
uint256 ethBalance = address(this).balance;
if (ethBalance > 0) {
// Intentionally allow transfer to fail for refunds
(bool success,) = sender.call{ value: ethBalance }("");
success;
if (!success) {
IWETH(wrappedNativeToken).deposit{ value: ethBalance }();
IERC20(wrappedNativeToken).safeTransfer(sender, ethBalance);
}
}
// Refund any specified tokens
for (uint256 i = 0; i < refundTokens.length; ++i) {
if (refundTokens[i] != address(0)) {
// Get token balance
uint256 balance = IERC20(refundTokens[i]).balanceOf(address(this));
if (balance > 0) {
// Intentionally allow transfer to fail for refunds
try IERC20(refundTokens[i]).transfer(sender, balance) { } catch { }
}
}
}
}
/**
* @notice Hashes IntentParams struct according to EIP712
* @dev Creates a hash of the entire IntentParams structure including nested Call array
* @param typeHash The EIP712 type hash to use for this specific method
* @param params Intent execution parameters
* @param deadline Expiration timestamp
* @return Hash of the structured data
*/
function _hashIntentParams(
bytes32 typeHash,
IntentParams calldata params,
uint256 deadline
) internal pure returns (bytes32) {
bytes32[] memory callHashes = new bytes32[](params.calls.length);
for (uint256 i = 0; i < params.calls.length; i++) {
callHashes[i] = keccak256(
abi.encode(
CALL_TYPEHASH, params.calls[i].target, keccak256(params.calls[i].data), params.calls[i].value
)
);
}
return keccak256(
abi.encode(
typeHash,
params.sender,
params.dataHash,
params.tokenID,
keccak256(bytes(params.intent)),
keccak256(abi.encodePacked(callHashes)),
keccak256(abi.encodePacked(params.refundTokens)),
deadline
)
);
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol)
pragma solidity ^0.8.20;
/**
* @dev Interface of the ERC20 standard as defined in the EIP.
*/
interface IERC20 {
/**
* @dev Emitted when `value` tokens are moved from one account (`from`) to
* another (`to`).
*
* Note that `value` may be zero.
*/
event Transfer(address indexed from, address indexed to, uint256 value);
/**
* @dev Emitted when the allowance of a `spender` for an `owner` is set by
* a call to {approve}. `value` is the new allowance.
*/
event Approval(address indexed owner, address indexed spender, uint256 value);
/**
* @dev Returns the value of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the value of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves a `value` amount of tokens from the caller's account to `to`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address to, uint256 value) 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 a `value` amount of tokens 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 value) external returns (bool);
/**
* @dev Moves a `value` amount of tokens from `from` to `to` using the
* allowance mechanism. `value` is then deducted from the caller's
* allowance.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transferFrom(address from, address to, uint256 value) external returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/utils/SafeERC20.sol)
pragma solidity ^0.8.20;
import {IERC20} from "../IERC20.sol";
import {IERC20Permit} from "../extensions/IERC20Permit.sol";
import {Address} from "../../../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 Address for address;
/**
* @dev An operation with an ERC20 token failed.
*/
error SafeERC20FailedOperation(address token);
/**
* @dev Indicates a failed `decreaseAllowance` request.
*/
error SafeERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease);
/**
* @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value,
* non-reverting calls are assumed to be successful.
*/
function safeTransfer(IERC20 token, address to, uint256 value) internal {
_callOptionalReturn(token, abi.encodeCall(token.transfer, (to, value)));
}
/**
* @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the
* calling contract. If `token` returns no value, non-reverting calls are assumed to be successful.
*/
function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal {
_callOptionalReturn(token, abi.encodeCall(token.transferFrom, (from, to, value)));
}
/**
* @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value,
* non-reverting calls are assumed to be successful.
*/
function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal {
uint256 oldAllowance = token.allowance(address(this), spender);
forceApprove(token, spender, oldAllowance + value);
}
/**
* @dev Decrease the calling contract's allowance toward `spender` by `requestedDecrease`. If `token` returns no
* value, non-reverting calls are assumed to be successful.
*/
function safeDecreaseAllowance(IERC20 token, address spender, uint256 requestedDecrease) internal {
unchecked {
uint256 currentAllowance = token.allowance(address(this), spender);
if (currentAllowance < requestedDecrease) {
revert SafeERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease);
}
forceApprove(token, spender, currentAllowance - requestedDecrease);
}
}
/**
* @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value,
* non-reverting calls are assumed to be successful. Meant to be used with tokens that require the approval
* to be set to zero before setting it to a non-zero value, such as USDT.
*/
function forceApprove(IERC20 token, address spender, uint256 value) internal {
bytes memory approvalCall = abi.encodeCall(token.approve, (spender, value));
if (!_callOptionalReturnBool(token, approvalCall)) {
_callOptionalReturn(token, abi.encodeCall(token.approve, (spender, 0)));
_callOptionalReturn(token, approvalCall);
}
}
/**
* @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);
if (returndata.length != 0 && !abi.decode(returndata, (bool))) {
revert SafeERC20FailedOperation(address(token));
}
}
/**
* @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).
*
* This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead.
*/
function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) {
// 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 cannot use {Address-functionCall} here since this should return false
// and not revert is the subcall reverts.
(bool success, bytes memory returndata) = address(token).call(data);
return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && address(token).code.length > 0;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/ECDSA.sol)
pragma solidity ^0.8.20;
/**
* @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.
*
* These functions can be used to verify that a message was signed by the holder
* of the private keys of a given address.
*/
library ECDSA {
enum RecoverError {
NoError,
InvalidSignature,
InvalidSignatureLength,
InvalidSignatureS
}
/**
* @dev The signature derives the `address(0)`.
*/
error ECDSAInvalidSignature();
/**
* @dev The signature has an invalid length.
*/
error ECDSAInvalidSignatureLength(uint256 length);
/**
* @dev The signature has an S value that is in the upper half order.
*/
error ECDSAInvalidSignatureS(bytes32 s);
/**
* @dev Returns the address that signed a hashed message (`hash`) with `signature` or an error. This will not
* return address(0) without also returning an error description. Errors are documented using an enum (error type)
* and a bytes32 providing additional information about the error.
*
* If no error is returned, then the address can be used for verification purposes.
*
* The `ecrecover` EVM precompile allows for malleable (non-unique) signatures:
* this function rejects them by requiring the `s` value to be in the lower
* half order, and the `v` value to be either 27 or 28.
*
* IMPORTANT: `hash` _must_ be the result of a hash operation for the
* verification to be secure: it is possible to craft signatures that
* recover to arbitrary addresses for non-hashed data. A safe way to ensure
* this is by receiving a hash of the original message (which may otherwise
* be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it.
*
* Documentation for signature generation:
* - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]
* - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]
*/
function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError, bytes32) {
if (signature.length == 65) {
bytes32 r;
bytes32 s;
uint8 v;
// ecrecover takes the signature parameters, and the only way to get them
// currently is to use assembly.
/// @solidity memory-safe-assembly
assembly {
r := mload(add(signature, 0x20))
s := mload(add(signature, 0x40))
v := byte(0, mload(add(signature, 0x60)))
}
return tryRecover(hash, v, r, s);
} else {
return (address(0), RecoverError.InvalidSignatureLength, bytes32(signature.length));
}
}
/**
* @dev Returns the address that signed a hashed message (`hash`) with
* `signature`. This address can then be used for verification purposes.
*
* The `ecrecover` EVM precompile allows for malleable (non-unique) signatures:
* this function rejects them by requiring the `s` value to be in the lower
* half order, and the `v` value to be either 27 or 28.
*
* IMPORTANT: `hash` _must_ be the result of a hash operation for the
* verification to be secure: it is possible to craft signatures that
* recover to arbitrary addresses for non-hashed data. A safe way to ensure
* this is by receiving a hash of the original message (which may otherwise
* be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it.
*/
function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {
(address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, signature);
_throwError(error, errorArg);
return recovered;
}
/**
* @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.
*
* See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]
*/
function tryRecover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address, RecoverError, bytes32) {
unchecked {
bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff);
// We do not check for an overflow here since the shift operation results in 0 or 1.
uint8 v = uint8((uint256(vs) >> 255) + 27);
return tryRecover(hash, v, r, s);
}
}
/**
* @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.
*/
function recover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address) {
(address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, r, vs);
_throwError(error, errorArg);
return recovered;
}
/**
* @dev Overload of {ECDSA-tryRecover} that receives the `v`,
* `r` and `s` signature fields separately.
*/
function tryRecover(
bytes32 hash,
uint8 v,
bytes32 r,
bytes32 s
) internal pure returns (address, RecoverError, bytes32) {
// EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature
// unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines
// the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most
// signatures from current libraries generate a unique signature with an s-value in the lower half order.
//
// If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value
// with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or
// vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept
// these malleable signatures as well.
if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {
return (address(0), RecoverError.InvalidSignatureS, s);
}
// If the signature is valid (and not malleable), return the signer address
address signer = ecrecover(hash, v, r, s);
if (signer == address(0)) {
return (address(0), RecoverError.InvalidSignature, bytes32(0));
}
return (signer, RecoverError.NoError, bytes32(0));
}
/**
* @dev Overload of {ECDSA-recover} that receives the `v`,
* `r` and `s` signature fields separately.
*/
function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {
(address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, v, r, s);
_throwError(error, errorArg);
return recovered;
}
/**
* @dev Optionally reverts with the corresponding custom error according to the `error` argument provided.
*/
function _throwError(RecoverError error, bytes32 errorArg) private pure {
if (error == RecoverError.NoError) {
return; // no error: do nothing
} else if (error == RecoverError.InvalidSignature) {
revert ECDSAInvalidSignature();
} else if (error == RecoverError.InvalidSignatureLength) {
revert ECDSAInvalidSignatureLength(uint256(errorArg));
} else if (error == RecoverError.InvalidSignatureS) {
revert ECDSAInvalidSignatureS(errorArg);
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/EIP712.sol)
pragma solidity ^0.8.20;
import {MessageHashUtils} from "./MessageHashUtils.sol";
import {ShortStrings, ShortString} from "../ShortStrings.sol";
import {IERC5267} from "../../interfaces/IERC5267.sol";
/**
* @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.
*
* The encoding scheme specified in the EIP requires a domain separator and a hash of the typed structured data, whose
* encoding is very generic and therefore its implementation in Solidity is not feasible, thus this contract
* does not implement the encoding itself. Protocols need to implement the type-specific encoding they need in order to
* produce the hash of their typed data using a combination of `abi.encode` and `keccak256`.
*
* This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding
* scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA
* ({_hashTypedDataV4}).
*
* The implementation of the domain separator was designed to be as efficient as possible while still properly updating
* the chain id to protect against replay attacks on an eventual fork of the chain.
*
* NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method
* https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].
*
* NOTE: In the upgradeable version of this contract, the cached values will correspond to the address, and the domain
* separator of the implementation contract. This will cause the {_domainSeparatorV4} function to always rebuild the
* separator from the immutable values, which is cheaper than accessing a cached version in cold storage.
*
* @custom:oz-upgrades-unsafe-allow state-variable-immutable
*/
abstract contract EIP712 is IERC5267 {
using ShortStrings for *;
bytes32 private constant TYPE_HASH =
keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)");
// Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to
// invalidate the cached domain separator if the chain id changes.
bytes32 private immutable _cachedDomainSeparator;
uint256 private immutable _cachedChainId;
address private immutable _cachedThis;
bytes32 private immutable _hashedName;
bytes32 private immutable _hashedVersion;
ShortString private immutable _name;
ShortString private immutable _version;
string private _nameFallback;
string private _versionFallback;
/**
* @dev Initializes the domain separator and parameter caches.
*
* The meaning of `name` and `version` is specified in
* https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]:
*
* - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol.
* - `version`: the current major version of the signing domain.
*
* NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart
* contract upgrade].
*/
constructor(string memory name, string memory version) {
_name = name.toShortStringWithFallback(_nameFallback);
_version = version.toShortStringWithFallback(_versionFallback);
_hashedName = keccak256(bytes(name));
_hashedVersion = keccak256(bytes(version));
_cachedChainId = block.chainid;
_cachedDomainSeparator = _buildDomainSeparator();
_cachedThis = address(this);
}
/**
* @dev Returns the domain separator for the current chain.
*/
function _domainSeparatorV4() internal view returns (bytes32) {
if (address(this) == _cachedThis && block.chainid == _cachedChainId) {
return _cachedDomainSeparator;
} else {
return _buildDomainSeparator();
}
}
function _buildDomainSeparator() private view returns (bytes32) {
return keccak256(abi.encode(TYPE_HASH, _hashedName, _hashedVersion, block.chainid, address(this)));
}
/**
* @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this
* function returns the hash of the fully encoded EIP712 message for this domain.
*
* This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example:
*
* ```solidity
* bytes32 digest = _hashTypedDataV4(keccak256(abi.encode(
* keccak256("Mail(address to,string contents)"),
* mailTo,
* keccak256(bytes(mailContents))
* )));
* address signer = ECDSA.recover(digest, signature);
* ```
*/
function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) {
return MessageHashUtils.toTypedDataHash(_domainSeparatorV4(), structHash);
}
/**
* @dev See {IERC-5267}.
*/
function eip712Domain()
public
view
virtual
returns (
bytes1 fields,
string memory name,
string memory version,
uint256 chainId,
address verifyingContract,
bytes32 salt,
uint256[] memory extensions
)
{
return (
hex"0f", // 01111
_EIP712Name(),
_EIP712Version(),
block.chainid,
address(this),
bytes32(0),
new uint256[](0)
);
}
/**
* @dev The name parameter for the EIP712 domain.
*
* NOTE: By default this function reads _name which is an immutable value.
* It only reads from storage if necessary (in case the value is too large to fit in a ShortString).
*/
// solhint-disable-next-line func-name-mixedcase
function _EIP712Name() internal view returns (string memory) {
return _name.toStringWithFallback(_nameFallback);
}
/**
* @dev The version parameter for the EIP712 domain.
*
* NOTE: By default this function reads _version which is an immutable value.
* It only reads from storage if necessary (in case the value is too large to fit in a ShortString).
*/
// solhint-disable-next-line func-name-mixedcase
function _EIP712Version() internal view returns (string memory) {
return _version.toStringWithFallback(_versionFallback);
}
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.27;
/**
* @title Intent Interface
* @notice Interface for batching multiple contract calls in a single transaction
* @dev Enables atomic execution of multiple function calls
*/
interface IIntent {
/**
* @notice Thrown when any call in the batch fails
* @dev Reverts the entire transaction if any call fails
*/
error CallFailed();
/**
* @notice Thrown when the signature is invalid
* @dev Used to indicate that the provided signature does not match the expected format
*/
error InvalidSignature();
/**
* @notice Thrown when delegate data contains invalid function selector
* @dev Only remoteExecute selector is allowed for delegate calls
*/
error OnlyRemoteExecute();
/**
* @notice Thrown when intent data is invalid
* @dev Used to indicate that the provided intent parameters are not valid
*/
error InvalidIntentData();
/**
* @notice Thrown when the deadline has expired
* @dev Used when block.timestamp exceeds the provided deadline
*/
error ExpiredDeadline();
/**
* @notice Thrown when a dataHash has already been used
* @dev Prevents replay attacks by ensuring each dataHash is only used once
*/
error DataHashAlreadyUsed();
/**
* @notice Parameters for a single call in the batch
* @param target Address of the contract to call
* @param data Encoded function call data
* @param value Amount of native currency to send with the call
*/
struct Call {
address target;
bytes data;
uint256 value;
}
/**
* @notice Parameters for intent execution
* @param sender Address of the sender executing the intent
* @param dataHash Unique identifier hash for this execution
* @param tokenID Identifier for the token this execution is related to
* @param intent String description of the operation's intent
* @param calls Array of Call structs containing target addresses, values, and call data
* @param refundTokens Array of token addresses to refund any leftover balances
*/
struct IntentParams {
bytes32 dataHash;
bytes32 tokenID;
address sender;
string intent;
Call[] calls;
address[] refundTokens;
}
/**
* @notice Emitted when an intent is requested (without signature verification)
* @param trader Address of the trader requesting the intent
* @param dataHash Unique identifier for the intent
* @param tokenID Unique identifier for the token
* @param intent The intent being requested
* @param value The value associated with the intent
*/
event IntentRequested(
bytes32 indexed dataHash, bytes32 indexed tokenID, address indexed trader, string intent, uint256 value
);
/**
* @notice Emitted when an intent is successfully executed (without signature verification)
* @param trader Address of the trader whose intent was executed
* @param dataHash Unique identifier for the intent
* @param tokenID Unique identifier for the token
* @param intent The intent that was executed
* @param value The value associated with the intent
*/
event IntentExecuted(
bytes32 indexed dataHash, bytes32 indexed tokenID, address indexed trader, string intent, uint256 value
);
/**
* @notice Emitted when an intent fails to execute (without signature verification)
* @param trader Address of the trader whose intent failed
* @param dataHash Unique identifier for the intent
* @param tokenID Unique identifier for the token
* @param intent The intent that failed
* @param value The value associated with the intent
* @param reason The failure reason from the contract call
*/
event IntentFailed(
bytes32 indexed dataHash,
bytes32 indexed tokenID,
address indexed trader,
string intent,
uint256 value,
bytes reason
);
/**
* @notice Emitted when an intent is requested
* @param trader Address of the trader requesting the intent
* @param dataHash Unique identifier for the intent
* @param tokenID Unique identifier for the token
* @param intent The intent being requested
* @param value The value associated with the intent
*/
event SignedIntentRequested(
bytes32 indexed dataHash,
bytes32 indexed tokenID,
address indexed trader,
string intent,
uint256 value,
address signer
);
/**
* @notice Emitted when an intent is successfully executed
* @param trader Address of the trader whose intent was executed
* @param dataHash Unique identifier for the intent
* @param tokenID Unique identifier for the token
* @param intent The intent that was executed
* @param value The value associated with the intent
*/
event SignedIntentExecuted(
bytes32 indexed dataHash,
bytes32 indexed tokenID,
address indexed trader,
string intent,
uint256 value,
address signer
);
/**
* @notice Emitted when an intent fails to execute
* @param trader Address of the trader whose intent failed
* @param dataHash Unique identifier for the intent
* @param tokenID Unique identifier for the token
* @param intent The intent that failed
* @param value The value associated with the intent
* @param reason The failure reason from the contract call
*/
event SignedIntentFailed(
bytes32 indexed dataHash,
bytes32 indexed tokenID,
address indexed trader,
string intent,
uint256 value,
bytes reason
);
/**
* @notice Emitted when an IntentProxy is deployed via executeIntentAddress
* @param dataHash The hash of the intent data
* @param intentAddress The deployed proxy address
*/
event IntentAddressDeploy(bytes32 indexed dataHash, address indexed trader, address indexed intentAddress);
/**
* @notice Emitted when an IntentProxy is deployed via signedExecuteIntentAddress
* @param dataHash The hash of the intent data
* @param intentAddress The deployed proxy address
*/
event SignedIntentAddressDeploy(
bytes32 indexed dataHash, address indexed trader, address indexed intentAddress, address signer
);
/**
* @notice Checks if a dataHash has been used
* @dev Used for replay protection in signed messages
* @param dataHash The dataHash to check
* @return Whether the dataHash has been used
*/
function isHashUsed(
bytes32 dataHash
) external view returns (bool);
/**
* @notice Returns the domain separator used for EIP712 signatures
* @dev Useful for off-chain signature generation
* @return The EIP712 domain separator
*/
function domainSeparatorV4() external view returns (bytes32);
/**
* @notice Calculate the address where IntentProxy will be deployed
* @dev Uses CREATE2 to derive deterministic address
* @param signed Whether this is for a signed intent execution
* @param delegateData The delegate call data that will be used
* @return The address where the IntentProxy will be deployed
*/
function getIntentAddress(
bool signed,
bytes calldata delegateData
) external view returns (address);
/**
* @notice Deploy and execute IntentProxy with the given delegate data (unsigned)
* @dev Creates a new IntentProxy that executes the delegate call and self-destructs
* @param delegateData The delegate call data to execute
*/
function executeIntentAddress(
bytes calldata delegateData
) external;
/**
* @notice Deploy and execute IntentProxy with the given delegate data (with signature verification)
* @dev Creates a new IntentProxy that executes the delegate call and self-destructs after validating signature
* @param delegateData The delegate call data to execute
* @param deadline Expiration timestamp for the signature
* @param signature EIP-712 signature from an authorized signer
*/
function signedExecuteIntentAddress(
bytes calldata delegateData,
uint256 deadline,
bytes calldata signature
) external;
/**
* @notice Executes multiple contract calls in a single transaction without signature verification
* @dev All calls are executed sequentially and atomically
* @param params Intent execution parameters
* @return results Array containing the return data from each call
* @custom:throws CallFailed if any call in the batch fails
*/
function execute(
IntentParams calldata params
) external payable returns (bytes[] memory results);
/**
* @notice Executes multiple contract calls in a single transaction with no signature verification
* @dev Uses try-catch to handle call failures gracefully with refunds and failure events
* @param params Intent execution parameters
* @return results Array of bytes containing the return data from each call
* @custom:emits IntentExecuted on successful execution
* @custom:emits IntentFailed on call failure with automatic refund
*/
function remoteExecute(
IntentParams calldata params
) external payable returns (bytes[] memory results);
/**
* @notice Executes multiple contract calls in a single transaction with signature verification
* @dev All calls are executed sequentially and atomically
* @param params Intent execution parameters
* @param deadline Expiration timestamp for the signature
* @param signature EIP-712 signature from an authorized signer
* @return results Array containing the return data from each call
* @custom:throws CallFailed if any call in the batch fails
* @custom:throws InvalidSignature if the signature is invalid or not from an authorized signer
*/
function signedExecute(
IntentParams calldata params,
uint256 deadline,
bytes calldata signature
) external payable returns (bytes[] memory results);
/**
* @notice Executes multiple contract calls in a single transaction with signature verification
* @dev Uses try-catch to handle call failures gracefully with refunds and failure events
* @param params Intent execution parameters
* @param deadline Expiration timestamp for the signature
* @param signature EIP-712 signature from an authorized signer
* @return results Array of bytes containing the return data from each call
* @custom:emits IntentExecuted on successful execution
* @custom:emits IntentFailed on call failure with automatic refund
* @custom:throws InvalidSignature if the signature is invalid or not from an authorized signer
*/
function signedRemoteExecute(
IntentParams calldata params,
uint256 deadline,
bytes calldata signature
) external payable returns (bytes[] memory results);
/**
* @notice Executes multiple contract calls in a single transaction
* @dev All calls are executed sequentially and atomically
* @param calls Array of Call structs containing call parameters
* @return results Array containing the return data from each call
* @custom:throws CallFailed if any call in the batch fails
*/
function multicall(
Call[] calldata calls
) external payable returns (bytes[] memory results);
/**
* @notice Decodes intent parameters from delegate data
* @dev Extracts IntentParams from encoded function calls
* @param delegateData The delegate call data to decode
* @return params The decoded intent parameters
*/
function decodeIntentParams(
bytes calldata delegateData
) external pure returns (IntentParams memory params);
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.27;
/**
* @title IWETH
* @notice Interface for Wrapped Ether (WETH) - an ERC20 token that wraps native ETH
*/
interface IWETH {
/**
* @notice Deposits native ETH into the contract to mint WETH tokens
* @dev The amount of WETH minted equals the amount of ETH sent with the transaction
*/
function deposit() external payable;
/**
* @notice Unwraps WETH back to ETH by burning tokens and transferring ETH
* @param wad Amount of WETH to unwrap into ETH
*/
function withdraw(
uint256 wad
) external;
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.27;
/**
* @title Whitelist
* @notice Abstract contract for managing a whitelist of authorized addresses
* @dev Provides validation functionality for up to 5 authorized addresses.
* This is an abstract contract that must be inherited by other contracts
* to provide whitelist-based access control functionality.
*/
abstract contract Whitelist {
/**
* @notice Error thrown when too many addresses are provided
* @dev Maximum of 5 addresses allowed
*/
error TooManyAddresses();
/**
* @notice Error thrown when zero address is provided in whitelist
* @dev All whitelist addresses must be non-zero
*/
error ZeroAddressNotAllowed();
/**
* @notice First whitelisted signer address
* @dev Can be address(0) if not set in constructor
*/
address public immutable whitelisted1;
/**
* @notice Second whitelisted signer address
* @dev Can be address(0) if not set in constructor
*/
address public immutable whitelisted2;
/**
* @notice Third whitelisted signer address
* @dev Can be address(0) if not set in constructor
*/
address public immutable whitelisted3;
/**
* @notice Fourth whitelisted signer address
* @dev Can be address(0) if not set in constructor
*/
address public immutable whitelisted4;
/**
* @notice Fifth whitelisted signer address
* @dev Can be address(0) if not set in constructor
*/
address public immutable whitelisted5;
/**
* @notice Constructor that sets up to 5 authorized signer addresses
* @dev Addresses cannot be changed after deployment
* @param authorized Array of authorized addresses for signature verification
*/
constructor(
address[] memory authorized
) {
if (authorized.length > 5) {
revert TooManyAddresses();
}
for (uint256 i = 0; i < authorized.length; ++i) {
if (authorized[i] == address(0)) {
revert ZeroAddressNotAllowed();
}
}
whitelisted1 = authorized.length > 0 ? authorized[0] : address(0);
whitelisted2 = authorized.length > 1 ? authorized[1] : address(0);
whitelisted3 = authorized.length > 2 ? authorized[2] : address(0);
whitelisted4 = authorized.length > 3 ? authorized[3] : address(0);
whitelisted5 = authorized.length > 4 ? authorized[4] : address(0);
}
/**
* @notice Checks if an address is whitelisted
* @dev Compares against all configured authorized addresses
* @param account The address to check for whitelist status
* @return True if the account is in the whitelist, false otherwise
*/
function _isWhitelisted(
address account
) internal view returns (bool) {
return account != address(0)
&& (account == whitelisted1
|| account == whitelisted2
|| account == whitelisted3
|| account == whitelisted4
|| account == whitelisted5);
}
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.27;
/**
* @title IntentProxy
* @notice Proxy contract for executing Intent operations with deterministic addresses
* @dev Creates deterministic proxy instances via CREATE2, executes delegate calls, then self-destructs
* Used to provide deterministic addresses for complex multi-call operations
*/
contract IntentProxy {
/**
* @notice Initializes the proxy and executes delegate call
* @dev Delegates call to the sender (Intent contract) and self-destructs after execution
* @param delegateData The delegate call data to execute
*/
constructor(
bytes memory delegateData
) {
(bool success, bytes memory data) = msg.sender.delegatecall(delegateData);
if (!success) {
assembly {
revert(add(32, data), mload(data))
}
}
selfdestruct(payable(msg.sender));
}
/**
* @notice Allows the proxy to receive ETH
* @dev Required for implementation to handle ETH transfers
* @dev Used to unwrap WETH tokens back to ETH
*/
receive() external payable { }
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/extensions/IERC20Permit.sol)
pragma solidity ^0.8.20;
/**
* @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
* https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
*
* Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
* presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't
* need to send a transaction, and thus is not required to hold Ether at all.
*
* ==== Security Considerations
*
* There are two important considerations concerning the use of `permit`. The first is that a valid permit signature
* expresses an allowance, and it should not be assumed to convey additional meaning. In particular, it should not be
* considered as an intention to spend the allowance in any specific way. The second is that because permits have
* built-in replay protection and can be submitted by anyone, they can be frontrun. A protocol that uses permits should
* take this into consideration and allow a `permit` call to fail. Combining these two aspects, a pattern that may be
* generally recommended is:
*
* ```solidity
* function doThingWithPermit(..., uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) public {
* try token.permit(msg.sender, address(this), value, deadline, v, r, s) {} catch {}
* doThing(..., value);
* }
*
* function doThing(..., uint256 value) public {
* token.safeTransferFrom(msg.sender, address(this), value);
* ...
* }
* ```
*
* Observe that: 1) `msg.sender` is used as the owner, leaving no ambiguity as to the signer intent, and 2) the use of
* `try/catch` allows the permit to fail and makes the code tolerant to frontrunning. (See also
* {SafeERC20-safeTransferFrom}).
*
* Additionally, note that smart contract wallets (such as Argent or Safe) are not able to produce permit signatures, so
* contracts should have entry points that don't rely on permit.
*/
interface IERC20Permit {
/**
* @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,
* given ``owner``'s signed approval.
*
* IMPORTANT: The same issues {IERC20-approve} has related to transaction
* ordering also apply here.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - `spender` cannot be the zero address.
* - `deadline` must be a timestamp in the future.
* - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
* over the EIP712-formatted function arguments.
* - the signature must use ``owner``'s current nonce (see {nonces}).
*
* For more information on the signature format, see the
* https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
* section].
*
* CAUTION: See Security Considerations above.
*/
function permit(
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) external;
/**
* @dev Returns the current nonce for `owner`. This value must be
* included whenever a signature is generated for {permit}.
*
* Every successful call to {permit} increases ``owner``'s nonce by one. This
* prevents a signature from being used multiple times.
*/
function nonces(address owner) external view returns (uint256);
/**
* @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.
*/
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view returns (bytes32);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/Address.sol)
pragma solidity ^0.8.20;
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev The ETH balance of the account is not enough to perform the operation.
*/
error AddressInsufficientBalance(address account);
/**
* @dev There's no code at `target` (it is not a contract).
*/
error AddressEmptyCode(address target);
/**
* @dev A call to an address target failed. The target may have reverted.
*/
error FailedInnerCall();
/**
* @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://consensys.net/diligence/blog/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.8.20/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
if (address(this).balance < amount) {
revert AddressInsufficientBalance(address(this));
}
(bool success, ) = recipient.call{value: amount}("");
if (!success) {
revert FailedInnerCall();
}
}
/**
* @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 or custom error, it is bubbled
* up by this function (like regular Solidity function calls). However, if
* the call reverted with no returned reason, this function reverts with a
* {FailedInnerCall} error.
*
* 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.
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0);
}
/**
* @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`.
*/
function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {
if (address(this).balance < value) {
revert AddressInsufficientBalance(address(this));
}
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResultFromTarget(target, success, returndata);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResultFromTarget(target, success, returndata);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResultFromTarget(target, success, returndata);
}
/**
* @dev Tool to verify that a low level call to smart-contract was successful, and reverts if the target
* was not a contract or bubbling up the revert reason (falling back to {FailedInnerCall}) in case of an
* unsuccessful call.
*/
function verifyCallResultFromTarget(
address target,
bool success,
bytes memory returndata
) internal view returns (bytes memory) {
if (!success) {
_revert(returndata);
} else {
// only check if target is a contract if the call was successful and the return data is empty
// otherwise we already know that it was a contract
if (returndata.length == 0 && target.code.length == 0) {
revert AddressEmptyCode(target);
}
return returndata;
}
}
/**
* @dev Tool to verify that a low level call was successful, and reverts if it wasn't, either by bubbling the
* revert reason or with a default {FailedInnerCall} error.
*/
function verifyCallResult(bool success, bytes memory returndata) internal pure returns (bytes memory) {
if (!success) {
_revert(returndata);
} else {
return returndata;
}
}
/**
* @dev Reverts with returndata if present. Otherwise reverts with {FailedInnerCall}.
*/
function _revert(bytes memory returndata) private pure {
// 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
/// @solidity memory-safe-assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert FailedInnerCall();
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/MessageHashUtils.sol)
pragma solidity ^0.8.20;
import {Strings} from "../Strings.sol";
/**
* @dev Signature message hash utilities for producing digests to be consumed by {ECDSA} recovery or signing.
*
* The library provides methods for generating a hash of a message that conforms to the
* https://eips.ethereum.org/EIPS/eip-191[EIP 191] and https://eips.ethereum.org/EIPS/eip-712[EIP 712]
* specifications.
*/
library MessageHashUtils {
/**
* @dev Returns the keccak256 digest of an EIP-191 signed data with version
* `0x45` (`personal_sign` messages).
*
* The digest is calculated by prefixing a bytes32 `messageHash` with
* `"\x19Ethereum Signed Message:\n32"` and hashing the result. It corresponds with the
* hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method.
*
* NOTE: The `messageHash` parameter is intended to be the result of hashing a raw message with
* keccak256, although any bytes32 value can be safely used because the final digest will
* be re-hashed.
*
* See {ECDSA-recover}.
*/
function toEthSignedMessageHash(bytes32 messageHash) internal pure returns (bytes32 digest) {
/// @solidity memory-safe-assembly
assembly {
mstore(0x00, "\x19Ethereum Signed Message:\n32") // 32 is the bytes-length of messageHash
mstore(0x1c, messageHash) // 0x1c (28) is the length of the prefix
digest := keccak256(0x00, 0x3c) // 0x3c is the length of the prefix (0x1c) + messageHash (0x20)
}
}
/**
* @dev Returns the keccak256 digest of an EIP-191 signed data with version
* `0x45` (`personal_sign` messages).
*
* The digest is calculated by prefixing an arbitrary `message` with
* `"\x19Ethereum Signed Message:\n" + len(message)` and hashing the result. It corresponds with the
* hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method.
*
* See {ECDSA-recover}.
*/
function toEthSignedMessageHash(bytes memory message) internal pure returns (bytes32) {
return
keccak256(bytes.concat("\x19Ethereum Signed Message:\n", bytes(Strings.toString(message.length)), message));
}
/**
* @dev Returns the keccak256 digest of an EIP-191 signed data with version
* `0x00` (data with intended validator).
*
* The digest is calculated by prefixing an arbitrary `data` with `"\x19\x00"` and the intended
* `validator` address. Then hashing the result.
*
* See {ECDSA-recover}.
*/
function toDataWithIntendedValidatorHash(address validator, bytes memory data) internal pure returns (bytes32) {
return keccak256(abi.encodePacked(hex"19_00", validator, data));
}
/**
* @dev Returns the keccak256 digest of an EIP-712 typed data (EIP-191 version `0x01`).
*
* The digest is calculated from a `domainSeparator` and a `structHash`, by prefixing them with
* `\x19\x01` and hashing the result. It corresponds to the hash signed by the
* https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] JSON-RPC method as part of EIP-712.
*
* See {ECDSA-recover}.
*/
function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32 digest) {
/// @solidity memory-safe-assembly
assembly {
let ptr := mload(0x40)
mstore(ptr, hex"19_01")
mstore(add(ptr, 0x02), domainSeparator)
mstore(add(ptr, 0x22), structHash)
digest := keccak256(ptr, 0x42)
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/ShortStrings.sol)
pragma solidity ^0.8.20;
import {StorageSlot} from "./StorageSlot.sol";
// | string | 0xAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA |
// | length | 0x BB |
type ShortString is bytes32;
/**
* @dev This library provides functions to convert short memory strings
* into a `ShortString` type that can be used as an immutable variable.
*
* Strings of arbitrary length can be optimized using this library if
* they are short enough (up to 31 bytes) by packing them with their
* length (1 byte) in a single EVM word (32 bytes). Additionally, a
* fallback mechanism can be used for every other case.
*
* Usage example:
*
* ```solidity
* contract Named {
* using ShortStrings for *;
*
* ShortString private immutable _name;
* string private _nameFallback;
*
* constructor(string memory contractName) {
* _name = contractName.toShortStringWithFallback(_nameFallback);
* }
*
* function name() external view returns (string memory) {
* return _name.toStringWithFallback(_nameFallback);
* }
* }
* ```
*/
library ShortStrings {
// Used as an identifier for strings longer than 31 bytes.
bytes32 private constant FALLBACK_SENTINEL = 0x00000000000000000000000000000000000000000000000000000000000000FF;
error StringTooLong(string str);
error InvalidShortString();
/**
* @dev Encode a string of at most 31 chars into a `ShortString`.
*
* This will trigger a `StringTooLong` error is the input string is too long.
*/
function toShortString(string memory str) internal pure returns (ShortString) {
bytes memory bstr = bytes(str);
if (bstr.length > 31) {
revert StringTooLong(str);
}
return ShortString.wrap(bytes32(uint256(bytes32(bstr)) | bstr.length));
}
/**
* @dev Decode a `ShortString` back to a "normal" string.
*/
function toString(ShortString sstr) internal pure returns (string memory) {
uint256 len = byteLength(sstr);
// using `new string(len)` would work locally but is not memory safe.
string memory str = new string(32);
/// @solidity memory-safe-assembly
assembly {
mstore(str, len)
mstore(add(str, 0x20), sstr)
}
return str;
}
/**
* @dev Return the length of a `ShortString`.
*/
function byteLength(ShortString sstr) internal pure returns (uint256) {
uint256 result = uint256(ShortString.unwrap(sstr)) & 0xFF;
if (result > 31) {
revert InvalidShortString();
}
return result;
}
/**
* @dev Encode a string into a `ShortString`, or write it to storage if it is too long.
*/
function toShortStringWithFallback(string memory value, string storage store) internal returns (ShortString) {
if (bytes(value).length < 32) {
return toShortString(value);
} else {
StorageSlot.getStringSlot(store).value = value;
return ShortString.wrap(FALLBACK_SENTINEL);
}
}
/**
* @dev Decode a string that was encoded to `ShortString` or written to storage using {setWithFallback}.
*/
function toStringWithFallback(ShortString value, string storage store) internal pure returns (string memory) {
if (ShortString.unwrap(value) != FALLBACK_SENTINEL) {
return toString(value);
} else {
return store;
}
}
/**
* @dev Return the length of a string that was encoded to `ShortString` or written to storage using
* {setWithFallback}.
*
* WARNING: This will return the "byte length" of the string. This may not reflect the actual length in terms of
* actual characters as the UTF-8 encoding of a single character can span over multiple bytes.
*/
function byteLengthWithFallback(ShortString value, string storage store) internal view returns (uint256) {
if (ShortString.unwrap(value) != FALLBACK_SENTINEL) {
return byteLength(value);
} else {
return bytes(store).length;
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC5267.sol)
pragma solidity ^0.8.20;
interface IERC5267 {
/**
* @dev MAY be emitted to signal that the domain could have changed.
*/
event EIP712DomainChanged();
/**
* @dev returns the fields and values that describe the domain separator used by this contract for EIP-712
* signature.
*/
function eip712Domain()
external
view
returns (
bytes1 fields,
string memory name,
string memory version,
uint256 chainId,
address verifyingContract,
bytes32 salt,
uint256[] memory extensions
);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/Strings.sol)
pragma solidity ^0.8.20;
import {Math} from "./math/Math.sol";
import {SignedMath} from "./math/SignedMath.sol";
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant HEX_DIGITS = "0123456789abcdef";
uint8 private constant ADDRESS_LENGTH = 20;
/**
* @dev The `value` string doesn't fit in the specified `length`.
*/
error StringsInsufficientHexLength(uint256 value, uint256 length);
/**
* @dev Converts a `uint256` to its ASCII `string` decimal representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
unchecked {
uint256 length = Math.log10(value) + 1;
string memory buffer = new string(length);
uint256 ptr;
/// @solidity memory-safe-assembly
assembly {
ptr := add(buffer, add(32, length))
}
while (true) {
ptr--;
/// @solidity memory-safe-assembly
assembly {
mstore8(ptr, byte(mod(value, 10), HEX_DIGITS))
}
value /= 10;
if (value == 0) break;
}
return buffer;
}
}
/**
* @dev Converts a `int256` to its ASCII `string` decimal representation.
*/
function toStringSigned(int256 value) internal pure returns (string memory) {
return string.concat(value < 0 ? "-" : "", toString(SignedMath.abs(value)));
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
*/
function toHexString(uint256 value) internal pure returns (string memory) {
unchecked {
return toHexString(value, Math.log256(value) + 1);
}
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
*/
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
uint256 localValue = value;
bytes memory buffer = new bytes(2 * length + 2);
buffer[0] = "0";
buffer[1] = "x";
for (uint256 i = 2 * length + 1; i > 1; --i) {
buffer[i] = HEX_DIGITS[localValue & 0xf];
localValue >>= 4;
}
if (localValue != 0) {
revert StringsInsufficientHexLength(value, length);
}
return string(buffer);
}
/**
* @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal
* representation.
*/
function toHexString(address addr) internal pure returns (string memory) {
return toHexString(uint256(uint160(addr)), ADDRESS_LENGTH);
}
/**
* @dev Returns true if the two strings are equal.
*/
function equal(string memory a, string memory b) internal pure returns (bool) {
return bytes(a).length == bytes(b).length && keccak256(bytes(a)) == keccak256(bytes(b));
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/StorageSlot.sol)
// This file was procedurally generated from scripts/generate/templates/StorageSlot.js.
pragma solidity ^0.8.20;
/**
* @dev Library for reading and writing primitive types to specific storage slots.
*
* Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.
* This library helps with reading and writing to such slots without the need for inline assembly.
*
* The functions in this library return Slot structs that contain a `value` member that can be used to read or write.
*
* Example usage to set ERC1967 implementation slot:
* ```solidity
* contract ERC1967 {
* bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;
*
* function _getImplementation() internal view returns (address) {
* return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;
* }
*
* function _setImplementation(address newImplementation) internal {
* require(newImplementation.code.length > 0);
* StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;
* }
* }
* ```
*/
library StorageSlot {
struct AddressSlot {
address value;
}
struct BooleanSlot {
bool value;
}
struct Bytes32Slot {
bytes32 value;
}
struct Uint256Slot {
uint256 value;
}
struct StringSlot {
string value;
}
struct BytesSlot {
bytes value;
}
/**
* @dev Returns an `AddressSlot` with member `value` located at `slot`.
*/
function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `BooleanSlot` with member `value` located at `slot`.
*/
function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `Bytes32Slot` with member `value` located at `slot`.
*/
function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `Uint256Slot` with member `value` located at `slot`.
*/
function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `StringSlot` with member `value` located at `slot`.
*/
function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `StringSlot` representation of the string storage pointer `store`.
*/
function getStringSlot(string storage store) internal pure returns (StringSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := store.slot
}
}
/**
* @dev Returns an `BytesSlot` with member `value` located at `slot`.
*/
function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`.
*/
function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := store.slot
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/math/Math.sol)
pragma solidity ^0.8.20;
/**
* @dev Standard math utilities missing in the Solidity language.
*/
library Math {
/**
* @dev Muldiv operation overflow.
*/
error MathOverflowedMulDiv();
enum Rounding {
Floor, // Toward negative infinity
Ceil, // Toward positive infinity
Trunc, // Toward zero
Expand // Away from zero
}
/**
* @dev Returns the addition of two unsigned integers, with an overflow flag.
*/
function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
uint256 c = a + b;
if (c < a) return (false, 0);
return (true, c);
}
}
/**
* @dev Returns the subtraction of two unsigned integers, with an overflow flag.
*/
function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b > a) return (false, 0);
return (true, a - b);
}
}
/**
* @dev Returns the multiplication of two unsigned integers, with an overflow flag.
*/
function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
// 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.
*/
function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
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.
*/
function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b == 0) return (false, 0);
return (true, a % b);
}
}
/**
* @dev Returns the largest of two numbers.
*/
function max(uint256 a, uint256 b) internal pure returns (uint256) {
return a > b ? a : b;
}
/**
* @dev Returns the smallest of two numbers.
*/
function min(uint256 a, uint256 b) internal pure returns (uint256) {
return a < b ? a : b;
}
/**
* @dev Returns the average of two numbers. The result is rounded towards
* zero.
*/
function average(uint256 a, uint256 b) internal pure returns (uint256) {
// (a + b) / 2 can overflow.
return (a & b) + (a ^ b) / 2;
}
/**
* @dev Returns the ceiling of the division of two numbers.
*
* This differs from standard division with `/` in that it rounds towards infinity instead
* of rounding towards zero.
*/
function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
if (b == 0) {
// Guarantee the same behavior as in a regular Solidity division.
return a / b;
}
// (a + b - 1) / b can overflow on addition, so we distribute.
return a == 0 ? 0 : (a - 1) / b + 1;
}
/**
* @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or
* denominator == 0.
* @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv) with further edits by
* Uniswap Labs also under MIT license.
*/
function mulDiv(uint256 x, uint256 y, uint256 denominator) internal pure returns (uint256 result) {
unchecked {
// 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
// use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
// variables such that product = prod1 * 2^256 + prod0.
uint256 prod0 = x * y; // Least significant 256 bits of the product
uint256 prod1; // Most significant 256 bits of the product
assembly {
let mm := mulmod(x, y, not(0))
prod1 := sub(sub(mm, prod0), lt(mm, prod0))
}
// Handle non-overflow cases, 256 by 256 division.
if (prod1 == 0) {
// Solidity will revert if denominator == 0, unlike the div opcode on its own.
// The surrounding unchecked block does not change this fact.
// See https://docs.soliditylang.org/en/latest/control-structures.html#checked-or-unchecked-arithmetic.
return prod0 / denominator;
}
// Make sure the result is less than 2^256. Also prevents denominator == 0.
if (denominator <= prod1) {
revert MathOverflowedMulDiv();
}
///////////////////////////////////////////////
// 512 by 256 division.
///////////////////////////////////////////////
// Make division exact by subtracting the remainder from [prod1 prod0].
uint256 remainder;
assembly {
// Compute remainder using mulmod.
remainder := mulmod(x, y, denominator)
// Subtract 256 bit number from 512 bit number.
prod1 := sub(prod1, gt(remainder, prod0))
prod0 := sub(prod0, remainder)
}
// Factor powers of two out of denominator and compute largest power of two divisor of denominator.
// Always >= 1. See https://cs.stackexchange.com/q/138556/92363.
uint256 twos = denominator & (0 - denominator);
assembly {
// Divide denominator by twos.
denominator := div(denominator, twos)
// Divide [prod1 prod0] by twos.
prod0 := div(prod0, twos)
// Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
twos := add(div(sub(0, twos), twos), 1)
}
// Shift in bits from prod1 into prod0.
prod0 |= prod1 * twos;
// Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
// that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
// four bits. That is, denominator * inv = 1 mod 2^4.
uint256 inverse = (3 * denominator) ^ 2;
// Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also
// works in modular arithmetic, doubling the correct bits in each step.
inverse *= 2 - denominator * inverse; // inverse mod 2^8
inverse *= 2 - denominator * inverse; // inverse mod 2^16
inverse *= 2 - denominator * inverse; // inverse mod 2^32
inverse *= 2 - denominator * inverse; // inverse mod 2^64
inverse *= 2 - denominator * inverse; // inverse mod 2^128
inverse *= 2 - denominator * inverse; // inverse mod 2^256
// Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
// This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
// less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
// is no longer required.
result = prod0 * inverse;
return result;
}
}
/**
* @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
*/
function mulDiv(uint256 x, uint256 y, uint256 denominator, Rounding rounding) internal pure returns (uint256) {
uint256 result = mulDiv(x, y, denominator);
if (unsignedRoundsUp(rounding) && mulmod(x, y, denominator) > 0) {
result += 1;
}
return result;
}
/**
* @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded
* towards zero.
*
* Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
*/
function sqrt(uint256 a) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
// For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
//
// We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
// `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
//
// This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
// → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
// → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
//
// Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
uint256 result = 1 << (log2(a) >> 1);
// At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
// since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
// every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
// into the expected uint128 result.
unchecked {
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
return min(result, a / result);
}
}
/**
* @notice Calculates sqrt(a), following the selected rounding direction.
*/
function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = sqrt(a);
return result + (unsignedRoundsUp(rounding) && result * result < a ? 1 : 0);
}
}
/**
* @dev Return the log in base 2 of a positive value rounded towards zero.
* Returns 0 if given 0.
*/
function log2(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 128;
}
if (value >> 64 > 0) {
value >>= 64;
result += 64;
}
if (value >> 32 > 0) {
value >>= 32;
result += 32;
}
if (value >> 16 > 0) {
value >>= 16;
result += 16;
}
if (value >> 8 > 0) {
value >>= 8;
result += 8;
}
if (value >> 4 > 0) {
value >>= 4;
result += 4;
}
if (value >> 2 > 0) {
value >>= 2;
result += 2;
}
if (value >> 1 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 2, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log2(value);
return result + (unsignedRoundsUp(rounding) && 1 << result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 10 of a positive value rounded towards zero.
* Returns 0 if given 0.
*/
function log10(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >= 10 ** 64) {
value /= 10 ** 64;
result += 64;
}
if (value >= 10 ** 32) {
value /= 10 ** 32;
result += 32;
}
if (value >= 10 ** 16) {
value /= 10 ** 16;
result += 16;
}
if (value >= 10 ** 8) {
value /= 10 ** 8;
result += 8;
}
if (value >= 10 ** 4) {
value /= 10 ** 4;
result += 4;
}
if (value >= 10 ** 2) {
value /= 10 ** 2;
result += 2;
}
if (value >= 10 ** 1) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 10, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log10(value);
return result + (unsignedRoundsUp(rounding) && 10 ** result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 256 of a positive value rounded towards zero.
* Returns 0 if given 0.
*
* Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
*/
function log256(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 16;
}
if (value >> 64 > 0) {
value >>= 64;
result += 8;
}
if (value >> 32 > 0) {
value >>= 32;
result += 4;
}
if (value >> 16 > 0) {
value >>= 16;
result += 2;
}
if (value >> 8 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 256, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log256(value);
return result + (unsignedRoundsUp(rounding) && 1 << (result << 3) < value ? 1 : 0);
}
}
/**
* @dev Returns whether a provided rounding mode is considered rounding up for unsigned integers.
*/
function unsignedRoundsUp(Rounding rounding) internal pure returns (bool) {
return uint8(rounding) % 2 == 1;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/math/SignedMath.sol)
pragma solidity ^0.8.20;
/**
* @dev Standard signed math utilities missing in the Solidity language.
*/
library SignedMath {
/**
* @dev Returns the largest of two signed numbers.
*/
function max(int256 a, int256 b) internal pure returns (int256) {
return a > b ? a : b;
}
/**
* @dev Returns the smallest of two signed numbers.
*/
function min(int256 a, int256 b) internal pure returns (int256) {
return a < b ? a : b;
}
/**
* @dev Returns the average of two signed numbers without overflow.
* The result is rounded towards zero.
*/
function average(int256 a, int256 b) internal pure returns (int256) {
// Formula from the book "Hacker's Delight"
int256 x = (a & b) + ((a ^ b) >> 1);
return x + (int256(uint256(x) >> 255) & (a ^ b));
}
/**
* @dev Returns the absolute unsigned value of a signed value.
*/
function abs(int256 n) internal pure returns (uint256) {
unchecked {
// must be unchecked in order to support `n = type(int256).min`
return uint256(n >= 0 ? n : -n);
}
}
}{
"remappings": [
"forge-std/=lib/forge-std/src/",
"@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/",
"@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/",
"ds-test/=lib/openzeppelin-contracts-upgradeable/lib/forge-std/lib/ds-test/src/",
"erc4626-tests/=lib/openzeppelin-contracts-upgradeable/lib/erc4626-tests/",
"halmos-cheatcodes/=lib/openzeppelin-contracts-upgradeable/lib/halmos-cheatcodes/src/",
"openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/",
"openzeppelin-contracts/=lib/openzeppelin-contracts/"
],
"optimizer": {
"enabled": true,
"runs": 5800
},
"metadata": {
"useLiteralContent": false,
"bytecodeHash": "ipfs",
"appendCBOR": true
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"evmVersion": "prague",
"viaIR": false
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"wrappedNativeToken_","type":"address"},{"internalType":"address[]","name":"authorized","type":"address[]"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"AddressEmptyCode","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"AddressInsufficientBalance","type":"error"},{"inputs":[],"name":"CallFailed","type":"error"},{"inputs":[],"name":"DataHashAlreadyUsed","type":"error"},{"inputs":[],"name":"ECDSAInvalidSignature","type":"error"},{"inputs":[{"internalType":"uint256","name":"length","type":"uint256"}],"name":"ECDSAInvalidSignatureLength","type":"error"},{"inputs":[{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"ECDSAInvalidSignatureS","type":"error"},{"inputs":[],"name":"ExpiredDeadline","type":"error"},{"inputs":[],"name":"FailedInnerCall","type":"error"},{"inputs":[],"name":"InvalidIntentData","type":"error"},{"inputs":[],"name":"InvalidShortString","type":"error"},{"inputs":[],"name":"InvalidSignature","type":"error"},{"inputs":[],"name":"OnlyRemoteExecute","type":"error"},{"inputs":[{"internalType":"address","name":"token","type":"address"}],"name":"SafeERC20FailedOperation","type":"error"},{"inputs":[{"internalType":"string","name":"str","type":"string"}],"name":"StringTooLong","type":"error"},{"inputs":[],"name":"TooManyAddresses","type":"error"},{"inputs":[],"name":"ZeroAddressNotAllowed","type":"error"},{"anonymous":false,"inputs":[],"name":"EIP712DomainChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":true,"internalType":"address","name":"intentAddress","type":"address"}],"name":"IntentAddressDeploy","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":false,"internalType":"string","name":"intent","type":"string"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"IntentExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":false,"internalType":"string","name":"intent","type":"string"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"reason","type":"bytes"}],"name":"IntentFailed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":false,"internalType":"string","name":"intent","type":"string"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"IntentRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":true,"internalType":"address","name":"intentAddress","type":"address"},{"indexed":false,"internalType":"address","name":"signer","type":"address"}],"name":"SignedIntentAddressDeploy","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":false,"internalType":"string","name":"intent","type":"string"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"},{"indexed":false,"internalType":"address","name":"signer","type":"address"}],"name":"SignedIntentExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":false,"internalType":"string","name":"intent","type":"string"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"reason","type":"bytes"}],"name":"SignedIntentFailed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"indexed":true,"internalType":"address","name":"trader","type":"address"},{"indexed":false,"internalType":"string","name":"intent","type":"string"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"},{"indexed":false,"internalType":"address","name":"signer","type":"address"}],"name":"SignedIntentRequested","type":"event"},{"inputs":[],"name":"CALL_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EXECUTE_INTENT_ADDRESS_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EXECUTE_INTENT_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EXECUTE_REMOTE_INTENT_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SELF","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"delegateData","type":"bytes"}],"name":"decodeIntentParams","outputs":[{"components":[{"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"string","name":"intent","type":"string"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"internalType":"struct IIntent.Call[]","name":"calls","type":"tuple[]"},{"internalType":"address[]","name":"refundTokens","type":"address[]"}],"internalType":"struct IIntent.IntentParams","name":"params","type":"tuple"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"domainSeparatorV4","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"eip712Domain","outputs":[{"internalType":"bytes1","name":"fields","type":"bytes1"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"version","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"address","name":"verifyingContract","type":"address"},{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"uint256[]","name":"extensions","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"string","name":"intent","type":"string"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"internalType":"struct IIntent.Call[]","name":"calls","type":"tuple[]"},{"internalType":"address[]","name":"refundTokens","type":"address[]"}],"internalType":"struct IIntent.IntentParams","name":"params","type":"tuple"}],"name":"execute","outputs":[{"internalType":"bytes[]","name":"results","type":"bytes[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes","name":"delegateData","type":"bytes"}],"name":"executeIntentAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"signed","type":"bool"},{"internalType":"bytes","name":"delegateData","type":"bytes"}],"name":"getIntentAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"dataHash","type":"bytes32"}],"name":"isHashUsed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"internalType":"struct IIntent.Call[]","name":"calls","type":"tuple[]"}],"name":"multicall","outputs":[{"internalType":"bytes[]","name":"","type":"bytes[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"string","name":"intent","type":"string"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"internalType":"struct IIntent.Call[]","name":"calls","type":"tuple[]"},{"internalType":"address[]","name":"refundTokens","type":"address[]"}],"internalType":"struct IIntent.IntentParams","name":"params","type":"tuple"}],"name":"remoteExecute","outputs":[{"internalType":"bytes[]","name":"results","type":"bytes[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"string","name":"intent","type":"string"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"internalType":"struct IIntent.Call[]","name":"calls","type":"tuple[]"},{"internalType":"address[]","name":"refundTokens","type":"address[]"}],"internalType":"struct IIntent.IntentParams","name":"params","type":"tuple"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"signedExecute","outputs":[{"internalType":"bytes[]","name":"results","type":"bytes[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes","name":"delegateData","type":"bytes"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"signedExecuteIntentAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"bytes32","name":"dataHash","type":"bytes32"},{"internalType":"bytes32","name":"tokenID","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"string","name":"intent","type":"string"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"},{"internalType":"uint256","name":"value","type":"uint256"}],"internalType":"struct IIntent.Call[]","name":"calls","type":"tuple[]"},{"internalType":"address[]","name":"refundTokens","type":"address[]"}],"internalType":"struct IIntent.IntentParams","name":"params","type":"tuple"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"signedRemoteExecute","outputs":[{"internalType":"bytes[]","name":"results","type":"bytes[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"usedHashes","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelisted1","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelisted2","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelisted3","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelisted4","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelisted5","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wrappedNativeToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]Contract Creation Code
6102406040523061020052348015610015575f5ffd5b5060405161400538038061400583398101604081905261003491610370565b60405180604001604052806006815260200165125b9d195b9d60d21b815250604051806040016040528060018152602001603160f81b8152508260058151111561009157604051637e1d76fb60e01b815260040160405180910390fd5b5f5b81518110156100ef575f6001600160a01b03168282815181106100b8576100b861044e565b60200260200101516001600160a01b0316036100e7576040516342bcdf7f60e11b815260040160405180910390fd5b600101610093565b505f8151116100fe575f610119565b805f815181106101105761011061044e565b60200260200101515b6001600160a01b03166080528051600110610134575f610150565b806001815181106101475761014761044e565b60200260200101515b6001600160a01b031660a052805160021061016b575f610187565b8060028151811061017e5761017e61044e565b60200260200101515b6001600160a01b031660c05280516003106101a2575f6101be565b806003815181106101b5576101b561044e565b60200260200101515b6001600160a01b031660e05280516004106101d9575f6101f5565b806004815181106101ec576101ec61044e565b60200260200101515b6001600160a01b0316610100525061020d825f6102c9565b6101c05261021c8160016102c9565b6101e0528151602080840191909120610180528151908201206101a05246610140526102ab610180516101a051604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f60208201529081019290925260608201524660808201523060a08201525f9060c00160405160208183030381529060405280519060200120905090565b6101205250503061016052506001600160a01b0316610220526105f8565b5f6020835110156102e4576102dd836102fb565b90506102f5565b816102ef84826104e6565b5060ff90505b92915050565b5f5f829050601f8151111561032e578260405163305a27a960e01b815260040161032591906105a0565b60405180910390fd5b8051610339826105d5565b179392505050565b80516001600160a01b0381168114610357575f5ffd5b919050565b634e487b7160e01b5f52604160045260245ffd5b5f5f60408385031215610381575f5ffd5b61038a83610341565b60208401519092506001600160401b038111156103a5575f5ffd5b8301601f810185136103b5575f5ffd5b80516001600160401b038111156103ce576103ce61035c565b604051600582901b90603f8201601f191681016001600160401b03811182821017156103fc576103fc61035c565b604052918252602081840181019290810188841115610419575f5ffd5b6020850194505b8385101561043f5761043185610341565b815260209485019401610420565b50809450505050509250929050565b634e487b7160e01b5f52603260045260245ffd5b600181811c9082168061047657607f821691505b60208210810361049457634e487b7160e01b5f52602260045260245ffd5b50919050565b601f8211156104e157805f5260205f20601f840160051c810160208510156104bf5750805b601f840160051c820191505b818110156104de575f81556001016104cb565b50505b505050565b81516001600160401b038111156104ff576104ff61035c565b6105138161050d8454610462565b8461049a565b6020601f821160018114610545575f831561052e5750848201515b5f19600385901b1c1916600184901b1784556104de565b5f84815260208120601f198516915b828110156105745787850151825560209485019460019092019101610554565b508482101561059157868401515f19600387901b60f8161c191681555b50505050600190811b01905550565b602081525f82518060208401528060208501604085015e5f604082850101526040601f19601f83011684010191505092915050565b80516020808301519190811015610494575f1960209190910360031b1b16919050565b60805160a05160c05160e05161010051610120516101405161016051610180516101a0516101c0516101e051610200516102205161393e6106c75f395f818161020801528181611a2b0152611aa501525f81816102cd0152611f0901525f611dc901525f611d9d01525f611d4601525f611d1e01525f611c7901525f611ca301525f611ccd01525f81816103a101526117e401525f818161040701526117a801525f8181610300015261176c01525f8181610198015261173001525f818161043a01526116f5015261393e5ff3fe608060405260043610610183575f3560e01c8063a7cbcd50116100d1578063cf95c95b1161007c578063e8abf37911610057578063e8abf3791461052f578063eeb1965114610542578063fc690fe01461056e575f5ffd5b8063cf95c95b146104ca578063da0842f7146104fd578063da5915081461051c575f5ffd5b8063aef18bf7116100ac578063aef18bf71461045c578063bcdd390f1461048a578063c92cc131146104a9575f5ffd5b8063a7cbcd50146103c3578063ab7244de146103f6578063ae09b8fa14610429575f5ffd5b806326bd0c4e1161013157806384b0196e1161010c57806384b0196e1461033657806390cfff2a1461035d578063a21ad4b814610390575f5ffd5b806326bd0c4e146102bc5780633d5172df146102ef57806378e890ba14610322575f5ffd5b80631a912f3e116101615780631a912f3e1461022a5780631c40a3591461026b57806320021d8b1461027e575f5ffd5b80630e0638be14610187578063166f37f6146101d757806317fcb39b146101f7575b5f5ffd5b348015610192575f5ffd5b506101ba7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b6101ea6101e53660046125f7565b610581565b6040516101ce9190612695565b348015610202575f5ffd5b506101ba7f000000000000000000000000000000000000000000000000000000000000000081565b348015610235575f5ffd5b5061025d7f96e412881b9055f40cc9a1b82ff7957e56c9d661e4493c769b55a42bc6b5ac7f81565b6040519081526020016101ce565b6101ea610279366004612716565b6107de565b348015610289575f5ffd5b506102ac610298366004612748565b5f9081526002602052604090205460ff1690565b60405190151581526020016101ce565b3480156102c7575f5ffd5b506101ba7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102fa575f5ffd5b506101ba7f000000000000000000000000000000000000000000000000000000000000000081565b34801561032d575f5ffd5b5061025d61087c565b348015610341575f5ffd5b5061034a61088a565b6040516101ce979695949392919061275f565b348015610368575f5ffd5b5061025d7f7967b984fb0a3c1384a03e582a53972b9a16e295dd9e635296def1f406112eeb81565b34801561039b575f5ffd5b506101ba7f000000000000000000000000000000000000000000000000000000000000000081565b3480156103ce575f5ffd5b5061025d7f3c5c3fffe366d8418c5276b046ae4bfd8887a0779c6750f459133811c55dc5eb81565b348015610401575f5ffd5b506101ba7f000000000000000000000000000000000000000000000000000000000000000081565b348015610434575f5ffd5b506101ba7f000000000000000000000000000000000000000000000000000000000000000081565b348015610467575f5ffd5b506102ac610476366004612748565b60026020525f908152604090205460ff1681565b348015610495575f5ffd5b506101ba6104a436600461281e565b6108e8565b3480156104b4575f5ffd5b506104c86104c336600461286f565b610ad0565b005b3480156104d5575f5ffd5b5061025d7f16f71df7185a51e60cfb3b8e021014dd95ec8b3a7d9094d75b290b5cb2560a9681565b348015610508575f5ffd5b506104c86105173660046128e8565b610cd8565b6101ea61052a366004612716565b610d9e565b6101ea61053d366004612927565b610ec0565b34801561054d575f5ffd5b5061056161055c3660046128e8565b610ed5565b6040516101ce91906129db565b6101ea61057c3660046125f7565b611111565b6060834211156105bd576040517ff87d927100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84355f9081526002602052604090205460ff1615610607576040517fd6a3c2d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f6106337f16f71df7185a51e60cfb3b8e021014dd95ec8b3a7d9094d75b290b5cb2560a9687876113b8565b90505f61063f82611670565b90505f61068386868080601f0160208091040260200160405190810160405280939291908181526020018383808284375f9201919091525086939250506116b79050565b905061068e816116df565b6106c4576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b87355f908152600260205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905561070e9060608a01908a01612aef565b6001600160a01b0316602089013589357f2c25950a88d2af6f8e025dc013f4fcc40e859e3c3b6e4f7979d1025899ea401861074c60608d018d612b0a565b348760405161075e9493929190612b76565b60405180910390a461077b61077660808a018a612ba9565b61181d565b93506107d361079060608a0160408b01612aef565b61079d60a08b018b612ba9565b808060200260200160405190810160405280939291908181526020018383602002808284375f920191909152506119cb92505050565b505050949350505050565b60606107ef82820160408401612aef565b6001600160a01b0316602083013583357f2742354653a6ba360731d003e1e2b4894255cbddd2f4050e7230db5cbae2128a61082d6060870187612b0a565b3460405161083d93929190612bef565b60405180910390a46108556107766080840184612ba9565b905061087761086a6060840160408501612aef565b61079d60a0850185612ba9565b919050565b5f610885611c6d565b905090565b5f6060805f5f5f606061089b611d96565b6108a3611dc2565b604080515f808252602082019092527f0f000000000000000000000000000000000000000000000000000000000000009b939a50919850469750309650945092509050565b5f6108f38383611def565b6040517feeb19651000000000000000000000000000000000000000000000000000000008152309063eeb19651906109319086908690600401612c3f565b5f60405180830381865afa92505050801561096d57506040513d5f823e601f3d908101601f1916820160405261096a9190810190612ebe565b60015b6109a3576040517fdabcbc2f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b507fff0000000000000000000000000000000000000000000000000000000000000030856109d1575f6109d4565b60015b6040516109e36020820161258f565b601f1982820381018352601f909101166040819052610a089088908890602001612c3f565b60408051601f1981840301815290829052610a269291602001612fbc565b60405160208183030381529060405280519060200120604051602001610aae94939291907fff0000000000000000000000000000000000000000000000000000000000000094909416845260609290921b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660018401526015830152603582015260550190565b604051602081830303815290604052805190602001205f1c90505b9392505050565b82421115610b0a576040517ff87d927100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610b148585611def565b5f7f7967b984fb0a3c1384a03e582a53972b9a16e295dd9e635296def1f406112eeb8686604051610b46929190612fd0565b604080519182900382206020830193909352810191909152606081018590526080016040516020818303038152906040528051906020012090505f610b8a82611670565b90505f610bce85858080601f0160208091040260200160405190810160405280939291908181526020018383808284375f9201919091525086939250506116b79050565b9050610bd9816116df565b610c0f576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610c1e604460248a8c612fdf565b610c2791613006565b90505f610c38608460708b8d612fdf565b610c4191613042565b60601c90505f60015f1b8b8b604051610c599061258f565b610c64929190612c3f565b8190604051809103905ff5905080158015610c81573d5f5f3e3d5ffd5b506040516001600160a01b0386811682529192508183169184169085907fadbc21ad7e1f77960f52858d8e4d14d953e23a380f62d4809611e516731932429060200160405180910390a45050505050505050505050565b610ce28282611def565b5f610cf1604460248486612fdf565b610cfa91613006565b90505f610d0b608460708587612fdf565b610d1491613042565b60601c90505f5f5f1b8585604051610d2b9061258f565b610d36929190612c3f565b8190604051809103905ff5905080158015610d53573d5f5f3e3d5ffd5b509050806001600160a01b0316826001600160a01b0316847fa299fa29a1850025e8c56c8ed2fb0932b6f6cf16bd0948ed0aee34bab796147460405160405180910390a45050505050565b60605f8080610db8610db36080870187612ba9565b611e88565b9250925092508215610e2f57610dd46060860160408701612aef565b6001600160a01b0316602086013586357f41856989118d8100f29fc0f0385da890ab23dbe5cb1403dc364937a4248010f0610e1260608a018a612b0a565b34604051610e2293929190612bef565b60405180910390a4610e98565b610e3f6060860160408701612aef565b6001600160a01b0316602086013586357f054ff99066858d6abaf7037a1f3b4a601ff6cce629c00ac000fb2530a2db0946610e7d60608a018a612b0a565b3488604051610e8f94939291906130a8565b60405180910390a45b610eb8610eab6060870160408801612aef565b61079d60a0880188612ba9565b949350505050565b6060610ecc838361181d565b90505b92915050565b610f146040518060c001604052805f81526020015f81526020015f6001600160a01b031681526020016060815260200160608152602001606081525090565b5f610f226004828587612fdf565b610f2b916130de565b9050365f610f3c8560048189612fdf565b90925090507fffffffff0000000000000000000000000000000000000000000000000000000083167ffc690fe0000000000000000000000000000000000000000000000000000000001480610fd257507fffffffff0000000000000000000000000000000000000000000000000000000083167f166f37f600000000000000000000000000000000000000000000000000000000145b15611033575f6060610fe68385018561338e565b80519298509093509150604114611029576040517fdabcbc2f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050610ecf565b7fffffffff0000000000000000000000000000000000000000000000000000000083167fda5915080000000000000000000000000000000000000000000000000000000014806110c457507fffffffff0000000000000000000000000000000000000000000000000000000083167f1c40a35900000000000000000000000000000000000000000000000000000000145b156110df576110d5818301836133fb565b9350505050610ecf565b6040517fdabcbc2f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60608342111561114d576040517ff87d927100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84355f9081526002602052604090205460ff1615611197576040517fd6a3c2d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f6111c37f3c5c3fffe366d8418c5276b046ae4bfd8887a0779c6750f459133811c55dc5eb87876113b8565b90505f6111cf82611670565b90505f61121386868080601f0160208091040260200160405190810160405280939291908181526020018383808284375f9201919091525086939250506116b79050565b905061121e816116df565b611254576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b87355f90815260026020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055808061129e610db360808d018d612ba9565b925092509250821561131c576112ba60608c0160408d01612aef565b6001600160a01b03168b602001358c5f01357f24042cc2931c07295fba5982b8cbeb67d07d7ab992b15f1ceeddba721d2a91cb8e80606001906112fd9190612b0a565b348a60405161130f9493929190612b76565b60405180910390a461138a565b61132c60608c0160408d01612aef565b6001600160a01b03168b602001358c5f01357f3b00b3a71f4507558d207cabff3e58f5ad8995c2b70a7c82acc066f59c78b1dd8e806060019061136f9190612b0a565b348860405161138194939291906130a8565b60405180910390a45b6113aa61139d60608d0160408e01612aef565b61079d60a08e018e612ba9565b9a9950505050505050505050565b5f806113c76080850185612ba9565b905067ffffffffffffffff8111156113e1576113e1612c12565b60405190808252806020026020018201604052801561140a578160200160208202803683370190505b5090505f5b61141c6080860186612ba9565b905081101561156e577f96e412881b9055f40cc9a1b82ff7957e56c9d661e4493c769b55a42bc6b5ac7f6114536080870187612ba9565b838181106114635761146361342d565b9050602002810190611475919061345a565b611483906020810190612aef565b6114906080880188612ba9565b848181106114a0576114a061342d565b90506020028101906114b2919061345a565b6114c0906020810190612b0a565b6040516114ce929190612fd0565b6040519081900390206114e46080890189612ba9565b858181106114f4576114f461342d565b9050602002810190611506919061345a565b6040805160208101959095526001600160a01b039093168484015260608401919091520135608082015260a0016040516020818303038152906040528051906020012082828151811061155b5761155b61342d565b602090810291909101015260010161140f565b50846115806060860160408701612aef565b853560208701356115946060890189612b0a565b6040516115a2929190612fd0565b6040518091039020856040516020016115bb9190613496565b60408051601f1981840301815291905280516020909101206115e060a08b018b612ba9565b6040516020016115f19291906134cb565b60408051601f198184030181528282528051602091820120908301989098526001600160a01b03909616958101959095526060850193909352608084019190915260a083015260c082015260e0810191909152610100810184905261012001604051602081830303815290604052805190602001209150509392505050565b5f610ecf61167c611c6d565b836040517f19010000000000000000000000000000000000000000000000000000000000008152600281019290925260228201526042902090565b5f5f5f5f6116c58686611fd9565b9250925092506116d58282612022565b5090949350505050565b5f6001600160a01b03821615801590610ecf57507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316148061176457507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316145b806117a057507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316145b806117dc57507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316145b80610ecf57507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b03161492915050565b6060815f8167ffffffffffffffff81111561183a5761183a612c12565b60405190808252806020026020018201604052801561186d57816020015b60608152602001906001900390816118585790505b5090505f5b828110156119c2575f5f87878481811061188e5761188e61342d565b90506020028101906118a0919061345a565b6118ae906020810190612aef565b6001600160a01b03168888858181106118c9576118c961342d565b90506020028101906118db919061345a565b604001358989868181106118f1576118f161342d565b9050602002810190611903919061345a565b611911906020810190612b0a565b60405161191f929190612fd0565b5f6040518083038185875af1925050503d805f8114611959576040519150601f19603f3d011682016040523d82523d5f602084013e61195e565b606091505b50915091508161199a576040517f3204506f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b808484815181106119ad576119ad61342d565b60209081029190910101525050600101611872565b50949350505050565b478015611ad2575f836001600160a01b0316826040515f6040518083038185875af1925050503d805f8114611a1b576040519150601f19603f3d011682016040523d82523d5f602084013e611a20565b606091505b5050905080611ad0577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663d0e30db0836040518263ffffffff1660e01b81526004015f604051808303818588803b158015611a82575f5ffd5b505af1158015611a94573d5f5f3e3d5ffd5b50611ad09350506001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001691508690508461212e565b505b5f5b8251811015611c67575f6001600160a01b0316838281518110611af957611af961342d565b60200260200101516001600160a01b031614611c5f575f838281518110611b2257611b2261342d565b60209081029190910101516040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b03909116906370a0823190602401602060405180830381865afa158015611b89573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611bad919061350c565b90508015611c5d57838281518110611bc757611bc761342d565b60209081029190910101516040517fa9059cbb0000000000000000000000000000000000000000000000000000000081526001600160a01b038781166004830152602482018490529091169063a9059cbb906044016020604051808303815f875af1925050508015611c56575060408051601f3d908101601f19168201909252611c5391810190613523565b60015b15611c5d57505b505b600101611ad4565b50505050565b5f306001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016148015611cc557507f000000000000000000000000000000000000000000000000000000000000000046145b15611cef57507f000000000000000000000000000000000000000000000000000000000000000090565b610885604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f60208201527f0000000000000000000000000000000000000000000000000000000000000000918101919091527f000000000000000000000000000000000000000000000000000000000000000060608201524660808201523060a08201525f9060c00160405160208183030381529060405280519060200120905090565b60606108857f00000000000000000000000000000000000000000000000000000000000000005f6121ae565b60606108857f000000000000000000000000000000000000000000000000000000000000000060016121ae565b5f611dfd6004828486612fdf565b611e06916130de565b90507fffffffff0000000000000000000000000000000000000000000000000000000081167fda5915080000000000000000000000000000000000000000000000000000000014611e83576040517f496c792100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b5f6060805f63e8abf37960e01b8686604051602401611ea892919061353e565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505090507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031681604051611f3f919061365f565b5f60405180830381855af49150503d805f8114611f77576040519150601f19603f3d011682016040523d82523d5f602084013e611f7c565b606091505b5090945092508315611fa35782806020019051810190611f9c919061366a565b9150611fd1565b604080515f8082526020820190925290611fcd565b6060815260200190600190039081611fb85790505b5091505b509250925092565b5f5f5f8351604103612010576020840151604085015160608601515f1a61200288828585612257565b95509550955050505061201b565b505081515f91506002905b9250925092565b5f8260038111156120355761203561371b565b0361203e575050565b60018260038111156120525761205261371b565b03612089576040517ff645eedf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600282600381111561209d5761209d61371b565b036120dc576040517ffce698f7000000000000000000000000000000000000000000000000000000008152600481018290526024015b60405180910390fd5b60038260038111156120f0576120f061371b565b0361212a576040517fd78bce0c000000000000000000000000000000000000000000000000000000008152600481018290526024016120d3565b5050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb00000000000000000000000000000000000000000000000000000000179052611e8390849061231f565b606060ff83146121c8576121c183612399565b9050610ecf565b8180546121d490613748565b80601f016020809104026020016040519081016040528092919081815260200182805461220090613748565b801561224b5780601f106122225761010080835404028352916020019161224b565b820191905f5260205f20905b81548152906001019060200180831161222e57829003601f168201915b50505050509050610ecf565b5f80807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a084111561229057505f91506003905082612315565b604080515f808252602082018084528a905260ff891692820192909252606081018790526080810186905260019060a0016020604051602081039080840390855afa1580156122e1573d5f5f3e3d5ffd5b5050604051601f1901519150506001600160a01b03811661230c57505f925060019150829050612315565b92505f91508190505b9450945094915050565b5f6123336001600160a01b038416836123d6565b905080515f141580156123575750808060200190518101906123559190613523565b155b15611e83576040517f5274afe70000000000000000000000000000000000000000000000000000000081526001600160a01b03841660048201526024016120d3565b60605f6123a5836123e3565b6040805160208082528183019092529192505f91906020820181803683375050509182525060208101929092525090565b6060610ecc83835f612423565b5f60ff8216601f811115610ecf576040517fb3512b0c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606081471015612461576040517fcd7860590000000000000000000000000000000000000000000000000000000081523060048201526024016120d3565b5f5f856001600160a01b0316848660405161247c919061365f565b5f6040518083038185875af1925050503d805f81146124b6576040519150601f19603f3d011682016040523d82523d5f602084013e6124bb565b606091505b50915091506124cb8683836124d5565b9695505050505050565b6060826124ea576124e58261254a565b610ac9565b815115801561250157506001600160a01b0384163b155b15612543576040517f9996b3150000000000000000000000000000000000000000000000000000000081526001600160a01b03851660048201526024016120d3565b5080610ac9565b80511561255a5780518082602001fd5b6040517f1425ea4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b6101758061379483390190565b5f60c082840312156125ac575f5ffd5b50919050565b5f5f83601f8401126125c2575f5ffd5b50813567ffffffffffffffff8111156125d9575f5ffd5b6020830191508360208285010111156125f0575f5ffd5b9250929050565b5f5f5f5f6060858703121561260a575f5ffd5b843567ffffffffffffffff811115612620575f5ffd5b61262c8782880161259c565b94505060208501359250604085013567ffffffffffffffff81111561264f575f5ffd5b61265b878288016125b2565b95989497509550505050565b5f81518084528060208401602086015e5f602082860101526020601f19601f83011685010191505092915050565b5f602082016020835280845180835260408501915060408160051b8601019250602086015f5b8281101561270a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc08786030184526126f5858351612667565b945060209384019391909101906001016126bb565b50929695505050505050565b5f60208284031215612726575f5ffd5b813567ffffffffffffffff81111561273c575f5ffd5b610eb88482850161259c565b5f60208284031215612758575f5ffd5b5035919050565b7fff000000000000000000000000000000000000000000000000000000000000008816815260e060208201525f61279960e0830189612667565b82810360408401526127ab8189612667565b606084018890526001600160a01b038716608085015260a0840186905283810360c0850152845180825260208087019350909101905f5b818110156128005783518352602093840193909201916001016127e2565b50909b9a5050505050505050505050565b801515811461258c575f5ffd5b5f5f5f60408486031215612830575f5ffd5b833561283b81612811565b9250602084013567ffffffffffffffff811115612856575f5ffd5b612862868287016125b2565b9497909650939450505050565b5f5f5f5f5f60608688031215612883575f5ffd5b853567ffffffffffffffff811115612899575f5ffd5b6128a5888289016125b2565b90965094505060208601359250604086013567ffffffffffffffff8111156128cb575f5ffd5b6128d7888289016125b2565b969995985093965092949392505050565b5f5f602083850312156128f9575f5ffd5b823567ffffffffffffffff81111561290f575f5ffd5b61291b858286016125b2565b90969095509350505050565b5f5f60208385031215612938575f5ffd5b823567ffffffffffffffff81111561294e575f5ffd5b8301601f8101851361295e575f5ffd5b803567ffffffffffffffff811115612974575f5ffd5b8560208260051b8401011115612988575f5ffd5b6020919091019590945092505050565b5f8151808452602084019350602083015f5b828110156129d15781516001600160a01b03168652602095860195909101906001016129aa565b5093949350505050565b6020815281516020820152602082015160408201526001600160a01b0360408301511660608201525f606083015160c06080840152612a1d60e0840182612667565b6080850151848203601f190160a0860152805180835291925060209081019181840191600582901b8501015f5b82811015612aa657601f1986830301845284516001600160a01b038151168352602081015160606020850152612a836060850182612667565b604092830151949092019390935260209586019594909401939150600101612a4a565b5060a08801519450601f198782030160c0880152612ac48186612998565b98975050505050505050565b6001600160a01b038116811461258c575f5ffd5b803561087781612ad0565b5f60208284031215612aff575f5ffd5b8135610ac981612ad0565b5f5f8335601e19843603018112612b1f575f5ffd5b83018035915067ffffffffffffffff821115612b39575f5ffd5b6020019150368190038213156125f0575f5ffd5b81835281816020850137505f602082840101525f6020601f19601f840116840101905092915050565b606081525f612b89606083018688612b4d565b90508360208301526001600160a01b038316604083015295945050505050565b5f5f8335601e19843603018112612bbe575f5ffd5b83018035915067ffffffffffffffff821115612bd8575f5ffd5b6020019150600581901b36038213156125f0575f5ffd5b604081525f612c02604083018587612b4d565b9050826020830152949350505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b602081525f610eb8602083018486612b4d565b6040516060810167ffffffffffffffff81118282101715612c7557612c75612c12565b60405290565b60405160c0810167ffffffffffffffff81118282101715612c7557612c75612c12565b604051601f8201601f1916810167ffffffffffffffff81118282101715612cc757612cc7612c12565b604052919050565b805161087781612ad0565b5f67ffffffffffffffff821115612cf357612cf3612c12565b50601f01601f191660200190565b5f82601f830112612d10575f5ffd5b8151602083015f612d28612d2384612cda565b612c9e565b9050828152858383011115612d3b575f5ffd5b8282602083015e5f92810160200192909252509392505050565b5f67ffffffffffffffff821115612d6e57612d6e612c12565b5060051b60200190565b5f82601f830112612d87575f5ffd5b8151612d95612d2382612d55565b8082825260208201915060208360051b860101925085831115612db6575f5ffd5b602085015b83811015612e5057805167ffffffffffffffff811115612dd9575f5ffd5b86016060818903601f19011215612dee575f5ffd5b612df6612c52565b6020820151612e0481612ad0565b8152604082015167ffffffffffffffff811115612e1f575f5ffd5b612e2e8a602083860101612d01565b6020838101919091526060939093015160408301525084529283019201612dbb565b5095945050505050565b5f82601f830112612e69575f5ffd5b8151612e77612d2382612d55565b8082825260208201915060208360051b860101925085831115612e98575f5ffd5b602085015b83811015612e50578051612eb081612ad0565b835260209283019201612e9d565b5f60208284031215612ece575f5ffd5b815167ffffffffffffffff811115612ee4575f5ffd5b820160c08185031215612ef5575f5ffd5b612efd612c7b565b8151815260208083015190820152612f1760408301612ccf565b6040820152606082015167ffffffffffffffff811115612f35575f5ffd5b612f4186828501612d01565b606083015250608082015167ffffffffffffffff811115612f60575f5ffd5b612f6c86828501612d78565b60808301525060a082015167ffffffffffffffff811115612f8b575f5ffd5b612f9786828501612e5a565b60a083015250949350505050565b5f81518060208401855e5f93019283525090919050565b5f610eb8612fca8386612fa5565b84612fa5565b818382375f9101908152919050565b5f5f85851115612fed575f5ffd5b83861115612ff9575f5ffd5b5050820193919092039150565b80356020831015610ecf577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b80357fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169060148410156130a1577fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808560140360031b1b82161691505b5092915050565b606081525f6130bb606083018688612b4d565b84602084015282810360408401526130d38185612667565b979650505050505050565b80357fffffffff0000000000000000000000000000000000000000000000000000000081169060048410156130a1577fffffffff00000000000000000000000000000000000000000000000000000000808560040360031b1b82161691505092915050565b5f82601f830112613152575f5ffd5b8135602083015f613165612d2384612cda565b9050828152858383011115613178575f5ffd5b828260208301375f92810160200192909252509392505050565b5f82601f8301126131a1575f5ffd5b81356131af612d2382612d55565b8082825260208201915060208360051b8601019250858311156131d0575f5ffd5b602085015b83811015612e5057803567ffffffffffffffff8111156131f3575f5ffd5b86016060818903601f19011215613208575f5ffd5b613210612c52565b602082013561321e81612ad0565b8152604082013567ffffffffffffffff811115613239575f5ffd5b6132488a602083860101613143565b60208381019190915260609390930135604083015250845292830192016131d5565b5f82601f830112613279575f5ffd5b8135613287612d2382612d55565b8082825260208201915060208360051b8601019250858311156132a8575f5ffd5b602085015b83811015612e505780356132c081612ad0565b8352602092830192016132ad565b5f60c082840312156132de575f5ffd5b6132e6612c7b565b8235815260208084013590820152905061330260408301612ae4565b6040820152606082013567ffffffffffffffff811115613320575f5ffd5b61332c84828501613143565b606083015250608082013567ffffffffffffffff81111561334b575f5ffd5b61335784828501613192565b60808301525060a082013567ffffffffffffffff811115613376575f5ffd5b6133828482850161326a565b60a08301525092915050565b5f5f5f606084860312156133a0575f5ffd5b833567ffffffffffffffff8111156133b6575f5ffd5b6133c2868287016132ce565b93505060208401359150604084013567ffffffffffffffff8111156133e5575f5ffd5b6133f186828701613143565b9150509250925092565b5f6020828403121561340b575f5ffd5b813567ffffffffffffffff811115613421575f5ffd5b610eb8848285016132ce565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f82357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa183360301811261348c575f5ffd5b9190910192915050565b81515f90829060208501835b828110156134c05781518452602093840193909101906001016134a2565b509195945050505050565b5f8184825b858110156135015781356134e381612ad0565b6001600160a01b0316835260209283019291909101906001016134d0565b509095945050505050565b5f6020828403121561351c575f5ffd5b5051919050565b5f60208284031215613533575f5ffd5b8151610ac981612811565b602080825281018290525f6040600584901b8301810190830185837fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa136839003015b87821015613652577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc087860301845282358181126135bc575f5ffd5b890180356135c981612ad0565b6001600160a01b03168652602081013536829003601e190181126135eb575f5ffd5b810160208101903567ffffffffffffffff811115613607575f5ffd5b803603821315613615575f5ffd5b6060602089015261362a606089018284612b4d565b6040938401359890930197909752509450602093840193929092019160019190910190613580565b5092979650505050505050565b5f610ecc8284612fa5565b5f6020828403121561367a575f5ffd5b815167ffffffffffffffff811115613690575f5ffd5b8201601f810184136136a0575f5ffd5b80516136ae612d2382612d55565b8082825260208201915060208360051b8501019250868311156136cf575f5ffd5b602084015b8381101561371057805167ffffffffffffffff8111156136f2575f5ffd5b61370189602083890101612d01565b845250602092830192016136d4565b509695505050505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602160045260245ffd5b600181811c9082168061375c57607f821691505b6020821081036125ac577f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffdfe608060405234801561000f575f5ffd5b5060405161017538038061017583398101604081905261002e916100ae565b5f5f336001600160a01b031683604051610048919061015e565b5f60405180830381855af49150503d805f8114610080576040519150601f19603f3d011682016040523d82523d5f602084013e610085565b606091505b50915091508161009757805181602001fd5b33ff5b634e487b7160e01b5f52604160045260245ffd5b5f602082840312156100be575f5ffd5b81516001600160401b038111156100d3575f5ffd5b8201601f810184136100e3575f5ffd5b80516001600160401b038111156100fc576100fc61009a565b604051601f8201601f19908116603f011681016001600160401b038111828210171561012a5761012a61009a565b604052818152828201602001861015610141575f5ffd5b8160208401602083015e5f91810160200191909152949350505050565b5f82518060208501845e5f92019182525091905056fea26469706673582212206c8186abce9b557cea5bc07e537bea67459e14ae5ac07f89e7e6b465cc8ef69b64736f6c634300081b003300000000000000000000000078c1b0c915c4faa5fffa6cabf0219da63d7f4cb800000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000005000000000000000000000000b5eaf06aa1704041e6ca112222a94d6f0a8a4098000000000000000000000000573c4e63f445fe243cf32d878482368627dede270000000000000000000000000db34395cc9d2647439d745d13f737666d629018000000000000000000000000757a2534dcee4f1c4087727febc175d2d67155dd000000000000000000000000786a8a48bc358fe59634b57b73927c58e32561d9
Deployed Bytecode
0x608060405260043610610183575f3560e01c8063a7cbcd50116100d1578063cf95c95b1161007c578063e8abf37911610057578063e8abf3791461052f578063eeb1965114610542578063fc690fe01461056e575f5ffd5b8063cf95c95b146104ca578063da0842f7146104fd578063da5915081461051c575f5ffd5b8063aef18bf7116100ac578063aef18bf71461045c578063bcdd390f1461048a578063c92cc131146104a9575f5ffd5b8063a7cbcd50146103c3578063ab7244de146103f6578063ae09b8fa14610429575f5ffd5b806326bd0c4e1161013157806384b0196e1161010c57806384b0196e1461033657806390cfff2a1461035d578063a21ad4b814610390575f5ffd5b806326bd0c4e146102bc5780633d5172df146102ef57806378e890ba14610322575f5ffd5b80631a912f3e116101615780631a912f3e1461022a5780631c40a3591461026b57806320021d8b1461027e575f5ffd5b80630e0638be14610187578063166f37f6146101d757806317fcb39b146101f7575b5f5ffd5b348015610192575f5ffd5b506101ba7f000000000000000000000000573c4e63f445fe243cf32d878482368627dede2781565b6040516001600160a01b0390911681526020015b60405180910390f35b6101ea6101e53660046125f7565b610581565b6040516101ce9190612695565b348015610202575f5ffd5b506101ba7f00000000000000000000000078c1b0c915c4faa5fffa6cabf0219da63d7f4cb881565b348015610235575f5ffd5b5061025d7f96e412881b9055f40cc9a1b82ff7957e56c9d661e4493c769b55a42bc6b5ac7f81565b6040519081526020016101ce565b6101ea610279366004612716565b6107de565b348015610289575f5ffd5b506102ac610298366004612748565b5f9081526002602052604090205460ff1690565b60405190151581526020016101ce565b3480156102c7575f5ffd5b506101ba7f000000000000000000000000576cbcde3fe704b2166e8fac54d7a664b0325c1081565b3480156102fa575f5ffd5b506101ba7f0000000000000000000000000db34395cc9d2647439d745d13f737666d62901881565b34801561032d575f5ffd5b5061025d61087c565b348015610341575f5ffd5b5061034a61088a565b6040516101ce979695949392919061275f565b348015610368575f5ffd5b5061025d7f7967b984fb0a3c1384a03e582a53972b9a16e295dd9e635296def1f406112eeb81565b34801561039b575f5ffd5b506101ba7f000000000000000000000000786a8a48bc358fe59634b57b73927c58e32561d981565b3480156103ce575f5ffd5b5061025d7f3c5c3fffe366d8418c5276b046ae4bfd8887a0779c6750f459133811c55dc5eb81565b348015610401575f5ffd5b506101ba7f000000000000000000000000757a2534dcee4f1c4087727febc175d2d67155dd81565b348015610434575f5ffd5b506101ba7f000000000000000000000000b5eaf06aa1704041e6ca112222a94d6f0a8a409881565b348015610467575f5ffd5b506102ac610476366004612748565b60026020525f908152604090205460ff1681565b348015610495575f5ffd5b506101ba6104a436600461281e565b6108e8565b3480156104b4575f5ffd5b506104c86104c336600461286f565b610ad0565b005b3480156104d5575f5ffd5b5061025d7f16f71df7185a51e60cfb3b8e021014dd95ec8b3a7d9094d75b290b5cb2560a9681565b348015610508575f5ffd5b506104c86105173660046128e8565b610cd8565b6101ea61052a366004612716565b610d9e565b6101ea61053d366004612927565b610ec0565b34801561054d575f5ffd5b5061056161055c3660046128e8565b610ed5565b6040516101ce91906129db565b6101ea61057c3660046125f7565b611111565b6060834211156105bd576040517ff87d927100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84355f9081526002602052604090205460ff1615610607576040517fd6a3c2d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f6106337f16f71df7185a51e60cfb3b8e021014dd95ec8b3a7d9094d75b290b5cb2560a9687876113b8565b90505f61063f82611670565b90505f61068386868080601f0160208091040260200160405190810160405280939291908181526020018383808284375f9201919091525086939250506116b79050565b905061068e816116df565b6106c4576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b87355f908152600260205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905561070e9060608a01908a01612aef565b6001600160a01b0316602089013589357f2c25950a88d2af6f8e025dc013f4fcc40e859e3c3b6e4f7979d1025899ea401861074c60608d018d612b0a565b348760405161075e9493929190612b76565b60405180910390a461077b61077660808a018a612ba9565b61181d565b93506107d361079060608a0160408b01612aef565b61079d60a08b018b612ba9565b808060200260200160405190810160405280939291908181526020018383602002808284375f920191909152506119cb92505050565b505050949350505050565b60606107ef82820160408401612aef565b6001600160a01b0316602083013583357f2742354653a6ba360731d003e1e2b4894255cbddd2f4050e7230db5cbae2128a61082d6060870187612b0a565b3460405161083d93929190612bef565b60405180910390a46108556107766080840184612ba9565b905061087761086a6060840160408501612aef565b61079d60a0850185612ba9565b919050565b5f610885611c6d565b905090565b5f6060805f5f5f606061089b611d96565b6108a3611dc2565b604080515f808252602082019092527f0f000000000000000000000000000000000000000000000000000000000000009b939a50919850469750309650945092509050565b5f6108f38383611def565b6040517feeb19651000000000000000000000000000000000000000000000000000000008152309063eeb19651906109319086908690600401612c3f565b5f60405180830381865afa92505050801561096d57506040513d5f823e601f3d908101601f1916820160405261096a9190810190612ebe565b60015b6109a3576040517fdabcbc2f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b507fff0000000000000000000000000000000000000000000000000000000000000030856109d1575f6109d4565b60015b6040516109e36020820161258f565b601f1982820381018352601f909101166040819052610a089088908890602001612c3f565b60408051601f1981840301815290829052610a269291602001612fbc565b60405160208183030381529060405280519060200120604051602001610aae94939291907fff0000000000000000000000000000000000000000000000000000000000000094909416845260609290921b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660018401526015830152603582015260550190565b604051602081830303815290604052805190602001205f1c90505b9392505050565b82421115610b0a576040517ff87d927100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610b148585611def565b5f7f7967b984fb0a3c1384a03e582a53972b9a16e295dd9e635296def1f406112eeb8686604051610b46929190612fd0565b604080519182900382206020830193909352810191909152606081018590526080016040516020818303038152906040528051906020012090505f610b8a82611670565b90505f610bce85858080601f0160208091040260200160405190810160405280939291908181526020018383808284375f9201919091525086939250506116b79050565b9050610bd9816116df565b610c0f576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610c1e604460248a8c612fdf565b610c2791613006565b90505f610c38608460708b8d612fdf565b610c4191613042565b60601c90505f60015f1b8b8b604051610c599061258f565b610c64929190612c3f565b8190604051809103905ff5905080158015610c81573d5f5f3e3d5ffd5b506040516001600160a01b0386811682529192508183169184169085907fadbc21ad7e1f77960f52858d8e4d14d953e23a380f62d4809611e516731932429060200160405180910390a45050505050505050505050565b610ce28282611def565b5f610cf1604460248486612fdf565b610cfa91613006565b90505f610d0b608460708587612fdf565b610d1491613042565b60601c90505f5f5f1b8585604051610d2b9061258f565b610d36929190612c3f565b8190604051809103905ff5905080158015610d53573d5f5f3e3d5ffd5b509050806001600160a01b0316826001600160a01b0316847fa299fa29a1850025e8c56c8ed2fb0932b6f6cf16bd0948ed0aee34bab796147460405160405180910390a45050505050565b60605f8080610db8610db36080870187612ba9565b611e88565b9250925092508215610e2f57610dd46060860160408701612aef565b6001600160a01b0316602086013586357f41856989118d8100f29fc0f0385da890ab23dbe5cb1403dc364937a4248010f0610e1260608a018a612b0a565b34604051610e2293929190612bef565b60405180910390a4610e98565b610e3f6060860160408701612aef565b6001600160a01b0316602086013586357f054ff99066858d6abaf7037a1f3b4a601ff6cce629c00ac000fb2530a2db0946610e7d60608a018a612b0a565b3488604051610e8f94939291906130a8565b60405180910390a45b610eb8610eab6060870160408801612aef565b61079d60a0880188612ba9565b949350505050565b6060610ecc838361181d565b90505b92915050565b610f146040518060c001604052805f81526020015f81526020015f6001600160a01b031681526020016060815260200160608152602001606081525090565b5f610f226004828587612fdf565b610f2b916130de565b9050365f610f3c8560048189612fdf565b90925090507fffffffff0000000000000000000000000000000000000000000000000000000083167ffc690fe0000000000000000000000000000000000000000000000000000000001480610fd257507fffffffff0000000000000000000000000000000000000000000000000000000083167f166f37f600000000000000000000000000000000000000000000000000000000145b15611033575f6060610fe68385018561338e565b80519298509093509150604114611029576040517fdabcbc2f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050610ecf565b7fffffffff0000000000000000000000000000000000000000000000000000000083167fda5915080000000000000000000000000000000000000000000000000000000014806110c457507fffffffff0000000000000000000000000000000000000000000000000000000083167f1c40a35900000000000000000000000000000000000000000000000000000000145b156110df576110d5818301836133fb565b9350505050610ecf565b6040517fdabcbc2f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60608342111561114d576040517ff87d927100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84355f9081526002602052604090205460ff1615611197576040517fd6a3c2d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f6111c37f3c5c3fffe366d8418c5276b046ae4bfd8887a0779c6750f459133811c55dc5eb87876113b8565b90505f6111cf82611670565b90505f61121386868080601f0160208091040260200160405190810160405280939291908181526020018383808284375f9201919091525086939250506116b79050565b905061121e816116df565b611254576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b87355f90815260026020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055808061129e610db360808d018d612ba9565b925092509250821561131c576112ba60608c0160408d01612aef565b6001600160a01b03168b602001358c5f01357f24042cc2931c07295fba5982b8cbeb67d07d7ab992b15f1ceeddba721d2a91cb8e80606001906112fd9190612b0a565b348a60405161130f9493929190612b76565b60405180910390a461138a565b61132c60608c0160408d01612aef565b6001600160a01b03168b602001358c5f01357f3b00b3a71f4507558d207cabff3e58f5ad8995c2b70a7c82acc066f59c78b1dd8e806060019061136f9190612b0a565b348860405161138194939291906130a8565b60405180910390a45b6113aa61139d60608d0160408e01612aef565b61079d60a08e018e612ba9565b9a9950505050505050505050565b5f806113c76080850185612ba9565b905067ffffffffffffffff8111156113e1576113e1612c12565b60405190808252806020026020018201604052801561140a578160200160208202803683370190505b5090505f5b61141c6080860186612ba9565b905081101561156e577f96e412881b9055f40cc9a1b82ff7957e56c9d661e4493c769b55a42bc6b5ac7f6114536080870187612ba9565b838181106114635761146361342d565b9050602002810190611475919061345a565b611483906020810190612aef565b6114906080880188612ba9565b848181106114a0576114a061342d565b90506020028101906114b2919061345a565b6114c0906020810190612b0a565b6040516114ce929190612fd0565b6040519081900390206114e46080890189612ba9565b858181106114f4576114f461342d565b9050602002810190611506919061345a565b6040805160208101959095526001600160a01b039093168484015260608401919091520135608082015260a0016040516020818303038152906040528051906020012082828151811061155b5761155b61342d565b602090810291909101015260010161140f565b50846115806060860160408701612aef565b853560208701356115946060890189612b0a565b6040516115a2929190612fd0565b6040518091039020856040516020016115bb9190613496565b60408051601f1981840301815291905280516020909101206115e060a08b018b612ba9565b6040516020016115f19291906134cb565b60408051601f198184030181528282528051602091820120908301989098526001600160a01b03909616958101959095526060850193909352608084019190915260a083015260c082015260e0810191909152610100810184905261012001604051602081830303815290604052805190602001209150509392505050565b5f610ecf61167c611c6d565b836040517f19010000000000000000000000000000000000000000000000000000000000008152600281019290925260228201526042902090565b5f5f5f5f6116c58686611fd9565b9250925092506116d58282612022565b5090949350505050565b5f6001600160a01b03821615801590610ecf57507f000000000000000000000000b5eaf06aa1704041e6ca112222a94d6f0a8a40986001600160a01b0316826001600160a01b0316148061176457507f000000000000000000000000573c4e63f445fe243cf32d878482368627dede276001600160a01b0316826001600160a01b0316145b806117a057507f0000000000000000000000000db34395cc9d2647439d745d13f737666d6290186001600160a01b0316826001600160a01b0316145b806117dc57507f000000000000000000000000757a2534dcee4f1c4087727febc175d2d67155dd6001600160a01b0316826001600160a01b0316145b80610ecf57507f000000000000000000000000786a8a48bc358fe59634b57b73927c58e32561d96001600160a01b0316826001600160a01b03161492915050565b6060815f8167ffffffffffffffff81111561183a5761183a612c12565b60405190808252806020026020018201604052801561186d57816020015b60608152602001906001900390816118585790505b5090505f5b828110156119c2575f5f87878481811061188e5761188e61342d565b90506020028101906118a0919061345a565b6118ae906020810190612aef565b6001600160a01b03168888858181106118c9576118c961342d565b90506020028101906118db919061345a565b604001358989868181106118f1576118f161342d565b9050602002810190611903919061345a565b611911906020810190612b0a565b60405161191f929190612fd0565b5f6040518083038185875af1925050503d805f8114611959576040519150601f19603f3d011682016040523d82523d5f602084013e61195e565b606091505b50915091508161199a576040517f3204506f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b808484815181106119ad576119ad61342d565b60209081029190910101525050600101611872565b50949350505050565b478015611ad2575f836001600160a01b0316826040515f6040518083038185875af1925050503d805f8114611a1b576040519150601f19603f3d011682016040523d82523d5f602084013e611a20565b606091505b5050905080611ad0577f00000000000000000000000078c1b0c915c4faa5fffa6cabf0219da63d7f4cb86001600160a01b031663d0e30db0836040518263ffffffff1660e01b81526004015f604051808303818588803b158015611a82575f5ffd5b505af1158015611a94573d5f5f3e3d5ffd5b50611ad09350506001600160a01b037f00000000000000000000000078c1b0c915c4faa5fffa6cabf0219da63d7f4cb81691508690508461212e565b505b5f5b8251811015611c67575f6001600160a01b0316838281518110611af957611af961342d565b60200260200101516001600160a01b031614611c5f575f838281518110611b2257611b2261342d565b60209081029190910101516040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b03909116906370a0823190602401602060405180830381865afa158015611b89573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611bad919061350c565b90508015611c5d57838281518110611bc757611bc761342d565b60209081029190910101516040517fa9059cbb0000000000000000000000000000000000000000000000000000000081526001600160a01b038781166004830152602482018490529091169063a9059cbb906044016020604051808303815f875af1925050508015611c56575060408051601f3d908101601f19168201909252611c5391810190613523565b60015b15611c5d57505b505b600101611ad4565b50505050565b5f306001600160a01b037f000000000000000000000000576cbcde3fe704b2166e8fac54d7a664b0325c1016148015611cc557507f000000000000000000000000000000000000000000000000000000000000138846145b15611cef57507f408df29df22169702340e4bc1ca860068677f021b9d1fb72840e0a9b00d51c1090565b610885604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f60208201527f16dfb97e922774064683b0238cc4fdceca37ab3d0c61264a57208eabb8490037918101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc660608201524660808201523060a08201525f9060c00160405160208183030381529060405280519060200120905090565b60606108857f496e74656e7400000000000000000000000000000000000000000000000000065f6121ae565b60606108857f310000000000000000000000000000000000000000000000000000000000000160016121ae565b5f611dfd6004828486612fdf565b611e06916130de565b90507fffffffff0000000000000000000000000000000000000000000000000000000081167fda5915080000000000000000000000000000000000000000000000000000000014611e83576040517f496c792100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050565b5f6060805f63e8abf37960e01b8686604051602401611ea892919061353e565b604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff838183161783525050505090507f000000000000000000000000576cbcde3fe704b2166e8fac54d7a664b0325c106001600160a01b031681604051611f3f919061365f565b5f60405180830381855af49150503d805f8114611f77576040519150601f19603f3d011682016040523d82523d5f602084013e611f7c565b606091505b5090945092508315611fa35782806020019051810190611f9c919061366a565b9150611fd1565b604080515f8082526020820190925290611fcd565b6060815260200190600190039081611fb85790505b5091505b509250925092565b5f5f5f8351604103612010576020840151604085015160608601515f1a61200288828585612257565b95509550955050505061201b565b505081515f91506002905b9250925092565b5f8260038111156120355761203561371b565b0361203e575050565b60018260038111156120525761205261371b565b03612089576040517ff645eedf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600282600381111561209d5761209d61371b565b036120dc576040517ffce698f7000000000000000000000000000000000000000000000000000000008152600481018290526024015b60405180910390fd5b60038260038111156120f0576120f061371b565b0361212a576040517fd78bce0c000000000000000000000000000000000000000000000000000000008152600481018290526024016120d3565b5050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb00000000000000000000000000000000000000000000000000000000179052611e8390849061231f565b606060ff83146121c8576121c183612399565b9050610ecf565b8180546121d490613748565b80601f016020809104026020016040519081016040528092919081815260200182805461220090613748565b801561224b5780601f106122225761010080835404028352916020019161224b565b820191905f5260205f20905b81548152906001019060200180831161222e57829003601f168201915b50505050509050610ecf565b5f80807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a084111561229057505f91506003905082612315565b604080515f808252602082018084528a905260ff891692820192909252606081018790526080810186905260019060a0016020604051602081039080840390855afa1580156122e1573d5f5f3e3d5ffd5b5050604051601f1901519150506001600160a01b03811661230c57505f925060019150829050612315565b92505f91508190505b9450945094915050565b5f6123336001600160a01b038416836123d6565b905080515f141580156123575750808060200190518101906123559190613523565b155b15611e83576040517f5274afe70000000000000000000000000000000000000000000000000000000081526001600160a01b03841660048201526024016120d3565b60605f6123a5836123e3565b6040805160208082528183019092529192505f91906020820181803683375050509182525060208101929092525090565b6060610ecc83835f612423565b5f60ff8216601f811115610ecf576040517fb3512b0c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606081471015612461576040517fcd7860590000000000000000000000000000000000000000000000000000000081523060048201526024016120d3565b5f5f856001600160a01b0316848660405161247c919061365f565b5f6040518083038185875af1925050503d805f81146124b6576040519150601f19603f3d011682016040523d82523d5f602084013e6124bb565b606091505b50915091506124cb8683836124d5565b9695505050505050565b6060826124ea576124e58261254a565b610ac9565b815115801561250157506001600160a01b0384163b155b15612543576040517f9996b3150000000000000000000000000000000000000000000000000000000081526001600160a01b03851660048201526024016120d3565b5080610ac9565b80511561255a5780518082602001fd5b6040517f1425ea4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50565b6101758061379483390190565b5f60c082840312156125ac575f5ffd5b50919050565b5f5f83601f8401126125c2575f5ffd5b50813567ffffffffffffffff8111156125d9575f5ffd5b6020830191508360208285010111156125f0575f5ffd5b9250929050565b5f5f5f5f6060858703121561260a575f5ffd5b843567ffffffffffffffff811115612620575f5ffd5b61262c8782880161259c565b94505060208501359250604085013567ffffffffffffffff81111561264f575f5ffd5b61265b878288016125b2565b95989497509550505050565b5f81518084528060208401602086015e5f602082860101526020601f19601f83011685010191505092915050565b5f602082016020835280845180835260408501915060408160051b8601019250602086015f5b8281101561270a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc08786030184526126f5858351612667565b945060209384019391909101906001016126bb565b50929695505050505050565b5f60208284031215612726575f5ffd5b813567ffffffffffffffff81111561273c575f5ffd5b610eb88482850161259c565b5f60208284031215612758575f5ffd5b5035919050565b7fff000000000000000000000000000000000000000000000000000000000000008816815260e060208201525f61279960e0830189612667565b82810360408401526127ab8189612667565b606084018890526001600160a01b038716608085015260a0840186905283810360c0850152845180825260208087019350909101905f5b818110156128005783518352602093840193909201916001016127e2565b50909b9a5050505050505050505050565b801515811461258c575f5ffd5b5f5f5f60408486031215612830575f5ffd5b833561283b81612811565b9250602084013567ffffffffffffffff811115612856575f5ffd5b612862868287016125b2565b9497909650939450505050565b5f5f5f5f5f60608688031215612883575f5ffd5b853567ffffffffffffffff811115612899575f5ffd5b6128a5888289016125b2565b90965094505060208601359250604086013567ffffffffffffffff8111156128cb575f5ffd5b6128d7888289016125b2565b969995985093965092949392505050565b5f5f602083850312156128f9575f5ffd5b823567ffffffffffffffff81111561290f575f5ffd5b61291b858286016125b2565b90969095509350505050565b5f5f60208385031215612938575f5ffd5b823567ffffffffffffffff81111561294e575f5ffd5b8301601f8101851361295e575f5ffd5b803567ffffffffffffffff811115612974575f5ffd5b8560208260051b8401011115612988575f5ffd5b6020919091019590945092505050565b5f8151808452602084019350602083015f5b828110156129d15781516001600160a01b03168652602095860195909101906001016129aa565b5093949350505050565b6020815281516020820152602082015160408201526001600160a01b0360408301511660608201525f606083015160c06080840152612a1d60e0840182612667565b6080850151848203601f190160a0860152805180835291925060209081019181840191600582901b8501015f5b82811015612aa657601f1986830301845284516001600160a01b038151168352602081015160606020850152612a836060850182612667565b604092830151949092019390935260209586019594909401939150600101612a4a565b5060a08801519450601f198782030160c0880152612ac48186612998565b98975050505050505050565b6001600160a01b038116811461258c575f5ffd5b803561087781612ad0565b5f60208284031215612aff575f5ffd5b8135610ac981612ad0565b5f5f8335601e19843603018112612b1f575f5ffd5b83018035915067ffffffffffffffff821115612b39575f5ffd5b6020019150368190038213156125f0575f5ffd5b81835281816020850137505f602082840101525f6020601f19601f840116840101905092915050565b606081525f612b89606083018688612b4d565b90508360208301526001600160a01b038316604083015295945050505050565b5f5f8335601e19843603018112612bbe575f5ffd5b83018035915067ffffffffffffffff821115612bd8575f5ffd5b6020019150600581901b36038213156125f0575f5ffd5b604081525f612c02604083018587612b4d565b9050826020830152949350505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b602081525f610eb8602083018486612b4d565b6040516060810167ffffffffffffffff81118282101715612c7557612c75612c12565b60405290565b60405160c0810167ffffffffffffffff81118282101715612c7557612c75612c12565b604051601f8201601f1916810167ffffffffffffffff81118282101715612cc757612cc7612c12565b604052919050565b805161087781612ad0565b5f67ffffffffffffffff821115612cf357612cf3612c12565b50601f01601f191660200190565b5f82601f830112612d10575f5ffd5b8151602083015f612d28612d2384612cda565b612c9e565b9050828152858383011115612d3b575f5ffd5b8282602083015e5f92810160200192909252509392505050565b5f67ffffffffffffffff821115612d6e57612d6e612c12565b5060051b60200190565b5f82601f830112612d87575f5ffd5b8151612d95612d2382612d55565b8082825260208201915060208360051b860101925085831115612db6575f5ffd5b602085015b83811015612e5057805167ffffffffffffffff811115612dd9575f5ffd5b86016060818903601f19011215612dee575f5ffd5b612df6612c52565b6020820151612e0481612ad0565b8152604082015167ffffffffffffffff811115612e1f575f5ffd5b612e2e8a602083860101612d01565b6020838101919091526060939093015160408301525084529283019201612dbb565b5095945050505050565b5f82601f830112612e69575f5ffd5b8151612e77612d2382612d55565b8082825260208201915060208360051b860101925085831115612e98575f5ffd5b602085015b83811015612e50578051612eb081612ad0565b835260209283019201612e9d565b5f60208284031215612ece575f5ffd5b815167ffffffffffffffff811115612ee4575f5ffd5b820160c08185031215612ef5575f5ffd5b612efd612c7b565b8151815260208083015190820152612f1760408301612ccf565b6040820152606082015167ffffffffffffffff811115612f35575f5ffd5b612f4186828501612d01565b606083015250608082015167ffffffffffffffff811115612f60575f5ffd5b612f6c86828501612d78565b60808301525060a082015167ffffffffffffffff811115612f8b575f5ffd5b612f9786828501612e5a565b60a083015250949350505050565b5f81518060208401855e5f93019283525090919050565b5f610eb8612fca8386612fa5565b84612fa5565b818382375f9101908152919050565b5f5f85851115612fed575f5ffd5b83861115612ff9575f5ffd5b5050820193919092039150565b80356020831015610ecf577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b80357fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169060148410156130a1577fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808560140360031b1b82161691505b5092915050565b606081525f6130bb606083018688612b4d565b84602084015282810360408401526130d38185612667565b979650505050505050565b80357fffffffff0000000000000000000000000000000000000000000000000000000081169060048410156130a1577fffffffff00000000000000000000000000000000000000000000000000000000808560040360031b1b82161691505092915050565b5f82601f830112613152575f5ffd5b8135602083015f613165612d2384612cda565b9050828152858383011115613178575f5ffd5b828260208301375f92810160200192909252509392505050565b5f82601f8301126131a1575f5ffd5b81356131af612d2382612d55565b8082825260208201915060208360051b8601019250858311156131d0575f5ffd5b602085015b83811015612e5057803567ffffffffffffffff8111156131f3575f5ffd5b86016060818903601f19011215613208575f5ffd5b613210612c52565b602082013561321e81612ad0565b8152604082013567ffffffffffffffff811115613239575f5ffd5b6132488a602083860101613143565b60208381019190915260609390930135604083015250845292830192016131d5565b5f82601f830112613279575f5ffd5b8135613287612d2382612d55565b8082825260208201915060208360051b8601019250858311156132a8575f5ffd5b602085015b83811015612e505780356132c081612ad0565b8352602092830192016132ad565b5f60c082840312156132de575f5ffd5b6132e6612c7b565b8235815260208084013590820152905061330260408301612ae4565b6040820152606082013567ffffffffffffffff811115613320575f5ffd5b61332c84828501613143565b606083015250608082013567ffffffffffffffff81111561334b575f5ffd5b61335784828501613192565b60808301525060a082013567ffffffffffffffff811115613376575f5ffd5b6133828482850161326a565b60a08301525092915050565b5f5f5f606084860312156133a0575f5ffd5b833567ffffffffffffffff8111156133b6575f5ffd5b6133c2868287016132ce565b93505060208401359150604084013567ffffffffffffffff8111156133e5575f5ffd5b6133f186828701613143565b9150509250925092565b5f6020828403121561340b575f5ffd5b813567ffffffffffffffff811115613421575f5ffd5b610eb8848285016132ce565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f82357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa183360301811261348c575f5ffd5b9190910192915050565b81515f90829060208501835b828110156134c05781518452602093840193909101906001016134a2565b509195945050505050565b5f8184825b858110156135015781356134e381612ad0565b6001600160a01b0316835260209283019291909101906001016134d0565b509095945050505050565b5f6020828403121561351c575f5ffd5b5051919050565b5f60208284031215613533575f5ffd5b8151610ac981612811565b602080825281018290525f6040600584901b8301810190830185837fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa136839003015b87821015613652577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc087860301845282358181126135bc575f5ffd5b890180356135c981612ad0565b6001600160a01b03168652602081013536829003601e190181126135eb575f5ffd5b810160208101903567ffffffffffffffff811115613607575f5ffd5b803603821315613615575f5ffd5b6060602089015261362a606089018284612b4d565b6040938401359890930197909752509450602093840193929092019160019190910190613580565b5092979650505050505050565b5f610ecc8284612fa5565b5f6020828403121561367a575f5ffd5b815167ffffffffffffffff811115613690575f5ffd5b8201601f810184136136a0575f5ffd5b80516136ae612d2382612d55565b8082825260208201915060208360051b8501019250868311156136cf575f5ffd5b602084015b8381101561371057805167ffffffffffffffff8111156136f2575f5ffd5b61370189602083890101612d01565b845250602092830192016136d4565b509695505050505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602160045260245ffd5b600181811c9082168061375c57607f821691505b6020821081036125ac577f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffdfe608060405234801561000f575f5ffd5b5060405161017538038061017583398101604081905261002e916100ae565b5f5f336001600160a01b031683604051610048919061015e565b5f60405180830381855af49150503d805f8114610080576040519150601f19603f3d011682016040523d82523d5f602084013e610085565b606091505b50915091508161009757805181602001fd5b33ff5b634e487b7160e01b5f52604160045260245ffd5b5f602082840312156100be575f5ffd5b81516001600160401b038111156100d3575f5ffd5b8201601f810184136100e3575f5ffd5b80516001600160401b038111156100fc576100fc61009a565b604051601f8201601f19908116603f011681016001600160401b038111828210171561012a5761012a61009a565b604052818152828201602001861015610141575f5ffd5b8160208401602083015e5f91810160200191909152949350505050565b5f82518060208501845e5f92019182525091905056fea26469706673582212206c8186abce9b557cea5bc07e537bea67459e14ae5ac07f89e7e6b465cc8ef69b64736f6c634300081b0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000078c1b0c915c4faa5fffa6cabf0219da63d7f4cb800000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000005000000000000000000000000b5eaf06aa1704041e6ca112222a94d6f0a8a4098000000000000000000000000573c4e63f445fe243cf32d878482368627dede270000000000000000000000000db34395cc9d2647439d745d13f737666d629018000000000000000000000000757a2534dcee4f1c4087727febc175d2d67155dd000000000000000000000000786a8a48bc358fe59634b57b73927c58e32561d9
-----Decoded View---------------
Arg [0] : wrappedNativeToken_ (address): 0x78c1b0C915c4FAA5FffA6CAbf0219DA63d7f4cb8
Arg [1] : authorized (address[]): 0xB5EAf06AA1704041E6ca112222A94d6F0a8A4098,0x573c4e63F445FE243cf32d878482368627dEDE27,0x0Db34395CC9D2647439d745d13F737666d629018,0x757A2534DCEE4F1c4087727feBc175d2D67155dD,0x786a8A48BC358fE59634B57b73927C58E32561D9
-----Encoded View---------------
8 Constructor Arguments found :
Arg [0] : 00000000000000000000000078c1b0c915c4faa5fffa6cabf0219da63d7f4cb8
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000040
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [3] : 000000000000000000000000b5eaf06aa1704041e6ca112222a94d6f0a8a4098
Arg [4] : 000000000000000000000000573c4e63f445fe243cf32d878482368627dede27
Arg [5] : 0000000000000000000000000db34395cc9d2647439d745d13f737666d629018
Arg [6] : 000000000000000000000000757a2534dcee4f1c4087727febc175d2d67155dd
Arg [7] : 000000000000000000000000786a8a48bc358fe59634b57b73927c58e32561d9
Net Worth in USD
Net Worth in MNT
Multichain Portfolio | 35 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
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.