Source Code
Latest 25 from a total of 1,063 transactions
| Transaction Hash |
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Distribute Batch | 41301758 | 9 mins ago | IN | 0 ETH | 0.00000104 | ||||
| Distribute | 41301754 | 9 mins ago | IN | 0 ETH | 0.00000049 | ||||
| Distribute | 41301750 | 9 mins ago | IN | 0 ETH | 0.0000007 | ||||
| Distribute | 41301746 | 9 mins ago | IN | 0 ETH | 0.00000099 | ||||
| Distribute | 41301737 | 9 mins ago | IN | 0 ETH | 0.0000008 | ||||
| Distribute | 41301733 | 9 mins ago | IN | 0 ETH | 0.00000072 | ||||
| Distribute | 41301732 | 9 mins ago | IN | 0 ETH | 0.00000072 | ||||
| Distribute Batch | 41301729 | 9 mins ago | IN | 0 ETH | 0.00000144 | ||||
| Distribute Batch | 41301728 | 10 mins ago | IN | 0 ETH | 0.00000216 | ||||
| Distribute Batch | 41298137 | 2 hrs ago | IN | 0 ETH | 0.0000005 | ||||
| Distribute Batch | 41298132 | 2 hrs ago | IN | 0 ETH | 0.00000053 | ||||
| Distribute Batch | 41298128 | 2 hrs ago | IN | 0 ETH | 0.00000101 | ||||
| Distribute | 41294547 | 4 hrs ago | IN | 0 ETH | 0.00000061 | ||||
| Distribute | 41294538 | 4 hrs ago | IN | 0 ETH | 0.00000065 | ||||
| Distribute Batch | 41294533 | 4 hrs ago | IN | 0 ETH | 0.00000099 | ||||
| Distribute | 41294533 | 4 hrs ago | IN | 0 ETH | 0.00000058 | ||||
| Distribute Batch | 41294529 | 4 hrs ago | IN | 0 ETH | 0.00000115 | ||||
| Distribute Batch | 41294528 | 4 hrs ago | IN | 0 ETH | 0.00000142 | ||||
| Distribute Batch | 41290958 | 6 hrs ago | IN | 0 ETH | 0.0000045 | ||||
| Distribute | 41290955 | 6 hrs ago | IN | 0 ETH | 0.00000234 | ||||
| Distribute Batch | 41290942 | 6 hrs ago | IN | 0 ETH | 0.00000522 | ||||
| Distribute | 41290941 | 6 hrs ago | IN | 0 ETH | 0.00000359 | ||||
| Distribute Batch | 41290937 | 6 hrs ago | IN | 0 ETH | 0.00000492 | ||||
| Distribute Batch | 41290937 | 6 hrs ago | IN | 0 ETH | 0.00000725 | ||||
| Distribute Batch | 41290933 | 6 hrs ago | IN | 0 ETH | 0.00000911 |
Latest 25 internal transactions (View All)
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 41301758 | 9 mins ago | 0.00006562 ETH | ||||
| 41301754 | 9 mins ago | 0.000025 ETH | ||||
| 41301728 | 10 mins ago | 0.00031112 ETH | ||||
| 41299745 | 1 hr ago | 0.000375 ETH | ||||
| 41299280 | 1 hr ago | 0.0000035 ETH | ||||
| 41298128 | 2 hrs ago | 0.000975 ETH | ||||
| 41297170 | 2 hrs ago | 0.0005 ETH | ||||
| 41297146 | 2 hrs ago | 0.0005 ETH | ||||
| 41294528 | 4 hrs ago | 0.00001027 ETH | ||||
| 41292589 | 5 hrs ago | 0.00001027 ETH | ||||
| 41290958 | 6 hrs ago | 0.00000052 ETH | ||||
| 41290955 | 6 hrs ago | 0.0000125 ETH | ||||
| 41290942 | 6 hrs ago | 0.00000148 ETH | ||||
| 41290937 | 6 hrs ago | 0.00019732 ETH | ||||
| 41290933 | 6 hrs ago | 0.00000877 ETH | ||||
| 41290933 | 6 hrs ago | 0.00004385 ETH | ||||
| 41290930 | 6 hrs ago | 0.00000582 ETH | ||||
| 41290928 | 6 hrs ago | 0.0006953 ETH | ||||
| 41289892 | 6 hrs ago | 0.0000005 ETH | ||||
| 41289859 | 6 hrs ago | 0.0000005 ETH | ||||
| 41288243 | 7 hrs ago | 0.0000035 ETH | ||||
| 41288191 | 7 hrs ago | 0.000018 ETH | ||||
| 41287866 | 7 hrs ago | 0.0005 ETH | ||||
| 41287385 | 8 hrs ago | 0.0004385 ETH | ||||
| 41287352 | 8 hrs ago | 0.0000225 ETH |
Cross-Chain Transactions
Loading...
Loading
Contract Name:
FeeDistribution
Compiler Version
v0.8.17+commit.8df45f5f
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED
pragma solidity 0.8.17;
import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import {ERC2771Context} from "@openzeppelin/contracts/metatx/ERC2771Context.sol";
import {AccessControl} from "@openzeppelin/contracts/access/AccessControl.sol";
import {Context} from "@openzeppelin/contracts/utils/Context.sol";
import {IFeeDistribution} from "./interfaces/IFeeDistribution.sol";
import {TransferHelper} from "@uniswap/lib/contracts/libraries/TransferHelper.sol";
/**
* @title FeeDistribution
* @notice Distributes fee tokens (ERC20 or native) to multiple recipients.
*/
contract FeeDistribution is AccessControl, ERC2771Context, IFeeDistribution {
bytes32 public constant FEE_DISTRIBUTOR_ROLE =
keccak256("FEE_DISTRIBUTOR_ROLE");
/// @dev Sentinel address used to denote native token in place of an ERC20.
address public constant NATIVE_TOKEN =
0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;
constructor(
address feeDistributor,
address trustedForwarder
) ERC2771Context(trustedForwarder) {
_setupRole(DEFAULT_ADMIN_ROLE, _msgSender());
_setupRole(FEE_DISTRIBUTOR_ROLE, feeDistributor);
}
/**
* @notice Distribute fees to multiple recipients across multiple fee tokens in a single call.
* @param feeTokens Array of fee token addresses (or native token sentinel).
* @param transactionHashes Array of arrays of transaction hashes (parallel to feeTokens).
* @param amounts Array of arrays of amounts (parallel to feeTokens).
* @param receivers Array of arrays of addresses to receive funds (parallel to feeTokens).
*/
function distributeBatch(
address[] calldata feeTokens,
bytes[][] calldata transactionHashes,
uint256[][] calldata amounts,
address[][] calldata receivers
) external onlyRole(FEE_DISTRIBUTOR_ROLE) {
uint256 len = feeTokens.length;
require(
len == transactionHashes.length &&
len == amounts.length &&
len == receivers.length,
"FeeDistribution: Parameter length mismatch"
);
for (uint256 i; i < len; ) {
_distribute(
feeTokens[i],
transactionHashes[i],
amounts[i],
receivers[i]
);
unchecked {
++i;
}
}
}
/**
* @notice Distribute fees of a single token type to multiple recipients.
* @param feeToken The address of the fee token (or native token sentinel).
* @param transactionHashes An array of transaction hashes associated with each distribution.
* @param amounts An array of amounts to distribute to each recipient.
* @param receivers An array of addresses to receive the amounts.
*/
function distribute(
address feeToken,
bytes[] calldata transactionHashes,
uint256[] calldata amounts,
address[] calldata receivers
) external onlyRole(FEE_DISTRIBUTOR_ROLE) {
_distribute(feeToken, transactionHashes, amounts, receivers);
}
/**
* @dev Internal function that actually performs the distribution.
*/
function _distribute(
address feeToken,
bytes[] calldata transactionHashes,
uint256[] calldata amounts,
address[] calldata receivers
) internal {
uint256 len = receivers.length;
require(
len == amounts.length,
"FeeDistribution: Amounts and receivers length mismatch"
);
require(
transactionHashes.length > 0,
"FeeDistribution: Transaction hashes are required"
);
if (feeToken == NATIVE_TOKEN) {
// Distribute native token
for (uint256 i; i < len; ) {
require(
amounts[i] > 0,
"FeeDistribution: Amount must be greater than 0"
);
require(
receivers[i] != address(0),
"FeeDistribution: Receiver address cannot be 0"
);
(bool success, ) = receivers[i].call{value: amounts[i]}("");
require(success, "Native transfer failed");
unchecked {
++i;
}
}
} else {
// Distribute ERC20 token
for (uint256 i; i < len; ) {
require(
amounts[i] > 0,
"FeeDistribution: Amount must be greater than 0"
);
require(
receivers[i] != address(0),
"FeeDistribution: Receiver address cannot be 0"
);
TransferHelper.safeTransfer(feeToken, receivers[i], amounts[i]);
unchecked {
++i;
}
}
}
emit FeeDistributed(feeToken, transactionHashes, amounts, receivers);
}
/**
* @dev Override for ERC2771 meta-transactions.
*/
function _msgSender()
internal
view
override(ERC2771Context, Context)
returns (address sender)
{
return ERC2771Context._msgSender();
}
/**
* @dev Override for ERC2771 meta-transactions.
*/
function _msgData()
internal
view
override(ERC2771Context, Context)
returns (bytes calldata)
{
return ERC2771Context._msgData();
}
/**
* @dev Fallback to receive native tokens directly.
*/
receive() external payable {}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (access/AccessControl.sol)
pragma solidity ^0.8.0;
import "./IAccessControl.sol";
import "../utils/Context.sol";
import "../utils/Strings.sol";
import "../utils/introspection/ERC165.sol";
/**
* @dev Contract module that allows children to implement role-based access
* control mechanisms. This is a lightweight version that doesn't allow enumerating role
* members except through off-chain means by accessing the contract event logs. Some
* applications may benefit from on-chain enumerability, for those cases see
* {AccessControlEnumerable}.
*
* Roles are referred to by their `bytes32` identifier. These should be exposed
* in the external API and be unique. The best way to achieve this is by
* using `public constant` hash digests:
*
* ```
* bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
* ```
*
* Roles can be used to represent a set of permissions. To restrict access to a
* function call, use {hasRole}:
*
* ```
* function foo() public {
* require(hasRole(MY_ROLE, msg.sender));
* ...
* }
* ```
*
* Roles can be granted and revoked dynamically via the {grantRole} and
* {revokeRole} functions. Each role has an associated admin role, and only
* accounts that have a role's admin role can call {grantRole} and {revokeRole}.
*
* By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
* that only accounts with this role will be able to grant or revoke other
* roles. More complex role relationships can be created by using
* {_setRoleAdmin}.
*
* WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
* grant and revoke this role. Extra precautions should be taken to secure
* accounts that have been granted it.
*/
abstract contract AccessControl is Context, IAccessControl, ERC165 {
struct RoleData {
mapping(address => bool) members;
bytes32 adminRole;
}
mapping(bytes32 => RoleData) private _roles;
bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;
/**
* @dev Modifier that checks that an account has a specific role. Reverts
* with a standardized message including the required role.
*
* The format of the revert reason is given by the following regular expression:
*
* /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
*
* _Available since v4.1._
*/
modifier onlyRole(bytes32 role) {
_checkRole(role);
_;
}
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);
}
/**
* @dev Returns `true` if `account` has been granted `role`.
*/
function hasRole(bytes32 role, address account) public view virtual override returns (bool) {
return _roles[role].members[account];
}
/**
* @dev Revert with a standard message if `_msgSender()` is missing `role`.
* Overriding this function changes the behavior of the {onlyRole} modifier.
*
* Format of the revert message is described in {_checkRole}.
*
* _Available since v4.6._
*/
function _checkRole(bytes32 role) internal view virtual {
_checkRole(role, _msgSender());
}
/**
* @dev Revert with a standard message if `account` is missing `role`.
*
* The format of the revert reason is given by the following regular expression:
*
* /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
*/
function _checkRole(bytes32 role, address account) internal view virtual {
if (!hasRole(role, account)) {
revert(
string(
abi.encodePacked(
"AccessControl: account ",
Strings.toHexString(account),
" is missing role ",
Strings.toHexString(uint256(role), 32)
)
)
);
}
}
/**
* @dev Returns the admin role that controls `role`. See {grantRole} and
* {revokeRole}.
*
* To change a role's admin, use {_setRoleAdmin}.
*/
function getRoleAdmin(bytes32 role) public view virtual override returns (bytes32) {
return _roles[role].adminRole;
}
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*
* May emit a {RoleGranted} event.
*/
function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
_grantRole(role, account);
}
/**
* @dev Revokes `role` from `account`.
*
* If `account` had been granted `role`, emits a {RoleRevoked} event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*
* May emit a {RoleRevoked} event.
*/
function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
_revokeRole(role, account);
}
/**
* @dev Revokes `role` from the calling account.
*
* Roles are often managed via {grantRole} and {revokeRole}: this function's
* purpose is to provide a mechanism for accounts to lose their privileges
* if they are compromised (such as when a trusted device is misplaced).
*
* If the calling account had been revoked `role`, emits a {RoleRevoked}
* event.
*
* Requirements:
*
* - the caller must be `account`.
*
* May emit a {RoleRevoked} event.
*/
function renounceRole(bytes32 role, address account) public virtual override {
require(account == _msgSender(), "AccessControl: can only renounce roles for self");
_revokeRole(role, account);
}
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event. Note that unlike {grantRole}, this function doesn't perform any
* checks on the calling account.
*
* May emit a {RoleGranted} event.
*
* [WARNING]
* ====
* This function should only be called from the constructor when setting
* up the initial roles for the system.
*
* Using this function in any other way is effectively circumventing the admin
* system imposed by {AccessControl}.
* ====
*
* NOTE: This function is deprecated in favor of {_grantRole}.
*/
function _setupRole(bytes32 role, address account) internal virtual {
_grantRole(role, account);
}
/**
* @dev Sets `adminRole` as ``role``'s admin role.
*
* Emits a {RoleAdminChanged} event.
*/
function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
bytes32 previousAdminRole = getRoleAdmin(role);
_roles[role].adminRole = adminRole;
emit RoleAdminChanged(role, previousAdminRole, adminRole);
}
/**
* @dev Grants `role` to `account`.
*
* Internal function without access restriction.
*
* May emit a {RoleGranted} event.
*/
function _grantRole(bytes32 role, address account) internal virtual {
if (!hasRole(role, account)) {
_roles[role].members[account] = true;
emit RoleGranted(role, account, _msgSender());
}
}
/**
* @dev Revokes `role` from `account`.
*
* Internal function without access restriction.
*
* May emit a {RoleRevoked} event.
*/
function _revokeRole(bytes32 role, address account) internal virtual {
if (hasRole(role, account)) {
_roles[role].members[account] = false;
emit RoleRevoked(role, account, _msgSender());
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol)
pragma solidity ^0.8.0;
/**
* @dev External interface of AccessControl declared to support ERC165 detection.
*/
interface IAccessControl {
/**
* @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
*
* `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
* {RoleAdminChanged} not being emitted signaling this.
*
* _Available since v3.1._
*/
event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);
/**
* @dev Emitted when `account` is granted `role`.
*
* `sender` is the account that originated the contract call, an admin role
* bearer except when using {AccessControl-_setupRole}.
*/
event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);
/**
* @dev Emitted when `account` is revoked `role`.
*
* `sender` is the account that originated the contract call:
* - if using `revokeRole`, it is the admin role bearer
* - if using `renounceRole`, it is the role bearer (i.e. `account`)
*/
event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);
/**
* @dev Returns `true` if `account` has been granted `role`.
*/
function hasRole(bytes32 role, address account) external view returns (bool);
/**
* @dev Returns the admin role that controls `role`. See {grantRole} and
* {revokeRole}.
*
* To change a role's admin, use {AccessControl-_setRoleAdmin}.
*/
function getRoleAdmin(bytes32 role) external view returns (bytes32);
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*/
function grantRole(bytes32 role, address account) external;
/**
* @dev Revokes `role` from `account`.
*
* If `account` had been granted `role`, emits a {RoleRevoked} event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*/
function revokeRole(bytes32 role, address account) external;
/**
* @dev Revokes `role` from the calling account.
*
* Roles are often managed via {grantRole} and {revokeRole}: this function's
* purpose is to provide a mechanism for accounts to lose their privileges
* if they are compromised (such as when a trusted device is misplaced).
*
* If the calling account had been granted `role`, emits a {RoleRevoked}
* event.
*
* Requirements:
*
* - the caller must be `account`.
*/
function renounceRole(bytes32 role, address account) external;
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (metatx/ERC2771Context.sol)
pragma solidity ^0.8.9;
import "../utils/Context.sol";
/**
* @dev Context variant with ERC2771 support.
*/
abstract contract ERC2771Context is Context {
/// @custom:oz-upgrades-unsafe-allow state-variable-immutable
address private immutable _trustedForwarder;
/// @custom:oz-upgrades-unsafe-allow constructor
constructor(address trustedForwarder) {
_trustedForwarder = trustedForwarder;
}
function isTrustedForwarder(address forwarder) public view virtual returns (bool) {
return forwarder == _trustedForwarder;
}
function _msgSender() internal view virtual override returns (address sender) {
if (isTrustedForwarder(msg.sender)) {
// The assembly code is more direct than the Solidity version using `abi.decode`.
/// @solidity memory-safe-assembly
assembly {
sender := shr(96, calldataload(sub(calldatasize(), 20)))
}
} else {
return super._msgSender();
}
}
function _msgData() internal view virtual override returns (bytes calldata) {
if (isTrustedForwarder(msg.sender)) {
return msg.data[:msg.data.length - 20];
} else {
return super._msgData();
}
}
}// 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 v4.4.1 (utils/Context.sol)
pragma solidity ^0.8.0;
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)
pragma solidity ^0.8.0;
import "./math/Math.sol";
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant _SYMBOLS = "0123456789abcdef";
uint8 private constant _ADDRESS_LENGTH = 20;
/**
* @dev Converts a `uint256` to its ASCII `string` decimal representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
unchecked {
uint256 length = Math.log10(value) + 1;
string memory buffer = new string(length);
uint256 ptr;
/// @solidity memory-safe-assembly
assembly {
ptr := add(buffer, add(32, length))
}
while (true) {
ptr--;
/// @solidity memory-safe-assembly
assembly {
mstore8(ptr, byte(mod(value, 10), _SYMBOLS))
}
value /= 10;
if (value == 0) break;
}
return buffer;
}
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
*/
function toHexString(uint256 value) internal pure returns (string memory) {
unchecked {
return toHexString(value, Math.log256(value) + 1);
}
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
*/
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
bytes memory buffer = new bytes(2 * length + 2);
buffer[0] = "0";
buffer[1] = "x";
for (uint256 i = 2 * length + 1; i > 1; --i) {
buffer[i] = _SYMBOLS[value & 0xf];
value >>= 4;
}
require(value == 0, "Strings: hex length insufficient");
return string(buffer);
}
/**
* @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
*/
function toHexString(address addr) internal pure returns (string memory) {
return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)
pragma solidity ^0.8.0;
import "./IERC165.sol";
/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
* for the additional interface id that will be supported. For example:
*
* ```solidity
* function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
* return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
* }
* ```
*
* Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
*/
abstract contract ERC165 is IERC165 {
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IERC165).interfaceId;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)
pragma solidity ^0.8.0;
/**
* @dev Standard math utilities missing in the Solidity language.
*/
library Math {
enum Rounding {
Down, // Toward negative infinity
Up, // Toward infinity
Zero // Toward zero
}
/**
* @dev Returns the largest of two numbers.
*/
function max(uint256 a, uint256 b) internal pure returns (uint256) {
return a > b ? a : b;
}
/**
* @dev Returns the smallest of two numbers.
*/
function min(uint256 a, uint256 b) internal pure returns (uint256) {
return a < b ? a : b;
}
/**
* @dev Returns the average of two numbers. The result is rounded towards
* zero.
*/
function average(uint256 a, uint256 b) internal pure returns (uint256) {
// (a + b) / 2 can overflow.
return (a & b) + (a ^ b) / 2;
}
/**
* @dev Returns the ceiling of the division of two numbers.
*
* This differs from standard division with `/` in that it rounds up instead
* of rounding down.
*/
function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
// (a + b - 1) / b can overflow on addition, so we distribute.
return a == 0 ? 0 : (a - 1) / b + 1;
}
/**
* @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0
* @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)
* with further edits by Uniswap Labs also under MIT license.
*/
function mulDiv(
uint256 x,
uint256 y,
uint256 denominator
) internal pure returns (uint256 result) {
unchecked {
// 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
// use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
// variables such that product = prod1 * 2^256 + prod0.
uint256 prod0; // Least significant 256 bits of the product
uint256 prod1; // Most significant 256 bits of the product
assembly {
let mm := mulmod(x, y, not(0))
prod0 := mul(x, y)
prod1 := sub(sub(mm, prod0), lt(mm, prod0))
}
// Handle non-overflow cases, 256 by 256 division.
if (prod1 == 0) {
return prod0 / denominator;
}
// Make sure the result is less than 2^256. Also prevents denominator == 0.
require(denominator > prod1);
///////////////////////////////////////////////
// 512 by 256 division.
///////////////////////////////////////////////
// Make division exact by subtracting the remainder from [prod1 prod0].
uint256 remainder;
assembly {
// Compute remainder using mulmod.
remainder := mulmod(x, y, denominator)
// Subtract 256 bit number from 512 bit number.
prod1 := sub(prod1, gt(remainder, prod0))
prod0 := sub(prod0, remainder)
}
// Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.
// See https://cs.stackexchange.com/q/138556/92363.
// Does not overflow because the denominator cannot be zero at this stage in the function.
uint256 twos = denominator & (~denominator + 1);
assembly {
// Divide denominator by twos.
denominator := div(denominator, twos)
// Divide [prod1 prod0] by twos.
prod0 := div(prod0, twos)
// Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
twos := add(div(sub(0, twos), twos), 1)
}
// Shift in bits from prod1 into prod0.
prod0 |= prod1 * twos;
// Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
// that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
// four bits. That is, denominator * inv = 1 mod 2^4.
uint256 inverse = (3 * denominator) ^ 2;
// Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works
// in modular arithmetic, doubling the correct bits in each step.
inverse *= 2 - denominator * inverse; // inverse mod 2^8
inverse *= 2 - denominator * inverse; // inverse mod 2^16
inverse *= 2 - denominator * inverse; // inverse mod 2^32
inverse *= 2 - denominator * inverse; // inverse mod 2^64
inverse *= 2 - denominator * inverse; // inverse mod 2^128
inverse *= 2 - denominator * inverse; // inverse mod 2^256
// Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
// This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
// less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
// is no longer required.
result = prod0 * inverse;
return result;
}
}
/**
* @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
*/
function mulDiv(
uint256 x,
uint256 y,
uint256 denominator,
Rounding rounding
) internal pure returns (uint256) {
uint256 result = mulDiv(x, y, denominator);
if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {
result += 1;
}
return result;
}
/**
* @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.
*
* Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
*/
function sqrt(uint256 a) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
// For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
//
// We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
// `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
//
// This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
// → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
// → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
//
// Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
uint256 result = 1 << (log2(a) >> 1);
// At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
// since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
// every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
// into the expected uint128 result.
unchecked {
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
return min(result, a / result);
}
}
/**
* @notice Calculates sqrt(a), following the selected rounding direction.
*/
function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = sqrt(a);
return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);
}
}
/**
* @dev Return the log in base 2, rounded down, of a positive value.
* Returns 0 if given 0.
*/
function log2(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 128;
}
if (value >> 64 > 0) {
value >>= 64;
result += 64;
}
if (value >> 32 > 0) {
value >>= 32;
result += 32;
}
if (value >> 16 > 0) {
value >>= 16;
result += 16;
}
if (value >> 8 > 0) {
value >>= 8;
result += 8;
}
if (value >> 4 > 0) {
value >>= 4;
result += 4;
}
if (value >> 2 > 0) {
value >>= 2;
result += 2;
}
if (value >> 1 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 2, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log2(value);
return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 10, rounded down, of a positive value.
* Returns 0 if given 0.
*/
function log10(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >= 10**64) {
value /= 10**64;
result += 64;
}
if (value >= 10**32) {
value /= 10**32;
result += 32;
}
if (value >= 10**16) {
value /= 10**16;
result += 16;
}
if (value >= 10**8) {
value /= 10**8;
result += 8;
}
if (value >= 10**4) {
value /= 10**4;
result += 4;
}
if (value >= 10**2) {
value /= 10**2;
result += 2;
}
if (value >= 10**1) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 10, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log10(value);
return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 256, rounded down, of a positive value.
* Returns 0 if given 0.
*
* Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
*/
function log256(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 16;
}
if (value >> 64 > 0) {
value >>= 64;
result += 8;
}
if (value >> 32 > 0) {
value >>= 32;
result += 4;
}
if (value >> 16 > 0) {
value >>= 16;
result += 2;
}
if (value >> 8 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 10, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log256(value);
return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);
}
}
}// SPDX-License-Identifier: GPL-3.0-or-later
pragma solidity >=0.6.0;
// helper methods for interacting with ERC20 tokens and sending ETH that do not consistently return true/false
library TransferHelper {
function safeApprove(
address token,
address to,
uint256 value
) internal {
// bytes4(keccak256(bytes('approve(address,uint256)')));
(bool success, bytes memory data) = token.call(abi.encodeWithSelector(0x095ea7b3, to, value));
require(
success && (data.length == 0 || abi.decode(data, (bool))),
'TransferHelper::safeApprove: approve failed'
);
}
function safeTransfer(
address token,
address to,
uint256 value
) internal {
// bytes4(keccak256(bytes('transfer(address,uint256)')));
(bool success, bytes memory data) = token.call(abi.encodeWithSelector(0xa9059cbb, to, value));
require(
success && (data.length == 0 || abi.decode(data, (bool))),
'TransferHelper::safeTransfer: transfer failed'
);
}
function safeTransferFrom(
address token,
address from,
address to,
uint256 value
) internal {
// bytes4(keccak256(bytes('transferFrom(address,address,uint256)')));
(bool success, bytes memory data) = token.call(abi.encodeWithSelector(0x23b872dd, from, to, value));
require(
success && (data.length == 0 || abi.decode(data, (bool))),
'TransferHelper::transferFrom: transferFrom failed'
);
}
function safeTransferETH(address to, uint256 value) internal {
(bool success, ) = to.call{value: value}(new bytes(0));
require(success, 'TransferHelper::safeTransferETH: ETH transfer failed');
}
}// SPDX-License-Identifier: UNLICENSED
pragma solidity 0.8.17;
interface IFeeDistribution {
event FeeDistributed(
address indexed feeToken,
bytes[] transactionHashes,
uint256[] amounts,
address[] receivers
);
function distributeBatch(
address[] calldata feeTokens,
bytes[][] calldata transactionHashes,
uint256[][] calldata amounts,
address[][] calldata receivers
) external;
function distribute(
address feeToken,
bytes[] calldata transactionHashes,
uint256[] calldata amounts,
address[] calldata receivers
) external;
}{
"evmVersion": "london",
"libraries": {},
"metadata": {
"bytecodeHash": "ipfs",
"useLiteralContent": true
},
"optimizer": {
"enabled": true,
"runs": 125
},
"remappings": [],
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"feeDistributor","type":"address"},{"internalType":"address","name":"trustedForwarder","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"feeToken","type":"address"},{"indexed":false,"internalType":"bytes[]","name":"transactionHashes","type":"bytes[]"},{"indexed":false,"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"indexed":false,"internalType":"address[]","name":"receivers","type":"address[]"}],"name":"FeeDistributed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FEE_DISTRIBUTOR_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NATIVE_TOKEN","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"feeToken","type":"address"},{"internalType":"bytes[]","name":"transactionHashes","type":"bytes[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"address[]","name":"receivers","type":"address[]"}],"name":"distribute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"feeTokens","type":"address[]"},{"internalType":"bytes[][]","name":"transactionHashes","type":"bytes[][]"},{"internalType":"uint256[][]","name":"amounts","type":"uint256[][]"},{"internalType":"address[][]","name":"receivers","type":"address[][]"}],"name":"distributeBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"forwarder","type":"address"}],"name":"isTrustedForwarder","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]Contract Creation Code
60a06040523480156200001157600080fd5b5060405162001647380380620016478339810160408190526200003491620001b2565b6001600160a01b038116608052620000576000620000516200008b565b620000a7565b620000837f59c7a9ef9a56707d87d116a5d27496afee2604c70b902ac2c4dbdcb68f36f2ea83620000a7565b5050620001ea565b6000620000a2620000b760201b620005741760201c565b905090565b620000b38282620000ef565b5050565b6080516000906001600160a01b03163303620000da575060131936013560601c90565b620000a26200019160201b6200059b1760201c565b6000828152602081815260408083206001600160a01b038516845290915290205460ff16620000b3576000828152602081815260408083206001600160a01b03851684529091529020805460ff191660011790556200014d6200008b565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b3390565b80516001600160a01b0381168114620001ad57600080fd5b919050565b60008060408385031215620001c657600080fd5b620001d18362000195565b9150620001e16020840162000195565b90509250929050565b60805161144162000206600039600061037901526114416000f3fe6080604052600436106100ab5760003560e01c8063572b6c0511610064578063572b6c05146101ce5780637b507371146101ee57806391d148541461020e578063a217fddf1461022e578063bfb56bcd14610243578063d547741f1461026357600080fd5b806301ffc9a7146100b75780630cdac963146100ec578063248a9ca31461011c5780632f2ff15d1461014c57806331f7d9641461016e57806336568abe146101ae57600080fd5b366100b257005b600080fd5b3480156100c357600080fd5b506100d76100d2366004610db3565b610283565b60405190151581526020015b60405180910390f35b3480156100f857600080fd5b5061010e6000805160206113ec83398151915281565b6040519081526020016100e3565b34801561012857600080fd5b5061010e610137366004610ddd565b60009081526020819052604090206001015490565b34801561015857600080fd5b5061016c610167366004610e12565b6102ba565b005b34801561017a57600080fd5b5061019673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee81565b6040516001600160a01b0390911681526020016100e3565b3480156101ba57600080fd5b5061016c6101c9366004610e12565b6102e4565b3480156101da57600080fd5b506100d76101e9366004610e3e565b610377565b3480156101fa57600080fd5b5061016c610209366004610ea5565b6103a9565b34801561021a57600080fd5b506100d7610229366004610e12565b6104f5565b34801561023a57600080fd5b5061010e600081565b34801561024f57600080fd5b5061016c61025e366004610f69565b61051e565b34801561026f57600080fd5b5061016c61027e366004610e12565b61054f565b60006001600160e01b03198216637965db0b60e01b14806102b457506301ffc9a760e01b6001600160e01b03198316145b92915050565b6000828152602081905260409020600101546102d58161059f565b6102df83836105b3565b505050565b6102ec610638565b6001600160a01b0316816001600160a01b0316146103695760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b60648201526084015b60405180910390fd5b6103738282610642565b5050565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0390811691161490565b6000805160206113ec8339815191526103c18161059f565b8786811480156103d057508085145b80156103db57508083145b61043a5760405162461bcd60e51b815260206004820152602a60248201527f466565446973747269627574696f6e3a20506172616d65746572206c656e67746044820152690d040dad2e6dac2e8c6d60b31b6064820152608401610360565b60005b818110156104e8576104e08b8b8381811061045a5761045a611014565b905060200201602081019061046f9190610e3e565b8a8a8481811061048157610481611014565b9050602002810190610493919061102a565b8a8a868181106104a5576104a5611014565b90506020028101906104b7919061102a565b8a8a888181106104c9576104c9611014565b90506020028101906104db919061102a565b6106c5565b60010161043d565b5050505050505050505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b6000805160206113ec8339815191526105368161059f565b610545888888888888886106c5565b5050505050505050565b60008281526020819052604090206001015461056a8161059f565b6102df8383610642565b600061057f33610377565b15610591575060131936013560601c90565b503390565b905090565b3390565b6105b0816105ab610638565b610a74565b50565b6105bd82826104f5565b610373576000828152602081815260408083206001600160a01b03851684529091529020805460ff191660011790556105f4610638565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000610596610574565b61064c82826104f5565b15610373576000828152602081815260408083206001600160a01b03851684529091529020805460ff19169055610681610638565b6001600160a01b0316816001600160a01b0316837ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b60405160405180910390a45050565b808381146107345760405162461bcd60e51b815260206004820152603660248201527f466565446973747269627574696f6e3a20416d6f756e747320616e64207265636044820152750cad2eccae4e640d8cadccee8d040dad2e6dac2e8c6d60531b6064820152608401610360565b8561079a5760405162461bcd60e51b815260206004820152603060248201527f466565446973747269627574696f6e3a205472616e73616374696f6e2068617360448201526f1a195cc8185c99481c995c5d5a5c995960821b6064820152608401610360565b73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeed196001600160a01b0389160161093a5760005b818110156109345760008686838181106107de576107de611014565b90506020020135116108025760405162461bcd60e51b815260040161036090611074565b600084848381811061081657610816611014565b905060200201602081019061082b9190610e3e565b6001600160a01b0316036108515760405162461bcd60e51b8152600401610360906110c2565b600084848381811061086557610865611014565b905060200201602081019061087a9190610e3e565b6001600160a01b031687878481811061089557610895611014565b9050602002013560405160006040518083038185875af1925050503d80600081146108dc576040519150601f19603f3d011682016040523d82523d6000602084013e6108e1565b606091505b505090508061092b5760405162461bcd60e51b815260206004820152601660248201527513985d1a5d99481d1c985b9cd9995c8819985a5b195960521b6044820152606401610360565b506001016107c2565b50610a1f565b60005b81811015610a1d57600086868381811061095957610959611014565b905060200201351161097d5760405162461bcd60e51b815260040161036090611074565b600084848381811061099157610991611014565b90506020020160208101906109a69190610e3e565b6001600160a01b0316036109cc5760405162461bcd60e51b8152600401610360906110c2565b610a15898585848181106109e2576109e2611014565b90506020020160208101906109f79190610e3e565b888885818110610a0957610a09611014565b90506020020135610acd565b60010161093d565b505b876001600160a01b03167f392ff21c7b3a788809afdc550938771fdce9e826f9cd2c532ccd3cfd3cbace32888888888888604051610a62969594939291906111b1565b60405180910390a25050505050505050565b610a7e82826104f5565b61037357610a8b81610bfe565b610a96836020610c10565b604051602001610aa792919061129e565b60408051601f198184030181529082905262461bcd60e51b82526103609160040161130d565b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b1790529151600092839290871691610b299190611340565b6000604051808303816000865af19150503d8060008114610b66576040519150601f19603f3d011682016040523d82523d6000602084013e610b6b565b606091505b5091509150818015610b95575080511580610b95575080806020019051810190610b95919061135c565b610bf75760405162461bcd60e51b815260206004820152602d60248201527f5472616e7366657248656c7065723a3a736166655472616e736665723a20747260448201526c185b9cd9995c8819985a5b1959609a1b6064820152608401610360565b5050505050565b60606102b46001600160a01b03831660145b60606000610c1f836002611394565b610c2a9060026113ab565b67ffffffffffffffff811115610c4257610c426113be565b6040519080825280601f01601f191660200182016040528015610c6c576020820181803683370190505b509050600360fc1b81600081518110610c8757610c87611014565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110610cb657610cb6611014565b60200101906001600160f81b031916908160001a9053506000610cda846002611394565b610ce59060016113ab565b90505b6001811115610d5d576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110610d1957610d19611014565b1a60f81b828281518110610d2f57610d2f611014565b60200101906001600160f81b031916908160001a90535060049490941c93610d56816113d4565b9050610ce8565b508315610dac5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610360565b9392505050565b600060208284031215610dc557600080fd5b81356001600160e01b031981168114610dac57600080fd5b600060208284031215610def57600080fd5b5035919050565b80356001600160a01b0381168114610e0d57600080fd5b919050565b60008060408385031215610e2557600080fd5b82359150610e3560208401610df6565b90509250929050565b600060208284031215610e5057600080fd5b610dac82610df6565b60008083601f840112610e6b57600080fd5b50813567ffffffffffffffff811115610e8357600080fd5b6020830191508360208260051b8501011115610e9e57600080fd5b9250929050565b6000806000806000806000806080898b031215610ec157600080fd5b883567ffffffffffffffff80821115610ed957600080fd5b610ee58c838d01610e59565b909a50985060208b0135915080821115610efe57600080fd5b610f0a8c838d01610e59565b909850965060408b0135915080821115610f2357600080fd5b610f2f8c838d01610e59565b909650945060608b0135915080821115610f4857600080fd5b50610f558b828c01610e59565b999c989b5096995094979396929594505050565b60008060008060008060006080888a031215610f8457600080fd5b610f8d88610df6565b9650602088013567ffffffffffffffff80821115610faa57600080fd5b610fb68b838c01610e59565b909850965060408a0135915080821115610fcf57600080fd5b610fdb8b838c01610e59565b909650945060608a0135915080821115610ff457600080fd5b506110018a828b01610e59565b989b979a50959850939692959293505050565b634e487b7160e01b600052603260045260246000fd5b6000808335601e1984360301811261104157600080fd5b83018035915067ffffffffffffffff82111561105c57600080fd5b6020019150600581901b3603821315610e9e57600080fd5b6020808252602e908201527f466565446973747269627574696f6e3a20416d6f756e74206d7573742062652060408201526d067726561746572207468616e20360941b606082015260800190565b6020808252602d908201527f466565446973747269627574696f6e3a2052656365697665722061646472657360408201526c0732063616e6e6f74206265203609c1b606082015260800190565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b81835260006001600160fb1b0383111561115157600080fd5b8260051b80836020870137939093016020019392505050565b8183526000602080850194508260005b858110156111a6576001600160a01b0361119383610df6565b168752958201959082019060010161117a565b509495945050505050565b6060808252810186905260006080600588901b8301810190830189835b8a81101561124257858403607f190183528135368d9003601e190181126111f457600080fd5b8c01602081810191359067ffffffffffffffff82111561121357600080fd5b81360383131561122257600080fd5b61122d87838561110f565b965094850194939093019250506001016111ce565b5050508281036020840152611258818789611138565b9050828103604084015261126d81858761116a565b9998505050505050505050565b60005b8381101561129557818101518382015260200161127d565b50506000910152565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b8152600083516112d081601785016020880161127a565b7001034b99036b4b9b9b4b733903937b6329607d1b601791840191820152835161130181602884016020880161127a565b01602801949350505050565b602081526000825180602084015261132c81604085016020870161127a565b601f01601f19169190910160400192915050565b6000825161135281846020870161127a565b9190910192915050565b60006020828403121561136e57600080fd5b81518015158114610dac57600080fd5b634e487b7160e01b600052601160045260246000fd5b80820281158282048414176102b4576102b461137e565b808201808211156102b4576102b461137e565b634e487b7160e01b600052604160045260246000fd5b6000816113e3576113e361137e565b50600019019056fe59c7a9ef9a56707d87d116a5d27496afee2604c70b902ac2c4dbdcb68f36f2eaa26469706673582212205f5c6fe2007a6f3fd0583fb014af59cba354c6be293b9b8939685ca942484db964736f6c6343000811003300000000000000000000000004d740d2d93af7417060ec7b35415c81820470d0000000000000000000000000d8253782c45a12053594b9deb72d8e8ab2fca54c
Deployed Bytecode
0x6080604052600436106100ab5760003560e01c8063572b6c0511610064578063572b6c05146101ce5780637b507371146101ee57806391d148541461020e578063a217fddf1461022e578063bfb56bcd14610243578063d547741f1461026357600080fd5b806301ffc9a7146100b75780630cdac963146100ec578063248a9ca31461011c5780632f2ff15d1461014c57806331f7d9641461016e57806336568abe146101ae57600080fd5b366100b257005b600080fd5b3480156100c357600080fd5b506100d76100d2366004610db3565b610283565b60405190151581526020015b60405180910390f35b3480156100f857600080fd5b5061010e6000805160206113ec83398151915281565b6040519081526020016100e3565b34801561012857600080fd5b5061010e610137366004610ddd565b60009081526020819052604090206001015490565b34801561015857600080fd5b5061016c610167366004610e12565b6102ba565b005b34801561017a57600080fd5b5061019673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee81565b6040516001600160a01b0390911681526020016100e3565b3480156101ba57600080fd5b5061016c6101c9366004610e12565b6102e4565b3480156101da57600080fd5b506100d76101e9366004610e3e565b610377565b3480156101fa57600080fd5b5061016c610209366004610ea5565b6103a9565b34801561021a57600080fd5b506100d7610229366004610e12565b6104f5565b34801561023a57600080fd5b5061010e600081565b34801561024f57600080fd5b5061016c61025e366004610f69565b61051e565b34801561026f57600080fd5b5061016c61027e366004610e12565b61054f565b60006001600160e01b03198216637965db0b60e01b14806102b457506301ffc9a760e01b6001600160e01b03198316145b92915050565b6000828152602081905260409020600101546102d58161059f565b6102df83836105b3565b505050565b6102ec610638565b6001600160a01b0316816001600160a01b0316146103695760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b60648201526084015b60405180910390fd5b6103738282610642565b5050565b7f000000000000000000000000d8253782c45a12053594b9deb72d8e8ab2fca54c6001600160a01b0390811691161490565b6000805160206113ec8339815191526103c18161059f565b8786811480156103d057508085145b80156103db57508083145b61043a5760405162461bcd60e51b815260206004820152602a60248201527f466565446973747269627574696f6e3a20506172616d65746572206c656e67746044820152690d040dad2e6dac2e8c6d60b31b6064820152608401610360565b60005b818110156104e8576104e08b8b8381811061045a5761045a611014565b905060200201602081019061046f9190610e3e565b8a8a8481811061048157610481611014565b9050602002810190610493919061102a565b8a8a868181106104a5576104a5611014565b90506020028101906104b7919061102a565b8a8a888181106104c9576104c9611014565b90506020028101906104db919061102a565b6106c5565b60010161043d565b5050505050505050505050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b6000805160206113ec8339815191526105368161059f565b610545888888888888886106c5565b5050505050505050565b60008281526020819052604090206001015461056a8161059f565b6102df8383610642565b600061057f33610377565b15610591575060131936013560601c90565b503390565b905090565b3390565b6105b0816105ab610638565b610a74565b50565b6105bd82826104f5565b610373576000828152602081815260408083206001600160a01b03851684529091529020805460ff191660011790556105f4610638565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000610596610574565b61064c82826104f5565b15610373576000828152602081815260408083206001600160a01b03851684529091529020805460ff19169055610681610638565b6001600160a01b0316816001600160a01b0316837ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b60405160405180910390a45050565b808381146107345760405162461bcd60e51b815260206004820152603660248201527f466565446973747269627574696f6e3a20416d6f756e747320616e64207265636044820152750cad2eccae4e640d8cadccee8d040dad2e6dac2e8c6d60531b6064820152608401610360565b8561079a5760405162461bcd60e51b815260206004820152603060248201527f466565446973747269627574696f6e3a205472616e73616374696f6e2068617360448201526f1a195cc8185c99481c995c5d5a5c995960821b6064820152608401610360565b73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeed196001600160a01b0389160161093a5760005b818110156109345760008686838181106107de576107de611014565b90506020020135116108025760405162461bcd60e51b815260040161036090611074565b600084848381811061081657610816611014565b905060200201602081019061082b9190610e3e565b6001600160a01b0316036108515760405162461bcd60e51b8152600401610360906110c2565b600084848381811061086557610865611014565b905060200201602081019061087a9190610e3e565b6001600160a01b031687878481811061089557610895611014565b9050602002013560405160006040518083038185875af1925050503d80600081146108dc576040519150601f19603f3d011682016040523d82523d6000602084013e6108e1565b606091505b505090508061092b5760405162461bcd60e51b815260206004820152601660248201527513985d1a5d99481d1c985b9cd9995c8819985a5b195960521b6044820152606401610360565b506001016107c2565b50610a1f565b60005b81811015610a1d57600086868381811061095957610959611014565b905060200201351161097d5760405162461bcd60e51b815260040161036090611074565b600084848381811061099157610991611014565b90506020020160208101906109a69190610e3e565b6001600160a01b0316036109cc5760405162461bcd60e51b8152600401610360906110c2565b610a15898585848181106109e2576109e2611014565b90506020020160208101906109f79190610e3e565b888885818110610a0957610a09611014565b90506020020135610acd565b60010161093d565b505b876001600160a01b03167f392ff21c7b3a788809afdc550938771fdce9e826f9cd2c532ccd3cfd3cbace32888888888888604051610a62969594939291906111b1565b60405180910390a25050505050505050565b610a7e82826104f5565b61037357610a8b81610bfe565b610a96836020610c10565b604051602001610aa792919061129e565b60408051601f198184030181529082905262461bcd60e51b82526103609160040161130d565b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b1790529151600092839290871691610b299190611340565b6000604051808303816000865af19150503d8060008114610b66576040519150601f19603f3d011682016040523d82523d6000602084013e610b6b565b606091505b5091509150818015610b95575080511580610b95575080806020019051810190610b95919061135c565b610bf75760405162461bcd60e51b815260206004820152602d60248201527f5472616e7366657248656c7065723a3a736166655472616e736665723a20747260448201526c185b9cd9995c8819985a5b1959609a1b6064820152608401610360565b5050505050565b60606102b46001600160a01b03831660145b60606000610c1f836002611394565b610c2a9060026113ab565b67ffffffffffffffff811115610c4257610c426113be565b6040519080825280601f01601f191660200182016040528015610c6c576020820181803683370190505b509050600360fc1b81600081518110610c8757610c87611014565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110610cb657610cb6611014565b60200101906001600160f81b031916908160001a9053506000610cda846002611394565b610ce59060016113ab565b90505b6001811115610d5d576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110610d1957610d19611014565b1a60f81b828281518110610d2f57610d2f611014565b60200101906001600160f81b031916908160001a90535060049490941c93610d56816113d4565b9050610ce8565b508315610dac5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610360565b9392505050565b600060208284031215610dc557600080fd5b81356001600160e01b031981168114610dac57600080fd5b600060208284031215610def57600080fd5b5035919050565b80356001600160a01b0381168114610e0d57600080fd5b919050565b60008060408385031215610e2557600080fd5b82359150610e3560208401610df6565b90509250929050565b600060208284031215610e5057600080fd5b610dac82610df6565b60008083601f840112610e6b57600080fd5b50813567ffffffffffffffff811115610e8357600080fd5b6020830191508360208260051b8501011115610e9e57600080fd5b9250929050565b6000806000806000806000806080898b031215610ec157600080fd5b883567ffffffffffffffff80821115610ed957600080fd5b610ee58c838d01610e59565b909a50985060208b0135915080821115610efe57600080fd5b610f0a8c838d01610e59565b909850965060408b0135915080821115610f2357600080fd5b610f2f8c838d01610e59565b909650945060608b0135915080821115610f4857600080fd5b50610f558b828c01610e59565b999c989b5096995094979396929594505050565b60008060008060008060006080888a031215610f8457600080fd5b610f8d88610df6565b9650602088013567ffffffffffffffff80821115610faa57600080fd5b610fb68b838c01610e59565b909850965060408a0135915080821115610fcf57600080fd5b610fdb8b838c01610e59565b909650945060608a0135915080821115610ff457600080fd5b506110018a828b01610e59565b989b979a50959850939692959293505050565b634e487b7160e01b600052603260045260246000fd5b6000808335601e1984360301811261104157600080fd5b83018035915067ffffffffffffffff82111561105c57600080fd5b6020019150600581901b3603821315610e9e57600080fd5b6020808252602e908201527f466565446973747269627574696f6e3a20416d6f756e74206d7573742062652060408201526d067726561746572207468616e20360941b606082015260800190565b6020808252602d908201527f466565446973747269627574696f6e3a2052656365697665722061646472657360408201526c0732063616e6e6f74206265203609c1b606082015260800190565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b81835260006001600160fb1b0383111561115157600080fd5b8260051b80836020870137939093016020019392505050565b8183526000602080850194508260005b858110156111a6576001600160a01b0361119383610df6565b168752958201959082019060010161117a565b509495945050505050565b6060808252810186905260006080600588901b8301810190830189835b8a81101561124257858403607f190183528135368d9003601e190181126111f457600080fd5b8c01602081810191359067ffffffffffffffff82111561121357600080fd5b81360383131561122257600080fd5b61122d87838561110f565b965094850194939093019250506001016111ce565b5050508281036020840152611258818789611138565b9050828103604084015261126d81858761116a565b9998505050505050505050565b60005b8381101561129557818101518382015260200161127d565b50506000910152565b76020b1b1b2b9b9a1b7b73a3937b61d1030b1b1b7bab73a1604d1b8152600083516112d081601785016020880161127a565b7001034b99036b4b9b9b4b733903937b6329607d1b601791840191820152835161130181602884016020880161127a565b01602801949350505050565b602081526000825180602084015261132c81604085016020870161127a565b601f01601f19169190910160400192915050565b6000825161135281846020870161127a565b9190910192915050565b60006020828403121561136e57600080fd5b81518015158114610dac57600080fd5b634e487b7160e01b600052601160045260246000fd5b80820281158282048414176102b4576102b461137e565b808201808211156102b4576102b461137e565b634e487b7160e01b600052604160045260246000fd5b6000816113e3576113e361137e565b50600019019056fe59c7a9ef9a56707d87d116a5d27496afee2604c70b902ac2c4dbdcb68f36f2eaa26469706673582212205f5c6fe2007a6f3fd0583fb014af59cba354c6be293b9b8939685ca942484db964736f6c63430008110033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000004d740d2d93af7417060ec7b35415c81820470d0000000000000000000000000d8253782c45a12053594b9deb72d8e8ab2fca54c
-----Decoded View---------------
Arg [0] : feeDistributor (address): 0x04d740D2D93AF7417060Ec7b35415c81820470d0
Arg [1] : trustedForwarder (address): 0xd8253782c45a12053594b9deB72d8e8aB2Fca54c
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 00000000000000000000000004d740d2d93af7417060ec7b35415c81820470d0
Arg [1] : 000000000000000000000000d8253782c45a12053594b9deb72d8e8ab2fca54c
Loading...
Loading
Loading...
Loading
Loading...
Loading
Net Worth in USD
$149.68
Net Worth in ETH
0.052158
Token Allocations
USDC
25.92%
ETH
24.92%
BSC-USD
22.86%
Others
26.30%
Multichain Portfolio | 35 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|---|---|---|---|---|
| BASE | 24.92% | $2,866.72 | 0.013 | $37.3 | |
| BASE | 21.15% | $0.999667 | 31.6742 | $31.66 | |
| BASE | 1.41% | $0.997926 | 2.1204 | $2.12 | |
| BASE | 1.01% | $0.031109 | 48.6048 | $1.51 | |
| BASE | 0.95% | $0.131788 | 10.7947 | $1.42 | |
| BASE | 0.77% | $0.793344 | 1.4527 | $1.15 | |
| BASE | 0.74% | $2,868.39 | 0.00038643 | $1.11 | |
| BASE | 0.64% | $0.999507 | 0.959 | $0.9585 | |
| BASE | 0.30% | $0.001015 | 441.0701 | $0.4478 | |
| BASE | 0.28% | $0.452842 | 0.9289 | $0.4206 | |
| BASE | 0.17% | $0.029836 | 8.314 | $0.248 | |
| BSC | 22.86% | $0.99887 | 34.2499 | $34.21 | |
| BSC | 17.31% | $870.44 | 0.0298 | $25.9 | |
| BSC | 4.77% | $0.999815 | 7.1386 | $7.14 | |
| BSC | 1.21% | $0.131553 | 13.767 | $1.81 | |
| BSC | 0.70% | $11.8 | 0.0894 | $1.06 | |
| BSC | 0.60% | $1.87 | 0.4801 | $0.8978 | |
| BSC | 0.21% | $0.010185 | 31.0227 | $0.3159 |
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.