S Price: $0.068194 (-0.18%)
Gas: 55 Gwei

Contract

0x447FD2fab1985Bb80B477cF186f216Fc72b90C50

Overview

S Balance

Sonic LogoSonic LogoSonic Logo0 S

S Value

$0.00

More Info

Private Name Tags

Multichain Info

No addresses found
Transaction Hash
Block
From
To
Transfer Ownersh...320084832025-06-05 10:35:57235 days ago1749119757IN
0x447FD2fa...c72b90C50
0 S0.001433950.0001
Create Three Poo...244532802025-05-05 6:52:10266 days ago1746427930IN
0x447FD2fa...c72b90C50
0 S0.2112928250.0001
Create Three Poo...195601152025-04-11 9:52:57290 days ago1744365177IN
0x447FD2fa...c72b90C50
0 S0.2171637850.0001

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Cross-Chain Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
ZFStableSwapFactory

Compiler Version
v0.8.23+commit.f704f362

Optimization Enabled:
Yes with 200 runs

Other Settings:
shanghai EvmVersion
// SPDX-License-Identifier: MIT
pragma solidity 0.8.23;

import "@openzeppelin-v4/contracts/access/Ownable.sol";
import "./interfaces/IZFStableSwap.sol";
import "./interfaces/IZFStableSwapLP.sol";
import "./interfaces/IZFStableSwapDeployer.sol";
import "./interfaces/IZFStableSwapLPFactory.sol";

contract ZFStableSwapFactory is Ownable {
    struct StableSwapPairInfo {
        address swapContract;
        address token0;
        address token1;
        address LPContract;
    }
    struct StableSwapThreePoolPairInfo {
        address swapContract;
        address token0;
        address token1;
        address token2;
        address LPContract;
    }

    mapping(address => mapping(address => mapping(address => StableSwapThreePoolPairInfo))) public stableSwapPairInfo;
    // Query three pool pair infomation by two tokens.
    mapping(address => mapping(address => StableSwapThreePoolPairInfo)) threePoolInfo;
    mapping(uint256 => address) public swapPairContract;

    IZFStableSwapLPFactory public immutable LPFactory;
    IZFStableSwapDeployer public immutable SwapTwoPoolDeployer;
    IZFStableSwapDeployer public immutable SwapThreePoolDeployer;

    address constant ZEROADDRESS = address(0);

    uint256 public pairLength;

    event NewStableSwapPair(address indexed swapContract, address tokenA, address tokenB, address tokenC, address LP);

    /**
     * @notice constructor
     * _LPFactory: LP factory
     * _SwapTwoPoolDeployer: Swap two pool deployer
     * _SwapThreePoolDeployer: Swap three pool deployer
     */
    constructor(
        IZFStableSwapLPFactory _LPFactory,
        IZFStableSwapDeployer _SwapTwoPoolDeployer,
        IZFStableSwapDeployer _SwapThreePoolDeployer
    ) {
        LPFactory = _LPFactory;
        SwapTwoPoolDeployer = _SwapTwoPoolDeployer;
        SwapThreePoolDeployer = _SwapThreePoolDeployer;
    }

    // returns sorted token addresses, used to handle return values from pairs sorted in this order
    function sortTokens(address tokenA, address tokenB) internal pure returns (address token0, address token1) {
        require(tokenA != tokenB, "IDENTICAL_ADDRESSES");
        (token0, token1) = tokenA < tokenB ? (tokenA, tokenB) : (tokenB, tokenA);
    }

    function sortTokens(
        address tokenA,
        address tokenB,
        address tokenC
    )
        internal
        pure
        returns (
            address,
            address,
            address
        )
    {
        require(tokenA != tokenB && tokenA != tokenC && tokenB != tokenC, "IDENTICAL_ADDRESSES");
        address tmp;
        if (tokenA > tokenB) {
            tmp = tokenA;
            tokenA = tokenB;
            tokenB = tmp;
        }
        if (tokenB > tokenC) {
            tmp = tokenB;
            tokenB = tokenC;
            tokenC = tmp;
            if (tokenA > tokenB) {
                tmp = tokenA;
                tokenA = tokenB;
                tokenB = tmp;
            }
        }
        return (tokenA, tokenB, tokenC);
    }

    /**
     * @notice createSwapPair
     * @param _tokenA: Addresses of ERC20 conracts .
     * @param _tokenB: Addresses of ERC20 conracts .
     * @param _A: Amplification coefficient multiplied by n * (n - 1)
     * @param _fee: Fee to charge for exchanges
     * @param _protocol_fee: Protocol fee
     */
    function createSwapPair(
        address _tokenA,
        address _tokenB,
        uint256 _A,
        uint256 _fee,
        uint256 _protocol_fee
    ) external onlyOwner {
        require(_tokenA != ZEROADDRESS && _tokenB != ZEROADDRESS && _tokenA != _tokenB, "Illegal token");
        (address t0, address t1) = sortTokens(_tokenA, _tokenB);
        address LP = LPFactory.createSwapLP(t0, t1, ZEROADDRESS, address(this));
        address swapContract = SwapTwoPoolDeployer.createSwapPair(t0, t1, _A, _fee, _protocol_fee, msg.sender, LP);
        IZFStableSwapLP(LP).setMinter(swapContract);
        addPairInfoInternal(swapContract, t0, t1, ZEROADDRESS, LP);
    }

    /**
     * @notice createThreePoolPair
     * @param _tokenA: Addresses of ERC20 conracts .
     * @param _tokenB: Addresses of ERC20 conracts .
     * @param _tokenC: Addresses of ERC20 conracts .
     * @param _A: Amplification coefficient multiplied by n * (n - 1)
     * @param _fee: Fee to charge for exchanges
     * @param _protocol_fee: Protocol fee
     */
    function createThreePoolPair(
        address _tokenA,
        address _tokenB,
        address _tokenC,
        uint256 _A,
        uint256 _fee,
        uint256 _protocol_fee
    ) external onlyOwner {
        require(
            _tokenA != ZEROADDRESS &&
                _tokenB != ZEROADDRESS &&
                _tokenC != ZEROADDRESS &&
                _tokenA != _tokenB &&
                _tokenA != _tokenC &&
                _tokenB != _tokenC,
            "Illegal token"
        );
        (address t0, address t1, address t2) = sortTokens(_tokenA, _tokenB, _tokenC);
        address LP = LPFactory.createSwapLP(t0, t1, t2, address(this));
        address swapContract = SwapThreePoolDeployer.createSwapPair(t0, t1, t2, _A, _fee, _protocol_fee, msg.sender, LP);
        IZFStableSwapLP(LP).setMinter(swapContract);
        addPairInfoInternal(swapContract, t0, t1, t2, LP);
    }

    function addPairInfoInternal(
        address _swapContract,
        address _t0,
        address _t1,
        address _t2,
        address _LP
    ) internal {
        StableSwapThreePoolPairInfo storage info = stableSwapPairInfo[_t0][_t1][_t2];
        info.swapContract = _swapContract;
        info.token0 = _t0;
        info.token1 = _t1;
        info.token2 = _t2;
        info.LPContract = _LP;
        swapPairContract[pairLength] = _swapContract;
        pairLength += 1;
        if (_t2 != ZEROADDRESS) {
            addThreePoolPairInfo(_t0, _t1, _t2, info);
        }

        emit NewStableSwapPair(_swapContract, _t0, _t1, _t2, _LP);
    }

    function addThreePoolPairInfo(
        address _t0,
        address _t1,
        address _t2,
        StableSwapThreePoolPairInfo memory info
    ) internal {
        threePoolInfo[_t0][_t1] = info;
        threePoolInfo[_t0][_t2] = info;
        threePoolInfo[_t1][_t2] = info;
    }

    function addPairInfo(address _swapContract) external onlyOwner {
        IZFStableSwap swap = IZFStableSwap(_swapContract);
        uint256 N_COINS = swap.N_COINS();
        if (N_COINS == 2) {
            addPairInfoInternal(_swapContract, swap.coins(0), swap.coins(1), ZEROADDRESS, swap.token());
        } else if (N_COINS == 3) {
            addPairInfoInternal(_swapContract, swap.coins(0), swap.coins(1), swap.coins(2), swap.token());
        }
    }

    function getPairInfo(address _tokenA, address _tokenB) external view returns (StableSwapPairInfo memory info) {
        (address t0, address t1) = sortTokens(_tokenA, _tokenB);
        StableSwapThreePoolPairInfo memory pairInfo = stableSwapPairInfo[t0][t1][ZEROADDRESS];
        info.swapContract = pairInfo.swapContract;
        info.token0 = pairInfo.token0;
        info.token1 = pairInfo.token1;
        info.LPContract = pairInfo.LPContract;
    }

    function getThreePoolPairInfo(address _tokenA, address _tokenB)
        external
        view
        returns (StableSwapThreePoolPairInfo memory info)
    {
        (address t0, address t1) = sortTokens(_tokenA, _tokenB);
        info = threePoolInfo[t0][t1];
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

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

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby disabling any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

// SPDX-License-Identifier: MIT
pragma solidity 0.8.23;

interface IZFStableSwap {
    function token() external view returns (address);

    function balances(uint256 i) external view returns (uint256);

    function N_COINS() external view returns (uint256);

    function RATES(uint256 i) external view returns (uint256);

    function coins(uint256 i) external view returns (address);

    function PRECISION_MUL(uint256 i) external view returns (uint256);

    function fee() external view returns (uint256);

    function protocol_fee() external view returns (uint256);

    function A() external view returns (uint256);

    function get_D_mem(uint256[2] memory _balances, uint256 amp) external view returns (uint256);

    function get_y(
        uint256 i,
        uint256 j,
        uint256 x,
        uint256[2] memory xp_
    ) external view returns (uint256);

    function calc_withdraw_one_coin(uint256 _token_amount, uint256 i) external view returns (uint256);
}

// SPDX-License-Identifier: MIT
pragma solidity 0.8.23;

interface IZFStableSwapLP {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    function mint(address _to, uint256 _amount) external;

    function burnFrom(address _to, uint256 _amount) external;

    function setMinter(address _newMinter) external;
}

// SPDX-License-Identifier: MIT
pragma solidity 0.8.23;

interface IZFStableSwapDeployer {
    function createSwapPair(
        address _tokenA,
        address _tokenB,
        uint256 _A,
        uint256 _fee,
        uint256 _protocol_fee,
        address _admin,
        address _LP
    ) external returns (address);

    function createSwapPair(
        address _tokenA,
        address _tokenB,
        address _tokenC,
        uint256 _A,
        uint256 _fee,
        uint256 _protocol_fee,
        address _admin,
        address _LP
    ) external returns (address);
}

File 6 of 7 : IZFStableSwapLPFactory.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.23;

interface IZFStableSwapLPFactory {
    function createSwapLP(
        address _tokenA,
        address _tokenB,
        address _tokenC,
        address _minter
    ) external returns (address);
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;

/**
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

Settings
{
  "remappings": [
    "@zf/=lib/@zf/",
    "base64-sol/=lib/base64/",
    "forge-std/=lib/forge-std/src/",
    "@openzeppelin-v4/=lib/openzeppelin-contracts-4.9.3/",
    "@openzeppelin-v5/=lib/openzeppelin-contracts-5.2.0/",
    "#@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/",
    "@uniswap/lib/contracts/=lib/solidity-lib.git/contracts/",
    "solmate/src/=lib/solmate/src/",
    "solidity-bytes-utils/contracts/=lib/solidity-bytes-utils/contracts/",
    "base64/=lib/base64/",
    "devtools/=lib/devtools/packages/toolbox-foundry/src/",
    "ds-test/=lib/solmate/lib/ds-test/src/",
    "erc4626-tests/=lib/openzeppelin-contracts/lib/erc4626-tests/",
    "halmos-cheatcodes/=lib/openzeppelin-contracts/lib/halmos-cheatcodes/src/",
    "layerzero-v2/=lib/layerzero-v2/",
    "openzeppelin-contracts-4.9.3/=lib/openzeppelin-contracts-4.9.3/",
    "openzeppelin-contracts-5.2.0/=lib/openzeppelin-contracts-5.2.0/",
    "openzeppelin-contracts/=lib/openzeppelin-contracts/contracts/",
    "solidity-lib.git/=lib/solidity-lib.git/contracts/"
  ],
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "metadata": {
    "useLiteralContent": false,
    "bytecodeHash": "ipfs",
    "appendCBOR": true
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "evmVersion": "shanghai",
  "viaIR": true,
  "libraries": {}
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"contract IZFStableSwapLPFactory","name":"_LPFactory","type":"address"},{"internalType":"contract IZFStableSwapDeployer","name":"_SwapTwoPoolDeployer","type":"address"},{"internalType":"contract IZFStableSwapDeployer","name":"_SwapThreePoolDeployer","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"swapContract","type":"address"},{"indexed":false,"internalType":"address","name":"tokenA","type":"address"},{"indexed":false,"internalType":"address","name":"tokenB","type":"address"},{"indexed":false,"internalType":"address","name":"tokenC","type":"address"},{"indexed":false,"internalType":"address","name":"LP","type":"address"}],"name":"NewStableSwapPair","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"LPFactory","outputs":[{"internalType":"contract IZFStableSwapLPFactory","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SwapThreePoolDeployer","outputs":[{"internalType":"contract IZFStableSwapDeployer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SwapTwoPoolDeployer","outputs":[{"internalType":"contract IZFStableSwapDeployer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_swapContract","type":"address"}],"name":"addPairInfo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenA","type":"address"},{"internalType":"address","name":"_tokenB","type":"address"},{"internalType":"uint256","name":"_A","type":"uint256"},{"internalType":"uint256","name":"_fee","type":"uint256"},{"internalType":"uint256","name":"_protocol_fee","type":"uint256"}],"name":"createSwapPair","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenA","type":"address"},{"internalType":"address","name":"_tokenB","type":"address"},{"internalType":"address","name":"_tokenC","type":"address"},{"internalType":"uint256","name":"_A","type":"uint256"},{"internalType":"uint256","name":"_fee","type":"uint256"},{"internalType":"uint256","name":"_protocol_fee","type":"uint256"}],"name":"createThreePoolPair","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenA","type":"address"},{"internalType":"address","name":"_tokenB","type":"address"}],"name":"getPairInfo","outputs":[{"components":[{"internalType":"address","name":"swapContract","type":"address"},{"internalType":"address","name":"token0","type":"address"},{"internalType":"address","name":"token1","type":"address"},{"internalType":"address","name":"LPContract","type":"address"}],"internalType":"struct ZFStableSwapFactory.StableSwapPairInfo","name":"info","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_tokenA","type":"address"},{"internalType":"address","name":"_tokenB","type":"address"}],"name":"getThreePoolPairInfo","outputs":[{"components":[{"internalType":"address","name":"swapContract","type":"address"},{"internalType":"address","name":"token0","type":"address"},{"internalType":"address","name":"token1","type":"address"},{"internalType":"address","name":"token2","type":"address"},{"internalType":"address","name":"LPContract","type":"address"}],"internalType":"struct ZFStableSwapFactory.StableSwapThreePoolPairInfo","name":"info","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pairLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"stableSwapPairInfo","outputs":[{"internalType":"address","name":"swapContract","type":"address"},{"internalType":"address","name":"token0","type":"address"},{"internalType":"address","name":"token1","type":"address"},{"internalType":"address","name":"token2","type":"address"},{"internalType":"address","name":"LPContract","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"swapPairContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60e0346100f257601f6114cc38819003918201601f19168301916001600160401b038311848410176100f6578084926060946040528339810103126100f25780516001600160a01b039182821682036100f25761006a60406100636020840161010a565b920161010a565b915f543360018060a01b03198216175f55604051943391167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a360805260a05260c0526113ad908161011f8239608051818181610232015281816109090152610cbd015260a0518181816102aa01526107b7015260c0518181816109900152610c7c0152f35b5f80fd5b634e487b7160e01b5f52604160045260245ffd5b51906001600160a01b03821682036100f25756fe60806040818152600480361015610014575f80fd5b5f925f3560e01c90816314c77a6d14610cab5750806321420c4b14610c6857806338802f1a14610bd4578063400f7a1e14610af05780634205381b14610818578063636e66a0146107e657806368fae3f3146107a2578063715018a6146107465780638da5cb5b1461071e578063923093cb1461066a578063b3c0e846146103ae578063ec69a0241461019e578063f2fde38b146100da5763fcc9136c146100ba575f80fd5b346100d657826003193601126100d65760209250549051908152f35b8280fd5b50346100d65760203660031901126100d6576100f4610cec565b906100fd610ea8565b6001600160a01b0391821692831561014c5750505f54826001600160601b0360a01b8216175f55167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a380f35b906020608492519162461bcd60e51b8352820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152fd5b5090346100d65760a03660031901126100d657826101ba610cec565b926101f86101c6610d02565b6101ce610ea8565b6001600160a01b03956101f381881680151590816103a2575b81610395575b50610de4565b610e81565b929091845194635920110d60e11b86528684168083880152878616978860248901525f6044890152306064890152602098898960848189867f0000000000000000000000000000000000000000000000000000000000000000165af198891561036c578699610376575b50835192639013148d60e01b84528584015260248301526044356044830152606435606483015260843560848301523360a4830152808816918260c4820152898160e48189867f0000000000000000000000000000000000000000000000000000000000000000165af1998a1561036c57869a61033d575b5050813b156103305760248986809486519788958694637e51dad560e11b865216908401525af1908115610334575061031c575b505061031993610eff565b80f35b61032590610d2e565b61033057845f61030e565b8480fd5b513d84823e3d90fd5b61035d929a50803d10610365575b6103558183610d72565b810190610e20565b975f806102da565b503d61034b565b84513d88823e3d90fd5b61038e9199508a3d8c11610365576103558183610d72565b975f610262565b905088841614155f6101ed565b848a16151591506101e7565b50346100d65760209081600319360112610666576103ca610cec565b906103d3610ea8565b8351630293577560e41b81526001600160a01b038316929084818481875afa9081156104a4578791610635575b50600281036104f6575084519163c661065760e01b80845287828501528584602481885afa9384156104cd5788946104d7575b5086519081526001828201528581602481885afa9485156104cd57869189966104ae575b508751637e062a3560e11b815292839182905afa9485156104a45761031996508795610485575b5050610eff565b61049c929550803d10610365576103558183610d72565b925f8061047e565b86513d89823e3d90fd5b6104c6919650823d8411610365576103558183610d72565b945f610457565b87513d8a823e3d90fd5b6104ef919450863d8811610365576103558183610d72565b925f610433565b600314610506575b505050505080f35b84519063c661065760e01b9283835287818401528583602481885afa9283156104cd578893610616575b508651938085526001828601528685602481895afa9485156105ed5789956105f7575b5087519081526002828201528681602481895afa9586156105ed5787918a976105ce575b508851637e062a3560e11b815292839182905afa9586156104cd576105a5975088966105af575b5050610fef565b5f808080806104fe565b6105c6929650803d10610365576103558183610d72565b935f8061059e565b6105e6919750823d8411610365576103558183610d72565b955f610577565b88513d8b823e3d90fd5b61060f919550873d8911610365576103558183610d72565b935f610553565b61062e919350863d8811610365576103558183610d72565b915f610530565b90508481813d831161065f575b61064c8183610d72565b8101031261065b57515f610400565b8680fd5b503d610642565b8380fd5b50503461071a578060031936011261071a5760a0916106bc61068a610cec565b610692610d02565b9083608086516106a181610d56565b82815282602082015282888201528260608201520152610e81565b9083600180871b039384809316815260026020522091165f5260205260806106e5835f20610d94565b835193838251168552836020830151166020860152838183015116908501528260608201511660608501520151166080820152f35b5080fd5b50503461071a578160031936011261071a57905490516001600160a01b039091168152602090f35b833461079f578060031936011261079f5761075f610ea8565b5f80546001600160a01b0319811682556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b80fd5b50503461071a578160031936011261071a57517f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03168152602090f35b50346100d65760203660031901126100d65735825260036020908152918190205490516001600160a01b039091168152f35b50919034610a1d5760c0366003190112610a1d57610834610cec565b61083c610d02565b610844610d18565b61084c610ea8565b6001600160a01b03958387169182151580610ae5575b80610ada575b80610ace575b80610ac2575b80610ab4575b61088390610de4565b80948481948a8216908181141580610aa8575b80610a9c575b6108a590610e3f565b11610a90575b5050878116908189861611610a73575b50508451635920110d60e11b81526001600160a01b03808416838301908152818616602082810191909152918716604082015230606082015290989196919089908890819060800103815f857f0000000000000000000000000000000000000000000000000000000000000000165af1968715610a69575f97610a4a575b50815190634cedbfc760e01b825280851684830152808616602483015280871660448301526064356064830152608435608483015260a43560a48301523360c4830152808816918260e48201528a81610104815f867f0000000000000000000000000000000000000000000000000000000000000000165af19a8b15610a40575f9b610a21575b5050813b15610a1d5760248a5f809486519788958694637e51dad560e11b865216908401525af1908115610a1457506109ff575b506103199495610fef565b6103199550610a0d90610d2e565b5f946109f4565b513d5f823e3d90fd5b5f80fd5b610a38929b50803d10610365576103558183610d72565b985f806109c0565b84513d5f823e3d90fd5b610a62919750893d8b11610365576103558183610d72565b955f610939565b82513d5f823e3d90fd5b939450839083891611610a87575b806108bb565b9192505f610a81565b90945092505f806108ab565b50848c1682141561089c565b508b8516811415610896565b50838816818916141561087a565b50878116831415610874565b5087841683141561086e565b508781161515610868565b508784161515610862565b509034610a1d5780600319360112610a1d57610b0a610cec565b610b12610d02565b908251926080840184811067ffffffffffffffff821117610bc1576080955081525f84526020808501935f8552610b56838701915f835260608801955f8752610e81565b929060018060a01b03968794858093165f526001845282875f2091165f528352855f205f80528352818a610b8b885f20610d94565b82815116809c52828682015116845282898201511687520151168752855198895251169087015251169084015251166060820152f35b604186634e487b7160e01b5f525260245ffd5b509034610a1d576060366003190112610a1d5760a091610bf2610cec565b90610bfb610d02565b610c03610d18565b90600180871b038094165f52600160205283855f2091165f5260205282845f2091165f52602052825f20908282541693836001840154169380600285015416928160038601541694015416938151958652602086015284015260608301526080820152f35b8234610a1d575f366003190112610a1d57517f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03168152602090f35b34610a1d575f366003190112610a1d577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03168152602090f35b600435906001600160a01b0382168203610a1d57565b602435906001600160a01b0382168203610a1d57565b604435906001600160a01b0382168203610a1d57565b67ffffffffffffffff8111610d4257604052565b634e487b7160e01b5f52604160045260245ffd5b60a0810190811067ffffffffffffffff821117610d4257604052565b90601f8019910116810190811067ffffffffffffffff821117610d4257604052565b90604051610da181610d56565b82546001600160a01b0390811682526001840154811660208301526002840154811660408301526003840154811660608301526004909301549092166080830152565b15610deb57565b60405162461bcd60e51b815260206004820152600d60248201526c24b63632b3b0b6103a37b5b2b760991b6044820152606490fd5b90816020910312610a1d57516001600160a01b0381168103610a1d5790565b15610e4657565b60405162461bcd60e51b81526020600482015260136024820152724944454e544943414c5f41444452455353455360681b6044820152606490fd5b6001600160a01b03828116908216610e9b81831415610e3f565b1015610ea45791565b9091565b5f546001600160a01b03163303610ebb57565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b91909260018060a01b0380941690815f52600160205260409385855f20941693845f52602052845f205f805260205285855f2091169560046001600160601b0360a01b928884825416178155600181018685825416179055600281018785825416179055600381018481541690550192169182828254161790556004545f52600360205285855f209182541617905560045460018101809111610fdb577f48dc7a1b156fe3e70ed5ed0afcb307661905edf536f15bb5786e327ea1933532946080945f92600455815194855260208501528301526060820152a2565b634e487b7160e01b5f52601160045260245ffd5b6001600160a01b038281165f818152600160208181526040808420898716808652908352818520878c1680875290845282862080546001600160a01b03199081169a8a169a8b178255818701805482169099179098556002810180548916909317909255600380830180548916909217909155600480830180548916998f16999099179098558754865290925290922080549093168517909255915492969195908301928310610fdb577f48dc7a1b156fe3e70ed5ed0afcb307661905edf536f15bb5786e327ea1933532956111029360045560018060a01b038216611107575b50604080516001600160a01b039586168152958516602087015290841690850152909116606083015281906080820190565b0390a2565b61111090610d94565b60018060a01b0385165f52600260205260405f2060018060a01b0387165f5260205260405f2060018060a01b038251166001600160601b0360a01b82541617815560018060a01b036020830151166001600160601b0360a01b60018301541617600182015560018060a01b036040830151166001600160601b0360a01b60028301541617600282015560018060a01b036060830151166001600160601b0360a01b600383015416176003820155600460018060a01b036080840151166001600160601b0360a01b82840154161791015560018060a01b0385165f52600260205260405f2060018060a01b0383165f52602052600460405f2060018060a01b038351166001600160601b0360a01b8254161781556001810160018060a01b036020850151166001600160601b0360a01b8254161790556002810160018060a01b036040850151166001600160601b0360a01b8254161790556003810160018060a01b036060850151166001600160601b0360a01b8254161790550160018060a01b036080830151166001600160601b0360a01b82541617905560018060a01b0386165f52600260205260405f2060018060a01b0383165f52602052600460405f2060018060a01b038351166001600160601b0360a01b8254161781556001810160018060a01b036020850151166001600160601b0360a01b8254161790556002810160018060a01b036040850151166001600160601b0360a01b8254161790556003810160018060a01b036060850151166001600160601b0360a01b8254161790550190608060018060a01b03910151166001600160601b0360a01b8254161790555f6110d056fea2646970667358221220c4e79079a4dc32cbd1f56dc410878b86703451268ad7bc4abf9bc4cb4fab250664736f6c634300081700330000000000000000000000005271d6f66d4d881421fc2b1c48d4f99a9ba1d04c000000000000000000000000f43fc445204174ea98cf45b21504463d32c28189000000000000000000000000c19a303f856847e60aeddfc5b773017110b06e37

Deployed Bytecode

0x60806040818152600480361015610014575f80fd5b5f925f3560e01c90816314c77a6d14610cab5750806321420c4b14610c6857806338802f1a14610bd4578063400f7a1e14610af05780634205381b14610818578063636e66a0146107e657806368fae3f3146107a2578063715018a6146107465780638da5cb5b1461071e578063923093cb1461066a578063b3c0e846146103ae578063ec69a0241461019e578063f2fde38b146100da5763fcc9136c146100ba575f80fd5b346100d657826003193601126100d65760209250549051908152f35b8280fd5b50346100d65760203660031901126100d6576100f4610cec565b906100fd610ea8565b6001600160a01b0391821692831561014c5750505f54826001600160601b0360a01b8216175f55167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a380f35b906020608492519162461bcd60e51b8352820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152fd5b5090346100d65760a03660031901126100d657826101ba610cec565b926101f86101c6610d02565b6101ce610ea8565b6001600160a01b03956101f381881680151590816103a2575b81610395575b50610de4565b610e81565b929091845194635920110d60e11b86528684168083880152878616978860248901525f6044890152306064890152602098898960848189867f0000000000000000000000005271d6f66d4d881421fc2b1c48d4f99a9ba1d04c165af198891561036c578699610376575b50835192639013148d60e01b84528584015260248301526044356044830152606435606483015260843560848301523360a4830152808816918260c4820152898160e48189867f000000000000000000000000f43fc445204174ea98cf45b21504463d32c28189165af1998a1561036c57869a61033d575b5050813b156103305760248986809486519788958694637e51dad560e11b865216908401525af1908115610334575061031c575b505061031993610eff565b80f35b61032590610d2e565b61033057845f61030e565b8480fd5b513d84823e3d90fd5b61035d929a50803d10610365575b6103558183610d72565b810190610e20565b975f806102da565b503d61034b565b84513d88823e3d90fd5b61038e9199508a3d8c11610365576103558183610d72565b975f610262565b905088841614155f6101ed565b848a16151591506101e7565b50346100d65760209081600319360112610666576103ca610cec565b906103d3610ea8565b8351630293577560e41b81526001600160a01b038316929084818481875afa9081156104a4578791610635575b50600281036104f6575084519163c661065760e01b80845287828501528584602481885afa9384156104cd5788946104d7575b5086519081526001828201528581602481885afa9485156104cd57869189966104ae575b508751637e062a3560e11b815292839182905afa9485156104a45761031996508795610485575b5050610eff565b61049c929550803d10610365576103558183610d72565b925f8061047e565b86513d89823e3d90fd5b6104c6919650823d8411610365576103558183610d72565b945f610457565b87513d8a823e3d90fd5b6104ef919450863d8811610365576103558183610d72565b925f610433565b600314610506575b505050505080f35b84519063c661065760e01b9283835287818401528583602481885afa9283156104cd578893610616575b508651938085526001828601528685602481895afa9485156105ed5789956105f7575b5087519081526002828201528681602481895afa9586156105ed5787918a976105ce575b508851637e062a3560e11b815292839182905afa9586156104cd576105a5975088966105af575b5050610fef565b5f808080806104fe565b6105c6929650803d10610365576103558183610d72565b935f8061059e565b6105e6919750823d8411610365576103558183610d72565b955f610577565b88513d8b823e3d90fd5b61060f919550873d8911610365576103558183610d72565b935f610553565b61062e919350863d8811610365576103558183610d72565b915f610530565b90508481813d831161065f575b61064c8183610d72565b8101031261065b57515f610400565b8680fd5b503d610642565b8380fd5b50503461071a578060031936011261071a5760a0916106bc61068a610cec565b610692610d02565b9083608086516106a181610d56565b82815282602082015282888201528260608201520152610e81565b9083600180871b039384809316815260026020522091165f5260205260806106e5835f20610d94565b835193838251168552836020830151166020860152838183015116908501528260608201511660608501520151166080820152f35b5080fd5b50503461071a578160031936011261071a57905490516001600160a01b039091168152602090f35b833461079f578060031936011261079f5761075f610ea8565b5f80546001600160a01b0319811682556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b80fd5b50503461071a578160031936011261071a57517f000000000000000000000000f43fc445204174ea98cf45b21504463d32c281896001600160a01b03168152602090f35b50346100d65760203660031901126100d65735825260036020908152918190205490516001600160a01b039091168152f35b50919034610a1d5760c0366003190112610a1d57610834610cec565b61083c610d02565b610844610d18565b61084c610ea8565b6001600160a01b03958387169182151580610ae5575b80610ada575b80610ace575b80610ac2575b80610ab4575b61088390610de4565b80948481948a8216908181141580610aa8575b80610a9c575b6108a590610e3f565b11610a90575b5050878116908189861611610a73575b50508451635920110d60e11b81526001600160a01b03808416838301908152818616602082810191909152918716604082015230606082015290989196919089908890819060800103815f857f0000000000000000000000005271d6f66d4d881421fc2b1c48d4f99a9ba1d04c165af1968715610a69575f97610a4a575b50815190634cedbfc760e01b825280851684830152808616602483015280871660448301526064356064830152608435608483015260a43560a48301523360c4830152808816918260e48201528a81610104815f867f000000000000000000000000c19a303f856847e60aeddfc5b773017110b06e37165af19a8b15610a40575f9b610a21575b5050813b15610a1d5760248a5f809486519788958694637e51dad560e11b865216908401525af1908115610a1457506109ff575b506103199495610fef565b6103199550610a0d90610d2e565b5f946109f4565b513d5f823e3d90fd5b5f80fd5b610a38929b50803d10610365576103558183610d72565b985f806109c0565b84513d5f823e3d90fd5b610a62919750893d8b11610365576103558183610d72565b955f610939565b82513d5f823e3d90fd5b939450839083891611610a87575b806108bb565b9192505f610a81565b90945092505f806108ab565b50848c1682141561089c565b508b8516811415610896565b50838816818916141561087a565b50878116831415610874565b5087841683141561086e565b508781161515610868565b508784161515610862565b509034610a1d5780600319360112610a1d57610b0a610cec565b610b12610d02565b908251926080840184811067ffffffffffffffff821117610bc1576080955081525f84526020808501935f8552610b56838701915f835260608801955f8752610e81565b929060018060a01b03968794858093165f526001845282875f2091165f528352855f205f80528352818a610b8b885f20610d94565b82815116809c52828682015116845282898201511687520151168752855198895251169087015251169084015251166060820152f35b604186634e487b7160e01b5f525260245ffd5b509034610a1d576060366003190112610a1d5760a091610bf2610cec565b90610bfb610d02565b610c03610d18565b90600180871b038094165f52600160205283855f2091165f5260205282845f2091165f52602052825f20908282541693836001840154169380600285015416928160038601541694015416938151958652602086015284015260608301526080820152f35b8234610a1d575f366003190112610a1d57517f000000000000000000000000c19a303f856847e60aeddfc5b773017110b06e376001600160a01b03168152602090f35b34610a1d575f366003190112610a1d577f0000000000000000000000005271d6f66d4d881421fc2b1c48d4f99a9ba1d04c6001600160a01b03168152602090f35b600435906001600160a01b0382168203610a1d57565b602435906001600160a01b0382168203610a1d57565b604435906001600160a01b0382168203610a1d57565b67ffffffffffffffff8111610d4257604052565b634e487b7160e01b5f52604160045260245ffd5b60a0810190811067ffffffffffffffff821117610d4257604052565b90601f8019910116810190811067ffffffffffffffff821117610d4257604052565b90604051610da181610d56565b82546001600160a01b0390811682526001840154811660208301526002840154811660408301526003840154811660608301526004909301549092166080830152565b15610deb57565b60405162461bcd60e51b815260206004820152600d60248201526c24b63632b3b0b6103a37b5b2b760991b6044820152606490fd5b90816020910312610a1d57516001600160a01b0381168103610a1d5790565b15610e4657565b60405162461bcd60e51b81526020600482015260136024820152724944454e544943414c5f41444452455353455360681b6044820152606490fd5b6001600160a01b03828116908216610e9b81831415610e3f565b1015610ea45791565b9091565b5f546001600160a01b03163303610ebb57565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b91909260018060a01b0380941690815f52600160205260409385855f20941693845f52602052845f205f805260205285855f2091169560046001600160601b0360a01b928884825416178155600181018685825416179055600281018785825416179055600381018481541690550192169182828254161790556004545f52600360205285855f209182541617905560045460018101809111610fdb577f48dc7a1b156fe3e70ed5ed0afcb307661905edf536f15bb5786e327ea1933532946080945f92600455815194855260208501528301526060820152a2565b634e487b7160e01b5f52601160045260245ffd5b6001600160a01b038281165f818152600160208181526040808420898716808652908352818520878c1680875290845282862080546001600160a01b03199081169a8a169a8b178255818701805482169099179098556002810180548916909317909255600380830180548916909217909155600480830180548916998f16999099179098558754865290925290922080549093168517909255915492969195908301928310610fdb577f48dc7a1b156fe3e70ed5ed0afcb307661905edf536f15bb5786e327ea1933532956111029360045560018060a01b038216611107575b50604080516001600160a01b039586168152958516602087015290841690850152909116606083015281906080820190565b0390a2565b61111090610d94565b60018060a01b0385165f52600260205260405f2060018060a01b0387165f5260205260405f2060018060a01b038251166001600160601b0360a01b82541617815560018060a01b036020830151166001600160601b0360a01b60018301541617600182015560018060a01b036040830151166001600160601b0360a01b60028301541617600282015560018060a01b036060830151166001600160601b0360a01b600383015416176003820155600460018060a01b036080840151166001600160601b0360a01b82840154161791015560018060a01b0385165f52600260205260405f2060018060a01b0383165f52602052600460405f2060018060a01b038351166001600160601b0360a01b8254161781556001810160018060a01b036020850151166001600160601b0360a01b8254161790556002810160018060a01b036040850151166001600160601b0360a01b8254161790556003810160018060a01b036060850151166001600160601b0360a01b8254161790550160018060a01b036080830151166001600160601b0360a01b82541617905560018060a01b0386165f52600260205260405f2060018060a01b0383165f52602052600460405f2060018060a01b038351166001600160601b0360a01b8254161781556001810160018060a01b036020850151166001600160601b0360a01b8254161790556002810160018060a01b036040850151166001600160601b0360a01b8254161790556003810160018060a01b036060850151166001600160601b0360a01b8254161790550190608060018060a01b03910151166001600160601b0360a01b8254161790555f6110d056fea2646970667358221220c4e79079a4dc32cbd1f56dc410878b86703451268ad7bc4abf9bc4cb4fab250664736f6c63430008170033

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

0000000000000000000000005271d6f66d4d881421fc2b1c48d4f99a9ba1d04c000000000000000000000000f43fc445204174ea98cf45b21504463d32c28189000000000000000000000000c19a303f856847e60aeddfc5b773017110b06e37

-----Decoded View---------------
Arg [0] : _LPFactory (address): 0x5271D6f66D4d881421fC2b1c48D4f99A9bA1D04c
Arg [1] : _SwapTwoPoolDeployer (address): 0xf43FC445204174EA98CF45B21504463d32C28189
Arg [2] : _SwapThreePoolDeployer (address): 0xC19A303f856847e60AeddfC5b773017110b06e37

-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 0000000000000000000000005271d6f66d4d881421fc2b1c48d4f99a9ba1d04c
Arg [1] : 000000000000000000000000f43fc445204174ea98cf45b21504463d32c28189
Arg [2] : 000000000000000000000000c19a303f856847e60aeddfc5b773017110b06e37


Block Transaction Gas Used Reward
view all blocks ##produced##

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

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.