ETH Price: $3,562.46 (+2.30%)

Contract

0x8234F990b149Ae59416dc260305E565e5DAfEb54
 
Transaction Hash
Method
Block
From
To
Value
New Account1216083712024-06-19 16:45:196 hrs ago1718815519IN
0x8234F990...e5DAfEb54
0 ETH0.000021340.06232387
New Account1216006132024-06-19 12:26:4311 hrs ago1718800003IN
0x8234F990...e5DAfEb54
0 ETH0.000021040.06143812
New Account1216004592024-06-19 12:21:3511 hrs ago1718799695IN
0x8234F990...e5DAfEb54
0 ETH0.000021070.06151939
New Account1215956852024-06-19 9:42:2713 hrs ago1718790147IN
0x8234F990...e5DAfEb54
0 ETH0.000027970.0816768
New Account1215720732024-06-18 20:35:2326 hrs ago1718742923IN
0x8234F990...e5DAfEb54
0 ETH0.000021170.06183784
New Account1215601132024-06-18 13:56:4333 hrs ago1718719003IN
0x8234F990...e5DAfEb54
0 ETH0.000021650.06322624
New Account1215523652024-06-18 9:38:2737 hrs ago1718703507IN
0x8234F990...e5DAfEb54
0 ETH0.000020830.06084173
New Account1215396352024-06-18 2:34:0744 hrs ago1718678047IN
0x8234F990...e5DAfEb54
0 ETH0.000043030.12565467
New Account1215134292024-06-17 12:00:352 days ago1718625635IN
0x8234F990...e5DAfEb54
0 ETH0.000000670.00197148
New Account1215068942024-06-17 8:22:452 days ago1718612565IN
0x8234F990...e5DAfEb54
0 ETH0.000000670.00196726
New Account1214982732024-06-17 3:35:232 days ago1718595323IN
0x8234F990...e5DAfEb54
0 ETH0.000000750.00220646
New Account1214849242024-06-16 20:10:253 days ago1718568625IN
0x8234F990...e5DAfEb54
0 ETH0.000006120.0178828
New Account1214758722024-06-16 15:08:413 days ago1718550521IN
0x8234F990...e5DAfEb54
0 ETH0.000000510.0015177
New Account1214430392024-06-15 20:54:154 days ago1718484855IN
0x8234F990...e5DAfEb54
0 ETH0.000000540.00159914
New Account1214134972024-06-15 4:29:314 days ago1718425771IN
0x8234F990...e5DAfEb54
0 ETH0.000000220.00070627
New Account1214134892024-06-15 4:29:154 days ago1718425755IN
0x8234F990...e5DAfEb54
0 ETH0.00000050.00147879
New Account1213954722024-06-14 18:28:415 days ago1718389721IN
0x8234F990...e5DAfEb54
0 ETH0.000002290.00670985
New Account1213860942024-06-14 13:16:055 days ago1718370965IN
0x8234F990...e5DAfEb54
0 ETH0.000000380.00111535
New Account1213793792024-06-14 9:32:155 days ago1718357535IN
0x8234F990...e5DAfEb54
0 ETH0.000000390.0011592
New Account1213729062024-06-14 5:56:295 days ago1718344589IN
0x8234F990...e5DAfEb54
0 ETH0.000000680.0020052
New Account1213661102024-06-14 2:09:575 days ago1718330997IN
0x8234F990...e5DAfEb54
0 ETH0.000000580.0017054
New Account1213636672024-06-14 0:48:315 days ago1718326111IN
0x8234F990...e5DAfEb54
0 ETH0.000000850.0025083
New Account1213256982024-06-13 3:42:536 days ago1718250173IN
0x8234F990...e5DAfEb54
0 ETH0.000001260.00369505
New Account1213133942024-06-12 20:52:457 days ago1718225565IN
0x8234F990...e5DAfEb54
0 ETH0.000004740.01385182
New Account1213115572024-06-12 19:51:317 days ago1718221891IN
0x8234F990...e5DAfEb54
0 ETH0.00000840.02454501
View all transactions

Latest 25 internal transactions (View All)

Advanced mode:
Parent Transaction Hash Block From To Value
1216083712024-06-19 16:45:196 hrs ago1718815519
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1216006132024-06-19 12:26:4311 hrs ago1718800003
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1216004592024-06-19 12:21:3511 hrs ago1718799695
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1215956852024-06-19 9:42:2713 hrs ago1718790147
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1215720732024-06-18 20:35:2326 hrs ago1718742923
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1215601132024-06-18 13:56:4333 hrs ago1718719003
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1215523652024-06-18 9:38:2737 hrs ago1718703507
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1215396352024-06-18 2:34:0744 hrs ago1718678047
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1215134292024-06-17 12:00:352 days ago1718625635
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1215068942024-06-17 8:22:452 days ago1718612565
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1214982732024-06-17 3:35:232 days ago1718595323
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1214849242024-06-16 20:10:253 days ago1718568625
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1214758722024-06-16 15:08:413 days ago1718550521
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1214430392024-06-15 20:54:154 days ago1718484855
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1214134972024-06-15 4:29:314 days ago1718425771
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1214134892024-06-15 4:29:154 days ago1718425755
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213954722024-06-14 18:28:415 days ago1718389721
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213860942024-06-14 13:16:055 days ago1718370965
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213793792024-06-14 9:32:155 days ago1718357535
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213729062024-06-14 5:56:295 days ago1718344589
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213661102024-06-14 2:09:575 days ago1718330997
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213636672024-06-14 0:48:315 days ago1718326111
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213256982024-06-13 3:42:536 days ago1718250173
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213133942024-06-12 20:52:457 days ago1718225565
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
1213115572024-06-12 19:51:317 days ago1718221891
0x8234F990...e5DAfEb54
 Contract Creation0 ETH
View All Internal Transactions

Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Factory

Compiler Version
v0.8.18+commit.87f61d96

Optimization Enabled:
Yes with 1000000 runs

Other Settings:
default evmVersion
File 1 of 5 : Factory.sol
// SPDX-License-Identifier: GPL-3.0-or-later
pragma solidity 0.8.18;

import {AccountProxy} from "./AccountProxy.sol";
import {IFactory} from "./interfaces/IFactory.sol";
import {Owned} from "@solmate/auth/Owned.sol";

/// @title Kwenta Account Factory
/// @author JaredBorders ([email protected])
/// @notice factory for creating smart margin accounts
/// @dev the factory acts as a beacon for the proxy {AccountProxy.sol} contract(s)
contract Factory is IFactory, Owned {
    /*//////////////////////////////////////////////////////////////
                                 STATE
    //////////////////////////////////////////////////////////////*/

    /// @inheritdoc IFactory
    bool public canUpgrade = true;

    /// @inheritdoc IFactory
    address public implementation;

    /// @inheritdoc IFactory
    mapping(address accounts => bool exist) public accounts;

    /// @notice mapping of owner to accounts owned by owner
    mapping(address owner => address[] accounts) internal ownerAccounts;

    /*//////////////////////////////////////////////////////////////
                              CONSTRUCTOR
    //////////////////////////////////////////////////////////////*/

    /// @notice constructor for factory that sets owner
    /// @param _owner: owner of factory
    constructor(address _owner) Owned(_owner) {}

    /*//////////////////////////////////////////////////////////////
                                 VIEWS
    //////////////////////////////////////////////////////////////*/

    /// @inheritdoc IFactory
    function getAccountOwner(address _account)
        public
        view
        override
        returns (address)
    {
        // ensure account is registered
        if (!accounts[_account]) revert AccountDoesNotExist();

        // fetch owner from account
        (bool success, bytes memory data) =
            _account.staticcall(abi.encodeWithSignature("owner()"));
        assert(success); // should never fail (account is a contract)

        return abi.decode(data, (address));
    }

    /// @inheritdoc IFactory
    function getAccountsOwnedBy(address _owner)
        external
        view
        override
        returns (address[] memory)
    {
        return ownerAccounts[_owner];
    }

    /*//////////////////////////////////////////////////////////////
                               OWNERSHIP
    //////////////////////////////////////////////////////////////*/

    /// @inheritdoc IFactory
    function updateAccountOwnership(address _newOwner, address _oldOwner)
        external
        override
    {
        // ensure account is registered by factory
        if (!accounts[msg.sender]) revert AccountDoesNotExist();

        // store length of ownerAccounts array in memory
        uint256 length = ownerAccounts[_oldOwner].length;

        for (uint256 i = 0; i < length;) {
            if (ownerAccounts[_oldOwner][i] == msg.sender) {
                // remove account from ownerAccounts mapping for old owner
                ownerAccounts[_oldOwner][i] =
                    ownerAccounts[_oldOwner][length - 1];
                ownerAccounts[_oldOwner].pop();

                // add account to ownerAccounts mapping for new owner
                ownerAccounts[_newOwner].push(msg.sender);

                return;
            }

            unchecked {
                ++i;
            }
        }
    }

    /*//////////////////////////////////////////////////////////////
                           ACCOUNT DEPLOYMENT
    //////////////////////////////////////////////////////////////*/

    /// @inheritdoc IFactory
    function newAccount()
        external
        override
        returns (address payable accountAddress)
    {
        // create account and set beacon to this address (i.e. factory address)
        accountAddress = payable(address(new AccountProxy(address(this))));

        // add account to accounts mapping
        accounts[accountAddress] = true;

        // add account to ownerAccounts mapping
        ownerAccounts[msg.sender].push(accountAddress);

        // set owner of account to caller
        (bool success, bytes memory data) = accountAddress.call(
            abi.encodeWithSignature("setInitialOwnership(address)", msg.sender)
        );
        if (!success) revert FailedToSetAcountOwner(data);

        // determine version for the following event
        (success, data) =
            accountAddress.call(abi.encodeWithSignature("VERSION()"));
        if (!success) revert AccountFailedToFetchVersion(data);

        emit NewAccount({
            creator: msg.sender,
            account: accountAddress,
            version: abi.decode(data, (bytes32))
        });
    }

    /*//////////////////////////////////////////////////////////////
                             UPGRADABILITY
    //////////////////////////////////////////////////////////////*/

    /// @inheritdoc IFactory
    function upgradeAccountImplementation(address _implementation)
        external
        override
        onlyOwner
    {
        if (!canUpgrade) revert CannotUpgrade();
        implementation = _implementation;
        emit AccountImplementationUpgraded({implementation: _implementation});
    }

    /// @inheritdoc IFactory
    function removeUpgradability() external override onlyOwner {
        canUpgrade = false;
    }
}

File 2 of 5 : Owned.sol
// SPDX-License-Identifier: AGPL-3.0-only
pragma solidity >=0.8.0;

/// @notice Simple single owner authorization mixin.
/// @author Solmate (https://github.com/transmissions11/solmate/blob/main/src/auth/Owned.sol)
abstract contract Owned {
    /*//////////////////////////////////////////////////////////////
                                 EVENTS
    //////////////////////////////////////////////////////////////*/

    event OwnershipTransferred(address indexed user, address indexed newOwner);

    /*//////////////////////////////////////////////////////////////
                            OWNERSHIP STORAGE
    //////////////////////////////////////////////////////////////*/

    address public owner;

    modifier onlyOwner() virtual {
        require(msg.sender == owner, "UNAUTHORIZED");

        _;
    }

    /*//////////////////////////////////////////////////////////////
                               CONSTRUCTOR
    //////////////////////////////////////////////////////////////*/

    constructor(address _owner) {
        owner = _owner;

        emit OwnershipTransferred(address(0), _owner);
    }

    /*//////////////////////////////////////////////////////////////
                             OWNERSHIP LOGIC
    //////////////////////////////////////////////////////////////*/

    function transferOwnership(address newOwner) public virtual onlyOwner {
        owner = newOwner;

        emit OwnershipTransferred(msg.sender, newOwner);
    }
}

File 3 of 5 : AccountProxy.sol
// SPDX-License-Identifier: GPL-3.0-or-later
pragma solidity 0.8.18;

import {IAccountProxy} from "./interfaces/IAccountProxy.sol";

/// @title Kwenta Account Proxy
/// @author OpenZeppelin, JaredBorders ([email protected])
/// @dev This contract implements a proxy that gets the
/// implementation address for each call from the {Beacon}
/// (which in this system is the contract: {Factory.sol}).
/// The beacon address is stored in the storage slot
/// `uint256(keccak256('eip1967.proxy.beacon')) - 1`, so that it doesn't
/// conflict with the storage layout of the implementation behind this proxy.
contract AccountProxy is IAccountProxy {
    /*//////////////////////////////////////////////////////////////
                           STORAGE MANAGEMENT
    //////////////////////////////////////////////////////////////*/

    bytes32 internal constant _BEACON_STORAGE_SLOT =
        bytes32(uint256(keccak256("eip1967.proxy.beacon")) - 1);

    /// @dev struct to store beacon address
    struct AddressSlot {
        address value;
    }

    /// @dev returns the storage slot where the beacon address is stored
    function _getAddressSlot(bytes32 slot)
        internal
        pure
        returns (AddressSlot storage r)
    {
        // solhint-disable-next-line no-inline-assembly
        assembly {
            r.slot := slot
        }
    }

    /*//////////////////////////////////////////////////////////////
                              CONSTRUCTOR
    //////////////////////////////////////////////////////////////*/

    /// @notice constructor for proxy
    /// @param _beaconAddress: address of beacon (i.e. factory address)
    /// @dev {Factory.sol} will store the implementation address,
    /// thus acting as the beacon
    constructor(address _beaconAddress) {
        _getAddressSlot(_BEACON_STORAGE_SLOT).value = _beaconAddress;
    }

    /*//////////////////////////////////////////////////////////////
                              BEACON LOGIC
    //////////////////////////////////////////////////////////////*/

    /// @return beacon address (i.e. the factory address)
    function _beacon() internal view returns (address beacon) {
        beacon = _getAddressSlot(_BEACON_STORAGE_SLOT).value;
        if (beacon == address(0)) revert BeaconNotSet();
    }

    /*//////////////////////////////////////////////////////////////
                          IMPLEMENTATION LOGIC
    //////////////////////////////////////////////////////////////*/

    /// @return implementation address (i.e. the account logic address)
    function _implementation() internal returns (address implementation) {
        (bool success, bytes memory data) =
            _beacon().call(abi.encodeWithSignature("implementation()"));
        if (!success) revert BeaconCallFailed();
        implementation = abi.decode(data, (address));
        if (implementation == address(0)) revert ImplementationNotSet();
    }

    /*//////////////////////////////////////////////////////////////
                            FORWARDING LOGIC
    //////////////////////////////////////////////////////////////*/

    /// @dev Fallback function that delegates calls to the address returned by `_implementation()`.
    /// Will run if no other function in the contract matches the call data.
    fallback() external payable {
        _fallback();
    }

    /// @dev Fallback function that delegates calls to the address returned by `_implementation()`.
    /// Will run if call data is empty.
    receive() external payable {
        _fallback();
    }

    /// @notice Delegates the current call to the address returned by `_implementation()`.
    /// @dev This function does not return to its internal call site,
    /// it will return directly to the external caller.
    function _fallback() internal {
        _delegate(_implementation());
    }

    /// @notice delegates the current call to `implementation`.
    /// @dev This function does not return to its internal call site,
    /// it will return directly to the external caller.
    function _delegate(address implementation) internal virtual {
        // solhint-disable-next-line no-inline-assembly
        assembly {
            // Copy msg.data. We take full control of memory in this inline assembly
            // block because it will not return to Solidity code. We overwrite the
            // Solidity scratch pad at memory position 0.
            calldatacopy(0, 0, calldatasize())

            // Call the implementation.
            // out and outsize are 0 because we don't know the size yet.
            let result :=
                delegatecall(gas(), implementation, 0, calldatasize(), 0, 0)

            // Copy the returned data.
            returndatacopy(0, 0, returndatasize())
            switch result
            // delegatecall returns 0 on error.
            case 0 { revert(0, returndatasize()) }
            default { return(0, returndatasize()) }
        }
    }
}

File 4 of 5 : IAccountProxy.sol
// SPDX-License-Identifier: GPL-3.0-or-later
pragma solidity 0.8.18;

/// @title Kwenta Account Proxy Interface
/// @author JaredBorders ([email protected])
interface IAccountProxy {
    /*//////////////////////////////////////////////////////////////
                                 ERRORS
    //////////////////////////////////////////////////////////////*/

    /// @dev thrown if beacon is not set to a valid address
    error BeaconNotSet();

    /// @dev thrown if implementation is not set to a valid address
    error ImplementationNotSet();

    /// @dev thrown if beacon call fails
    error BeaconCallFailed();
}

File 5 of 5 : IFactory.sol
// SPDX-License-Identifier: GPL-3.0-or-later
pragma solidity 0.8.18;

/// @title Kwenta Factory Interface
/// @author JaredBorders ([email protected])
interface IFactory {
    /*//////////////////////////////////////////////////////////////
                                 EVENTS
    //////////////////////////////////////////////////////////////*/

    /// @notice emitted when new account is created
    /// @param creator: account creator (address that called newAccount())
    /// @param account: address of account that was created (will be address of proxy)
    event NewAccount(
        address indexed creator, address indexed account, bytes32 version
    );

    /// @notice emitted when implementation is upgraded
    /// @param implementation: address of new implementation
    event AccountImplementationUpgraded(address implementation);

    /*//////////////////////////////////////////////////////////////
                                 ERRORS
    //////////////////////////////////////////////////////////////*/

    /// @notice thrown when factory cannot set account owner to the msg.sender
    /// @param data: data returned from failed low-level call
    error FailedToSetAcountOwner(bytes data);

    /// @notice thrown when Account creation fails due to no version being set
    /// @param data: data returned from failed low-level call
    error AccountFailedToFetchVersion(bytes data);

    /// @notice thrown when factory is not upgradable
    error CannotUpgrade();

    /// @notice thrown when account is unrecognized by factory
    error AccountDoesNotExist();

    /*//////////////////////////////////////////////////////////////
                                 VIEWS
    //////////////////////////////////////////////////////////////*/

    /// @return canUpgrade: bool to determine if system can be upgraded
    function canUpgrade() external view returns (bool);

    /// @return logic: account logic address
    function implementation() external view returns (address);

    /// @param _account: address of account
    /// @return whether or not account exists
    function accounts(address _account) external view returns (bool);

    /// @param _account: address of account
    /// @return owner of account
    function getAccountOwner(address _account)
        external
        view
        returns (address);

    /// @param _owner: address of owner
    /// @return array of accounts owned by _owner
    function getAccountsOwnedBy(address _owner)
        external
        view
        returns (address[] memory);

    /*//////////////////////////////////////////////////////////////
                               OWNERSHIP
    //////////////////////////////////////////////////////////////*/

    /// @notice update owner to account(s) mapping
    /// @dev does *NOT* check new owner != old owner
    /// @param _newOwner: new owner of account
    /// @param _oldOwner: old owner of account
    function updateAccountOwnership(address _newOwner, address _oldOwner)
        external;

    /*//////////////////////////////////////////////////////////////
                           ACCOUNT DEPLOYMENT
    //////////////////////////////////////////////////////////////*/

    /// @notice create unique account proxy for function caller
    /// @return accountAddress address of account created
    function newAccount() external returns (address payable accountAddress);

    /*//////////////////////////////////////////////////////////////
                             UPGRADABILITY
    //////////////////////////////////////////////////////////////*/

    /// @notice upgrade implementation of account which all account proxies currently point to
    /// @dev this *will* impact all existing accounts
    /// @dev future accounts will also point to this new implementation (until
    /// upgradeAccountImplementation() is called again with a newer implementation)
    /// @dev *DANGER* this function does not check the new implementation for validity,
    /// thus, a bad upgrade could result in severe consequences.
    /// @param _implementation: address of new implementation
    function upgradeAccountImplementation(address _implementation) external;

    /// @notice remove upgradability from factory
    /// @dev cannot be undone
    function removeUpgradability() external;
}

Settings
{
  "remappings": [
    "@openzeppelin/=lib/openzeppelin-contracts/",
    "@solmate/=lib/solmate/src/",
    "@synthetix/=src/interfaces/synthetix/",
    "ds-test/=lib/forge-std/lib/ds-test/src/",
    "forge-std/=lib/forge-std/src/",
    "openzeppelin-contracts/=lib/openzeppelin-contracts/",
    "solmate/=lib/solmate/src/"
  ],
  "optimizer": {
    "enabled": true,
    "runs": 1000000
  },
  "metadata": {
    "bytecodeHash": "ipfs",
    "appendCBOR": true
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "evmVersion": "london",
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AccountDoesNotExist","type":"error"},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"name":"AccountFailedToFetchVersion","type":"error"},{"inputs":[],"name":"CannotUpgrade","type":"error"},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"name":"FailedToSetAcountOwner","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"implementation","type":"address"}],"name":"AccountImplementationUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"creator","type":"address"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"bytes32","name":"version","type":"bytes32"}],"name":"NewAccount","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[{"internalType":"address","name":"accounts","type":"address"}],"name":"accounts","outputs":[{"internalType":"bool","name":"exist","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"canUpgrade","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"getAccountOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"getAccountsOwnedBy","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"implementation","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"newAccount","outputs":[{"internalType":"address payable","name":"accountAddress","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"removeUpgradability","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newOwner","type":"address"},{"internalType":"address","name":"_oldOwner","type":"address"}],"name":"updateAccountOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_implementation","type":"address"}],"name":"upgradeAccountImplementation","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040526000805460ff60a01b1916600160a01b17905534801561002357600080fd5b5060405161144738038061144783398101604081905261004291610091565b600080546001600160a01b0319166001600160a01b03831690811782556040518392907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a350506100c1565b6000602082840312156100a357600080fd5b81516001600160a01b03811681146100ba57600080fd5b9392505050565b611377806100d06000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80638da5cb5b11610081578063bf335e621161005b578063bf335e62146101e0578063f2fde38b146101e8578063fc8613f9146101fb57600080fd5b80638da5cb5b1461017b5780639738968c1461019b578063b53bc1e3146101c057600080fd5b80634b06effe116100b25780634b06effe146101205780635c60da1b146101285780635e5c06e21461014857600080fd5b80632e9ca204146100ce578063442b172c146100e3575b600080fd5b6100e16100dc366004610cea565b61020e565b005b6100f66100f1366004610d23565b61048a565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100e16105d5565b6001546100f69073ffffffffffffffffffffffffffffffffffffffff1681565b61016b610156366004610d23565b60026020526000908152604090205460ff1681565b6040519015158152602001610117565b6000546100f69073ffffffffffffffffffffffffffffffffffffffff1681565b60005461016b9074010000000000000000000000000000000000000000900460ff1681565b6101d36101ce366004610d23565b610685565b6040516101179190610d47565b6100f6610715565b6100e16101f6366004610d23565b610a79565b6100e1610209366004610d23565b610b6a565b3360009081526002602052604090205460ff16610257576040517fe76ea87f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260036020526040812054905b818110156104845773ffffffffffffffffffffffffffffffffffffffff831660009081526003602052604090208054339190839081106102c1576102c1610da1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff160361047c5773ffffffffffffffffffffffffffffffffffffffff83166000908152600360205260409020610318600184610dd0565b8154811061032857610328610da1565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff86811684526003909252604090922080549190921691908390811061037257610372610da1565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff94851617905591851681526003909152604090208054806103dc576103dc610e10565b6000828152602080822083017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000908116909155930190935573ffffffffffffffffffffffffffffffffffffffff96909616865260038252604086208054600181018255908752919095200180549094163317909355505050565b60010161027f565b50505050565b73ffffffffffffffffffffffffffffffffffffffff811660009081526002602052604081205460ff166104e9576040517fe76ea87f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f8da5cb5b000000000000000000000000000000000000000000000000000000001790529051600091829173ffffffffffffffffffffffffffffffffffffffff86169161056791610e63565b600060405180830381855afa9150503d80600081146105a2576040519150601f19603f3d011682016040523d82523d6000602084013e6105a7565b606091505b5091509150816105b9576105b9610e7f565b808060200190518101906105cd9190610eae565b949350505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461065b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f554e415554484f52495a4544000000000000000000000000000000000000000060448201526064015b60405180910390fd5b600080547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055565b73ffffffffffffffffffffffffffffffffffffffff811660009081526003602090815260409182902080548351818402810184019094528084526060939283018282801561070957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106de575b50505050509050919050565b60003060405161072490610cb8565b73ffffffffffffffffffffffffffffffffffffffff9091168152602001604051809103906000f08015801561075d573d6000803e3d6000fd5b5073ffffffffffffffffffffffffffffffffffffffff8116600081815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915533808552600384528285208054928301815585529284200180547fffffffffffffffffffffffff0000000000000000000000000000000000000000168517905551602481019190915292935091829190604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd6c7ef8b00000000000000000000000000000000000000000000000000000000179052516108869190610e63565b6000604051808303816000865af19150503d80600081146108c3576040519150601f19603f3d011682016040523d82523d6000602084013e6108c8565b606091505b50915091508161090657806040517f215529560000000000000000000000000000000000000000000000000000000081526004016106529190610ecb565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffa1ad7400000000000000000000000000000000000000000000000000000000179052905173ffffffffffffffffffffffffffffffffffffffff85169161097f91610e63565b6000604051808303816000865af19150503d80600081146109bc576040519150601f19603f3d011682016040523d82523d6000602084013e6109c1565b606091505b50909250905081610a0057806040517ff873e28c0000000000000000000000000000000000000000000000000000000081526004016106529190610ecb565b8273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f6814d673ab3768002b6eeaf470ba6db3e2b3e4b0f346c0ee23ee9271c1445c3d83806020019051810190610a639190610f1c565b60405190815260200160405180910390a3505090565b60005473ffffffffffffffffffffffffffffffffffffffff163314610afa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f554e415554484f52495a454400000000000000000000000000000000000000006044820152606401610652565b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081178255604051909133917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a350565b60005473ffffffffffffffffffffffffffffffffffffffff163314610beb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f554e415554484f52495a454400000000000000000000000000000000000000006044820152606401610652565b60005474010000000000000000000000000000000000000000900460ff16610c3f576040517f24c1d6d400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081179091556040519081527fdaa2b90d4f4e53aac69bc06e8ce6fc4a0d69c6582f74cd6e4547abcb972f7c6e9060200160405180910390a150565b61040c80610f3683390190565b73ffffffffffffffffffffffffffffffffffffffff81168114610ce757600080fd5b50565b60008060408385031215610cfd57600080fd5b8235610d0881610cc5565b91506020830135610d1881610cc5565b809150509250929050565b600060208284031215610d3557600080fd5b8135610d4081610cc5565b9392505050565b6020808252825182820181905260009190848201906040850190845b81811015610d9557835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610d63565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b81810381811115610e0a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b60005b83811015610e5a578181015183820152602001610e42565b50506000910152565b60008251610e75818460208701610e3f565b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600060208284031215610ec057600080fd5b8151610d4081610cc5565b6020815260008251806020840152610eea816040850160208701610e3f565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b600060208284031215610f2e57600080fd5b505191905056fe608060405234801561001057600080fd5b5060405161040c38038061040c83398101604081905261002f91610085565b8061006161005e60017fa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d516100b5565b90565b80546001600160a01b0319166001600160a01b0392909216919091179055506100dc565b60006020828403121561009757600080fd5b81516001600160a01b03811681146100ae57600080fd5b9392505050565b818103818111156100d657634e487b7160e01b600052601160045260246000fd5b92915050565b610321806100eb6000396000f3fe60806040523661001357610011610017565b005b6100115b610027610022610029565b610198565b565b60008060006100366101bc565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f5c60da1b00000000000000000000000000000000000000000000000000000000179052905173ffffffffffffffffffffffffffffffffffffffff92909216916100b2919061023f565b6000604051808303816000865af19150503d80600081146100ef576040519150601f19603f3d011682016040523d82523d6000602084013e6100f4565b606091505b509150915081610130576040517f73a769bf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80806020019051810190610144919061026e565b925073ffffffffffffffffffffffffffffffffffffffff8316610193576040517f40dde93500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505090565b3660008037600080366000845af43d6000803e8080156101b7573d6000f35b3d6000fd5b60006101ef6101ec60017fa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d516102ab565b90565b5473ffffffffffffffffffffffffffffffffffffffff169050806101ec576040517fee755c3e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000825160005b818110156102605760208186018101518583015201610246565b506000920191825250919050565b60006020828403121561028057600080fd5b815173ffffffffffffffffffffffffffffffffffffffff811681146102a457600080fd5b9392505050565b818103818111156102e5577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea2646970667358221220a9fe180b118f059af22133ae7f06251ccb7ca886e7c85092c4cf14b7a43fce0064736f6c63430008120033a264697066735822122074c2971fbf6c0bf00f081ec7e4edef26fc5749dd447d3f7dd60a6d5335a62d5264736f6c6343000812003300000000000000000000000039cfca7b389529ac861cbb05add802e5b06e5101

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100c95760003560e01c80638da5cb5b11610081578063bf335e621161005b578063bf335e62146101e0578063f2fde38b146101e8578063fc8613f9146101fb57600080fd5b80638da5cb5b1461017b5780639738968c1461019b578063b53bc1e3146101c057600080fd5b80634b06effe116100b25780634b06effe146101205780635c60da1b146101285780635e5c06e21461014857600080fd5b80632e9ca204146100ce578063442b172c146100e3575b600080fd5b6100e16100dc366004610cea565b61020e565b005b6100f66100f1366004610d23565b61048a565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100e16105d5565b6001546100f69073ffffffffffffffffffffffffffffffffffffffff1681565b61016b610156366004610d23565b60026020526000908152604090205460ff1681565b6040519015158152602001610117565b6000546100f69073ffffffffffffffffffffffffffffffffffffffff1681565b60005461016b9074010000000000000000000000000000000000000000900460ff1681565b6101d36101ce366004610d23565b610685565b6040516101179190610d47565b6100f6610715565b6100e16101f6366004610d23565b610a79565b6100e1610209366004610d23565b610b6a565b3360009081526002602052604090205460ff16610257576040517fe76ea87f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260036020526040812054905b818110156104845773ffffffffffffffffffffffffffffffffffffffff831660009081526003602052604090208054339190839081106102c1576102c1610da1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff160361047c5773ffffffffffffffffffffffffffffffffffffffff83166000908152600360205260409020610318600184610dd0565b8154811061032857610328610da1565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff86811684526003909252604090922080549190921691908390811061037257610372610da1565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff94851617905591851681526003909152604090208054806103dc576103dc610e10565b6000828152602080822083017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000908116909155930190935573ffffffffffffffffffffffffffffffffffffffff96909616865260038252604086208054600181018255908752919095200180549094163317909355505050565b60010161027f565b50505050565b73ffffffffffffffffffffffffffffffffffffffff811660009081526002602052604081205460ff166104e9576040517fe76ea87f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f8da5cb5b000000000000000000000000000000000000000000000000000000001790529051600091829173ffffffffffffffffffffffffffffffffffffffff86169161056791610e63565b600060405180830381855afa9150503d80600081146105a2576040519150601f19603f3d011682016040523d82523d6000602084013e6105a7565b606091505b5091509150816105b9576105b9610e7f565b808060200190518101906105cd9190610eae565b949350505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461065b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f554e415554484f52495a4544000000000000000000000000000000000000000060448201526064015b60405180910390fd5b600080547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055565b73ffffffffffffffffffffffffffffffffffffffff811660009081526003602090815260409182902080548351818402810184019094528084526060939283018282801561070957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106de575b50505050509050919050565b60003060405161072490610cb8565b73ffffffffffffffffffffffffffffffffffffffff9091168152602001604051809103906000f08015801561075d573d6000803e3d6000fd5b5073ffffffffffffffffffffffffffffffffffffffff8116600081815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915533808552600384528285208054928301815585529284200180547fffffffffffffffffffffffff0000000000000000000000000000000000000000168517905551602481019190915292935091829190604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd6c7ef8b00000000000000000000000000000000000000000000000000000000179052516108869190610e63565b6000604051808303816000865af19150503d80600081146108c3576040519150601f19603f3d011682016040523d82523d6000602084013e6108c8565b606091505b50915091508161090657806040517f215529560000000000000000000000000000000000000000000000000000000081526004016106529190610ecb565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffa1ad7400000000000000000000000000000000000000000000000000000000179052905173ffffffffffffffffffffffffffffffffffffffff85169161097f91610e63565b6000604051808303816000865af19150503d80600081146109bc576040519150601f19603f3d011682016040523d82523d6000602084013e6109c1565b606091505b50909250905081610a0057806040517ff873e28c0000000000000000000000000000000000000000000000000000000081526004016106529190610ecb565b8273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f6814d673ab3768002b6eeaf470ba6db3e2b3e4b0f346c0ee23ee9271c1445c3d83806020019051810190610a639190610f1c565b60405190815260200160405180910390a3505090565b60005473ffffffffffffffffffffffffffffffffffffffff163314610afa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f554e415554484f52495a454400000000000000000000000000000000000000006044820152606401610652565b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081178255604051909133917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a350565b60005473ffffffffffffffffffffffffffffffffffffffff163314610beb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f554e415554484f52495a454400000000000000000000000000000000000000006044820152606401610652565b60005474010000000000000000000000000000000000000000900460ff16610c3f576040517f24c1d6d400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081179091556040519081527fdaa2b90d4f4e53aac69bc06e8ce6fc4a0d69c6582f74cd6e4547abcb972f7c6e9060200160405180910390a150565b61040c80610f3683390190565b73ffffffffffffffffffffffffffffffffffffffff81168114610ce757600080fd5b50565b60008060408385031215610cfd57600080fd5b8235610d0881610cc5565b91506020830135610d1881610cc5565b809150509250929050565b600060208284031215610d3557600080fd5b8135610d4081610cc5565b9392505050565b6020808252825182820181905260009190848201906040850190845b81811015610d9557835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610d63565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b81810381811115610e0a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b60005b83811015610e5a578181015183820152602001610e42565b50506000910152565b60008251610e75818460208701610e3f565b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600060208284031215610ec057600080fd5b8151610d4081610cc5565b6020815260008251806020840152610eea816040850160208701610e3f565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b600060208284031215610f2e57600080fd5b505191905056fe608060405234801561001057600080fd5b5060405161040c38038061040c83398101604081905261002f91610085565b8061006161005e60017fa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d516100b5565b90565b80546001600160a01b0319166001600160a01b0392909216919091179055506100dc565b60006020828403121561009757600080fd5b81516001600160a01b03811681146100ae57600080fd5b9392505050565b818103818111156100d657634e487b7160e01b600052601160045260246000fd5b92915050565b610321806100eb6000396000f3fe60806040523661001357610011610017565b005b6100115b610027610022610029565b610198565b565b60008060006100366101bc565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f5c60da1b00000000000000000000000000000000000000000000000000000000179052905173ffffffffffffffffffffffffffffffffffffffff92909216916100b2919061023f565b6000604051808303816000865af19150503d80600081146100ef576040519150601f19603f3d011682016040523d82523d6000602084013e6100f4565b606091505b509150915081610130576040517f73a769bf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80806020019051810190610144919061026e565b925073ffffffffffffffffffffffffffffffffffffffff8316610193576040517f40dde93500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505090565b3660008037600080366000845af43d6000803e8080156101b7573d6000f35b3d6000fd5b60006101ef6101ec60017fa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d516102ab565b90565b5473ffffffffffffffffffffffffffffffffffffffff169050806101ec576040517fee755c3e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000825160005b818110156102605760208186018101518583015201610246565b506000920191825250919050565b60006020828403121561028057600080fd5b815173ffffffffffffffffffffffffffffffffffffffff811681146102a457600080fd5b9392505050565b818103818111156102e5577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea2646970667358221220a9fe180b118f059af22133ae7f06251ccb7ca886e7c85092c4cf14b7a43fce0064736f6c63430008120033a264697066735822122074c2971fbf6c0bf00f081ec7e4edef26fc5749dd447d3f7dd60a6d5335a62d5264736f6c63430008120033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

00000000000000000000000039cfca7b389529ac861cbb05add802e5b06e5101

-----Decoded View---------------
Arg [0] : _owner (address): 0x39CFcA7b389529ac861CbB05aDD802e5B06E5101

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 00000000000000000000000039cfca7b389529ac861cbb05add802e5b06e5101


Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
[ 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.