Overview
ETH Balance
ETH Value
$0.00Latest 9 from a total of 9 transactions
| Transaction Hash |
|
Block
|
From
|
To
|
|||||
|---|---|---|---|---|---|---|---|---|---|
| Pause | 28275816 | 120 days ago | IN | 0 ETH | 0.0000007 | ||||
| Pause | 26039382 | 146 days ago | IN | 0 ETH | 0.0000007 | ||||
| Pause | 19851041 | 218 days ago | IN | 0 ETH | 0.00000078 | ||||
| Renounce Role | 9226093 | 341 days ago | IN | 0 ETH | 0.00000005 | ||||
| Grant Role | 9226090 | 341 days ago | IN | 0 ETH | 0.00000012 | ||||
| Grant Role | 8542351 | 349 days ago | IN | 0 ETH | 0.00000146 | ||||
| Grant Role | 8542348 | 349 days ago | IN | 0 ETH | 0.00000143 | ||||
| Grant Role | 8542346 | 349 days ago | IN | 0 ETH | 0.00000154 | ||||
| Grant Role | 8542343 | 349 days ago | IN | 0 ETH | 0.00000156 |
Latest 3 internal transactions
| Parent Transaction Hash | Block | From | To | |||
|---|---|---|---|---|---|---|
| 28275816 | 120 days ago | Contract Creation | 0 ETH | |||
| 26039382 | 146 days ago | Contract Creation | 0 ETH | |||
| 19851041 | 218 days ago | Contract Creation | 0 ETH |
Cross-Chain Transactions
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-2.0-or-later
pragma solidity ^0.8.0;
import {AccessControlEnumerable} from "openzeppelin-contracts/access/extensions/AccessControlEnumerable.sol";
import {GenericFactory} from "evk/GenericFactory/GenericFactory.sol";
import {RevertBytes} from "evk/EVault/shared/lib/RevertBytes.sol";
import {ReadOnlyProxy} from "./ReadOnlyProxy.sol";
/// @title FactoryGovernor
/// @custom:security-contact [email protected]
/// @author Euler Labs (https://www.eulerlabs.com/)
/// @notice Governor for the EVK beacon (factory), allowing pause guardians to upgrade the implementation to read only
/// proxy
contract FactoryGovernor is AccessControlEnumerable {
/// @notice Role identifier for the pause guardian role.
bytes32 public constant PAUSE_GUARDIAN_ROLE = keccak256("PAUSE_GUARDIAN_ROLE");
/// @notice Role identifier for admin allowed to unpause the factory.
bytes32 public constant UNPAUSE_ADMIN_ROLE = keccak256("UNPAUSE_ADMIN_ROLE");
/// @dev Address of the read only proxy deployed during the latest pause
address internal latestReadOnlyProxy;
/// @notice Event emitted when an admin call is made to a factory.
/// @param admin The address of the admin making the call.
/// @param factory The address of the factory being called.
/// @param data The calldata of the admin call.
event AdminCall(address indexed admin, address indexed factory, bytes data);
/// @notice Event emitted when a factory is paused.
/// @param guardian The address of the guardian who paused the factory.
/// @param factory The address of the factory that was paused.
/// @param roProxy The address of the read-only proxy which was installed.
event Paused(address indexed guardian, address indexed factory, address indexed roProxy);
/// @notice Event emitted when a factory is unpaused.
/// @param admin The address of the unpause admin who unpaused the factory.
/// @param factory The address of the factory that was unpaused.
/// @param implementation The address of the implementation which was restored.
event Unpaused(address indexed admin, address indexed factory, address indexed implementation);
/// @notice Constructor to set the initial admin of the contract.
/// @param admin The address of the initial admin.
constructor(address admin) {
_grantRole(DEFAULT_ADMIN_ROLE, admin);
}
/// @notice Executes a call to a specified factory.
/// @param factory The address of the factory to call.
/// @param data The calldata to be called on the factory.
/// @return Return data of the factory call.
function adminCall(address factory, bytes calldata data)
external
onlyRole(DEFAULT_ADMIN_ROLE)
returns (bytes memory)
{
(bool success, bytes memory result) = factory.call(data);
if (!success) RevertBytes.revertBytes(result);
emit AdminCall(_msgSender(), factory, data);
return result;
}
/// @notice Pauses all upgradeable vaults by installing a new implementation,
/// which is a read only proxy to the current implementation
/// @param factory Address of the factory to pause.
function pause(address factory) external onlyRole(PAUSE_GUARDIAN_ROLE) {
address oldImplementation = GenericFactory(factory).implementation();
// To prevent pausing twice, check if the factory implementation is already the latest read-only proxy.
// Only checking the latest pause, assuming the admin will not upgrade implementation to a previous proxy.
if (oldImplementation == latestReadOnlyProxy) {
revert("already paused");
} else {
address readOnlyProxy = address(new ReadOnlyProxy(oldImplementation));
GenericFactory(factory).setImplementation(readOnlyProxy);
latestReadOnlyProxy = readOnlyProxy;
emit Paused(_msgSender(), factory, readOnlyProxy);
}
}
/// @notice Unpauses all upgradeable vaults by installing the previous implementation,
/// stored in the read only proxy
/// @param factory Address of the factory to unpause.
function unpause(address factory) external onlyRole(UNPAUSE_ADMIN_ROLE) {
address implementation = GenericFactory(factory).implementation();
if (implementation == latestReadOnlyProxy) {
address previousImplementation = ReadOnlyProxy(implementation).roProxyImplementation();
GenericFactory(factory).setImplementation(previousImplementation);
emit Unpaused(_msgSender(), factory, previousImplementation);
} else {
revert("not paused");
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (access/extensions/AccessControlEnumerable.sol)
pragma solidity ^0.8.20;
import {IAccessControlEnumerable} from "./IAccessControlEnumerable.sol";
import {AccessControl} from "../AccessControl.sol";
import {EnumerableSet} from "../../utils/structs/EnumerableSet.sol";
/**
* @dev Extension of {AccessControl} that allows enumerating the members of each role.
*/
abstract contract AccessControlEnumerable is IAccessControlEnumerable, AccessControl {
using EnumerableSet for EnumerableSet.AddressSet;
mapping(bytes32 role => EnumerableSet.AddressSet) private _roleMembers;
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IAccessControlEnumerable).interfaceId || super.supportsInterface(interfaceId);
}
/**
* @dev Returns one of the accounts that have `role`. `index` must be a
* value between 0 and {getRoleMemberCount}, non-inclusive.
*
* Role bearers are not sorted in any particular way, and their ordering may
* change at any point.
*
* WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure
* you perform all queries on the same block. See the following
* https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post]
* for more information.
*/
function getRoleMember(bytes32 role, uint256 index) public view virtual returns (address) {
return _roleMembers[role].at(index);
}
/**
* @dev Returns the number of accounts that have `role`. Can be used
* together with {getRoleMember} to enumerate all bearers of a role.
*/
function getRoleMemberCount(bytes32 role) public view virtual returns (uint256) {
return _roleMembers[role].length();
}
/**
* @dev Return all accounts that have `role`
*
* WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
* to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
* this function has an unbounded cost, and using it as part of a state-changing function may render the function
* uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
*/
function getRoleMembers(bytes32 role) public view virtual returns (address[] memory) {
return _roleMembers[role].values();
}
/**
* @dev Overload {AccessControl-_grantRole} to track enumerable memberships
*/
function _grantRole(bytes32 role, address account) internal virtual override returns (bool) {
bool granted = super._grantRole(role, account);
if (granted) {
_roleMembers[role].add(account);
}
return granted;
}
/**
* @dev Overload {AccessControl-_revokeRole} to track enumerable memberships
*/
function _revokeRole(bytes32 role, address account) internal virtual override returns (bool) {
bool revoked = super._revokeRole(role, account);
if (revoked) {
_roleMembers[role].remove(account);
}
return revoked;
}
}// SPDX-License-Identifier: GPL-2.0-or-later
pragma solidity ^0.8.0;
import {BeaconProxy} from "./BeaconProxy.sol";
import {MetaProxyDeployer} from "./MetaProxyDeployer.sol";
/// @title IComponent
/// @notice Minimal interface which must be implemented by the contract deployed by the factory
interface IComponent {
/// @notice Function replacing the constructor in proxied contracts
/// @param creator The new contract's creator address
function initialize(address creator) external;
}
/// @title GenericFactory
/// @custom:security-contact [email protected]
/// @author Euler Labs (https://www.eulerlabs.com/)
/// @notice The factory allows permissionless creation of upgradeable or non-upgradeable proxy contracts and serves as a
/// beacon for the upgradeable ones
contract GenericFactory is MetaProxyDeployer {
// Constants
uint256 internal constant REENTRANCYLOCK__UNLOCKED = 1;
uint256 internal constant REENTRANCYLOCK__LOCKED = 2;
// State
/// @title ProxyConfig
/// @notice This struct is used to store the configuration of a proxy deployed by the factory
struct ProxyConfig {
// If true, proxy is an instance of the BeaconProxy
bool upgradeable;
// Address of the implementation contract
// May be an out-of-date value, if upgradeable (handled by getProxyConfig)
address implementation;
// The metadata attached to every call passing through the proxy
bytes trailingData;
}
uint256 private reentrancyLock;
/// @notice Address of the account authorized to upgrade the implementation contract
address public upgradeAdmin;
/// @notice Address of the implementation contract, which the deployed proxies will delegate-call to
/// @dev The contract must implement the `IComponent` interface
address public implementation;
/// @notice A lookup for configurations of the proxy contracts deployed by the factory
mapping(address proxy => ProxyConfig) internal proxyLookup;
/// @notice An array of addresses of all the proxies deployed by the factory
address[] public proxyList;
// Events
/// @notice The factory is created
event Genesis();
/// @notice A new proxy is created
/// @param proxy Address of the new proxy
/// @param upgradeable If true, proxy is an instance of the BeaconProxy. If false, the proxy is a minimal meta proxy
/// @param implementation Address of the implementation contract, at the time the proxy was deployed
/// @param trailingData The metadata that will be attached to every call passing through the proxy
event ProxyCreated(address indexed proxy, bool upgradeable, address implementation, bytes trailingData);
/// @notice Set a new implementation contract. All the BeaconProxies are upgraded to the new logic
/// @param newImplementation Address of the new implementation contract
event SetImplementation(address indexed newImplementation);
/// @notice Set a new upgrade admin
/// @param newUpgradeAdmin Address of the new admin
event SetUpgradeAdmin(address indexed newUpgradeAdmin);
// Errors
error E_Reentrancy();
error E_Unauthorized();
error E_Implementation();
error E_BadAddress();
error E_BadQuery();
// Modifiers
modifier nonReentrant() {
if (reentrancyLock == REENTRANCYLOCK__LOCKED) revert E_Reentrancy();
reentrancyLock = REENTRANCYLOCK__LOCKED;
_;
reentrancyLock = REENTRANCYLOCK__UNLOCKED;
}
modifier adminOnly() {
if (msg.sender != upgradeAdmin) revert E_Unauthorized();
_;
}
constructor(address admin) {
emit Genesis();
if (admin == address(0)) revert E_BadAddress();
reentrancyLock = REENTRANCYLOCK__UNLOCKED;
upgradeAdmin = admin;
emit SetUpgradeAdmin(admin);
}
/// @notice A permissionless funtion to deploy new proxies
/// @param desiredImplementation Address of the implementation contract expected to be registered in the factory
/// during proxy creation
/// @param upgradeable If true, the proxy will be an instance of the BeaconProxy. If false, a minimal meta proxy
/// will be deployed
/// @param trailingData Metadata to be attached to every call passing through the new proxy
/// @return The address of the new proxy
/// @dev The desired implementation serves as a protection against (unintentional) front-running of upgrades
function createProxy(address desiredImplementation, bool upgradeable, bytes memory trailingData)
external
nonReentrant
returns (address)
{
address _implementation = implementation;
if (desiredImplementation == address(0)) desiredImplementation = _implementation;
if (desiredImplementation == address(0) || desiredImplementation != _implementation) revert E_Implementation();
// The provided trailing data is prefixed with 4 zero bytes to avoid potential selector clashing in case the
// proxy is called with empty calldata.
bytes memory prefixTrailingData = abi.encodePacked(bytes4(0), trailingData);
address proxy;
if (upgradeable) {
proxy = address(new BeaconProxy(prefixTrailingData));
} else {
proxy = deployMetaProxy(desiredImplementation, prefixTrailingData);
}
proxyLookup[proxy] =
ProxyConfig({upgradeable: upgradeable, implementation: desiredImplementation, trailingData: trailingData});
proxyList.push(proxy);
IComponent(proxy).initialize(msg.sender);
emit ProxyCreated(proxy, upgradeable, desiredImplementation, trailingData);
return proxy;
}
// EVault beacon upgrade
/// @notice Set a new implementation contract
/// @param newImplementation Address of the new implementation contract
/// @dev Upgrades all existing BeaconProxies to the new logic immediately
function setImplementation(address newImplementation) external nonReentrant adminOnly {
if (newImplementation.code.length == 0) revert E_BadAddress();
implementation = newImplementation;
emit SetImplementation(newImplementation);
}
// Admin role
/// @notice Transfer admin rights to a new address
/// @param newUpgradeAdmin Address of the new admin
/// @dev For creating non upgradeable factories, or to finalize all upgradeable proxies to current implementation,
/// @dev set the admin to zero address.
/// @dev If setting to address zero, make sure the implementation contract is already set
function setUpgradeAdmin(address newUpgradeAdmin) external nonReentrant adminOnly {
upgradeAdmin = newUpgradeAdmin;
emit SetUpgradeAdmin(newUpgradeAdmin);
}
// Proxy getters
/// @notice Get current proxy configuration
/// @param proxy Address of the proxy to query
/// @return config The proxy's configuration, including current implementation
function getProxyConfig(address proxy) external view returns (ProxyConfig memory config) {
config = proxyLookup[proxy];
if (config.upgradeable) config.implementation = implementation;
}
/// @notice Check if an address is a proxy deployed with this factory
/// @param proxy Address to check
/// @return True if the address is a proxy
function isProxy(address proxy) external view returns (bool) {
return proxyLookup[proxy].implementation != address(0);
}
/// @notice Fetch the length of the deployed proxies list
/// @return The length of the proxy list array
function getProxyListLength() external view returns (uint256) {
return proxyList.length;
}
/// @notice Get a slice of the deployed proxies array
/// @param start Start index of the slice
/// @param end End index of the slice
/// @return list An array containing the slice of the proxy list
function getProxyListSlice(uint256 start, uint256 end) external view returns (address[] memory list) {
if (end == type(uint256).max) end = proxyList.length;
if (end < start || end > proxyList.length) revert E_BadQuery();
list = new address[](end - start);
for (uint256 i; i < end - start; ++i) {
list[i] = proxyList[start + i];
}
}
}// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.0; import "../Errors.sol"; /// @title RevertBytes Library /// @custom:security-contact [email protected] /// @author Euler Labs (https://www.eulerlabs.com/) /// @notice The library provides a helper function for bubbling up errors library RevertBytes { function revertBytes(bytes memory errMsg) internal pure { if (errMsg.length > 0) { assembly { revert(add(32, errMsg), mload(errMsg)) } } revert Errors.E_EmptyError(); } }
// SPDX-License-Identifier: GPL-2.0-or-later
pragma solidity ^0.8.0;
import {RevertBytes} from "evk/EVault/shared/lib/RevertBytes.sol";
/// @title ReadOnlyProxy
/// @custom:security-contact [email protected]
/// @author Euler Labs (https://www.eulerlabs.com/)
/// @notice This contract is read-only proxy to the configured implementation contract
contract ReadOnlyProxy {
address internal immutable implementation;
/// @notice Constructor to set the implementation address to proxy to
/// @param _implementation Old implementation contract to proxy to
constructor(address _implementation) {
implementation = _implementation;
}
/// @dev Callable only by fallback, delegate calls original payload in a static frame,
/// which means any state mutation will cause a revert
/// @dev It should be ensured that the function signature has no collision with the target contract
function roProxyDelegateView(bytes memory payload) external returns (bytes memory) {
require(msg.sender == address(this), "unauthorized");
(bool success, bytes memory data) = implementation.delegatecall(payload);
if (!success) {
// assume the empty error is a result of state mutation in a static call
if (data.length == 0) revert("contract is in read-only mode");
else RevertBytes.revertBytes(data);
}
assembly {
return(add(32, data), mload(data))
}
}
/// @dev Fallback function forwards the calldata in a staticcall frame to `proxyDelegateView` which in turn
/// delegate calls into the proxied implementation, with guarantee that any state mutation will revert the tx
fallback() external {
(bool success, bytes memory data) =
address(this).staticcall(abi.encodeCall(this.roProxyDelegateView, (msg.data)));
if (!success) RevertBytes.revertBytes(data);
assembly {
return(add(32, data), mload(data))
}
}
/// @notice retrieve the implementation contract to which calls are forwarded
/// @dev It should be ensured that the function signature has no collision with the target contract
function roProxyImplementation() external view returns (address) {
return implementation;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (access/extensions/IAccessControlEnumerable.sol)
pragma solidity ^0.8.20;
import {IAccessControl} from "../IAccessControl.sol";
/**
* @dev External interface of AccessControlEnumerable declared to support ERC-165 detection.
*/
interface IAccessControlEnumerable is IAccessControl {
/**
* @dev Returns one of the accounts that have `role`. `index` must be a
* value between 0 and {getRoleMemberCount}, non-inclusive.
*
* Role bearers are not sorted in any particular way, and their ordering may
* change at any point.
*
* WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure
* you perform all queries on the same block. See the following
* https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post]
* for more information.
*/
function getRoleMember(bytes32 role, uint256 index) external view returns (address);
/**
* @dev Returns the number of accounts that have `role`. Can be used
* together with {getRoleMember} to enumerate all bearers of a role.
*/
function getRoleMemberCount(bytes32 role) external view returns (uint256);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (access/AccessControl.sol)
pragma solidity ^0.8.20;
import {IAccessControl} from "./IAccessControl.sol";
import {Context} from "../utils/Context.sol";
import {ERC165} from "../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:
*
* ```solidity
* 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}:
*
* ```solidity
* 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. We recommend using {AccessControlDefaultAdminRules}
* to enforce additional security measures for this role.
*/
abstract contract AccessControl is Context, IAccessControl, ERC165 {
struct RoleData {
mapping(address account => bool) hasRole;
bytes32 adminRole;
}
mapping(bytes32 role => RoleData) private _roles;
bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;
/**
* @dev Modifier that checks that an account has a specific role. Reverts
* with an {AccessControlUnauthorizedAccount} error including the required role.
*/
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 returns (bool) {
return _roles[role].hasRole[account];
}
/**
* @dev Reverts with an {AccessControlUnauthorizedAccount} error if `_msgSender()`
* is missing `role`. Overriding this function changes the behavior of the {onlyRole} modifier.
*/
function _checkRole(bytes32 role) internal view virtual {
_checkRole(role, _msgSender());
}
/**
* @dev Reverts with an {AccessControlUnauthorizedAccount} error if `account`
* is missing `role`.
*/
function _checkRole(bytes32 role, address account) internal view virtual {
if (!hasRole(role, account)) {
revert AccessControlUnauthorizedAccount(account, role);
}
}
/**
* @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 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 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 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 `callerConfirmation`.
*
* May emit a {RoleRevoked} event.
*/
function renounceRole(bytes32 role, address callerConfirmation) public virtual {
if (callerConfirmation != _msgSender()) {
revert AccessControlBadConfirmation();
}
_revokeRole(role, callerConfirmation);
}
/**
* @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 Attempts to grant `role` to `account` and returns a boolean indicating if `role` was granted.
*
* Internal function without access restriction.
*
* May emit a {RoleGranted} event.
*/
function _grantRole(bytes32 role, address account) internal virtual returns (bool) {
if (!hasRole(role, account)) {
_roles[role].hasRole[account] = true;
emit RoleGranted(role, account, _msgSender());
return true;
} else {
return false;
}
}
/**
* @dev Attempts to revoke `role` to `account` and returns a boolean indicating if `role` was revoked.
*
* Internal function without access restriction.
*
* May emit a {RoleRevoked} event.
*/
function _revokeRole(bytes32 role, address account) internal virtual returns (bool) {
if (hasRole(role, account)) {
_roles[role].hasRole[account] = false;
emit RoleRevoked(role, account, _msgSender());
return true;
} else {
return false;
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (utils/structs/EnumerableSet.sol)
// This file was procedurally generated from scripts/generate/templates/EnumerableSet.js.
pragma solidity ^0.8.20;
/**
* @dev Library for managing
* https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
* types.
*
* Sets have the following properties:
*
* - Elements are added, removed, and checked for existence in constant time
* (O(1)).
* - Elements are enumerated in O(n). No guarantees are made on the ordering.
*
* ```solidity
* contract Example {
* // Add the library methods
* using EnumerableSet for EnumerableSet.AddressSet;
*
* // Declare a set state variable
* EnumerableSet.AddressSet private mySet;
* }
* ```
*
* As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
* and `uint256` (`UintSet`) are supported.
*
* [WARNING]
* ====
* Trying to delete such a structure from storage will likely result in data corruption, rendering the structure
* unusable.
* See https://github.com/ethereum/solidity/pull/11843[ethereum/solidity#11843] for more info.
*
* In order to clean an EnumerableSet, you can either remove all elements one by one or create a fresh instance using an
* array of EnumerableSet.
* ====
*/
library EnumerableSet {
// To implement this library for multiple types with as little code
// repetition as possible, we write it in terms of a generic Set type with
// bytes32 values.
// The Set implementation uses private functions, and user-facing
// implementations (such as AddressSet) are just wrappers around the
// underlying Set.
// This means that we can only create new EnumerableSets for types that fit
// in bytes32.
struct Set {
// Storage of set values
bytes32[] _values;
// Position is the index of the value in the `values` array plus 1.
// Position 0 is used to mean a value is not in the set.
mapping(bytes32 value => uint256) _positions;
}
/**
* @dev Add a value to a set. O(1).
*
* Returns true if the value was added to the set, that is if it was not
* already present.
*/
function _add(Set storage set, bytes32 value) private returns (bool) {
if (!_contains(set, value)) {
set._values.push(value);
// The value is stored at length-1, but we add 1 to all indexes
// and use 0 as a sentinel value
set._positions[value] = set._values.length;
return true;
} else {
return false;
}
}
/**
* @dev Removes a value from a set. O(1).
*
* Returns true if the value was removed from the set, that is if it was
* present.
*/
function _remove(Set storage set, bytes32 value) private returns (bool) {
// We cache the value's position to prevent multiple reads from the same storage slot
uint256 position = set._positions[value];
if (position != 0) {
// Equivalent to contains(set, value)
// To delete an element from the _values array in O(1), we swap the element to delete with the last one in
// the array, and then remove the last element (sometimes called as 'swap and pop').
// This modifies the order of the array, as noted in {at}.
uint256 valueIndex = position - 1;
uint256 lastIndex = set._values.length - 1;
if (valueIndex != lastIndex) {
bytes32 lastValue = set._values[lastIndex];
// Move the lastValue to the index where the value to delete is
set._values[valueIndex] = lastValue;
// Update the tracked position of the lastValue (that was just moved)
set._positions[lastValue] = position;
}
// Delete the slot where the moved value was stored
set._values.pop();
// Delete the tracked position for the deleted slot
delete set._positions[value];
return true;
} else {
return false;
}
}
/**
* @dev Returns true if the value is in the set. O(1).
*/
function _contains(Set storage set, bytes32 value) private view returns (bool) {
return set._positions[value] != 0;
}
/**
* @dev Returns the number of values on the set. O(1).
*/
function _length(Set storage set) private view returns (uint256) {
return set._values.length;
}
/**
* @dev Returns the value stored at position `index` in the set. O(1).
*
* Note that there are no guarantees on the ordering of values inside the
* array, and it may change when more values are added or removed.
*
* Requirements:
*
* - `index` must be strictly less than {length}.
*/
function _at(Set storage set, uint256 index) private view returns (bytes32) {
return set._values[index];
}
/**
* @dev Return the entire set in an array
*
* WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
* to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
* this function has an unbounded cost, and using it as part of a state-changing function may render the function
* uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
*/
function _values(Set storage set) private view returns (bytes32[] memory) {
return set._values;
}
// Bytes32Set
struct Bytes32Set {
Set _inner;
}
/**
* @dev Add a value to a set. O(1).
*
* Returns true if the value was added to the set, that is if it was not
* already present.
*/
function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
return _add(set._inner, value);
}
/**
* @dev Removes a value from a set. O(1).
*
* Returns true if the value was removed from the set, that is if it was
* present.
*/
function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
return _remove(set._inner, value);
}
/**
* @dev Returns true if the value is in the set. O(1).
*/
function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
return _contains(set._inner, value);
}
/**
* @dev Returns the number of values in the set. O(1).
*/
function length(Bytes32Set storage set) internal view returns (uint256) {
return _length(set._inner);
}
/**
* @dev Returns the value stored at position `index` in the set. O(1).
*
* Note that there are no guarantees on the ordering of values inside the
* array, and it may change when more values are added or removed.
*
* Requirements:
*
* - `index` must be strictly less than {length}.
*/
function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
return _at(set._inner, index);
}
/**
* @dev Return the entire set in an array
*
* WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
* to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
* this function has an unbounded cost, and using it as part of a state-changing function may render the function
* uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
*/
function values(Bytes32Set storage set) internal view returns (bytes32[] memory) {
bytes32[] memory store = _values(set._inner);
bytes32[] memory result;
assembly ("memory-safe") {
result := store
}
return result;
}
// AddressSet
struct AddressSet {
Set _inner;
}
/**
* @dev Add a value to a set. O(1).
*
* Returns true if the value was added to the set, that is if it was not
* already present.
*/
function add(AddressSet storage set, address value) internal returns (bool) {
return _add(set._inner, bytes32(uint256(uint160(value))));
}
/**
* @dev Removes a value from a set. O(1).
*
* Returns true if the value was removed from the set, that is if it was
* present.
*/
function remove(AddressSet storage set, address value) internal returns (bool) {
return _remove(set._inner, bytes32(uint256(uint160(value))));
}
/**
* @dev Returns true if the value is in the set. O(1).
*/
function contains(AddressSet storage set, address value) internal view returns (bool) {
return _contains(set._inner, bytes32(uint256(uint160(value))));
}
/**
* @dev Returns the number of values in the set. O(1).
*/
function length(AddressSet storage set) internal view returns (uint256) {
return _length(set._inner);
}
/**
* @dev Returns the value stored at position `index` in the set. O(1).
*
* Note that there are no guarantees on the ordering of values inside the
* array, and it may change when more values are added or removed.
*
* Requirements:
*
* - `index` must be strictly less than {length}.
*/
function at(AddressSet storage set, uint256 index) internal view returns (address) {
return address(uint160(uint256(_at(set._inner, index))));
}
/**
* @dev Return the entire set in an array
*
* WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
* to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
* this function has an unbounded cost, and using it as part of a state-changing function may render the function
* uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
*/
function values(AddressSet storage set) internal view returns (address[] memory) {
bytes32[] memory store = _values(set._inner);
address[] memory result;
assembly ("memory-safe") {
result := store
}
return result;
}
// UintSet
struct UintSet {
Set _inner;
}
/**
* @dev Add a value to a set. O(1).
*
* Returns true if the value was added to the set, that is if it was not
* already present.
*/
function add(UintSet storage set, uint256 value) internal returns (bool) {
return _add(set._inner, bytes32(value));
}
/**
* @dev Removes a value from a set. O(1).
*
* Returns true if the value was removed from the set, that is if it was
* present.
*/
function remove(UintSet storage set, uint256 value) internal returns (bool) {
return _remove(set._inner, bytes32(value));
}
/**
* @dev Returns true if the value is in the set. O(1).
*/
function contains(UintSet storage set, uint256 value) internal view returns (bool) {
return _contains(set._inner, bytes32(value));
}
/**
* @dev Returns the number of values in the set. O(1).
*/
function length(UintSet storage set) internal view returns (uint256) {
return _length(set._inner);
}
/**
* @dev Returns the value stored at position `index` in the set. O(1).
*
* Note that there are no guarantees on the ordering of values inside the
* array, and it may change when more values are added or removed.
*
* Requirements:
*
* - `index` must be strictly less than {length}.
*/
function at(UintSet storage set, uint256 index) internal view returns (uint256) {
return uint256(_at(set._inner, index));
}
/**
* @dev Return the entire set in an array
*
* WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
* to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
* this function has an unbounded cost, and using it as part of a state-changing function may render the function
* uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
*/
function values(UintSet storage set) internal view returns (uint256[] memory) {
bytes32[] memory store = _values(set._inner);
uint256[] memory result;
assembly ("memory-safe") {
result := store
}
return result;
}
}// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.0; /// @title BeaconProxy /// @custom:security-contact [email protected] /// @author Euler Labs (https://www.eulerlabs.com/) /// @notice A proxy contract, forwarding all calls to an implementation contract, fetched from a beacon /// @dev The proxy attaches up to 128 bytes of metadata to the delegated call data. contract BeaconProxy { // ERC-1967 beacon address slot. bytes32(uint256(keccak256('eip1967.proxy.beacon')) - 1) bytes32 internal constant BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50; // Beacon implementation() selector bytes32 internal constant IMPLEMENTATION_SELECTOR = 0x5c60da1b00000000000000000000000000000000000000000000000000000000; // Max trailing data length, 4 immutable slots uint256 internal constant MAX_TRAILING_DATA_LENGTH = 128; address internal immutable beacon; uint256 internal immutable metadataLength; bytes32 internal immutable metadata0; bytes32 internal immutable metadata1; bytes32 internal immutable metadata2; bytes32 internal immutable metadata3; event Genesis(); constructor(bytes memory trailingData) { emit Genesis(); require(trailingData.length <= MAX_TRAILING_DATA_LENGTH, "trailing data too long"); // Beacon is always the proxy creator; store it in immutable beacon = msg.sender; // Store the beacon address in ERC-1967 slot for compatibility with block explorers assembly { sstore(BEACON_SLOT, caller()) } // Record length as immutable metadataLength = trailingData.length; // Pad length with uninitialized memory so the decode will succeed assembly { mstore(trailingData, MAX_TRAILING_DATA_LENGTH) } (metadata0, metadata1, metadata2, metadata3) = abi.decode(trailingData, (bytes32, bytes32, bytes32, bytes32)); } fallback() external payable { address beacon_ = beacon; uint256 metadataLength_ = metadataLength; bytes32 metadata0_ = metadata0; bytes32 metadata1_ = metadata1; bytes32 metadata2_ = metadata2; bytes32 metadata3_ = metadata3; assembly { // Fetch implementation address from the beacon mstore(0, IMPLEMENTATION_SELECTOR) // Implementation call is trusted not to revert and to return an address let result := staticcall(gas(), beacon_, 0, 4, 0, 32) let implementation := mload(0) // delegatecall to the implementation with trailing metadata calldatacopy(0, 0, calldatasize()) mstore(calldatasize(), metadata0_) mstore(add(32, calldatasize()), metadata1_) mstore(add(64, calldatasize()), metadata2_) mstore(add(96, calldatasize()), metadata3_) result := delegatecall(gas(), implementation, 0, add(metadataLength_, calldatasize()), 0, 0) returndatacopy(0, 0, returndatasize()) switch result case 0 { revert(0, returndatasize()) } default { return(0, returndatasize()) } } } }
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.0; /// @title MetaProxyDeployer /// @custom:security-contact [email protected] /// @author Euler Labs (https://www.eulerlabs.com/) /// @notice Contract for deploying minimal proxies with metadata, based on EIP-3448. /// @dev The metadata of the proxies does not include the data length as defined by EIP-3448, saving gas at a cost of /// supporting variable size data. contract MetaProxyDeployer { error E_DeploymentFailed(); // Meta proxy bytecode from EIP-3488 https://eips.ethereum.org/EIPS/eip-3448 bytes constant BYTECODE_HEAD = hex"600b380380600b3d393df3363d3d373d3d3d3d60368038038091363936013d73"; bytes constant BYTECODE_TAIL = hex"5af43d3d93803e603457fd5bf3"; /// @dev Creates a proxy for `targetContract` with metadata from `metadata`. /// @return addr A non-zero address if successful. function deployMetaProxy(address targetContract, bytes memory metadata) internal returns (address addr) { bytes memory code = abi.encodePacked(BYTECODE_HEAD, targetContract, BYTECODE_TAIL, metadata); assembly ("memory-safe") { addr := create(0, add(code, 32), mload(code)) } if (addr == address(0)) revert E_DeploymentFailed(); } }
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.0; /// @title Errors /// @custom:security-contact [email protected] /// @author Euler Labs (https://www.eulerlabs.com/) /// @notice Contract implementing EVault's custom errors contract Errors { error E_Initialized(); error E_ProxyMetadata(); error E_SelfTransfer(); error E_InsufficientAllowance(); error E_InsufficientCash(); error E_InsufficientAssets(); error E_InsufficientBalance(); error E_InsufficientDebt(); error E_FlashLoanNotRepaid(); error E_Reentrancy(); error E_OperationDisabled(); error E_OutstandingDebt(); error E_AmountTooLargeToEncode(); error E_DebtAmountTooLargeToEncode(); error E_RepayTooMuch(); error E_TransientState(); error E_SelfLiquidation(); error E_ControllerDisabled(); error E_CollateralDisabled(); error E_ViolatorLiquidityDeferred(); error E_LiquidationCoolOff(); error E_ExcessiveRepayAmount(); error E_MinYield(); error E_BadAddress(); error E_ZeroAssets(); error E_ZeroShares(); error E_Unauthorized(); error E_CheckUnauthorized(); error E_NotSupported(); error E_EmptyError(); error E_BadBorrowCap(); error E_BadSupplyCap(); error E_BadCollateral(); error E_AccountLiquidity(); error E_NoLiability(); error E_NotController(); error E_BadFee(); error E_SupplyCapExceeded(); error E_BorrowCapExceeded(); error E_InvalidLTVAsset(); error E_NoPriceOracle(); error E_ConfigAmountTooLargeToEncode(); error E_BadAssetReceiver(); error E_BadSharesOwner(); error E_BadSharesReceiver(); error E_BadMaxLiquidationDiscount(); error E_LTVBorrow(); error E_LTVLiquidation(); error E_NotHookTarget(); }
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (access/IAccessControl.sol)
pragma solidity ^0.8.20;
/**
* @dev External interface of AccessControl declared to support ERC-165 detection.
*/
interface IAccessControl {
/**
* @dev The `account` is missing a role.
*/
error AccessControlUnauthorizedAccount(address account, bytes32 neededRole);
/**
* @dev The caller of a function is not the expected one.
*
* NOTE: Don't confuse with {AccessControlUnauthorizedAccount}.
*/
error AccessControlBadConfirmation();
/**
* @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.
*/
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. This account bears the admin role (for the granted role).
* Expected in cases where the role was granted using the internal {AccessControl-_grantRole}.
*/
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 `callerConfirmation`.
*/
function renounceRole(bytes32 role, address callerConfirmation) external;
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol)
pragma solidity ^0.8.20;
/**
* @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;
}
function _contextSuffixLength() internal view virtual returns (uint256) {
return 0;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (utils/introspection/ERC165.sol)
pragma solidity ^0.8.20;
import {IERC165} from "./IERC165.sol";
/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts that want to implement ERC-165 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);
* }
* ```
*/
abstract contract ERC165 is IERC165 {
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) {
return interfaceId == type(IERC165).interfaceId;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (utils/introspection/IERC165.sol)
pragma solidity ^0.8.20;
/**
* @dev Interface of the ERC-165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[ERC].
*
* 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[ERC 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);
}{
"remappings": [
"lib/euler-price-oracle:@openzeppelin/contracts/=lib/euler-price-oracle/lib/openzeppelin-contracts/contracts/",
"lib/euler-earn:@openzeppelin/=lib/euler-earn/lib/openzeppelin-contracts/",
"lib/euler-earn:@openzeppelin-upgradeable/=lib/euler-earn/lib/openzeppelin-contracts-upgradeable/contracts/",
"lib/euler-earn:ethereum-vault-connector/=lib/euler-earn/lib/ethereum-vault-connector/src/",
"lib/layerzero-devtools/packages/oft-evm/contracts:@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts/contracts/",
"lib/layerzero-devtools/packages/oft-evm-upgradeable/contracts:@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/",
"lib/layerzero-devtools/packages/oapp-evm-upgradeable/contracts:@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/",
"@layerzerolabs/oft-evm/=lib/layerzero-devtools/packages/oft-evm/",
"@layerzerolabs/oapp-evm/=lib/layerzero-devtools/packages/oapp-evm/",
"@layerzerolabs/oapp-evm-upgradeable/=lib/layerzero-devtools/packages/oapp-evm-upgradeable/",
"@layerzerolabs/lz-evm-protocol-v2/=lib/layerzero-v2/packages/layerzero-v2/evm/protocol/",
"@layerzerolabs/lz-evm-messagelib-v2/=lib/layerzero-v2/packages/layerzero-v2/evm/messagelib/",
"@layerzerolabs/lz-evm-oapp-v2/=lib/layerzero-v2/packages/layerzero-v2/evm/oapp/",
"openzeppelin-contracts/=lib/openzeppelin-contracts/contracts/",
"openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/",
"ethereum-vault-connector/=lib/ethereum-vault-connector/src/",
"evc/=lib/ethereum-vault-connector/src/",
"evk/=lib/euler-vault-kit/src/",
"evk-test/=lib/euler-vault-kit/test/",
"euler-price-oracle/=lib/euler-price-oracle/src/",
"euler-price-oracle-test/=lib/euler-price-oracle/test/",
"fee-flow/=lib/fee-flow/src/",
"reward-streams/=lib/reward-streams/src/",
"@openzeppelin/=lib/openzeppelin-contracts/contracts/",
"euler-earn/=lib/euler-earn/src/",
"layerzero/oft-evm/=lib/layerzero-devtools/packages/oft-evm/contracts/",
"layerzero/oft-evm-upgradeable/=lib/layerzero-devtools/packages/oft-evm-upgradeable/contracts/",
"solidity-bytes-utils/=lib/solidity-bytes-utils/",
"@openzeppelin-upgradeable/=lib/euler-earn/lib/openzeppelin-contracts-upgradeable/contracts/",
"@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/",
"@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/",
"@pendle/core-v2/=lib/euler-price-oracle/lib/pendle-core-v2-public/contracts/",
"@pyth/=lib/euler-price-oracle/lib/pyth-sdk-solidity/",
"@redstone/evm-connector/=lib/euler-price-oracle/lib/redstone-oracles-monorepo/packages/evm-connector/contracts/",
"@solady/=lib/euler-price-oracle/lib/solady/src/",
"@uniswap/v3-core/=lib/euler-price-oracle/lib/v3-core/",
"@uniswap/v3-periphery/=lib/euler-price-oracle/lib/v3-periphery/",
"ERC4626/=lib/euler-earn/lib/properties/lib/ERC4626/contracts/",
"crytic-properties/=lib/euler-earn/lib/properties/contracts/",
"ds-test/=lib/ethereum-vault-connector/lib/forge-std/lib/ds-test/src/",
"erc4626-tests/=lib/openzeppelin-contracts-upgradeable/lib/erc4626-tests/",
"euler-vault-kit/=lib/euler-vault-kit/",
"forge-gas-snapshot/=lib/euler-vault-kit/lib/permit2/lib/forge-gas-snapshot/src/",
"forge-std/=lib/forge-std/src/",
"halmos-cheatcodes/=lib/openzeppelin-contracts-upgradeable/lib/halmos-cheatcodes/src/",
"layerzero-devtools/=lib/layerzero-devtools/packages/toolbox-foundry/src/",
"layerzero-v2/=lib/layerzero-v2/",
"openzeppelin/=lib/ethereum-vault-connector/lib/openzeppelin-contracts/contracts/",
"pendle-core-v2-public/=lib/euler-price-oracle/lib/pendle-core-v2-public/contracts/",
"permit2/=lib/euler-vault-kit/lib/permit2/",
"properties/=lib/euler-earn/lib/properties/contracts/",
"pyth-sdk-solidity/=lib/euler-price-oracle/lib/pyth-sdk-solidity/",
"redstone-oracles-monorepo/=lib/euler-price-oracle/lib/",
"solady/=lib/euler-price-oracle/lib/solady/src/",
"solmate/=lib/fee-flow/lib/solmate/src/",
"v3-core/=lib/euler-price-oracle/lib/v3-core/contracts/",
"v3-periphery/=lib/euler-price-oracle/lib/v3-periphery/contracts/"
],
"optimizer": {
"enabled": true,
"runs": 20000
},
"metadata": {
"useLiteralContent": false,
"bytecodeHash": "ipfs",
"appendCBOR": true
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"evmVersion": "cancun",
"viaIR": false,
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AccessControlBadConfirmation","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"neededRole","type":"bytes32"}],"name":"AccessControlUnauthorizedAccount","type":"error"},{"inputs":[],"name":"E_EmptyError","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":true,"internalType":"address","name":"factory","type":"address"},{"indexed":false,"internalType":"bytes","name":"data","type":"bytes"}],"name":"AdminCall","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"guardian","type":"address"},{"indexed":true,"internalType":"address","name":"factory","type":"address"},{"indexed":true,"internalType":"address","name":"roProxy","type":"address"}],"name":"Paused","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"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":true,"internalType":"address","name":"factory","type":"address"},{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PAUSE_GUARDIAN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"UNPAUSE_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"factory","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"adminCall","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"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":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMembers","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"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":"factory","type":"address"}],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"callerConfirmation","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"},{"inputs":[{"internalType":"address","name":"factory","type":"address"}],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"}]Contract Creation Code
608060405234801562000010575f80fd5b5060405162001aa038038062001aa0833981016040819052620000339162000184565b6200003f5f8262000047565b5050620001ac565b5f8062000055848462000082565b9050801562000079575f8481526001602052604090206200007790846200012d565b505b90505b92915050565b5f828152602081815260408083206001600160a01b038516845290915281205460ff1662000125575f838152602081815260408083206001600160a01b03861684529091529020805460ff19166001179055620000dc3390565b6001600160a01b0316826001600160a01b0316847f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45060016200007c565b505f6200007c565b5f62000079836001600160a01b0384165f8181526001830160205260408120546200012557508154600181810184555f8481526020808220909301849055845484825282860190935260409020919091556200007c565b5f6020828403121562000195575f80fd5b81516001600160a01b038116811462000079575f80fd5b6118e680620001ba5f395ff3fe608060405234801561000f575f80fd5b50600436106100f0575f3560e01c80639010d07c11610093578063bf64a82d11610063578063bf64a82d14610263578063ca15c87314610283578063d547741f14610296578063eb43d914146102a9575f80fd5b80639010d07c146101c157806391d14854146101f9578063a217fddf1461023c578063a3246ad314610243575f80fd5b806336568abe116100ce57806336568abe146101615780634509e6ae1461017457806357b001f91461019b57806376a67a51146101ae575f80fd5b806301ffc9a7146100f4578063248a9ca31461011c5780632f2ff15d1461014c575b5f80fd5b610107610102366004610f9d565b6102d0565b60405190151581526020015b60405180910390f35b61013e61012a366004610fdc565b5f9081526020819052604090206001015490565b604051908152602001610113565b61015f61015a366004611014565b61032b565b005b61015f61016f366004611014565b610355565b61013e7f3bb181d5689164b4d72d34b056228c95b51f3fb0f6dbdb7f9ddba5f91c6821dd81565b61015f6101a9366004611042565b6103b3565b61015f6101bc366004611042565b610643565b6101d46101cf36600461105d565b6108a2565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610113565b610107610207366004611014565b5f9182526020828152604080842073ffffffffffffffffffffffffffffffffffffffff93909316845291905290205460ff1690565b61013e5f81565b610256610251366004610fdc565b6108c0565b604051610113919061107d565b6102766102713660046110d6565b6108d9565b6040516101139190611154565b61013e610291366004610fdc565b6109d0565b61015f6102a4366004611014565b6109e6565b61013e7f93ccdda76c68897d89056a6026f2a1482750c42a196252ed8a777b693cbf838481565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f5a05180f000000000000000000000000000000000000000000000000000000001480610325575061032582610a0a565b92915050565b5f8281526020819052604090206001015461034581610aa0565b61034f8383610aad565b50505050565b73ffffffffffffffffffffffffffffffffffffffff811633146103a4576040517f6697b23200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103ae8282610ae0565b505050565b7f93ccdda76c68897d89056a6026f2a1482750c42a196252ed8a777b693cbf83846103dd81610aa0565b5f8273ffffffffffffffffffffffffffffffffffffffff16635c60da1b6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610427573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061044b91906111be565b60025490915073ffffffffffffffffffffffffffffffffffffffff908116908216036105dc575f8173ffffffffffffffffffffffffffffffffffffffff1663630e2e956040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104bb573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104df91906111be565b6040517fd784d42600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80831660048301529192509085169063d784d426906024015f604051808303815f87803b158015610549575f80fd5b505af115801561055b573d5f803e3d5ffd5b505050508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff166105943390565b73ffffffffffffffffffffffffffffffffffffffff167fb74e3efefe1b2b5bf06faa561e8b9c8b08caeaf560bf7d8c50bf41c018c636aa60405160405180910390a450505050565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207061757365640000000000000000000000000000000000000000000060448201526064015b60405180910390fd5b7f3bb181d5689164b4d72d34b056228c95b51f3fb0f6dbdb7f9ddba5f91c6821dd61066d81610aa0565b5f8273ffffffffffffffffffffffffffffffffffffffff16635c60da1b6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156106b7573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106db91906111be565b60025490915073ffffffffffffffffffffffffffffffffffffffff90811690821603610763576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f616c726561647920706175736564000000000000000000000000000000000000604482015260640161063a565b5f8160405161077190610f90565b73ffffffffffffffffffffffffffffffffffffffff9091168152602001604051809103905ff0801580156107a7573d5f803e3d5ffd5b506040517fd784d42600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80831660048301529192509085169063d784d426906024015f604051808303815f87803b158015610812575f80fd5b505af1158015610824573d5f803e3d5ffd5b5050600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff858116918217909255604051909350908716915033907f17e36fe6a9192b7b5b6885473d85f1ef942d4b1c086dd920208838c5256336c0905f90a450505050565b5f8281526001602052604081206108b99083610b0b565b9392505050565b5f81815260016020526040902060609061032590610b16565b60605f6108e581610aa0565b5f808673ffffffffffffffffffffffffffffffffffffffff16868660405161090e9291906111d9565b5f604051808303815f865af19150503d805f8114610947576040519150601f19603f3d011682016040523d82523d5f602084013e61094c565b606091505b50915091508161095f5761095f81610b22565b73ffffffffffffffffffffffffffffffffffffffff87163373ffffffffffffffffffffffffffffffffffffffff167f5a1dce108565d9fab9d07cb6bba7198001535dbcadd2c7c193226398abe05c7788886040516109be9291906111e8565b60405180910390a39695505050505050565b5f81815260016020526040812061032590610b63565b5f82815260208190526040902060010154610a0081610aa0565b61034f8383610ae0565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b00000000000000000000000000000000000000000000000000000000148061032557507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610325565b610aaa8133610b6c565b50565b5f80610ab98484610bf5565b905080156108b9575f848152600160205260409020610ad89084610cee565b509392505050565b5f80610aec8484610d0f565b905080156108b9575f848152600160205260409020610ad89084610dc8565b5f6108b98383610de9565b60605f6108b983610e0f565b805115610b3157805181602001fd5b6040517f2082e20000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610325825490565b5f8281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16610bf1576040517fe2517d3f00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024810183905260440161063a565b5050565b5f8281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915281205460ff16610ce7575f8381526020818152604080832073ffffffffffffffffffffffffffffffffffffffff86168452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055610c853390565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16847f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a4506001610325565b505f610325565b5f6108b98373ffffffffffffffffffffffffffffffffffffffff8416610e68565b5f8281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915281205460ff1615610ce7575f8381526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8616808552925280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905551339286917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a4506001610325565b5f6108b98373ffffffffffffffffffffffffffffffffffffffff8416610ead565b5f825f018281548110610dfe57610dfe611234565b905f5260205f200154905092915050565b6060815f01805480602002602001604051908101604052809291908181526020018280548015610e5c57602002820191905f5260205f20905b815481526020019060010190808311610e48575b50505050509050919050565b5f818152600183016020526040812054610ce757508154600181810184555f848152602080822090930184905584548482528286019093526040902091909155610325565b5f8181526001830160205260408120548015610f87575f610ecf600183611261565b85549091505f90610ee290600190611261565b9050808214610f41575f865f018281548110610f0057610f00611234565b905f5260205f200154905080875f018481548110610f2057610f20611234565b5f918252602080832090910192909255918252600188019052604090208390555b8554869080610f5257610f52611299565b600190038181905f5260205f20015f90559055856001015f8681526020019081526020015f205f905560019350505050610325565b5f915050610325565b6105ea806112c783390190565b5f60208284031215610fad575f80fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146108b9575f80fd5b5f60208284031215610fec575f80fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff81168114610aaa575f80fd5b5f8060408385031215611025575f80fd5b82359150602083013561103781610ff3565b809150509250929050565b5f60208284031215611052575f80fd5b81356108b981610ff3565b5f806040838503121561106e575f80fd5b50508035926020909101359150565b602080825282518282018190525f9190848201906040850190845b818110156110ca57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101611098565b50909695505050505050565b5f805f604084860312156110e8575f80fd5b83356110f381610ff3565b9250602084013567ffffffffffffffff8082111561110f575f80fd5b818601915086601f830112611122575f80fd5b813581811115611130575f80fd5b876020828501011115611141575f80fd5b6020830194508093505050509250925092565b5f602080835283518060208501525f5b8181101561118057858101830151858201604001528201611164565b505f6040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b5f602082840312156111ce575f80fd5b81516108b981610ff3565b818382375f9101908152919050565b60208152816020820152818360408301375f818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b81810381811115610325577f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603160045260245ffdfe60a060405234801561000f575f80fd5b506040516105ea3803806105ea83398101604081905261002e9161003f565b6001600160a01b031660805261006c565b5f6020828403121561004f575f80fd5b81516001600160a01b0381168114610065575f80fd5b9392505050565b60805161055f61008b5f395f8181610159015261025d015261055f5ff3fe608060405234801561000f575f80fd5b5060043610610034575f3560e01c8063630e2e951461013f578063900ff44d14610188575b5f803073ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff1663900ff44d5f3660405160240161007c92919061035a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660e09490941b9390931790925290516100e792506103c8565b5f60405180830381855afa9150503d805f811461011f576040519150601f19603f3d011682016040523d82523d5f602084013e610124565b606091505b50915091508161013757610137816101a8565b805181602001f35b60405173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001681526020015b60405180910390f35b61019b610196366004610410565b6101e9565b60405161017f91906104d9565b8051156101b757805181602001fd5b6040517f2082e20000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6060333014610259576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f756e617574686f72697a6564000000000000000000000000000000000000000060448201526064015b60405180910390fd5b5f807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16846040516102a091906103c8565b5f60405180830381855af49150503d805f81146102d8576040519150601f19603f3d011682016040523d82523d5f602084013e6102dd565b606091505b5091509150816101375780515f03610351576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f636f6e747261637420697320696e20726561642d6f6e6c79206d6f64650000006044820152606401610250565b610137816101a8565b60208152816020820152818360408301375f818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b5f5b838110156103c05781810151838201526020016103a8565b50505f910152565b5f82516103d98184602087016103a6565b9190910192915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b5f60208284031215610420575f80fd5b813567ffffffffffffffff80821115610437575f80fd5b818401915084601f83011261044a575f80fd5b81358181111561045c5761045c6103e3565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156104a2576104a26103e3565b816040528281528760208487010111156104ba575f80fd5b826020860160208301375f928101602001929092525095945050505050565b602081525f82518060208401526104f78160408501602087016103a6565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fea2646970667358221220e39a61316d07f6e835c793781050134ae9d50df6a40ebb01bfcf954d056a483764736f6c63430008180033a2646970667358221220b43a3a8572aa6fa01856e98a214433a9779ebc195b9fef96311953e42eb7d29c64736f6c634300081800330000000000000000000000003566a8b300606516de2e4576ec4132a0e13f9f66
Deployed Bytecode
0x608060405234801561000f575f80fd5b50600436106100f0575f3560e01c80639010d07c11610093578063bf64a82d11610063578063bf64a82d14610263578063ca15c87314610283578063d547741f14610296578063eb43d914146102a9575f80fd5b80639010d07c146101c157806391d14854146101f9578063a217fddf1461023c578063a3246ad314610243575f80fd5b806336568abe116100ce57806336568abe146101615780634509e6ae1461017457806357b001f91461019b57806376a67a51146101ae575f80fd5b806301ffc9a7146100f4578063248a9ca31461011c5780632f2ff15d1461014c575b5f80fd5b610107610102366004610f9d565b6102d0565b60405190151581526020015b60405180910390f35b61013e61012a366004610fdc565b5f9081526020819052604090206001015490565b604051908152602001610113565b61015f61015a366004611014565b61032b565b005b61015f61016f366004611014565b610355565b61013e7f3bb181d5689164b4d72d34b056228c95b51f3fb0f6dbdb7f9ddba5f91c6821dd81565b61015f6101a9366004611042565b6103b3565b61015f6101bc366004611042565b610643565b6101d46101cf36600461105d565b6108a2565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610113565b610107610207366004611014565b5f9182526020828152604080842073ffffffffffffffffffffffffffffffffffffffff93909316845291905290205460ff1690565b61013e5f81565b610256610251366004610fdc565b6108c0565b604051610113919061107d565b6102766102713660046110d6565b6108d9565b6040516101139190611154565b61013e610291366004610fdc565b6109d0565b61015f6102a4366004611014565b6109e6565b61013e7f93ccdda76c68897d89056a6026f2a1482750c42a196252ed8a777b693cbf838481565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f5a05180f000000000000000000000000000000000000000000000000000000001480610325575061032582610a0a565b92915050565b5f8281526020819052604090206001015461034581610aa0565b61034f8383610aad565b50505050565b73ffffffffffffffffffffffffffffffffffffffff811633146103a4576040517f6697b23200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103ae8282610ae0565b505050565b7f93ccdda76c68897d89056a6026f2a1482750c42a196252ed8a777b693cbf83846103dd81610aa0565b5f8273ffffffffffffffffffffffffffffffffffffffff16635c60da1b6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610427573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061044b91906111be565b60025490915073ffffffffffffffffffffffffffffffffffffffff908116908216036105dc575f8173ffffffffffffffffffffffffffffffffffffffff1663630e2e956040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104bb573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906104df91906111be565b6040517fd784d42600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80831660048301529192509085169063d784d426906024015f604051808303815f87803b158015610549575f80fd5b505af115801561055b573d5f803e3d5ffd5b505050508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff166105943390565b73ffffffffffffffffffffffffffffffffffffffff167fb74e3efefe1b2b5bf06faa561e8b9c8b08caeaf560bf7d8c50bf41c018c636aa60405160405180910390a450505050565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f74207061757365640000000000000000000000000000000000000000000060448201526064015b60405180910390fd5b7f3bb181d5689164b4d72d34b056228c95b51f3fb0f6dbdb7f9ddba5f91c6821dd61066d81610aa0565b5f8273ffffffffffffffffffffffffffffffffffffffff16635c60da1b6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156106b7573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106db91906111be565b60025490915073ffffffffffffffffffffffffffffffffffffffff90811690821603610763576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f616c726561647920706175736564000000000000000000000000000000000000604482015260640161063a565b5f8160405161077190610f90565b73ffffffffffffffffffffffffffffffffffffffff9091168152602001604051809103905ff0801580156107a7573d5f803e3d5ffd5b506040517fd784d42600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80831660048301529192509085169063d784d426906024015f604051808303815f87803b158015610812575f80fd5b505af1158015610824573d5f803e3d5ffd5b5050600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff858116918217909255604051909350908716915033907f17e36fe6a9192b7b5b6885473d85f1ef942d4b1c086dd920208838c5256336c0905f90a450505050565b5f8281526001602052604081206108b99083610b0b565b9392505050565b5f81815260016020526040902060609061032590610b16565b60605f6108e581610aa0565b5f808673ffffffffffffffffffffffffffffffffffffffff16868660405161090e9291906111d9565b5f604051808303815f865af19150503d805f8114610947576040519150601f19603f3d011682016040523d82523d5f602084013e61094c565b606091505b50915091508161095f5761095f81610b22565b73ffffffffffffffffffffffffffffffffffffffff87163373ffffffffffffffffffffffffffffffffffffffff167f5a1dce108565d9fab9d07cb6bba7198001535dbcadd2c7c193226398abe05c7788886040516109be9291906111e8565b60405180910390a39695505050505050565b5f81815260016020526040812061032590610b63565b5f82815260208190526040902060010154610a0081610aa0565b61034f8383610ae0565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b00000000000000000000000000000000000000000000000000000000148061032557507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610325565b610aaa8133610b6c565b50565b5f80610ab98484610bf5565b905080156108b9575f848152600160205260409020610ad89084610cee565b509392505050565b5f80610aec8484610d0f565b905080156108b9575f848152600160205260409020610ad89084610dc8565b5f6108b98383610de9565b60605f6108b983610e0f565b805115610b3157805181602001fd5b6040517f2082e20000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f610325825490565b5f8281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16610bf1576040517fe2517d3f00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024810183905260440161063a565b5050565b5f8281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915281205460ff16610ce7575f8381526020818152604080832073ffffffffffffffffffffffffffffffffffffffff86168452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055610c853390565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16847f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a4506001610325565b505f610325565b5f6108b98373ffffffffffffffffffffffffffffffffffffffff8416610e68565b5f8281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915281205460ff1615610ce7575f8381526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8616808552925280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905551339286917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a4506001610325565b5f6108b98373ffffffffffffffffffffffffffffffffffffffff8416610ead565b5f825f018281548110610dfe57610dfe611234565b905f5260205f200154905092915050565b6060815f01805480602002602001604051908101604052809291908181526020018280548015610e5c57602002820191905f5260205f20905b815481526020019060010190808311610e48575b50505050509050919050565b5f818152600183016020526040812054610ce757508154600181810184555f848152602080822090930184905584548482528286019093526040902091909155610325565b5f8181526001830160205260408120548015610f87575f610ecf600183611261565b85549091505f90610ee290600190611261565b9050808214610f41575f865f018281548110610f0057610f00611234565b905f5260205f200154905080875f018481548110610f2057610f20611234565b5f918252602080832090910192909255918252600188019052604090208390555b8554869080610f5257610f52611299565b600190038181905f5260205f20015f90559055856001015f8681526020019081526020015f205f905560019350505050610325565b5f915050610325565b6105ea806112c783390190565b5f60208284031215610fad575f80fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146108b9575f80fd5b5f60208284031215610fec575f80fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff81168114610aaa575f80fd5b5f8060408385031215611025575f80fd5b82359150602083013561103781610ff3565b809150509250929050565b5f60208284031215611052575f80fd5b81356108b981610ff3565b5f806040838503121561106e575f80fd5b50508035926020909101359150565b602080825282518282018190525f9190848201906040850190845b818110156110ca57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101611098565b50909695505050505050565b5f805f604084860312156110e8575f80fd5b83356110f381610ff3565b9250602084013567ffffffffffffffff8082111561110f575f80fd5b818601915086601f830112611122575f80fd5b813581811115611130575f80fd5b876020828501011115611141575f80fd5b6020830194508093505050509250925092565b5f602080835283518060208501525f5b8181101561118057858101830151858201604001528201611164565b505f6040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b5f602082840312156111ce575f80fd5b81516108b981610ff3565b818382375f9101908152919050565b60208152816020820152818360408301375f818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b81810381811115610325577f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603160045260245ffdfe60a060405234801561000f575f80fd5b506040516105ea3803806105ea83398101604081905261002e9161003f565b6001600160a01b031660805261006c565b5f6020828403121561004f575f80fd5b81516001600160a01b0381168114610065575f80fd5b9392505050565b60805161055f61008b5f395f8181610159015261025d015261055f5ff3fe608060405234801561000f575f80fd5b5060043610610034575f3560e01c8063630e2e951461013f578063900ff44d14610188575b5f803073ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff1663900ff44d5f3660405160240161007c92919061035a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660e09490941b9390931790925290516100e792506103c8565b5f60405180830381855afa9150503d805f811461011f576040519150601f19603f3d011682016040523d82523d5f602084013e610124565b606091505b50915091508161013757610137816101a8565b805181602001f35b60405173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001681526020015b60405180910390f35b61019b610196366004610410565b6101e9565b60405161017f91906104d9565b8051156101b757805181602001fd5b6040517f2082e20000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6060333014610259576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f756e617574686f72697a6564000000000000000000000000000000000000000060448201526064015b60405180910390fd5b5f807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16846040516102a091906103c8565b5f60405180830381855af49150503d805f81146102d8576040519150601f19603f3d011682016040523d82523d5f602084013e6102dd565b606091505b5091509150816101375780515f03610351576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f636f6e747261637420697320696e20726561642d6f6e6c79206d6f64650000006044820152606401610250565b610137816101a8565b60208152816020820152818360408301375f818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b5f5b838110156103c05781810151838201526020016103a8565b50505f910152565b5f82516103d98184602087016103a6565b9190910192915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b5f60208284031215610420575f80fd5b813567ffffffffffffffff80821115610437575f80fd5b818401915084601f83011261044a575f80fd5b81358181111561045c5761045c6103e3565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156104a2576104a26103e3565b816040528281528760208487010111156104ba575f80fd5b826020860160208301375f928101602001929092525095945050505050565b602081525f82518060208401526104f78160408501602087016103a6565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fea2646970667358221220e39a61316d07f6e835c793781050134ae9d50df6a40ebb01bfcf954d056a483764736f6c63430008180033a2646970667358221220b43a3a8572aa6fa01856e98a214433a9779ebc195b9fef96311953e42eb7d29c64736f6c63430008180033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000003566a8b300606516de2e4576ec4132a0e13f9f66
-----Decoded View---------------
Arg [0] : admin (address): 0x3566a8b300606516De2E4576eC4132a0E13f9f66
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 0000000000000000000000003566a8b300606516de2e4576ec4132a0e13f9f66
Net Worth in USD
Net Worth in ETH
Multichain Portfolio | 35 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.