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 | Method | Block |
From
|
|
To
|
||
|---|---|---|---|---|---|---|---|
| 0x60806040 | 16946644 | 1081 days ago | Contract Creation | 0 ETH |
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions
Loading...
Loading
Contract Name:
XLARSCValve
Compiler Version
v0.8.9+commit.e5eed63a
Optimization Enabled:
Yes with 10000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol";
import "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol";
import "../interfaces/IFeeFactory.sol";
import "../interfaces/IRecursiveRSC.sol";
contract XLARSCValve is OwnableUpgradeable {
using SafeERC20 for IERC20;
mapping(address => bool) public distributors;
address public controller;
bool public isImmutableRecipients;
bool public isAutoNativeCurrencyDistribution;
uint256 public minAutoDistributionAmount;
uint256 public platformFee;
IFeeFactory public factory;
address payable [] public recipients;
mapping(address => uint256) public recipientsPercentage;
event SetRecipients(address payable [] recipients, uint256[] percentages);
event DistributeToken(address token, uint256 amount);
event DistributorChanged(address distributor, bool isDistributor);
event ControllerChanged(address oldController, address newController);
event MinAutoDistributionAmountChanged(uint256 oldAmount, uint256 newAmount);
event AutoNativeCurrencyDistributionChanged(bool oldValue, bool newValue);
event ImmutableRecipients(bool isImmutableRecipients);
// Throw when if sender is not distributor
error OnlyDistributorError();
// Throw when sender is not controller
error OnlyControllerError();
// Throw when transaction fails
error TransferFailedError();
// Throw when submitted recipient with address(0)
error NullAddressRecipientError();
// Throw if recipient is already in contract
error RecipientAlreadyAddedError();
// Throw when arrays are submit without same length
error InconsistentDataLengthError();
// Throw when sum of percentage is not 100%
error InvalidPercentageError();
// Throw when distributor address is same as submit one
error DistributorAlreadyConfiguredError();
// Throw when distributor address is same as submit one
error ControllerAlreadyConfiguredError();
// Throw when change is triggered for immutable recipients
error ImmutableRecipientsError();
// Throw when renounce ownership is called
error RenounceOwnershipForbidden();
/**
* @dev Checks whether sender is distributor
*/
modifier onlyDistributor {
if (distributors[msg.sender] == false) {
revert OnlyDistributorError();
}
_;
}
/**
* @dev Checks whether sender is controller
*/
modifier onlyController {
if (msg.sender != controller) {
revert OnlyControllerError();
}
_;
}
/**
* @dev Constructor function, can be called only once
* @param _owner Owner of the contract
* @param _controller address which control setting / removing recipients
* @param _distributors list of addresses which can distribute ERC20 tokens or native currency
* @param _isImmutableRecipients flag indicating whether recipients could be changed
* @param _isAutoNativeCurrencyDistribution flag indicating whether native currency will be automatically distributed or manually
* @param _minAutoDistributionAmount Minimum native currency amount to trigger auto native currency distribution
* @param _platformFee Percentage defining fee for distribution services
* @param _factoryAddress Address of the factory used for creating this RSC
* @param _initialRecipients Initial recipient addresses
* @param _percentages initial percentages for recipients
*/
function initialize(
address _owner,
address _controller,
address[] memory _distributors,
bool _isImmutableRecipients,
bool _isAutoNativeCurrencyDistribution,
uint256 _minAutoDistributionAmount,
uint256 _platformFee,
address _factoryAddress,
address payable [] memory _initialRecipients,
uint256[] memory _percentages
) public initializer {
uint256 distributorsLength = _distributors.length;
for (uint256 i = 0; i < distributorsLength;) {
distributors[_distributors[i]] = true;
unchecked{i++;}
}
controller = _controller;
isAutoNativeCurrencyDistribution = _isAutoNativeCurrencyDistribution;
minAutoDistributionAmount = _minAutoDistributionAmount;
factory = IFeeFactory(_factoryAddress);
platformFee = _platformFee;
_setRecipients(_initialRecipients, _percentages);
isImmutableRecipients = _isImmutableRecipients;
_transferOwnership(_owner);
}
fallback() external payable {
// Check whether automatic native currency distribution is enabled
// and that contractBalance is more than automatic distribution threshold
uint256 contractBalance = address(this).balance;
if (isAutoNativeCurrencyDistribution && contractBalance >= minAutoDistributionAmount) {
_redistributeNativeCurrency(contractBalance);
}
}
receive() external payable {
// Check whether automatic native currency distribution is enabled
// and that contractBalance is more than automatic distribution threshold
uint256 contractBalance = address(this).balance;
if (isAutoNativeCurrencyDistribution && contractBalance >= minAutoDistributionAmount) {
_redistributeNativeCurrency(contractBalance);
}
}
/**
* @notice External function to return number of recipients
*/
function numberOfRecipients() external view returns(uint256) {
return recipients.length;
}
/**
* @notice Internal function to redistribute native currency based on percentages assign to the recipients
* @param _valueToDistribute native currency amount to be distributed
*/
function _redistributeNativeCurrency(uint256 _valueToDistribute) internal {
uint256 fee = ((_valueToDistribute * platformFee) / 10000000);
_valueToDistribute -= fee;
if(_valueToDistribute < 10000000) {
return;
}
address payable platformWallet = factory.platformWallet();
if(fee != 0 && platformWallet != address(0)) {
(bool success,) = platformWallet.call{value: fee}("");
if (success == false) {
revert TransferFailedError();
}
}
uint256 recipientsLength = recipients.length;
for (uint256 i = 0; i < recipientsLength;) {
address payable recipient = recipients[i];
uint256 percentage = recipientsPercentage[recipient];
uint256 amountToReceive = ((_valueToDistribute * percentage) / 10000000);
(bool success,) = payable(recipient).call{value: amountToReceive}("");
if (success == false) {
revert TransferFailedError();
}
_recursiveNativeCurrencyDistribution(recipient);
unchecked{i++;}
}
}
/**
* @notice External function to redistribute native currency based on percentages assign to the recipients
*/
function redistributeNativeCurrency() external onlyDistributor {
_redistributeNativeCurrency(address(this).balance);
}
/**
* @notice Internal function for adding recipient to revenue share
* @param _recipient Fixed amount of token user want to buy
* @param _percentage code of the affiliation partner
*/
function _addRecipient(address payable _recipient, uint256 _percentage) internal {
if (_recipient == address(0)) {
revert NullAddressRecipientError();
}
if (recipientsPercentage[_recipient] != 0) {
revert RecipientAlreadyAddedError();
}
recipients.push(_recipient);
recipientsPercentage[_recipient] = _percentage;
}
/**
* @notice Internal function for removing all recipients
*/
function _removeAll() internal {
uint256 recipientsLength = recipients.length;
if (recipientsLength == 0) {
return;
}
for (uint256 i = 0; i < recipientsLength;) {
address recipient = recipients[i];
recipientsPercentage[recipient] = 0;
unchecked{i++;}
}
delete recipients;
}
/**
* @notice Internal function for setting recipients
* @param _newRecipients Addresses to be added
* @param _percentages new percentages for recipients
*/
function _setRecipients(
address payable [] memory _newRecipients,
uint256[] memory _percentages
) internal {
if (isImmutableRecipients) {
revert ImmutableRecipientsError();
}
uint256 newRecipientsLength = _newRecipients.length;
if (newRecipientsLength != _percentages.length) {
revert InconsistentDataLengthError();
}
_removeAll();
uint256 percentageSum;
for (uint256 i = 0; i < newRecipientsLength;) {
uint256 percentage = _percentages[i];
_addRecipient(_newRecipients[i], percentage);
percentageSum += percentage;
unchecked{i++;}
}
if (percentageSum != 10000000) {
revert InvalidPercentageError();
}
emit SetRecipients(_newRecipients, _percentages);
}
/**
* @notice External function for setting recipients
* @param _newRecipients Addresses to be added
* @param _percentages new percentages for recipients
*/
function setRecipients(
address payable [] memory _newRecipients,
uint256[] memory _percentages
) public onlyController {
_setRecipients(_newRecipients, _percentages);
}
/**
* @notice External function for setting recipients and make recipients immutable
* @param _newRecipients Addresses to be added
* @param _percentages new percentages for recipients
*/
function setRecipientsExt(
address payable [] memory _newRecipients,
uint256[] memory _percentages
) public onlyController {
_setRecipients(_newRecipients, _percentages);
_setImmutableRecipients();
}
/**
* @notice External function to redistribute ERC20 token based on percentages assign to the recipients
* @param _token Address of the ERC20 token to be distribute
*/
function redistributeToken(address _token) external onlyDistributor {
IERC20 erc20Token = IERC20(_token);
uint256 contractBalance = erc20Token.balanceOf(address(this));
uint256 fee = ((contractBalance * platformFee) / 10000000);
contractBalance -= fee;
if (contractBalance < 10000000) {
// because of percentage
return;
}
uint256 recipientsLength = recipients.length;
address payable platformWallet = factory.platformWallet();
if(fee != 0 && platformWallet != address(0)) {
erc20Token.safeTransfer(platformWallet, fee);
}
for (uint256 i = 0; i < recipientsLength;) {
address payable recipient = recipients[i];
uint256 percentage = recipientsPercentage[recipient];
uint256 amountToReceive = ((contractBalance * percentage) / 10000000);
erc20Token.safeTransfer(recipient, amountToReceive);
_recursiveERC20Distribution(recipient, _token);
unchecked{i++;}
}
emit DistributeToken(_token, contractBalance);
}
/**
* @notice External function to set distributor address
* @param _distributor address of new distributor
* @param _isDistributor bool indicating whether address is / isn't distributor
*/
function setDistributor(address _distributor, bool _isDistributor) external onlyOwner {
emit DistributorChanged(_distributor, _isDistributor);
distributors[_distributor] = _isDistributor;
}
/**
* @notice External function to set controller address, if set to address(0), unable to change it
* @param _controller address of new controller
*/
function setController(address _controller) external onlyOwner {
emit ControllerChanged(controller, _controller);
controller = _controller;
}
/**
* @notice Internal function to check whether recipient should be recursively distributed
* @param _recipient Address of recipient to recursively distribute
* @param _token token to be distributed
*/
function _recursiveERC20Distribution(address _recipient, address _token) internal {
// Handle Recursive token distribution
IRecursiveRSC recursiveRecipient = IRecursiveRSC(_recipient);
// Wallets have size 0 and contracts > 0. This way we can distinguish them.
uint256 recipientSize;
assembly {recipientSize := extcodesize(_recipient)}
if (recipientSize > 0) {
// Validate this contract is distributor in child recipient
try recursiveRecipient.distributors(address(this)) returns(bool isBranchDistributor) {
if (isBranchDistributor) {
recursiveRecipient.redistributeToken(_token);
}
} catch {return;} // unable to recursively distribute
}
}
/**
* @notice Internal function to check whether recipient should be recursively distributed
* @param _recipient Address of recipient to recursively distribute
*/
function _recursiveNativeCurrencyDistribution(address _recipient) internal {
// Handle Recursive token distribution
IRecursiveRSC recursiveRecipient = IRecursiveRSC(_recipient);
// Wallets have size 0 and contracts > 0. This way we can distinguish them.
uint256 recipientSize;
assembly {recipientSize := extcodesize(_recipient)}
if (recipientSize > 0) {
// Check whether child recipient have autoNativeCurrencyDistribution set to true,
// if yes tokens will be recursively distributed automatically
try recursiveRecipient.isAutoNativeCurrencyDistribution() returns(bool childAutoNativeCurrencyDistribution) {
if (childAutoNativeCurrencyDistribution == true) {
return;
}
} catch {return;}
// Validate this contract is distributor in child recipient
try recursiveRecipient.distributors(address(this)) returns(bool isBranchDistributor) {
if (isBranchDistributor) {
recursiveRecipient.redistributeNativeCurrency();
}
} catch {return;} // unable to recursively distribute
}
}
/**
* @notice Internal function for setting immutable recipients to true
*/
function _setImmutableRecipients() internal {
emit ImmutableRecipients(true);
isImmutableRecipients = true;
}
/**
* @notice external function for setting immutable recipients to true
*/
function setImmutableRecipients() external onlyOwner {
if (isImmutableRecipients) {
revert ImmutableRecipientsError();
}
_setImmutableRecipients();
}
/**
* @notice external function for setting auto native currency distribution
* @param _isAutoNativeCurrencyDistribution Bool switching whether auto native currency distribution is enabled
*/
function setAutoNativeCurrencyDistribution(bool _isAutoNativeCurrencyDistribution) external onlyOwner {
emit AutoNativeCurrencyDistributionChanged(isAutoNativeCurrencyDistribution, _isAutoNativeCurrencyDistribution);
isAutoNativeCurrencyDistribution = _isAutoNativeCurrencyDistribution;
}
/**
* @notice external function for setting auto native currency distribution
* @param _minAutoDistributionAmount New minimum distribution amount
*/
function setMinAutoDistributionAmount(uint256 _minAutoDistributionAmount) external onlyOwner {
emit MinAutoDistributionAmountChanged(minAutoDistributionAmount, _minAutoDistributionAmount);
minAutoDistributionAmount = _minAutoDistributionAmount;
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions anymore. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will is forbidden for RSC contract
*/
function renounceOwnership() public view override onlyOwner {
revert RenounceOwnershipForbidden();
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)
pragma solidity ^0.8.0;
import "../utils/ContextUpgradeable.sol";
import "../proxy/utils/Initializable.sol";
/**
* @dev Contract module which provides a basic access control mechanism, where
* there is an account (an owner) that can be granted exclusive access to
* specific functions.
*
* By default, the owner account will be the one that deploys the contract. This
* can later be changed with {transferOwnership}.
*
* This module is used through inheritance. It will make available the modifier
* `onlyOwner`, which can be applied to your functions to restrict their use to
* the owner.
*/
abstract contract OwnableUpgradeable is Initializable, ContextUpgradeable {
address private _owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/
function __Ownable_init() internal onlyInitializing {
__Ownable_init_unchained();
}
function __Ownable_init_unchained() internal onlyInitializing {
_transferOwnership(_msgSender());
}
/**
* @dev Throws if called by any account other than the owner.
*/
modifier onlyOwner() {
_checkOwner();
_;
}
/**
* @dev Returns the address of the current owner.
*/
function owner() public view virtual returns (address) {
return _owner;
}
/**
* @dev Throws if the sender is not the owner.
*/
function _checkOwner() internal view virtual {
require(owner() == _msgSender(), "Ownable: caller is not the owner");
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions anymore. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby removing any functionality that is only available to the owner.
*/
function renounceOwnership() public virtual onlyOwner {
_transferOwnership(address(0));
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Can only be called by the current owner.
*/
function transferOwnership(address newOwner) public virtual onlyOwner {
require(newOwner != address(0), "Ownable: new owner is the zero address");
_transferOwnership(newOwner);
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Internal function without access restriction.
*/
function _transferOwnership(address newOwner) internal virtual {
address oldOwner = _owner;
_owner = newOwner;
emit OwnershipTransferred(oldOwner, newOwner);
}
/**
* @dev This empty reserved space is put in place to allow future versions to add new
* variables without shifting down storage in the inheritance chain.
* See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps
*/
uint256[49] private __gap;
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (proxy/utils/Initializable.sol)
pragma solidity ^0.8.2;
import "../../utils/AddressUpgradeable.sol";
/**
* @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
* behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an
* external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
* function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
*
* The initialization functions use a version number. Once a version number is used, it is consumed and cannot be
* reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in
* case an upgrade adds a module that needs to be initialized.
*
* For example:
*
* [.hljs-theme-light.nopadding]
* ```
* contract MyToken is ERC20Upgradeable {
* function initialize() initializer public {
* __ERC20_init("MyToken", "MTK");
* }
* }
* contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {
* function initializeV2() reinitializer(2) public {
* __ERC20Permit_init("MyToken");
* }
* }
* ```
*
* TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
* possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
*
* CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
* that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
*
* [CAUTION]
* ====
* Avoid leaving a contract uninitialized.
*
* An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation
* contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke
* the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:
*
* [.hljs-theme-light.nopadding]
* ```
* /// @custom:oz-upgrades-unsafe-allow constructor
* constructor() {
* _disableInitializers();
* }
* ```
* ====
*/
abstract contract Initializable {
/**
* @dev Indicates that the contract has been initialized.
* @custom:oz-retyped-from bool
*/
uint8 private _initialized;
/**
* @dev Indicates that the contract is in the process of being initialized.
*/
bool private _initializing;
/**
* @dev Triggered when the contract has been initialized or reinitialized.
*/
event Initialized(uint8 version);
/**
* @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,
* `onlyInitializing` functions can be used to initialize parent contracts. Equivalent to `reinitializer(1)`.
*/
modifier initializer() {
bool isTopLevelCall = !_initializing;
require(
(isTopLevelCall && _initialized < 1) || (!AddressUpgradeable.isContract(address(this)) && _initialized == 1),
"Initializable: contract is already initialized"
);
_initialized = 1;
if (isTopLevelCall) {
_initializing = true;
}
_;
if (isTopLevelCall) {
_initializing = false;
emit Initialized(1);
}
}
/**
* @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the
* contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be
* used to initialize parent contracts.
*
* `initializer` is equivalent to `reinitializer(1)`, so a reinitializer may be used after the original
* initialization step. This is essential to configure modules that are added through upgrades and that require
* initialization.
*
* Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in
* a contract, executing them in the right order is up to the developer or operator.
*/
modifier reinitializer(uint8 version) {
require(!_initializing && _initialized < version, "Initializable: contract is already initialized");
_initialized = version;
_initializing = true;
_;
_initializing = false;
emit Initialized(version);
}
/**
* @dev Modifier to protect an initialization function so that it can only be invoked by functions with the
* {initializer} and {reinitializer} modifiers, directly or indirectly.
*/
modifier onlyInitializing() {
require(_initializing, "Initializable: contract is not initializing");
_;
}
/**
* @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.
* Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized
* to any version. It is recommended to use this to lock implementation contracts that are designed to be called
* through proxies.
*/
function _disableInitializers() internal virtual {
require(!_initializing, "Initializable: contract is initializing");
if (_initialized < type(uint8).max) {
_initialized = type(uint8).max;
emit Initialized(type(uint8).max);
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)
pragma solidity ^0.8.1;
/**
* @dev Collection of functions related to the address type
*/
library AddressUpgradeable {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will return false for the following
* types of addresses:
*
* - an externally-owned account
* - a contract in construction
* - an address where a contract will be created
* - an address where a contract lived, but was destroyed
* ====
*
* [IMPORTANT]
* ====
* You shouldn't rely on `isContract` to protect against flash loan attacks!
*
* Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
* like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
* constructor.
* ====
*/
function isContract(address account) internal view returns (bool) {
// This method relies on extcodesize/address.code.length, which returns 0
// for contracts in construction, since the code is only stored at the end
// of the constructor execution.
return account.code.length > 0;
}
/**
* @dev Replacement for Solidity's `transfer`: sends `amount` wei to
* `recipient`, forwarding all available gas and reverting on errors.
*
* https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
* of certain opcodes, possibly making contracts go over the 2300 gas limit
* imposed by `transfer`, making them unable to receive funds via
* `transfer`. {sendValue} removes this limitation.
*
* https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
*
* IMPORTANT: because control is transferred to `recipient`, care must be
* taken to not create reentrancy vulnerabilities. Consider using
* {ReentrancyGuard} or the
* https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
require(address(this).balance >= amount, "Address: insufficient balance");
(bool success, ) = recipient.call{value: amount}("");
require(success, "Address: unable to send value, recipient may have reverted");
}
/**
* @dev Performs a Solidity function call using a low level `call`. A
* plain `call` is an unsafe replacement for a function call: use this
* function instead.
*
* If `target` reverts with a revert reason, it is bubbled up by this
* function (like regular Solidity function calls).
*
* Returns the raw returned data. To convert to the expected return value,
* use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
*
* Requirements:
*
* - `target` must be a contract.
* - calling `target` with `data` must not revert.
*
* _Available since v3.1._
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCall(target, data, "Address: low-level call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
* `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but also transferring `value` wei to `target`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value
) internal returns (bytes memory) {
return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
}
/**
* @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
* with `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value,
string memory errorMessage
) internal returns (bytes memory) {
require(address(this).balance >= value, "Address: insufficient balance for call");
require(isContract(target), "Address: call to non-contract");
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
return functionStaticCall(target, data, "Address: low-level static call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(
address target,
bytes memory data,
string memory errorMessage
) internal view returns (bytes memory) {
require(isContract(target), "Address: static call to non-contract");
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
* revert reason using the provided one.
*
* _Available since v4.3._
*/
function verifyCallResult(
bool success,
bytes memory returndata,
string memory errorMessage
) internal pure returns (bytes memory) {
if (success) {
return returndata;
} else {
// Look for revert reason and bubble it up if present
if (returndata.length > 0) {
// The easiest way to bubble the revert reason is using memory via assembly
/// @solidity memory-safe-assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)
pragma solidity ^0.8.0;
import "../proxy/utils/Initializable.sol";
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract ContextUpgradeable is Initializable {
function __Context_init() internal onlyInitializing {
}
function __Context_init_unchained() internal onlyInitializing {
}
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
/**
* @dev This empty reserved space is put in place to allow future versions to add new
* variables without shifting down storage in the inheritance chain.
* See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps
*/
uint256[50] private __gap;
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)
pragma solidity ^0.8.0;
/**
* @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.
*/
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].
*/
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 v4.6.0) (token/ERC20/IERC20.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC20 standard as defined in the EIP.
*/
interface IERC20 {
/**
* @dev Emitted when `value` tokens are moved from one account (`from`) to
* another (`to`).
*
* Note that `value` may be zero.
*/
event Transfer(address indexed from, address indexed to, uint256 value);
/**
* @dev Emitted when the allowance of a `spender` for an `owner` is set by
* a call to {approve}. `value` is the new allowance.
*/
event Approval(address indexed owner, address indexed spender, uint256 value);
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `to`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address to, uint256 amount) external returns (bool);
/**
* @dev Returns the remaining number of tokens that `spender` will be
* allowed to spend on behalf of `owner` through {transferFrom}. This is
* zero by default.
*
* This value changes when {approve} or {transferFrom} are called.
*/
function allowance(address owner, address spender) external view returns (uint256);
/**
* @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* IMPORTANT: Beware that changing an allowance with this method brings the risk
* that someone may use both the old and the new allowance by unfortunate
* transaction ordering. One possible solution to mitigate this race
* condition is to first reduce the spender's allowance to 0 and set the
* desired value afterwards:
* https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
*
* Emits an {Approval} event.
*/
function approve(address spender, uint256 amount) external returns (bool);
/**
* @dev Moves `amount` tokens from `from` to `to` using the
* allowance mechanism. `amount` is then deducted from the caller's
* allowance.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transferFrom(
address from,
address to,
uint256 amount
) external returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC20/utils/SafeERC20.sol)
pragma solidity ^0.8.0;
import "../IERC20.sol";
import "../extensions/draft-IERC20Permit.sol";
import "../../../utils/Address.sol";
/**
* @title SafeERC20
* @dev Wrappers around ERC20 operations that throw on failure (when the token
* contract returns false). Tokens that return no value (and instead revert or
* throw on failure) are also supported, non-reverting calls are assumed to be
* successful.
* To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
* which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
*/
library SafeERC20 {
using Address for address;
function safeTransfer(
IERC20 token,
address to,
uint256 value
) internal {
_callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
}
function safeTransferFrom(
IERC20 token,
address from,
address to,
uint256 value
) internal {
_callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
}
/**
* @dev Deprecated. This function has issues similar to the ones found in
* {IERC20-approve}, and its usage is discouraged.
*
* Whenever possible, use {safeIncreaseAllowance} and
* {safeDecreaseAllowance} instead.
*/
function safeApprove(
IERC20 token,
address spender,
uint256 value
) internal {
// safeApprove should only be called when setting an initial allowance,
// or when resetting it to zero. To increase and decrease it, use
// 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
require(
(value == 0) || (token.allowance(address(this), spender) == 0),
"SafeERC20: approve from non-zero to non-zero allowance"
);
_callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
}
function safeIncreaseAllowance(
IERC20 token,
address spender,
uint256 value
) internal {
uint256 newAllowance = token.allowance(address(this), spender) + value;
_callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
}
function safeDecreaseAllowance(
IERC20 token,
address spender,
uint256 value
) internal {
unchecked {
uint256 oldAllowance = token.allowance(address(this), spender);
require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
uint256 newAllowance = oldAllowance - value;
_callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
}
}
function safePermit(
IERC20Permit token,
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) internal {
uint256 nonceBefore = token.nonces(owner);
token.permit(owner, spender, value, deadline, v, r, s);
uint256 nonceAfter = token.nonces(owner);
require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed");
}
/**
* @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
* on the return value: the return value is optional (but if data is returned, it must not be false).
* @param token The token targeted by the call.
* @param data The call data (encoded using abi.encode or one of its variants).
*/
function _callOptionalReturn(IERC20 token, bytes memory data) private {
// We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
// we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
// the target address contains contract code and also asserts for success in the low-level call.
bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
if (returndata.length > 0) {
// Return data is optional
require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)
pragma solidity ^0.8.1;
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will return false for the following
* types of addresses:
*
* - an externally-owned account
* - a contract in construction
* - an address where a contract will be created
* - an address where a contract lived, but was destroyed
* ====
*
* [IMPORTANT]
* ====
* You shouldn't rely on `isContract` to protect against flash loan attacks!
*
* Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
* like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
* constructor.
* ====
*/
function isContract(address account) internal view returns (bool) {
// This method relies on extcodesize/address.code.length, which returns 0
// for contracts in construction, since the code is only stored at the end
// of the constructor execution.
return account.code.length > 0;
}
/**
* @dev Replacement for Solidity's `transfer`: sends `amount` wei to
* `recipient`, forwarding all available gas and reverting on errors.
*
* https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
* of certain opcodes, possibly making contracts go over the 2300 gas limit
* imposed by `transfer`, making them unable to receive funds via
* `transfer`. {sendValue} removes this limitation.
*
* https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
*
* IMPORTANT: because control is transferred to `recipient`, care must be
* taken to not create reentrancy vulnerabilities. Consider using
* {ReentrancyGuard} or the
* https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
require(address(this).balance >= amount, "Address: insufficient balance");
(bool success, ) = recipient.call{value: amount}("");
require(success, "Address: unable to send value, recipient may have reverted");
}
/**
* @dev Performs a Solidity function call using a low level `call`. A
* plain `call` is an unsafe replacement for a function call: use this
* function instead.
*
* If `target` reverts with a revert reason, it is bubbled up by this
* function (like regular Solidity function calls).
*
* Returns the raw returned data. To convert to the expected return value,
* use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
*
* Requirements:
*
* - `target` must be a contract.
* - calling `target` with `data` must not revert.
*
* _Available since v3.1._
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCall(target, data, "Address: low-level call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
* `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but also transferring `value` wei to `target`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value
) internal returns (bytes memory) {
return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
}
/**
* @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
* with `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value,
string memory errorMessage
) internal returns (bytes memory) {
require(address(this).balance >= value, "Address: insufficient balance for call");
require(isContract(target), "Address: call to non-contract");
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
return functionStaticCall(target, data, "Address: low-level static call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(
address target,
bytes memory data,
string memory errorMessage
) internal view returns (bytes memory) {
require(isContract(target), "Address: static call to non-contract");
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
return functionDelegateCall(target, data, "Address: low-level delegate call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
require(isContract(target), "Address: delegate call to non-contract");
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
* revert reason using the provided one.
*
* _Available since v4.3._
*/
function verifyCallResult(
bool success,
bytes memory returndata,
string memory errorMessage
) internal pure returns (bytes memory) {
if (success) {
return returndata;
} else {
// Look for revert reason and bubble it up if present
if (returndata.length > 0) {
// The easiest way to bubble the revert reason is using memory via assembly
/// @solidity memory-safe-assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;
interface IFeeFactory {
function platformWallet() external returns(address payable);
}// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;
interface IRecursiveRSC {
function distributors(address _distributor) external returns(bool);
function redistributeToken(address _token) external;
function redistributeNativeCurrency() external;
function isAutoNativeCurrencyDistribution() external returns(bool);
}{
"optimizer": {
"enabled": true,
"runs": 10000
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"name":"ControllerAlreadyConfiguredError","type":"error"},{"inputs":[],"name":"DistributorAlreadyConfiguredError","type":"error"},{"inputs":[],"name":"ImmutableRecipientsError","type":"error"},{"inputs":[],"name":"InconsistentDataLengthError","type":"error"},{"inputs":[],"name":"InvalidPercentageError","type":"error"},{"inputs":[],"name":"NullAddressRecipientError","type":"error"},{"inputs":[],"name":"OnlyControllerError","type":"error"},{"inputs":[],"name":"OnlyDistributorError","type":"error"},{"inputs":[],"name":"RecipientAlreadyAddedError","type":"error"},{"inputs":[],"name":"RenounceOwnershipForbidden","type":"error"},{"inputs":[],"name":"TransferFailedError","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"oldValue","type":"bool"},{"indexed":false,"internalType":"bool","name":"newValue","type":"bool"}],"name":"AutoNativeCurrencyDistributionChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldController","type":"address"},{"indexed":false,"internalType":"address","name":"newController","type":"address"}],"name":"ControllerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"DistributeToken","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"distributor","type":"address"},{"indexed":false,"internalType":"bool","name":"isDistributor","type":"bool"}],"name":"DistributorChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"isImmutableRecipients","type":"bool"}],"name":"ImmutableRecipients","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newAmount","type":"uint256"}],"name":"MinAutoDistributionAmountChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address payable[]","name":"recipients","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"percentages","type":"uint256[]"}],"name":"SetRecipients","type":"event"},{"stateMutability":"payable","type":"fallback"},{"inputs":[],"name":"controller","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"distributors","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"factory","outputs":[{"internalType":"contract IFeeFactory","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_controller","type":"address"},{"internalType":"address[]","name":"_distributors","type":"address[]"},{"internalType":"bool","name":"_isImmutableRecipients","type":"bool"},{"internalType":"bool","name":"_isAutoNativeCurrencyDistribution","type":"bool"},{"internalType":"uint256","name":"_minAutoDistributionAmount","type":"uint256"},{"internalType":"uint256","name":"_platformFee","type":"uint256"},{"internalType":"address","name":"_factoryAddress","type":"address"},{"internalType":"address payable[]","name":"_initialRecipients","type":"address[]"},{"internalType":"uint256[]","name":"_percentages","type":"uint256[]"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isAutoNativeCurrencyDistribution","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isImmutableRecipients","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minAutoDistributionAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"numberOfRecipients","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"platformFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"recipients","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"recipientsPercentage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"redistributeNativeCurrency","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"redistributeToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_isAutoNativeCurrencyDistribution","type":"bool"}],"name":"setAutoNativeCurrencyDistribution","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_controller","type":"address"}],"name":"setController","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_distributor","type":"address"},{"internalType":"bool","name":"_isDistributor","type":"bool"}],"name":"setDistributor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setImmutableRecipients","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minAutoDistributionAmount","type":"uint256"}],"name":"setMinAutoDistributionAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable[]","name":"_newRecipients","type":"address[]"},{"internalType":"uint256[]","name":"_percentages","type":"uint256[]"}],"name":"setRecipients","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable[]","name":"_newRecipients","type":"address[]"},{"internalType":"uint256[]","name":"_percentages","type":"uint256[]"}],"name":"setRecipientsExt","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]Contract Creation Code
608060405234801561001057600080fd5b50612581806100206000396000f3fe6080604052600436106101845760003560e01c8063ae373c1b116100d6578063eaf4598a1161007f578063f432c79f11610059578063f432c79f146104e3578063f4d3bdec14610503578063f77c479114610523576101c9565b8063eaf4598a1461047c578063ee0e01c7146104ae578063f2fde38b146104c3576101c9565b8063d1bc76a1116100b0578063d1bc76a11461041c578063d59ba0df1461043c578063e6bfdc0b1461045c576101c9565b8063ae373c1b1461039f578063c45a0155146103bf578063cc642784146103ec576101c9565b8063478f425a116101385780638d2de9e1116101125780638d2de9e1146103135780638da5cb5b1461033357806392eefe9b1461037f576101c9565b8063478f425a146102d357806350a2f6c8146102e9578063715018a6146102fe576101c9565b806326232a2e1161016957806326232a2e146102865780633d12394a1461029c5780633d39e377146102b3576101c9565b80630808e1c6146102035780631558ab2f1461024b576101c9565b366101c95760665447907501000000000000000000000000000000000000000000900460ff1680156101b857506067548110155b156101c6576101c681610550565b50005b60665447907501000000000000000000000000000000000000000000900460ff1680156101b8575060675481106101c6576101c681610550565b34801561020f57600080fd5b50606654610236907501000000000000000000000000000000000000000000900460ff1681565b60405190151581526020015b60405180910390f35b34801561025757600080fd5b50610278610266366004611efa565b606b6020526000908152604090205481565b604051908152602001610242565b34801561029257600080fd5b5061027860685481565b3480156102a857600080fd5b506102b1610824565b005b3480156102bf57600080fd5b506102b16102ce366004611f30565b610878565b3480156102df57600080fd5b5061027860675481565b3480156102f557600080fd5b506102b1610926565b34801561030a57600080fd5b506102b161098b565b34801561031f57600080fd5b506102b161032e3660046120be565b6109c5565b34801561033f57600080fd5b5060335473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610242565b34801561038b57600080fd5b506102b161039a366004611efa565b610a2c565b3480156103ab57600080fd5b506102b16103ba3660046120be565b610acf565b3480156103cb57600080fd5b5060695461035a9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156103f857600080fd5b50610236610407366004611efa565b60656020526000908152604090205460ff1681565b34801561042857600080fd5b5061035a610437366004612122565b610b2a565b34801561044857600080fd5b506102b161045736600461213b565b610b61565b34801561046857600080fd5b506102b16104773660046121d8565b610c0f565b34801561048857600080fd5b506066546102369074010000000000000000000000000000000000000000900460ff1681565b3480156104ba57600080fd5b50606a54610278565b3480156104cf57600080fd5b506102b16104de366004611efa565b610f26565b3480156104ef57600080fd5b506102b16104fe366004612122565b610fdd565b34801561050f57600080fd5b506102b161051e366004611efa565b611026565b34801561052f57600080fd5b5060665461035a9073ffffffffffffffffffffffffffffffffffffffff1681565b6000629896806068548361056491906122f8565b61056e9190612335565b905061057a8183612370565b91506298968082101561058b575050565b606954604080517ffa2af9da000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163fa2af9da91600480830192602092919082900301818787803b1580156105f757600080fd5b505af115801561060b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061062f9190612387565b90508115801590610655575073ffffffffffffffffffffffffffffffffffffffff811615155b156106f75760008173ffffffffffffffffffffffffffffffffffffffff168360405160006040518083038185875af1925050503d80600081146106b4576040519150601f19603f3d011682016040523d82523d6000602084013e6106b9565b606091505b5090915050806106f5576040517f570f1df400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505b606a5460005b8181101561081d576000606a828154811061071a5761071a6123a4565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff16808352606b9091526040822054909250906298968061075d838a6122f8565b6107679190612335565b905060008373ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146107c3576040519150601f19603f3d011682016040523d82523d6000602084013e6107c8565b606091505b509091505080610804576040517f570f1df400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61080d84611340565b5050600190920191506106fd9050565b5050505050565b3360009081526065602052604090205460ff1661086d576040517f26448fa300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61087647610550565b565b610880611526565b60665460408051750100000000000000000000000000000000000000000090920460ff161515825282151560208301527ff13ee37d031ddceccecf7f053d7a9147f2ad0e9b87ededc4c06eb5b1c03913ee910160405180910390a1606680549115157501000000000000000000000000000000000000000000027fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff909216919091179055565b61092e611526565b60665474010000000000000000000000000000000000000000900460ff1615610983576040517fcbccdabd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108766115a7565b610993611526565b6040517f07a573ed00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60665473ffffffffffffffffffffffffffffffffffffffff163314610a16576040517f56be192700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610a20828261161c565b610a286115a7565b5050565b610a34611526565b6066546040805173ffffffffffffffffffffffffffffffffffffffff928316815291831660208301527f6aef1fb5b23d0e109fc7f2b0601019e1edbacd177e31a441ec8548e8dd14f0f7910160405180910390a1606680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60665473ffffffffffffffffffffffffffffffffffffffff163314610b20576040517f56be192700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610a28828261161c565b606a8181548110610b3a57600080fd5b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16905081565b610b69611526565b6040805173ffffffffffffffffffffffffffffffffffffffff8416815282151560208201527f8bf2a0d80ce6d302421a2752aaa61bd2997f9ac551c58cced2df9092331e7c9b910160405180910390a173ffffffffffffffffffffffffffffffffffffffff91909116600090815260656020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b600054610100900460ff1615808015610c2f5750600054600160ff909116105b80610c495750303b158015610c49575060005460ff166001145b610cda576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084015b60405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790558015610d3857600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b885160005b81811015610dc2576001606560008d8481518110610d5d57610d5d6123a4565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055600101610d3d565b506066805473ffffffffffffffffffffffffffffffffffffffff8d81167fffffffffffffffffffff00ff00000000000000000000000000000000000000009092169190911775010000000000000000000000000000000000000000008b151502179091556067889055606980547fffffffffffffffffffffffff0000000000000000000000000000000000000000169187169190911790556068869055610e69848461161c565b606680547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16740100000000000000000000000000000000000000008b151502179055610eb58c611793565b508015610f1957600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050505050565b610f2e611526565b73ffffffffffffffffffffffffffffffffffffffff8116610fd1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610cd1565b610fda81611793565b50565b610fe5611526565b60675460408051918252602082018390527f3378b50a584a500797d8185e1763efadd89fc212945683ab9f284d293c5f9180910160405180910390a1606755565b3360009081526065602052604090205460ff1661106f576040517f26448fa300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152819060009073ffffffffffffffffffffffffffffffffffffffff8316906370a082319060240160206040518083038186803b1580156110d957600080fd5b505afa1580156110ed573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111191906123d3565b90506000629896806068548361112791906122f8565b6111319190612335565b905061113d8183612370565b9150629896808210156111505750505050565b606a54606954604080517ffa2af9da000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163fa2af9da91600480830192602092919082900301818787803b1580156111bf57600080fd5b505af11580156111d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111f79190612387565b9050821580159061121d575073ffffffffffffffffffffffffffffffffffffffff811615155b156112435761124373ffffffffffffffffffffffffffffffffffffffff8616828561180a565b60005b828110156112e8576000606a8281548110611263576112636123a4565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff16808352606b909152604082205490925090629896806112a6838a6122f8565b6112b09190612335565b90506112d373ffffffffffffffffffffffffffffffffffffffff8a16848361180a565b6112dd838b611897565b505050600101611246565b506040805173ffffffffffffffffffffffffffffffffffffffff88168152602081018690527f8e303f84fe3357e09112a03b39540286c13cbd04593711fe74fbce4d3233f383910160405180910390a1505050505050565b80803b8015611521578173ffffffffffffffffffffffffffffffffffffffff16630808e1c66040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561139157600080fd5b505af19250505080156113df575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526113dc918101906123ec565b60015b6113e857505050565b600181151514156113f95750505050565b506040517fcc64278400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff83169063cc64278490602401602060405180830381600087803b15801561146157600080fd5b505af19250505080156114af575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526114ac918101906123ec565b60015b6114b857505050565b801561151f578273ffffffffffffffffffffffffffffffffffffffff16633d12394a6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561150657600080fd5b505af115801561151a573d6000803e3d6000fd5b505050505b505b505050565b60335473ffffffffffffffffffffffffffffffffffffffff163314610876576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610cd1565b604051600181527fc9be97a6d486c04196f3a4971b118e670fe71948efd6c21b526031d1703f9ef99060200160405180910390a1606680547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1674010000000000000000000000000000000000000000179055565b60665474010000000000000000000000000000000000000000900460ff1615611671576040517fcbccdabd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151815181146116ad576040517f483927d000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6116b56119ed565b6000805b828110156117175760008482815181106116d5576116d56123a4565b602002602001015190506117028683815181106116f4576116f46123a4565b602002602001015182611a5d565b61170c8184612409565b9250506001016116b9565b50806298968014611754576040517f42732e3700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7ff3e591d98b1952fef0df15496db7836218c3b60be892f6eab11583e5300261688484604051611785929190612421565b60405180910390a150505050565b6033805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb00000000000000000000000000000000000000000000000000000000179052611521908490611b88565b81803b801561151f576040517fcc64278400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff83169063cc64278490602401602060405180830381600087803b15801561190757600080fd5b505af1925050508015611955575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201909252611952918101906123ec565b60015b61195f5750505050565b801561081d576040517ff4d3bdec00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116600483015284169063f4d3bdec90602401600060405180830381600087803b1580156119ce57600080fd5b505af11580156119e2573d6000803e3d6000fd5b505050505050505050565b606a54806119f85750565b60005b81811015611a50576000606a8281548110611a1857611a186123a4565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff168252606b90526040812055506001016119fb565b50610fda606a6000611e96565b73ffffffffffffffffffffffffffffffffffffffff8216611aaa576040517feff9f60700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff82166000908152606b602052604090205415611b07576040517fbcae37c200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606a8054600181019091557f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a5101805473ffffffffffffffffffffffffffffffffffffffff9093167fffffffffffffffffffffffff0000000000000000000000000000000000000000909316831790556000918252606b602052604090912055565b6000611bea826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16611c949092919063ffffffff16565b8051909150156115215780806020019051810190611c0891906123ec565b611521576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152608401610cd1565b6060611ca38484600085611cad565b90505b9392505050565b606082471015611d3f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610cd1565b73ffffffffffffffffffffffffffffffffffffffff85163b611dbd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610cd1565b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051611de691906124de565b60006040518083038185875af1925050503d8060008114611e23576040519150601f19603f3d011682016040523d82523d6000602084013e611e28565b606091505b5091509150611e38828286611e43565b979650505050505050565b60608315611e52575081611ca6565b825115611e625782518084602001fd5b816040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cd191906124fa565b5080546000825590600052602060002090810190610fda91905b80821115611ec45760008155600101611eb0565b5090565b73ffffffffffffffffffffffffffffffffffffffff81168114610fda57600080fd5b8035611ef581611ec8565b919050565b600060208284031215611f0c57600080fd5b8135611ca681611ec8565b8015158114610fda57600080fd5b8035611ef581611f17565b600060208284031215611f4257600080fd5b8135611ca681611f17565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611fc357611fc3611f4d565b604052919050565b600067ffffffffffffffff821115611fe557611fe5611f4d565b5060051b60200190565b600082601f83011261200057600080fd5b8135602061201561201083611fcb565b611f7c565b82815260059290921b8401810191818101908684111561203457600080fd5b8286015b8481101561205857803561204b81611ec8565b8352918301918301612038565b509695505050505050565b600082601f83011261207457600080fd5b8135602061208461201083611fcb565b82815260059290921b840181019181810190868411156120a357600080fd5b8286015b8481101561205857803583529183019183016120a7565b600080604083850312156120d157600080fd5b823567ffffffffffffffff808211156120e957600080fd5b6120f586838701611fef565b9350602085013591508082111561210b57600080fd5b5061211885828601612063565b9150509250929050565b60006020828403121561213457600080fd5b5035919050565b6000806040838503121561214e57600080fd5b823561215981611ec8565b9150602083013561216981611f17565b809150509250929050565b600082601f83011261218557600080fd5b8135602061219561201083611fcb565b82815260059290921b840181019181810190868411156121b457600080fd5b8286015b848110156120585780356121cb81611ec8565b83529183019183016121b8565b6000806000806000806000806000806101408b8d0312156121f857600080fd5b6122018b611eea565b995061220f60208c01611eea565b985060408b013567ffffffffffffffff8082111561222c57600080fd5b6122388e838f01612174565b995061224660608e01611f25565b985061225460808e01611f25565b975060a08d0135965060c08d0135955061227060e08e01611eea565b94506101008d013591508082111561228757600080fd5b6122938e838f01611fef565b93506101208d01359150808211156122aa57600080fd5b506122b78d828e01612063565b9150509295989b9194979a5092959850565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615612330576123306122c9565b500290565b60008261236b577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b600082821015612382576123826122c9565b500390565b60006020828403121561239957600080fd5b8151611ca681611ec8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000602082840312156123e557600080fd5b5051919050565b6000602082840312156123fe57600080fd5b8151611ca681611f17565b6000821982111561241c5761241c6122c9565b500190565b604080825283519082018190526000906020906060840190828701845b8281101561247057815173ffffffffffffffffffffffffffffffffffffffff168452928401929084019060010161243e565b5050508381038285015284518082528583019183019060005b818110156124a557835183529284019291840191600101612489565b5090979650505050505050565b60005b838110156124cd5781810151838201526020016124b5565b8381111561151f5750506000910152565b600082516124f08184602087016124b2565b9190910192915050565b60208152600082518060208401526125198160408501602087016124b2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fea26469706673582212204f394e33f3d28fcd70b73d83cc2607ed321762dcb1eebe5e91ed78e4b0e1452464736f6c63430008090033
Deployed Bytecode
0x6080604052600436106101845760003560e01c8063ae373c1b116100d6578063eaf4598a1161007f578063f432c79f11610059578063f432c79f146104e3578063f4d3bdec14610503578063f77c479114610523576101c9565b8063eaf4598a1461047c578063ee0e01c7146104ae578063f2fde38b146104c3576101c9565b8063d1bc76a1116100b0578063d1bc76a11461041c578063d59ba0df1461043c578063e6bfdc0b1461045c576101c9565b8063ae373c1b1461039f578063c45a0155146103bf578063cc642784146103ec576101c9565b8063478f425a116101385780638d2de9e1116101125780638d2de9e1146103135780638da5cb5b1461033357806392eefe9b1461037f576101c9565b8063478f425a146102d357806350a2f6c8146102e9578063715018a6146102fe576101c9565b806326232a2e1161016957806326232a2e146102865780633d12394a1461029c5780633d39e377146102b3576101c9565b80630808e1c6146102035780631558ab2f1461024b576101c9565b366101c95760665447907501000000000000000000000000000000000000000000900460ff1680156101b857506067548110155b156101c6576101c681610550565b50005b60665447907501000000000000000000000000000000000000000000900460ff1680156101b8575060675481106101c6576101c681610550565b34801561020f57600080fd5b50606654610236907501000000000000000000000000000000000000000000900460ff1681565b60405190151581526020015b60405180910390f35b34801561025757600080fd5b50610278610266366004611efa565b606b6020526000908152604090205481565b604051908152602001610242565b34801561029257600080fd5b5061027860685481565b3480156102a857600080fd5b506102b1610824565b005b3480156102bf57600080fd5b506102b16102ce366004611f30565b610878565b3480156102df57600080fd5b5061027860675481565b3480156102f557600080fd5b506102b1610926565b34801561030a57600080fd5b506102b161098b565b34801561031f57600080fd5b506102b161032e3660046120be565b6109c5565b34801561033f57600080fd5b5060335473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610242565b34801561038b57600080fd5b506102b161039a366004611efa565b610a2c565b3480156103ab57600080fd5b506102b16103ba3660046120be565b610acf565b3480156103cb57600080fd5b5060695461035a9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156103f857600080fd5b50610236610407366004611efa565b60656020526000908152604090205460ff1681565b34801561042857600080fd5b5061035a610437366004612122565b610b2a565b34801561044857600080fd5b506102b161045736600461213b565b610b61565b34801561046857600080fd5b506102b16104773660046121d8565b610c0f565b34801561048857600080fd5b506066546102369074010000000000000000000000000000000000000000900460ff1681565b3480156104ba57600080fd5b50606a54610278565b3480156104cf57600080fd5b506102b16104de366004611efa565b610f26565b3480156104ef57600080fd5b506102b16104fe366004612122565b610fdd565b34801561050f57600080fd5b506102b161051e366004611efa565b611026565b34801561052f57600080fd5b5060665461035a9073ffffffffffffffffffffffffffffffffffffffff1681565b6000629896806068548361056491906122f8565b61056e9190612335565b905061057a8183612370565b91506298968082101561058b575050565b606954604080517ffa2af9da000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163fa2af9da91600480830192602092919082900301818787803b1580156105f757600080fd5b505af115801561060b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061062f9190612387565b90508115801590610655575073ffffffffffffffffffffffffffffffffffffffff811615155b156106f75760008173ffffffffffffffffffffffffffffffffffffffff168360405160006040518083038185875af1925050503d80600081146106b4576040519150601f19603f3d011682016040523d82523d6000602084013e6106b9565b606091505b5090915050806106f5576040517f570f1df400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505b606a5460005b8181101561081d576000606a828154811061071a5761071a6123a4565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff16808352606b9091526040822054909250906298968061075d838a6122f8565b6107679190612335565b905060008373ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146107c3576040519150601f19603f3d011682016040523d82523d6000602084013e6107c8565b606091505b509091505080610804576040517f570f1df400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61080d84611340565b5050600190920191506106fd9050565b5050505050565b3360009081526065602052604090205460ff1661086d576040517f26448fa300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61087647610550565b565b610880611526565b60665460408051750100000000000000000000000000000000000000000090920460ff161515825282151560208301527ff13ee37d031ddceccecf7f053d7a9147f2ad0e9b87ededc4c06eb5b1c03913ee910160405180910390a1606680549115157501000000000000000000000000000000000000000000027fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff909216919091179055565b61092e611526565b60665474010000000000000000000000000000000000000000900460ff1615610983576040517fcbccdabd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108766115a7565b610993611526565b6040517f07a573ed00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60665473ffffffffffffffffffffffffffffffffffffffff163314610a16576040517f56be192700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610a20828261161c565b610a286115a7565b5050565b610a34611526565b6066546040805173ffffffffffffffffffffffffffffffffffffffff928316815291831660208301527f6aef1fb5b23d0e109fc7f2b0601019e1edbacd177e31a441ec8548e8dd14f0f7910160405180910390a1606680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60665473ffffffffffffffffffffffffffffffffffffffff163314610b20576040517f56be192700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610a28828261161c565b606a8181548110610b3a57600080fd5b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16905081565b610b69611526565b6040805173ffffffffffffffffffffffffffffffffffffffff8416815282151560208201527f8bf2a0d80ce6d302421a2752aaa61bd2997f9ac551c58cced2df9092331e7c9b910160405180910390a173ffffffffffffffffffffffffffffffffffffffff91909116600090815260656020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b600054610100900460ff1615808015610c2f5750600054600160ff909116105b80610c495750303b158015610c49575060005460ff166001145b610cda576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084015b60405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790558015610d3857600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b885160005b81811015610dc2576001606560008d8481518110610d5d57610d5d6123a4565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055600101610d3d565b506066805473ffffffffffffffffffffffffffffffffffffffff8d81167fffffffffffffffffffff00ff00000000000000000000000000000000000000009092169190911775010000000000000000000000000000000000000000008b151502179091556067889055606980547fffffffffffffffffffffffff0000000000000000000000000000000000000000169187169190911790556068869055610e69848461161c565b606680547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16740100000000000000000000000000000000000000008b151502179055610eb58c611793565b508015610f1957600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050505050505050565b610f2e611526565b73ffffffffffffffffffffffffffffffffffffffff8116610fd1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610cd1565b610fda81611793565b50565b610fe5611526565b60675460408051918252602082018390527f3378b50a584a500797d8185e1763efadd89fc212945683ab9f284d293c5f9180910160405180910390a1606755565b3360009081526065602052604090205460ff1661106f576040517f26448fa300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152819060009073ffffffffffffffffffffffffffffffffffffffff8316906370a082319060240160206040518083038186803b1580156110d957600080fd5b505afa1580156110ed573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111191906123d3565b90506000629896806068548361112791906122f8565b6111319190612335565b905061113d8183612370565b9150629896808210156111505750505050565b606a54606954604080517ffa2af9da000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163fa2af9da91600480830192602092919082900301818787803b1580156111bf57600080fd5b505af11580156111d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111f79190612387565b9050821580159061121d575073ffffffffffffffffffffffffffffffffffffffff811615155b156112435761124373ffffffffffffffffffffffffffffffffffffffff8616828561180a565b60005b828110156112e8576000606a8281548110611263576112636123a4565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff16808352606b909152604082205490925090629896806112a6838a6122f8565b6112b09190612335565b90506112d373ffffffffffffffffffffffffffffffffffffffff8a16848361180a565b6112dd838b611897565b505050600101611246565b506040805173ffffffffffffffffffffffffffffffffffffffff88168152602081018690527f8e303f84fe3357e09112a03b39540286c13cbd04593711fe74fbce4d3233f383910160405180910390a1505050505050565b80803b8015611521578173ffffffffffffffffffffffffffffffffffffffff16630808e1c66040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561139157600080fd5b505af19250505080156113df575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526113dc918101906123ec565b60015b6113e857505050565b600181151514156113f95750505050565b506040517fcc64278400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff83169063cc64278490602401602060405180830381600087803b15801561146157600080fd5b505af19250505080156114af575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526114ac918101906123ec565b60015b6114b857505050565b801561151f578273ffffffffffffffffffffffffffffffffffffffff16633d12394a6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561150657600080fd5b505af115801561151a573d6000803e3d6000fd5b505050505b505b505050565b60335473ffffffffffffffffffffffffffffffffffffffff163314610876576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610cd1565b604051600181527fc9be97a6d486c04196f3a4971b118e670fe71948efd6c21b526031d1703f9ef99060200160405180910390a1606680547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1674010000000000000000000000000000000000000000179055565b60665474010000000000000000000000000000000000000000900460ff1615611671576040517fcbccdabd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8151815181146116ad576040517f483927d000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6116b56119ed565b6000805b828110156117175760008482815181106116d5576116d56123a4565b602002602001015190506117028683815181106116f4576116f46123a4565b602002602001015182611a5d565b61170c8184612409565b9250506001016116b9565b50806298968014611754576040517f42732e3700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7ff3e591d98b1952fef0df15496db7836218c3b60be892f6eab11583e5300261688484604051611785929190612421565b60405180910390a150505050565b6033805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb00000000000000000000000000000000000000000000000000000000179052611521908490611b88565b81803b801561151f576040517fcc64278400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff83169063cc64278490602401602060405180830381600087803b15801561190757600080fd5b505af1925050508015611955575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201909252611952918101906123ec565b60015b61195f5750505050565b801561081d576040517ff4d3bdec00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116600483015284169063f4d3bdec90602401600060405180830381600087803b1580156119ce57600080fd5b505af11580156119e2573d6000803e3d6000fd5b505050505050505050565b606a54806119f85750565b60005b81811015611a50576000606a8281548110611a1857611a186123a4565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff168252606b90526040812055506001016119fb565b50610fda606a6000611e96565b73ffffffffffffffffffffffffffffffffffffffff8216611aaa576040517feff9f60700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff82166000908152606b602052604090205415611b07576040517fbcae37c200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606a8054600181019091557f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a5101805473ffffffffffffffffffffffffffffffffffffffff9093167fffffffffffffffffffffffff0000000000000000000000000000000000000000909316831790556000918252606b602052604090912055565b6000611bea826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16611c949092919063ffffffff16565b8051909150156115215780806020019051810190611c0891906123ec565b611521576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152608401610cd1565b6060611ca38484600085611cad565b90505b9392505050565b606082471015611d3f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610cd1565b73ffffffffffffffffffffffffffffffffffffffff85163b611dbd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610cd1565b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051611de691906124de565b60006040518083038185875af1925050503d8060008114611e23576040519150601f19603f3d011682016040523d82523d6000602084013e611e28565b606091505b5091509150611e38828286611e43565b979650505050505050565b60608315611e52575081611ca6565b825115611e625782518084602001fd5b816040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cd191906124fa565b5080546000825590600052602060002090810190610fda91905b80821115611ec45760008155600101611eb0565b5090565b73ffffffffffffffffffffffffffffffffffffffff81168114610fda57600080fd5b8035611ef581611ec8565b919050565b600060208284031215611f0c57600080fd5b8135611ca681611ec8565b8015158114610fda57600080fd5b8035611ef581611f17565b600060208284031215611f4257600080fd5b8135611ca681611f17565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611fc357611fc3611f4d565b604052919050565b600067ffffffffffffffff821115611fe557611fe5611f4d565b5060051b60200190565b600082601f83011261200057600080fd5b8135602061201561201083611fcb565b611f7c565b82815260059290921b8401810191818101908684111561203457600080fd5b8286015b8481101561205857803561204b81611ec8565b8352918301918301612038565b509695505050505050565b600082601f83011261207457600080fd5b8135602061208461201083611fcb565b82815260059290921b840181019181810190868411156120a357600080fd5b8286015b8481101561205857803583529183019183016120a7565b600080604083850312156120d157600080fd5b823567ffffffffffffffff808211156120e957600080fd5b6120f586838701611fef565b9350602085013591508082111561210b57600080fd5b5061211885828601612063565b9150509250929050565b60006020828403121561213457600080fd5b5035919050565b6000806040838503121561214e57600080fd5b823561215981611ec8565b9150602083013561216981611f17565b809150509250929050565b600082601f83011261218557600080fd5b8135602061219561201083611fcb565b82815260059290921b840181019181810190868411156121b457600080fd5b8286015b848110156120585780356121cb81611ec8565b83529183019183016121b8565b6000806000806000806000806000806101408b8d0312156121f857600080fd5b6122018b611eea565b995061220f60208c01611eea565b985060408b013567ffffffffffffffff8082111561222c57600080fd5b6122388e838f01612174565b995061224660608e01611f25565b985061225460808e01611f25565b975060a08d0135965060c08d0135955061227060e08e01611eea565b94506101008d013591508082111561228757600080fd5b6122938e838f01611fef565b93506101208d01359150808211156122aa57600080fd5b506122b78d828e01612063565b9150509295989b9194979a5092959850565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615612330576123306122c9565b500290565b60008261236b577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b600082821015612382576123826122c9565b500390565b60006020828403121561239957600080fd5b8151611ca681611ec8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000602082840312156123e557600080fd5b5051919050565b6000602082840312156123fe57600080fd5b8151611ca681611f17565b6000821982111561241c5761241c6122c9565b500190565b604080825283519082018190526000906020906060840190828701845b8281101561247057815173ffffffffffffffffffffffffffffffffffffffff168452928401929084019060010161243e565b5050508381038285015284518082528583019183019060005b818110156124a557835183529284019291840191600101612489565b5090979650505050505050565b60005b838110156124cd5781810151838201526020016124b5565b8381111561151f5750506000910152565b600082516124f08184602087016124b2565b9190910192915050565b60208152600082518060208401526125198160408501602087016124b2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fea26469706673582212204f394e33f3d28fcd70b73d83cc2607ed321762dcb1eebe5e91ed78e4b0e1452464736f6c63430008090033
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 33 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.