Source Code
Overview
ETH Balance
0 ETH
ETH Value
$0.00| Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
Latest 1 internal transaction
Advanced mode:
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 4580992 | 140 days ago | Contract Creation | 0 ETH |
Cross-Chain Transactions
Loading...
Loading
Contract Name:
GenericRateProviderWithDecimalScaling
Compiler Version
v0.8.21+commit.d9974bed
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED
pragma solidity 0.8.21;
import {GenericRateProvider} from "src/helper/GenericRateProvider.sol";
contract GenericRateProviderWithDecimalScaling is GenericRateProvider {
//============================== STRUCTS ===============================
struct ConstructorArgs {
address target;
bytes4 selector;
bytes32 staticArgument0;
bytes32 staticArgument1;
bytes32 staticArgument2;
bytes32 staticArgument3;
bytes32 staticArgument4;
bytes32 staticArgument5;
bytes32 staticArgument6;
bytes32 staticArgument7;
bool signed;
uint8 inputDecimals;
uint8 outputDecimals;
}
//============================== ERRORS ===============================
error GenericRateProviderWithDecimalScaling__DecimalsCannotBeZero();
//============================== IMMUTABLES ===============================
uint8 public immutable inputDecimals;
uint8 public immutable outputDecimals;
constructor(
ConstructorArgs memory _args
) GenericRateProvider(
_args.target,
_args.selector,
_args.staticArgument0,
_args.staticArgument1,
_args.staticArgument2,
_args.staticArgument3,
_args.staticArgument4,
_args.staticArgument5,
_args.staticArgument6,
_args.staticArgument7,
_args.signed
) {
if (_args.inputDecimals == 0 || _args.outputDecimals == 0) {
revert GenericRateProviderWithDecimalScaling__DecimalsCannotBeZero();
}
inputDecimals = _args.inputDecimals;
outputDecimals = _args.outputDecimals;
}
function getRate() public override view returns (uint256) {
uint256 rate = super.getRate();
if (inputDecimals > outputDecimals) {
return rate / 10 ** (inputDecimals - outputDecimals);
} else if (inputDecimals < outputDecimals) {
return rate * 10 ** (outputDecimals - inputDecimals);
} else {
return rate;
}
}
}// 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: UNLICENSED
pragma solidity 0.8.21;
import {IRateProvider} from "src/interfaces/IRateProvider.sol";
import {Address} from "@openzeppelin/contracts/utils/Address.sol";
contract GenericRateProvider is IRateProvider {
using Address for address;
//============================== ERRORS ===============================
error GenericRateProvider__PriceCannotBeLtZero();
//============================== IMMUTABLES ===============================
/**
* @notice The address to make rate calls to.
*/
address public immutable target;
/**
* @notice The selector to call on the target.
*/
bytes4 public immutable selector;
/**
* @notice boolean indicating if we need to check for a signed return value.
* @dev if true, this indicates an int256 return value or similar signed number
*/
bool public immutable signed;
/**
* @notice Static arguments to pass to the target.
*/
bytes32 public immutable staticArgument0;
bytes32 public immutable staticArgument1;
bytes32 public immutable staticArgument2;
bytes32 public immutable staticArgument3;
bytes32 public immutable staticArgument4;
bytes32 public immutable staticArgument5;
bytes32 public immutable staticArgument6;
bytes32 public immutable staticArgument7;
constructor(
address _target,
bytes4 _selector,
bytes32 _staticArgument0,
bytes32 _staticArgument1,
bytes32 _staticArgument2,
bytes32 _staticArgument3,
bytes32 _staticArgument4,
bytes32 _staticArgument5,
bytes32 _staticArgument6,
bytes32 _staticArgument7,
bool _signed
) {
target = _target;
selector = _selector;
staticArgument0 = _staticArgument0;
staticArgument1 = _staticArgument1;
staticArgument2 = _staticArgument2;
staticArgument3 = _staticArgument3;
staticArgument4 = _staticArgument4;
staticArgument5 = _staticArgument5;
staticArgument6 = _staticArgument6;
staticArgument7 = _staticArgument7;
signed = _signed;
// Make sure getRate succeeds.
getRate();
}
// ========================================= RATE FUNCTION =========================================
/**
* @notice Get the rate of some generic asset.
* @dev This function only supports selectors that only contain static arguments, dynamic arguments will not be encoded correctly,
* and calls will likely fail.
* @dev If staticArgumentN is not used, it can be left as 0.
*/
function getRate() public virtual view returns (uint256) {
bytes memory callData = abi.encodeWithSelector(
selector,
staticArgument0,
staticArgument1,
staticArgument2,
staticArgument3,
staticArgument4,
staticArgument5,
staticArgument6,
staticArgument7
);
bytes memory result = target.functionStaticCall(callData);
if (signed) {
//if target func() returns an int, we get the result and then cast it to a uint256
int256 res = abi.decode(result, (int256));
if (res < 0) revert GenericRateProvider__PriceCannotBeLtZero();
return uint256(res);
} else {
return abi.decode(result, (uint256));
}
}
}// SPDX-License-Identifier: UNLICENSED
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
pragma solidity ^0.8.0;
interface IRateProvider {
function getRate() external view returns (uint256);
}{
"evmVersion": "shanghai",
"metadata": {
"appendCBOR": true,
"bytecodeHash": "ipfs",
"useLiteralContent": false
},
"optimizer": {
"enabled": true,
"runs": 200
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"abi"
]
}
},
"remappings": [
"@solmate/=lib/solmate/src/",
"@forge-std/=lib/forge-std/src/",
"@ds-test/=lib/forge-std/lib/ds-test/src/",
"ds-test/=lib/forge-std/lib/ds-test/src/",
"@openzeppelin/=lib/openzeppelin-contracts/",
"@ccip/=lib/ccip/",
"@oapp-auth/=lib/OAppAuth/src/",
"@devtools-oapp-evm/=lib/OAppAuth/lib/devtools/packages/oapp-evm/contracts/oapp/",
"@layerzerolabs/lz-evm-messagelib-v2/=lib/OAppAuth/node_modules/@layerzerolabs/lz-evm-messagelib-v2/",
"@layerzerolabs/lz-evm-protocol-v2/=lib/OAppAuth/lib/LayerZero-V2/packages/layerzero-v2/evm/protocol/",
"@layerzerolabs/oapp-evm/=lib/OAppAuth/lib/devtools/packages/oapp-evm/",
"@lz-oapp-evm/=lib/OAppAuth/lib/LayerZero-V2/packages/layerzero-v2/evm/oapp/contracts/oapp/",
"@sbu/=lib/OAppAuth/lib/solidity-bytes-utils/",
"LayerZero-V2/=lib/OAppAuth/lib/",
"OAppAuth/=lib/OAppAuth/",
"ccip/=lib/ccip/contracts/",
"erc4626-tests/=lib/openzeppelin-contracts/lib/erc4626-tests/",
"forge-std/=lib/forge-std/src/",
"halmos-cheatcodes/=lib/OAppAuth/lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/",
"openzeppelin-contracts/=lib/openzeppelin-contracts/",
"solidity-bytes-utils/=lib/OAppAuth/node_modules/solidity-bytes-utils/",
"solmate/=lib/solmate/src/"
],
"viaIR": false
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes4","name":"selector","type":"bytes4"},{"internalType":"bytes32","name":"staticArgument0","type":"bytes32"},{"internalType":"bytes32","name":"staticArgument1","type":"bytes32"},{"internalType":"bytes32","name":"staticArgument2","type":"bytes32"},{"internalType":"bytes32","name":"staticArgument3","type":"bytes32"},{"internalType":"bytes32","name":"staticArgument4","type":"bytes32"},{"internalType":"bytes32","name":"staticArgument5","type":"bytes32"},{"internalType":"bytes32","name":"staticArgument6","type":"bytes32"},{"internalType":"bytes32","name":"staticArgument7","type":"bytes32"},{"internalType":"bool","name":"signed","type":"bool"},{"internalType":"uint8","name":"inputDecimals","type":"uint8"},{"internalType":"uint8","name":"outputDecimals","type":"uint8"}],"internalType":"struct GenericRateProviderWithDecimalScaling.ConstructorArgs","name":"_args","type":"tuple"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"AddressEmptyCode","type":"error"},{"inputs":[],"name":"FailedInnerCall","type":"error"},{"inputs":[],"name":"GenericRateProviderWithDecimalScaling__DecimalsCannotBeZero","type":"error"},{"inputs":[],"name":"GenericRateProvider__PriceCannotBeLtZero","type":"error"},{"inputs":[],"name":"getRate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"inputDecimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"outputDecimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"selector","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"signed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument0","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument1","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument2","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument3","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument4","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument5","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument6","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"staticArgument7","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"target","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]Contract Creation Code
61022060405234801562000011575f80fd5b5060405162001223380380620012238339810160408190526200003491620004ba565b805f015181602001518260400151836060015184608001518560a001518660c001518760e001518861010001518961012001518a61014001518a6001600160a01b03166080816001600160a01b031681525050896001600160e01b03191660a0816001600160e01b031916815250508860e08181525050876101008181525050866101208181525050856101408181525050846101608181525050836101808181525050826101a08181525050816101c0818152505080151560c081151581525050620001066200016f60201b60201c565b50505050505050505050505080610160015160ff165f14806200012f575061018081015160ff16155b156200014e5760405163183c64f760e01b815260040160405180910390fd5b61016081015160ff9081166101e05261018090910151166102005262000746565b5f806200017b6200020c565b90506102005160ff166101e05160ff161115620001c557610200516101e051620001a69190620005a1565b620001b390600a620006b6565b620001bf9082620006c6565b91505090565b6102005160ff166101e05160ff16101562000207576101e05161020051620001ee9190620005a1565b620001fb90600a620006b6565b620001bf9082620006e6565b919050565b60a05160e05161010051610120516101405161016051610180516101a0516101c051604051602481019890985260448801969096526064870194909452608486019290925260a485015260c484015260e48301526101048201525f9182916101240160408051808303601f190181529190526020810180516001600160e01b0319939093166001600160e01b039384161790526080519092505f91620002bf916001600160a01b03169084906200032916565b905060c051156200030c575f81806020019051810190620002e1919062000700565b90505f8112156200030557604051630c67ca6960e31b815260040160405180910390fd5b9392505050565b8080602001905181019062000322919062000700565b9250505090565b60605f80846001600160a01b03168460405162000347919062000718565b5f60405180830381855afa9150503d805f811462000381576040519150601f19603f3d011682016040523d82523d5f602084013e62000386565b606091505b50909250905062000399858383620003a4565b925050505b92915050565b606082620003bd57620003b7826200040a565b62000305565b8151158015620003d557506001600160a01b0384163b155b156200040357604051639996b31560e01b81526001600160a01b038516600482015260240160405180910390fd5b5092915050565b8051156200041b5780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b6040516101a081016001600160401b03811182821017156200046457634e487b7160e01b5f52604160045260245ffd5b60405290565b80516001600160a01b038116811462000207575f80fd5b80516001600160e01b03198116811462000207575f80fd5b8051801515811462000207575f80fd5b805160ff8116811462000207575f80fd5b5f6101a08284031215620004cc575f80fd5b620004d662000434565b620004e1836200046a565b8152620004f16020840162000481565b602082015260408301516040820152606083015160608201526080830151608082015260a083015160a082015260c083015160c082015260e083015160e08201526101008084015181830152506101208084015181830152506101406200055a81850162000499565b908201526101606200056e848201620004a9565b9082015261018062000582848201620004a9565b908201529392505050565b634e487b7160e01b5f52601160045260245ffd5b60ff82811682821603908111156200039e576200039e6200058d565b600181815b80851115620005fd57815f1904821115620005e157620005e16200058d565b80851615620005ef57918102915b93841c9390800290620005c2565b509250929050565b5f8262000615575060016200039e565b816200062357505f6200039e565b81600181146200063c5760028114620006475762000667565b60019150506200039e565b60ff8411156200065b576200065b6200058d565b50506001821b6200039e565b5060208310610133831016604e8410600b84101617156200068c575081810a6200039e565b620006988383620005bd565b805f1904821115620006ae57620006ae6200058d565b029392505050565b5f6200030560ff84168362000605565b5f82620006e157634e487b7160e01b5f52601260045260245ffd5b500490565b80820281158282048414176200039e576200039e6200058d565b5f6020828403121562000711575f80fd5b5051919050565b5f82515f5b818110156200073957602081860181015185830152016200071d565b505f920191825250919050565b60805160a05160c05160e05161010051610120516101405161016051610180516101a0516101c0516101e051610200516109cb620008585f395f818161026301528181610360015281816103b101528181610413015261048501525f818161022a01528181610384015281816103d201528181610437015261046401525f818161020301526105d301525f818161033001526105ad01525f818161012a015261058701525f818161028a015261056101525f81816101b5015261053b01525f818161015f015261051501525f818161018601526104ef01525f81816101dc01526104c901525f818160ee015261068601525f81816102f0015261062001525f81816102b1015261065c01526109cb5ff3fe608060405234801561000f575f80fd5b50600436106100e5575f3560e01c8063a9f31af511610088578063c2a69a9811610063578063c2a69a9814610285578063d4b83992146102ac578063ea3d508a146102eb578063ef060d4f1461032b575f80fd5b8063a9f31af5146101fe578063ba8bdb0314610225578063bf560ad81461025e575f80fd5b806361efe54d116100c357806361efe54d14610181578063679aefce146101a857806392be0620146101b05780639cc5661d146101d7575f80fd5b8063232a6b9d146100e957806333307567146101255780634d8aefa21461015a575b5f80fd5b6101107f000000000000000000000000000000000000000000000000000000000000000081565b60405190151581526020015b60405180910390f35b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b60405190815260200161011c565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c610352565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61024c7f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff909116815260200161011c565b61024c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b6102d37f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b03909116815260200161011c565b6103127f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160e01b0319909116815260200161011c565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b5f8061035c6104c3565b90507f000000000000000000000000000000000000000000000000000000000000000060ff167f000000000000000000000000000000000000000000000000000000000000000060ff161115610411576103f67f00000000000000000000000000000000000000000000000000000000000000007f0000000000000000000000000000000000000000000000000000000000000000610815565b61040190600a61090e565b61040b908261091c565b91505090565b7f000000000000000000000000000000000000000000000000000000000000000060ff167f000000000000000000000000000000000000000000000000000000000000000060ff1610156104be576104a97f00000000000000000000000000000000000000000000000000000000000000007f0000000000000000000000000000000000000000000000000000000000000000610815565b6104b490600a61090e565b61040b908261093b565b919050565b604080517f000000000000000000000000000000000000000000000000000000000000000060248201527f000000000000000000000000000000000000000000000000000000000000000060448201527f000000000000000000000000000000000000000000000000000000000000000060648201527f000000000000000000000000000000000000000000000000000000000000000060848201527f000000000000000000000000000000000000000000000000000000000000000060a48201527f000000000000000000000000000000000000000000000000000000000000000060c48201527f000000000000000000000000000000000000000000000000000000000000000060e48201527f000000000000000000000000000000000000000000000000000000000000000061010480830191909152825180830390910181526101249091019091526020810180516001600160e01b03167f00000000000000000000000000000000000000000000000000000000000000006001600160e01b0319161790525f90816106826001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001683610704565b90507f0000000000000000000000000000000000000000000000000000000000000000156106e9575f818060200190518101906106bf9190610952565b90505f8112156106e257604051630c67ca6960e31b815260040160405180910390fd5b9392505050565b808060200190518101906106fd9190610952565b9250505090565b60605f80846001600160a01b0316846040516107209190610969565b5f60405180830381855afa9150503d805f8114610758576040519150601f19603f3d011682016040523d82523d5f602084013e61075d565b606091505b509150915061076d858383610778565b925050505b92915050565b60608261078d57610788826107d8565b6106e2565b81511580156107a457506001600160a01b0384163b155b156107d157604051639996b31560e01b81526001600160a01b038516600482015260240160405180910390fd5b5092915050565b8051156107e85780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b634e487b7160e01b5f52601160045260245ffd5b60ff828116828216039081111561077257610772610801565b600181815b8085111561086857815f190482111561084e5761084e610801565b8085161561085b57918102915b93841c9390800290610833565b509250929050565b5f8261087e57506001610772565b8161088a57505f610772565b81600181146108a057600281146108aa576108c6565b6001915050610772565b60ff8411156108bb576108bb610801565b50506001821b610772565b5060208310610133831016604e8410600b84101617156108e9575081810a610772565b6108f3838361082e565b805f190482111561090657610906610801565b029392505050565b5f6106e260ff841683610870565b5f8261093657634e487b7160e01b5f52601260045260245ffd5b500490565b808202811582820484141761077257610772610801565b5f60208284031215610962575f80fd5b5051919050565b5f82515f5b81811015610988576020818601810151858301520161096e565b505f92019182525091905056fea26469706673582212204a778e2da5a6e604a30cb2bdec0daea6b7a605b31d6c49722d48cbf42d55329764736f6c634300081500330000000000000000000000003eae75c0a2f9b1038c7c9993c1da36281e83881150d25bcd0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000012
Deployed Bytecode
0x608060405234801561000f575f80fd5b50600436106100e5575f3560e01c8063a9f31af511610088578063c2a69a9811610063578063c2a69a9814610285578063d4b83992146102ac578063ea3d508a146102eb578063ef060d4f1461032b575f80fd5b8063a9f31af5146101fe578063ba8bdb0314610225578063bf560ad81461025e575f80fd5b806361efe54d116100c357806361efe54d14610181578063679aefce146101a857806392be0620146101b05780639cc5661d146101d7575f80fd5b8063232a6b9d146100e957806333307567146101255780634d8aefa21461015a575b5f80fd5b6101107f000000000000000000000000000000000000000000000000000000000000000181565b60405190151581526020015b60405180910390f35b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b60405190815260200161011c565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c610352565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b61024c7f000000000000000000000000000000000000000000000000000000000000000881565b60405160ff909116815260200161011c565b61024c7f000000000000000000000000000000000000000000000000000000000000001281565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b6102d37f0000000000000000000000003eae75c0a2f9b1038c7c9993c1da36281e83881181565b6040516001600160a01b03909116815260200161011c565b6103127f50d25bcd0000000000000000000000000000000000000000000000000000000081565b6040516001600160e01b0319909116815260200161011c565b61014c7f000000000000000000000000000000000000000000000000000000000000000081565b5f8061035c6104c3565b90507f000000000000000000000000000000000000000000000000000000000000001260ff167f000000000000000000000000000000000000000000000000000000000000000860ff161115610411576103f67f00000000000000000000000000000000000000000000000000000000000000127f0000000000000000000000000000000000000000000000000000000000000008610815565b61040190600a61090e565b61040b908261091c565b91505090565b7f000000000000000000000000000000000000000000000000000000000000001260ff167f000000000000000000000000000000000000000000000000000000000000000860ff1610156104be576104a97f00000000000000000000000000000000000000000000000000000000000000087f0000000000000000000000000000000000000000000000000000000000000012610815565b6104b490600a61090e565b61040b908261093b565b919050565b604080517f000000000000000000000000000000000000000000000000000000000000000060248201527f000000000000000000000000000000000000000000000000000000000000000060448201527f000000000000000000000000000000000000000000000000000000000000000060648201527f000000000000000000000000000000000000000000000000000000000000000060848201527f000000000000000000000000000000000000000000000000000000000000000060a48201527f000000000000000000000000000000000000000000000000000000000000000060c48201527f000000000000000000000000000000000000000000000000000000000000000060e48201527f000000000000000000000000000000000000000000000000000000000000000061010480830191909152825180830390910181526101249091019091526020810180516001600160e01b03167f50d25bcd000000000000000000000000000000000000000000000000000000006001600160e01b0319161790525f90816106826001600160a01b037f0000000000000000000000003eae75c0a2f9b1038c7c9993c1da36281e8388111683610704565b90507f0000000000000000000000000000000000000000000000000000000000000001156106e9575f818060200190518101906106bf9190610952565b90505f8112156106e257604051630c67ca6960e31b815260040160405180910390fd5b9392505050565b808060200190518101906106fd9190610952565b9250505090565b60605f80846001600160a01b0316846040516107209190610969565b5f60405180830381855afa9150503d805f8114610758576040519150601f19603f3d011682016040523d82523d5f602084013e61075d565b606091505b509150915061076d858383610778565b925050505b92915050565b60608261078d57610788826107d8565b6106e2565b81511580156107a457506001600160a01b0384163b155b156107d157604051639996b31560e01b81526001600160a01b038516600482015260240160405180910390fd5b5092915050565b8051156107e85780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b634e487b7160e01b5f52601160045260245ffd5b60ff828116828216039081111561077257610772610801565b600181815b8085111561086857815f190482111561084e5761084e610801565b8085161561085b57918102915b93841c9390800290610833565b509250929050565b5f8261087e57506001610772565b8161088a57505f610772565b81600181146108a057600281146108aa576108c6565b6001915050610772565b60ff8411156108bb576108bb610801565b50506001821b610772565b5060208310610133831016604e8410600b84101617156108e9575081810a610772565b6108f3838361082e565b805f190482111561090657610906610801565b029392505050565b5f6106e260ff841683610870565b5f8261093657634e487b7160e01b5f52601260045260245ffd5b500490565b808202811582820484141761077257610772610801565b5f60208284031215610962575f80fd5b5051919050565b5f82515f5b81811015610988576020818601810151858301520161096e565b505f92019182525091905056fea26469706673582212204a778e2da5a6e604a30cb2bdec0daea6b7a605b31d6c49722d48cbf42d55329764736f6c63430008150033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000003eae75c0a2f9b1038c7c9993c1da36281e83881150d25bcd0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000012
-----Decoded View---------------
Arg [0] : _args (tuple):
Arg [1] : target (address): 0x3Eae75C0a2f9b1038C7c9993C1Da36281E838811
Arg [2] : selector (bytes4): 0x50d25bcd
Arg [3] : staticArgument0 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [4] : staticArgument1 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [5] : staticArgument2 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [6] : staticArgument3 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [7] : staticArgument4 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [8] : staticArgument5 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [9] : staticArgument6 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [10] : staticArgument7 (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [11] : signed (bool): True
Arg [12] : inputDecimals (uint8): 8
Arg [13] : outputDecimals (uint8): 18
-----Encoded View---------------
13 Constructor Arguments found :
Arg [0] : 0000000000000000000000003eae75c0a2f9b1038c7c9993c1da36281e838811
Arg [1] : 50d25bcd00000000000000000000000000000000000000000000000000000000
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [8] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [10] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [11] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000012
Deployed Bytecode Sourcemap
137:1952:2:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;884:28:1;;;;;;;;179:14:4;;172:22;154:41;;142:2;127:18;884:28:1;;;;;;;;1221:40;;;;;;;;352:25:4;;;340:2;325:18;1221:40:1;206:177:4;1083:40:1;;;;;1037;;;;;1699:388:2;;;:::i;1129:40:1:-;;;;;991;;;;;1313;;;;;949:36:2;;;;;;;;742:4:4;730:17;;;712:36;;700:2;685:18;949:36:2;570:184:4;991:37:2;;;;;1175:40:1;;;;;559:31;;;;;;;;-1:-1:-1;;;;;923:32:4;;;905:51;;893:2;878:18;559:31:1;759:203:4;664:32:1;;;;;;;;-1:-1:-1;;;;;;1129:33:4;;;1111:52;;1099:2;1084:18;664:32:1;967:202:4;1267:40:1;;;;;1699:388:2;1748:7;1767:12;1782:15;:13;:15::i;:::-;1767:30;;1827:14;1811:30;;:13;:30;;;1807:274;;;1878:30;1894:14;1878:13;:30;:::i;:::-;1871:38;;:2;:38;:::i;:::-;1864:45;;:4;:45;:::i;:::-;1857:52;;;1699:388;:::o;1807:274::-;1946:14;1930:30;;:13;:30;;;1926:155;;;1997:30;2014:13;1997:14;:30;:::i;:::-;1990:38;;:2;:38;:::i;:::-;1983:45;;:4;:45;:::i;1926:155::-;2066:4;1699:388;-1:-1:-1;1699:388:2:o;2643:824:1:-;2734:286;;;2792:15;2734:286;;;3583:25:4;2821:15:1;3624:18:4;;;3617:34;2850:15:1;3667:18:4;;;3660:34;2879:15:1;3710:18:4;;;3703:34;2908:15:1;3753:19:4;;;3746:35;2937:15:1;3797:19:4;;;3790:35;2966:15:1;3841:19:4;;;3834:35;2995:15:1;3885:19:4;;;;3878:35;;;;2734:286:1;;;;;;;;;;3555:19:4;;;;2734:286:1;;;;;;;;-1:-1:-1;;;;;2734:286:1;2770:8;-1:-1:-1;;;;;;2734:286:1;;;;-1:-1:-1;;;3052:35:1;-1:-1:-1;;;;;3052:6:1;:25;2734:286;3052:25;:35::i;:::-;3030:57;;3102:6;3098:363;;;3219:10;3243:6;3232:28;;;;;;;;;;;;:::i;:::-;3219:41;;3285:1;3279:3;:7;3275:62;;;3295:42;;-1:-1:-1;;;3295:42:1;;;;;;;;;;;3275:62;3368:3;2643:824;-1:-1:-1;;;2643:824:1:o;3098:363::-;3432:6;3421:29;;;;;;;;;;;;:::i;:::-;3414:36;;;;2643:824;:::o;3711:254:0:-;3797:12;3822;3836:23;3863:6;-1:-1:-1;;;;;3863:17:0;3881:4;3863:23;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3821:65;;;;3903:55;3930:6;3938:7;3947:10;3903:26;:55::i;:::-;3896:62;;;;3711:254;;;;;:::o;4625:582::-;4769:12;4798:7;4793:408;;4821:19;4829:10;4821:7;:19::i;:::-;4793:408;;;5045:17;;:22;:49;;;;-1:-1:-1;;;;;;5071:18:0;;;:23;5045:49;5041:119;;;5121:24;;-1:-1:-1;;;5121:24:0;;-1:-1:-1;;;;;923:32:4;;5121:24:0;;;905:51:4;878:18;;5121:24:0;;;;;;;5041:119;-1:-1:-1;5180:10:0;4625:582;-1:-1:-1;;4625:582:0:o;5743:516::-;5874:17;;:21;5870:383;;6102:10;6096:17;6158:15;6145:10;6141:2;6137:19;6130:44;5870:383;6225:17;;-1:-1:-1;;;6225:17:0;;;;;;;;;;;1174:127:4;1235:10;1230:3;1226:20;1223:1;1216:31;1266:4;1263:1;1256:15;1290:4;1287:1;1280:15;1306:151;1396:4;1389:12;;;1375;;;1371:31;;1414:14;;1411:40;;;1431:18;;:::i;1462:422::-;1551:1;1594:5;1551:1;1608:270;1629:7;1619:8;1616:21;1608:270;;;1688:4;1684:1;1680:6;1676:17;1670:4;1667:27;1664:53;;;1697:18;;:::i;:::-;1747:7;1737:8;1733:22;1730:55;;;1767:16;;;;1730:55;1846:22;;;;1806:15;;;;1608:270;;;1612:3;1462:422;;;;;:::o;1889:806::-;1938:5;1968:8;1958:80;;-1:-1:-1;2009:1:4;2023:5;;1958:80;2057:4;2047:76;;-1:-1:-1;2094:1:4;2108:5;;2047:76;2139:4;2157:1;2152:59;;;;2225:1;2220:130;;;;2132:218;;2152:59;2182:1;2173:10;;2196:5;;;2220:130;2257:3;2247:8;2244:17;2241:43;;;2264:18;;:::i;:::-;-1:-1:-1;;2320:1:4;2306:16;;2335:5;;2132:218;;2434:2;2424:8;2421:16;2415:3;2409:4;2406:13;2402:36;2396:2;2386:8;2383:16;2378:2;2372:4;2369:12;2365:35;2362:77;2359:159;;;-1:-1:-1;2471:19:4;;;2503:5;;2359:159;2550:34;2575:8;2569:4;2550:34;:::i;:::-;2620:6;2616:1;2612:6;2608:19;2599:7;2596:32;2593:58;;;2631:18;;:::i;:::-;2669:20;;1889:806;-1:-1:-1;;;1889:806:4:o;2700:140::-;2758:5;2787:47;2828:4;2818:8;2814:19;2808:4;2787:47;:::i;2845:217::-;2885:1;2911;2901:132;;2955:10;2950:3;2946:20;2943:1;2936:31;2990:4;2987:1;2980:15;3018:4;3015:1;3008:15;2901:132;-1:-1:-1;3047:9:4;;2845:217::o;3067:168::-;3140:9;;;3171;;3188:15;;;3182:22;;3168:37;3158:71;;3209:18;;:::i;3924:183::-;3993:6;4046:2;4034:9;4025:7;4021:23;4017:32;4014:52;;;4062:1;4059;4052:12;4014:52;-1:-1:-1;4085:16:4;;3924:183;-1:-1:-1;3924:183:4:o;4301:412::-;4430:3;4468:6;4462:13;4493:1;4503:129;4517:6;4514:1;4511:13;4503:129;;;4615:4;4599:14;;;4595:25;;4589:32;4576:11;;;4569:53;4532:12;4503:129;;;-1:-1:-1;4687:1:4;4651:16;;4676:13;;;-1:-1:-1;4651:16:4;4301:412;-1:-1:-1;4301:412:4:o
Swarm Source
ipfs://4a778e2da5a6e604a30cb2bdec0daea6b7a605b31d6c49722d48cbf42d553297
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.