S Price: $0.067689 (-3.19%)
Gas: 55 Gwei

Contract

0x5a2e7C9f5164368B250Af2c2cdc4709c908fA686

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
Approve255133132025-05-09 13:23:49261 days ago1746797029IN
0x5a2e7C9f...c908fA686
0 S0.0026947855
Approve235076302025-05-01 11:47:28269 days ago1746100048IN
0x5a2e7C9f...c908fA686
0 S0.0028487761.05
Approve235076152025-05-01 11:47:23269 days ago1746100043IN
0x5a2e7C9f...c908fA686
0 S0.0028487761.05
Approve235075702025-05-01 11:47:09269 days ago1746100029IN
0x5a2e7C9f...c908fA686
0 S0.0048486498.96
Approve234214222025-05-01 3:07:59270 days ago1746068879IN
0x5a2e7C9f...c908fA686
0 S0.0026952655.01
Approve233728972025-04-30 21:18:24270 days ago1746047904IN
0x5a2e7C9f...c908fA686
0 S0.0023157550.0001
Transfer233722952025-04-30 21:14:13270 days ago1746047653IN
0x5a2e7C9f...c908fA686
0 S0.0079506650.0001
Execute Fee Upda...232783742025-04-30 11:43:01270 days ago1746013381IN
0x5a2e7C9f...c908fA686
0 S0.002356650.0001
Setve69LP Addres...232727852025-04-30 11:05:34271 days ago1746011134IN
0x5a2e7C9f...c908fA686
0 S0.001511650.0001
Set Lottery Addr...232727062025-04-30 11:05:03271 days ago1746011103IN
0x5a2e7C9f...c908fA686
0 S0.001324550.0001
Set Exchange Pai...232726622025-04-30 11:04:39271 days ago1746011079IN
0x5a2e7C9f...c908fA686
0 S0.0015127550.0001
Executeve69LP Ad...232725582025-04-30 11:03:49271 days ago1746011029IN
0x5a2e7C9f...c908fA686
0 S0.00165550.0001
Execute Jackpot ...232724272025-04-30 11:02:53271 days ago1746010973IN
0x5a2e7C9f...c908fA686
0 S0.0015989550.0001
Transfer223584292025-04-26 3:46:20275 days ago1745639180IN
0x5a2e7C9f...c908fA686
0 S0.0070535150.0001
Approve218946932025-04-24 2:25:55277 days ago1745461555IN
0x5a2e7C9f...c908fA686
0 S0.0023301550.0001
Approve218934082025-04-24 2:17:11277 days ago1745461031IN
0x5a2e7C9f...c908fA686
0 S0.0023151550.0001
Transfer218186142025-04-23 18:00:41277 days ago1745431241IN
0x5a2e7C9f...c908fA686
0 S0.0103030455.01
Scheduleve69LP A...214046542025-04-21 16:34:09279 days ago1745253249IN
0x5a2e7C9f...c908fA686
0 S0.001728550
Schedule Jackpot...214046432025-04-21 16:34:04279 days ago1745253244IN
0x5a2e7C9f...c908fA686
0 S0.0017318550
Scheduleve69LP A...214045032025-04-21 16:33:09279 days ago1745253189IN
0x5a2e7C9f...c908fA686
0 S0.001728550
Schedule Jackpot...214044912025-04-21 16:33:04279 days ago1745253184IN
0x5a2e7C9f...c908fA686
0 S0.0019858757.33400666
Set Sell Fees214042312025-04-21 16:31:10279 days ago1745253070IN
0x5a2e7C9f...c908fA686
0 S0.002047150
Set Buy Fees214042212025-04-21 16:31:06279 days ago1745253066IN
0x5a2e7C9f...c908fA686
0 S0.0020454550
Schedule Fee Upd...214042112025-04-21 16:31:02279 days ago1745253062IN
0x5a2e7C9f...c908fA686
0 S0.0018660953.668
Schedule Fee Upd...214041952025-04-21 16:30:57279 days ago1745253057IN
0x5a2e7C9f...c908fA686
0 S0.0017385550
View all transactions

View more zero value Internal Transactions in Advanced View mode

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

Similar Match Source Code
This contract matches the deployed Bytecode of the Source Code for Contract 0xF7441c12...5a4fb94a9
The constructor portion of the code might be different and could alter the actual behaviour of the contract

Contract Name:
Dragon

Compiler Version
v0.8.20+commit.a1b79de6

Optimization Enabled:
Yes with 200 runs

Other Settings:
paris EvmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 16 : Dragon.sol
// SPDX-License-Identifier: MIT
// Fair, Verifiable, Simple
// https://x.com/sonicreddragon
// https://t.me/sonicreddragon
// "You never catch me, Detective James Carter of the LAPD!" - Ricky Tan

pragma solidity ^0.8.20;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Burnable.sol";
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";
import "@openzeppelin/contracts/utils/Address.sol";
import "@openzeppelin/contracts/utils/math/SafeMath.sol";
import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol";
import "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol";
import "@openzeppelin/contracts/utils/math/Math.sol";
import "./interfaces/IDragonLotterySwap.sol";
import "./interfaces/IUniswapV2Router.sol";

/**
 * @title Dragon
 * @dev A deflationary ERC20 token with transparent fee distribution
 * Fixed 10% total fee on buys and sells:
 * - 6.9% jackpot
 * - 2.41% ve69LP
 * - 0.69% burned (sent to dead address)
 * No minting, no blacklist, no fee exclusions, no hidden fees
 */
contract Dragon is ERC20, Ownable, ReentrancyGuard {
    using EnumerableSet for EnumerableSet.AddressSet;
    using SafeMath for uint256;
    using SafeERC20 for IERC20;
    
    // Constants
    uint256 public constant FEE_DENOMINATOR = 10000;
    uint256 public constant MAX_LOCK_DURATION = 365 days;
    uint256 public constant MAX_SPECIAL_TRANSACTION_AMOUNT = 1000000 * 10**18;
    uint256 public constant MAX_TRANSACTION_AMOUNT = 10000000 * 10**18;
    uint256 public constant MAX_TOTAL_FEE = 1000; // 10%
    uint256 public constant INITIAL_SUPPLY = 6_942_000 * 10**18;
    uint256 public constant SPECIAL_LIMIT_TRANSACTIONS = 69;
    uint256 public constant SPECIAL_WALLET_LIMIT_PERCENT = 100; // 1%
    uint256 public constant POST_SPECIAL_WALLET_LIMIT_PERCENT = 1000; // 10%
    uint256 public constant FEE_UPDATE_DELAY = 24 hours;
    uint256 public constant ADMIN_ACTION_DELAY = 24 hours;
    address public constant BURN_ADDRESS = 0x000000000000000000000000000000000000dEaD;
    
    // State variables
    uint256 public transactionCount;
    uint256 public lastFeeUpdate;
    uint256 public totalBurned;
    uint256 public totalJackpotFees;
    uint256 public totalve69LPFees;
    uint256 public launchTimestamp;
    uint256 public totalHolders;
    
    // Fee tracking variables for current transaction
    uint256 private _jackpotFee;
    uint256 private _burnFee;
    uint256 private _ve69LPFee;
    uint256 private _totalFee;

    // Buy fees (in basis points, 100 = 1%)
    uint256 public buyBurnFee = 69;        // 0.69% = 69 basis points
    uint256 public buyJackpotFee = 690;    // 6.9% = 690 basis points
    uint256 public buyve69LPFee = 241;     // 2.41% = 241 basis points
    uint256 public totalFeeBuy = 1000;     // 10% = 1000 basis points
    
    // Sell fees (in basis points, 100 = 1%)
    uint256 public sellBurnFee = 69;       // 0.69% = 69 basis points
    uint256 public sellJackpotFee = 690;   // 6.9% = 690 basis points
    uint256 public sellve69LPFee = 241;    // 2.41% = 241 basis points
    uint256 public totalFeeSell = 1000;    // 10% = 1000 basis points

    // Regular Fees
    uint256 public jackpotFeeRegular;
    uint256 public burnFeeRegular;
    uint256 public ve69LPFeeRegular;
    uint256 public totalFeeRegular;
    
    // Current Fees
    uint256 public jackpotFee;
    uint256 public burnFee;
    uint256 public ve69LPFee;
    uint256 public totalFee;
    
    // Addresses
    address public jackpotAddress;
    address public ve69LPAddress;
    address public burnAddress;
    address public wrappedSonicAddress;
    address public lotteryAddress;
    address public exchangePair;

    // Trading state
    bool public tradingEnabled = false;
    bool public tradingEnabledPermanently = false;
    bool private inSwap = false;
    bool private _transferOptimization = true;
    bool public ownershipLocked = false;
    
    // Mappings
    mapping(address => bool) public isFeeExempt;
    mapping(address => uint256) public lastTransferTimestamp;
    mapping(address => bool) private _optimizedTransfers;
    mapping(bytes32 => uint256) public pendingActions;
    mapping(bytes32 => string) public pendingActionDescriptions;
    
    // Interfaces
    IERC20 public wrappedSonic;
    
    // Holder tracking
    EnumerableSet.AddressSet private _holders;
    
    // Events
    event FeesDistributed(uint256 amount);
    event TradingEnabled(bool enabled);
    event ExchangePairSet(address indexed pair);
    event SwapDetected(address indexed from, address indexed to, bool isWStoTokenSwap, uint256 wsAmount);
    event SwapDebug(string message, uint256 value);
    event SpecialTransactionPeriodEnded(uint256 timestamp);
    event ActionScheduled(bytes32 indexed actionId, string actionDescription, uint256 executionTime);
    event ActionExecuted(bytes32 indexed actionId, string actionDescription);
    event ActionCancelled(bytes32 indexed actionId, string actionDescription);
    event OwnershipRenounced();
    event ve69LPAddressUpdated(address indexed newAddress);
    event OwnershipLocked(uint256 duration);
    event RouterUpdated(address indexed newRouter);
    event TokensTransferred(
        address indexed from,
        address indexed to,
        uint256 transferAmount,
        uint256 burnAmount,
        uint256 jackpotAmount,
        uint256 veAmount
    );
    event FeeCollected(address indexed from, uint256 burnAmount, uint256 jackpotAmount, uint256 ve69LPAmount);
    event BuyFeesUpdated(uint256 burnFee, uint256 jackpotFee, uint256 ve69LPFee);
    event SellFeesUpdated(uint256 burnFee, uint256 jackpotFee, uint256 ve69LPFee);
    event FeeExemptUpdated(address indexed account, bool exempt);
    
    // Fee structure
    uint256 public constant SPECIAL_WALLET_LIMIT = INITIAL_SUPPLY * 69 / 10000;    // 0.69% of initial supply
    uint256 public constant POST_SPECIAL_WALLET_LIMIT = INITIAL_SUPPLY * 420 / 10000; // 4.20% of initial supply
    uint256 public constant SPECIAL_TRANSACTION_COUNT = 69;  // Number of special transactions
    
    // Track wS balance before and after swap to calculate the exact wS amount used
    uint256 private _preBuyWSBalance;
    bool private _trackingBuy;
    
    // Add this router variable to the state variables section
    IUniswapV2Router public router;
    
    /**
     * @dev Constructor to initialize the token with transparent security features
     */
    constructor(
        address _jackpotAddress,
        address _ve69LPAddress,
        address _burnAddress,
        address _wrappedSonicAddress
    ) ERC20("Dragon", "DRAGON") {
        require(_jackpotAddress != address(0), "Jackpot address cannot be zero");
        require(_ve69LPAddress != address(0), "ve69LP address cannot be zero");
        require(_burnAddress != address(0), "Burn address cannot be zero");
        require(_wrappedSonicAddress != address(0), "Wrapped Sonic address cannot be zero");

        jackpotAddress = _jackpotAddress;
        ve69LPAddress = _ve69LPAddress;
        burnAddress = _burnAddress;
        wrappedSonicAddress = _wrappedSonicAddress;
        wrappedSonic = IERC20(_wrappedSonicAddress);

        // Set initial fee exemptions
        isFeeExempt[address(this)] = true;
        isFeeExempt[address(this)] = true;
        buyve69LPFee = 241;  // 2.41%
        totalFeeBuy = buyJackpotFee + buyBurnFee + buyve69LPFee;

        // Initialize sell fees (10% total)
        sellJackpotFee = 690; // 6.9%
        sellBurnFee = 69;     // 0.69%
        sellve69LPFee = 241;  // 2.41%
        totalFeeSell = sellJackpotFee + sellBurnFee + sellve69LPFee;

        // Initialize regular fees (1% total)
        jackpotFeeRegular = 69;  // 0.69%
        burnFeeRegular = 7;      // 0.07%
        ve69LPFeeRegular = 24;   // 0.24%
        totalFeeRegular = 100;   // 1%

        // Set initial fee values
        jackpotFee = jackpotFeeRegular;
        burnFee = burnFeeRegular;
        ve69LPFee = ve69LPFeeRegular;
        totalFee = totalFeeRegular;

        // Mint initial supply to owner
        _mint(msg.sender, INITIAL_SUPPLY);
    }
    
    /**
     * @dev Sets the exchange pair address
     */
    function setExchangePair(address _exchangePair) external onlyOwner {
        require(_exchangePair != address(0), "Exchange pair cannot be zero address");
        exchangePair = _exchangePair;
        emit ExchangePairSet(_exchangePair);
    }
    
    /**
     * @dev Enables trading permanently - can only be called once
     */
    function enableTrading() external onlyOwner {
        require(!tradingEnabled, "Trading already enabled");
        tradingEnabled = true;
        tradingEnabledPermanently = true;
        emit TradingEnabled(true);
    }
    
    /**
     * @dev Handle the swap from $DRAGON to $wS, applying full fee structure
     * First, 0.69% of the $DRAGON tokens are burned
     * Then, from the resulting $wS, 6.9% goes to jackpot and 2.41% goes to ve69LP
     * @param user Address of the user swapping
     * @param dragonAmount Amount of $DRAGON tokens being swapped
     * @return wsAmount Amount of $wS tokens to return to user
     */
    function handleSwapToWS(address user, uint256 dragonAmount) external returns (uint256 wsAmount) {
        require(msg.sender == exchangePair, "Only exchange pair can call this");
        require(dragonAmount > 0, "Amount must be greater than zero");
        
        // First step: Calculate and burn 0.69% of input $DRAGON
        uint256 burnAmount = (dragonAmount * 69) / 10000; // 0.69%
        uint256 swapAmount = dragonAmount - burnAmount;  // 99.31%
        
        // Burn DRAGON tokens directly
        _burn(user, burnAmount);
        totalBurned += burnAmount;
        _trackFeeDistribution(3, burnAmount);
        
        // Transfer DRAGON tokens from user to exchange pair for the swap
        super._transfer(user, exchangePair, swapAmount);
        
        // Calculate resulting wS amount (1:1 for simplicity)
        // In a real implementation, this would use the actual exchange rate
        uint256 totalWsResult = swapAmount;
        
        // Second step: Calculate $wS fees from the swap result
        uint256 wsJackpotFee = (totalWsResult * 690) / 10000; // 6.9%
        uint256 wsve69LPFee = (totalWsResult * 241) / 10000;  // 2.41%
        uint256 wsTotalFee = wsJackpotFee + wsve69LPFee;      // 9.31%
        
        // Calculate the final $wS amount the user receives
        wsAmount = totalWsResult - wsTotalFee;
        
        // Distribute the $wS fees to their destinations
        // In a real implementation, the exchange would collect these and send them
        // Showing here for logical completion
        if (wsJackpotFee > 0) {
            // Exchange would send this amount of $wS to jackpot
            _trackFeeDistribution(1, wsJackpotFee);
            if (lotteryAddress != address(0)) {
                try IDragonLotterySwap(lotteryAddress).addToJackpot(wsJackpotFee) {} catch {}
            }
        }
        
        if (wsve69LPFee > 0) {
            // Exchange would send this amount of $wS to ve69LP
            _trackFeeDistribution(2, wsve69LPFee);
        }
        
        // Handle lottery sale event if needed
        if (lotteryAddress != address(0) && user == tx.origin && user.code.length == 0) {
            try IDragonLotterySwap(lotteryAddress).processSell(user, wsAmount) {} catch {}
        }
        
        // The exchange would send this amount of $wS to the user
        return wsAmount;
    }

    /**
     * @dev Handle the swap from $wS to $DRAGON, applying fees directly
     * Takes 9.31% of the input $wS tokens (6.9% to jackpot, 2.41% to ve69LP)
     * Burns 0.69% of the minted $DRAGON tokens
     * @param user Address of the user swapping
     * @param wsAmount Amount of $wS tokens being swapped
     * @return dragonAmount Amount of $DRAGON tokens returned to user
     */
    function handleSwapFromWS(address user, uint256 wsAmount) external returns (uint256 dragonAmount) {
        require(msg.sender == exchangePair, "Only exchange pair can call this");
        require(wsAmount > 0, "Amount must be greater than zero");
        
        // Calculate $wS fee amounts (9.31% of input $wS)
        uint256 wsJackpotFee = (wsAmount * 690) / 10000; // 6.9%
        uint256 wsve69LPFee = (wsAmount * 241) / 10000;  // 2.41%
        uint256 wsTotalFee = wsJackpotFee + wsve69LPFee; // 9.31%
        
        // Calculate actual $wS amount to be used for swap (after fees)
        uint256 wsSwapAmount = wsAmount - wsTotalFee;
        
        // Transfer $wS fees directly to their destinations
        if (wsJackpotFee > 0) {
            wrappedSonic.safeTransferFrom(user, jackpotAddress, wsJackpotFee);
            _trackFeeDistribution(1, wsJackpotFee);
            if (lotteryAddress != address(0)) {
                try IDragonLotterySwap(lotteryAddress).addToJackpot(wsJackpotFee) {} catch {}
            }
        }
        
        if (wsve69LPFee > 0) {
            wrappedSonic.safeTransferFrom(user, ve69LPAddress, wsve69LPFee);
            _trackFeeDistribution(2, wsve69LPFee);
        }
        
        // Transfer remaining $wS to exchange pair for the swap
        wrappedSonic.safeTransferFrom(user, exchangePair, wsSwapAmount);
        
        // Calculate $DRAGON burn amount (0.69% of resulting tokens)
        // Use 1:1 ratio for simplicity, in real implementation would use actual exchange rate
        dragonAmount = wsSwapAmount;
        uint256 burnAmount = (dragonAmount * 69) / 10000; // 0.69%
        uint256 userAmount = dragonAmount - burnAmount;   // 99.31%
        
        // Mint tokens (actual implementation would convert based on exchange rate)
        _mint(BURN_ADDRESS, burnAmount);
        _mint(user, userAmount);
        
        // Track the burn
        totalBurned += burnAmount;
        _trackFeeDistribution(3, burnAmount);
        
        // Handle lottery entry for user
        if (lotteryAddress != address(0) && user == tx.origin && user.code.length == 0) {
            try IDragonLotterySwap(lotteryAddress).processBuy(user, wsAmount) {} catch {}
        }
        
        // Return the total $DRAGON amount user receives
        return userAmount;
    }

    // In _transfer remove the fee logic since we're moving to swap-based fees
    function _transfer(address from, address to, uint256 amount) internal override {
        require(from != address(0), "Transfer from zero address");
        require(to != address(0), "Transfer to zero address");
        require(amount > 0, "Transfer amount must be greater than zero");

        // Check if trading is enabled
        if (!tradingEnabled && !isFeeExempt[from] && !isFeeExempt[to]) {
            revert("Trading not yet enabled");
        }

        // Update last transfer timestamp
        lastTransferTimestamp[from] = block.timestamp;
        lastTransferTimestamp[to] = block.timestamp;

        // Transfer without fees
        super._transfer(from, to, amount);
        
        // Update transaction count
        if (!isFeeExempt[from] && !isFeeExempt[to]) {
            transactionCount = transactionCount.add(1);
        }
    }

    function buyFees() internal {
        jackpotFee = buyJackpotFee;
        burnFee = buyBurnFee;
        ve69LPFee = buyve69LPFee;
        totalFee = totalFeeBuy;
    }

    function sellFees() internal {
        jackpotFee = sellJackpotFee;
        burnFee = sellBurnFee;
        ve69LPFee = sellve69LPFee;
        totalFee = totalFeeSell;
    }

    function regularFees() internal {
        jackpotFee = jackpotFeeRegular;
        burnFee = burnFeeRegular;
        ve69LPFee = ve69LPFeeRegular;
        totalFee = totalFeeRegular;
    }

    function shouldTakeFee(address sender) internal view returns (bool) {
        return false; // No more transfer fees
    }

    // Admin functions to update fees
    function setBuyFees(uint256 burnFee_, uint256 jackpotFee_, uint256 ve69LPFee_) external onlyOwner {
        require(burnFee_ + jackpotFee_ + ve69LPFee_ <= MAX_TOTAL_FEE, "Total fee too high");
        buyBurnFee = burnFee_;
        buyJackpotFee = jackpotFee_;
        buyve69LPFee = ve69LPFee_;
        emit BuyFeesUpdated(burnFee_, jackpotFee_, ve69LPFee_);
    }

    function setSellFees(uint256 burnFee_, uint256 jackpotFee_, uint256 ve69LPFee_) external onlyOwner {
        require(burnFee_ + jackpotFee_ + ve69LPFee_ <= MAX_TOTAL_FEE, "Total fee too high");
        sellBurnFee = burnFee_;
        sellJackpotFee = jackpotFee_;
        sellve69LPFee = ve69LPFee_;
        emit SellFeesUpdated(burnFee_, jackpotFee_, ve69LPFee_);
    }

    function setFeeExempt(address _account, bool _exempt) external onlyOwner {
        isFeeExempt[_account] = _exempt;
        emit FeeExemptUpdated(_account, _exempt);
    }

    /**
     * @dev Override the transfer function to add reentrancy protection
     */
    function transfer(address to, uint256 amount) public virtual override returns (bool) {
        _transfer(msg.sender, to, amount);
        return true;
    }

    /**
     * @dev Override the transferFrom function to add reentrancy protection
     */
    function transferFrom(address from, address to, uint256 amount) public virtual override returns (bool) {
        address spender = msg.sender;
        _spendAllowance(from, spender, amount);
        _transfer(from, to, amount);
        return true;
    }

    /**
     * @dev Sets the inSwap flag - only callable by the pair
     */
    function setInSwap(bool _inSwap) external {
        require(msg.sender == exchangePair, "Only pair can set inSwap");
        inSwap = _inSwap;
    }

    /**
     * @dev Handle lottery entry for a user
     * @param _user Address of the user
     * @param _wsAmount Amount of wS tokens
     */
    function _handleLotteryEntry(address _user, uint256 _wsAmount) private {
        // Ensure lottery contract is set and only allow actual users (not contracts)
        if (lotteryAddress != address(0) && _user == tx.origin && _user.code.length == 0) {
            // Only trigger lottery when swapping FROM wSonic TO DRAGON
            // Check if this transaction is a buy (DRAGON receiving)
            if (exchangePair != address(0) && msg.sender == exchangePair) {
                // Try to process lottery entry
                try IDragonLotterySwap(lotteryAddress).processBuy(_user, _wsAmount) {} catch {}
            }
        }
    }
    
    /**
     * @dev Check if an address is a contract
     * @param account Address to check
     * @return bool True if the address is a contract
     */
    function isContract(address account) private view returns (bool) {
        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

    // Transfer optimization
    function setTransferOptimization(bool enabled) external onlyOwner {
        _transferOptimization = enabled;
    }
    
    function setOptimizedTransfer(address account, bool enabled) external onlyOwner {
        _optimizedTransfers[account] = enabled;
    }

    function setTradingEnabled(bool _enabled) external onlyOwner {
        require(!tradingEnabledPermanently, "Trading is permanently enabled");
        tradingEnabled = _enabled;
        emit TradingEnabled(_enabled);
    }

    /**
     * @dev Set the lottery contract address
     */
    function setLotteryAddress(address _lotteryAddress) external onlyOwner {
        require(_lotteryAddress != address(0), "Lottery address cannot be zero");
        lotteryAddress = _lotteryAddress;
    }

    /**
     * @dev Get current transaction limit based on transaction count
     * @return The current maximum transaction amount (1% for first 69 tx, 10% after)
     */
    function getCurrentTransactionLimit() public view returns (uint256) {
        if (transactionCount < SPECIAL_LIMIT_TRANSACTIONS) {
            return SPECIAL_WALLET_LIMIT; // 1% during first 69 transactions
        }
        return POST_SPECIAL_WALLET_LIMIT; // 10% after first 69 transactions
    }

    /**
     * @dev Get current wallet limit based on transaction count
     * @return The current maximum wallet amount (1% for first 69 tx, 10% after)
     */
    function getCurrentWalletLimit() public view returns (uint256) {
        uint256 totalSupply = totalSupply();
        if (transactionCount < SPECIAL_LIMIT_TRANSACTIONS) {
            return totalSupply.mul(SPECIAL_WALLET_LIMIT_PERCENT).div(10000); // 1% during first 69 transactions
        }
        return totalSupply.mul(POST_SPECIAL_WALLET_LIMIT_PERCENT).div(10000); // 10% after first 69 transactions
    }

    /**
     * @dev Returns the number of remaining transactions at special limits
     * @return Number of transactions remaining at the 2% special limit
     */
    function getRemainingSpecialTransactions() public view returns (uint256) {
        if (transactionCount >= SPECIAL_LIMIT_TRANSACTIONS) {
            return 0;
        }
        return SPECIAL_LIMIT_TRANSACTIONS - transactionCount;
    }

    // Timelock admin functions
    
    /**
     * @dev Schedule an admin action to be executed after timelock
     * @param actionId The unique identifier for the action
     * @param description A human-readable description of the action
     */
    function scheduleAction(bytes32 actionId, string memory description) external onlyOwner {
        require(pendingActions[actionId] == 0, "Action already scheduled");
        require(!ownershipLocked, "Ownership is locked");
        
        pendingActions[actionId] = block.timestamp + ADMIN_ACTION_DELAY;
        pendingActionDescriptions[actionId] = description;
        
        emit ActionScheduled(actionId, description, pendingActions[actionId]);
    }
    
    /**
     * @dev Cancel a proposed action
     * @param actionId The ID of the action to cancel
     */
    function cancelAction(bytes32 actionId) external onlyOwner {
        require(pendingActions[actionId] > 0, "Action not scheduled");
        
        string memory description = pendingActionDescriptions[actionId];
        delete pendingActions[actionId];
        delete pendingActionDescriptions[actionId];
        
        emit ActionCancelled(actionId, description);
    }
    
    /**
     * @dev Check if an action is ready to be executed
     * @param actionId The action to check
     * @return bool True if the action is ready for execution
     */
    function isActionReady(bytes32 actionId) public view returns (bool) {
        uint256 executionTime = pendingActions[actionId];
        return executionTime > 0 && block.timestamp >= executionTime;
    }
    
    /**
     * @dev Generate action ID for common operations
     * @param functionSig Function signature
     * @param params Parameters to include in the ID
     * @return bytes32 The generated action ID
     */
    function getActionId(string memory functionSig, bytes memory params) public pure returns (bytes32) {
        return keccak256(abi.encodePacked(functionSig, params));
    }
    
    /**
     * @dev Execute setExchangePair with timelock
     * @param _exchangePair The exchange pair address to set
     */
    function setExchangePairWithTimelock(address _exchangePair) external onlyOwner {
        bytes32 actionId = getActionId("setExchangePair", abi.encodePacked(_exchangePair));
        require(isActionReady(actionId), "Timelock not expired");
        
        // Clear the pending action
        delete pendingActions[actionId];
        string memory description = pendingActionDescriptions[actionId];
        delete pendingActionDescriptions[actionId];
        
        // Execute the actual function
        _setExchangePair(_exchangePair);
        
        emit ActionExecuted(actionId, description);
    }
    
    /**
     * @dev Internal implementation of setExchangePair
     */
    function _setExchangePair(address _exchangePair) private {
        require(_exchangePair != address(0), "Exchange pair cannot be zero address");
        exchangePair = _exchangePair;
        emit ExchangePairSet(_exchangePair);
    }
    
    /**
     * @dev Set the lottery address with timelock
     * @param _lotteryAddress The new lottery address
     */
    function setLotteryAddressWithTimelock(address _lotteryAddress) external onlyOwner {
        bytes32 actionId = getActionId("setLotteryAddress", abi.encodePacked(_lotteryAddress));
        require(isActionReady(actionId), "Timelock not expired");
        
        // Clear the pending action
        delete pendingActions[actionId];
        string memory description = pendingActionDescriptions[actionId];
        delete pendingActionDescriptions[actionId];
        
        // Execute the actual function
        _setLotteryAddress(_lotteryAddress);
        
        emit ActionExecuted(actionId, description);
    }
    
    /**
     * @dev Internal implementation of setLotteryAddress
     */
    function _setLotteryAddress(address _lotteryAddress) private {
        require(_lotteryAddress != address(0), "Lottery address cannot be zero");
        lotteryAddress = _lotteryAddress;
    }
    
    /**
     * @dev Set fee exemption status with timelock
     * @param account The account to set exemption for
     * @param exempt Whether the account should be exempt from fees
     */
    function setFeeExemptWithTimelock(address account, bool exempt) external onlyOwner {
        bytes32 actionId = getActionId("setFeeExempt", abi.encodePacked(account, exempt));
        require(isActionReady(actionId), "Timelock not expired");
        
        // Clear the pending action
        delete pendingActions[actionId];
        string memory description = pendingActionDescriptions[actionId];
        delete pendingActionDescriptions[actionId];
        
        // Execute the actual function
        _setFeeExempt(account, exempt);
        
        emit ActionExecuted(actionId, description);
    }
    
    /**
     * @dev Internal implementation of setFeeExempt
     */
    function _setFeeExempt(address account, bool exempt) private {
        require(account != address(0), "Cannot exempt zero address");
        isFeeExempt[account] = exempt;
    }
    
    /**
     * @dev Lock all direct admin functions to enforce timelock usage
     * This enhances security by requiring all admin actions to use timelock
     */
    function lockOwnership(uint256 _lockDuration) external onlyOwner {
        require(!ownershipLocked, "Ownership already locked");
        require(_lockDuration > 0 && _lockDuration <= MAX_LOCK_DURATION, "Invalid lock duration");
        
        ownershipLocked = true;
        emit OwnershipLocked(_lockDuration);
    }
    
    /**
     * @dev Permanently renounce ownership with timelock for maximum security
     * This is irreversible and will remove all admin control over the contract
     */
    function renounceOwnershipWithTimelock() external onlyOwner {
        bytes32 actionId = getActionId("renounceOwnership", "");
        require(isActionReady(actionId), "Timelock not expired");
        
        // Execute ownership renouncement
        _transferOwnership(address(0));
        
        emit OwnershipRenounced();
        emit ActionExecuted(actionId, "Renounce ownership");
    }
    
    // Transparency functions
    
    /**
     * @dev Get detailed fee information for transparency
     * @return jackpotFeeBuy_ Current buy jackpot fee
     * @return burnFeeBuy_ Current buy burn fee
     * @return ve69LPFeeBuy_ Current buy ve69LP fee
     * @return totalFeeBuy_ Total buy fee
     * @return jackpotFeeSell_ Current sell jackpot fee
     * @return burnFeeSell_ Current sell burn fee
     * @return ve69LPFeeSell_ Current sell ve69LP fee
     * @return totalFeeSell_ Total sell fee
     */
    function getDetailedFeeInfo() external view returns (
        uint256 jackpotFeeBuy_,
        uint256 burnFeeBuy_,
        uint256 ve69LPFeeBuy_,
        uint256 totalFeeBuy_,
        uint256 jackpotFeeSell_,
        uint256 burnFeeSell_,
        uint256 ve69LPFeeSell_,
        uint256 totalFeeSell_
    ) {
        return (
            buyJackpotFee,
            buyBurnFee,
            buyve69LPFee,
            totalFeeBuy,
            sellJackpotFee,
            sellBurnFee,
            sellve69LPFee,
            totalFeeSell
        );
    }
    
    /**
     * @dev Get detailed contract configuration for transparency
     * @return jackpotAddress_ Address receiving jackpot fees
     * @return ve69LPAddress_ Address receiving liquidity and development fees
     * @return burnAddress_ Address receiving burn fees
     * @return wrappedSonicAddress_ Address of wrapped Sonic token
     * @return lotteryAddress_ Address of lottery contract
     * @return exchangePair_ Address of exchange pair
     * @return tradingEnabled_ Whether trading is enabled
     * @return ownershipLocked_ Whether ownership is locked
     */
    function getContractConfiguration() external view returns (
        address jackpotAddress_,
        address ve69LPAddress_,
        address burnAddress_,
        address wrappedSonicAddress_,
        address lotteryAddress_,
        address exchangePair_,
        bool tradingEnabled_,
        bool ownershipLocked_
    ) {
        return (
            jackpotAddress,
            ve69LPAddress,
            burnAddress,
            wrappedSonicAddress,
            lotteryAddress,
            exchangePair,
            tradingEnabled,
            ownershipLocked
        );
    }
    
    /**
     * @dev Get transaction limits information
     * @return currentTxLimit Current maximum transaction amount
     * @return currentWalletLimit Current maximum wallet amount
     * @return specialTxRemaining Number of special transactions remaining
     * @return currentTxCount Current transaction count
     */
    function getLimitsInfo() external view returns (
        uint256 currentTxLimit,
        uint256 currentWalletLimit,
        uint256 specialTxRemaining,
        uint256 currentTxCount
    ) {
        return (
            getCurrentTransactionLimit(),
            getCurrentWalletLimit(),
            getRemainingSpecialTransactions(),
            transactionCount
        );
    }
    
    /**
     * @dev Track fee distributions for transparency
     * @param feeType The type of fee (1=jackpot, 2=liquidity, 3=burn, 4=development)
     * @param amount The amount of fee distributed
     */
    function _trackFeeDistribution(uint8 feeType, uint256 amount) private {
        if (feeType == 1) {
            totalJackpotFees += amount;
        } else if (feeType == 2) {
            totalve69LPFees += amount;
        } else if (feeType == 3) {
            totalBurned += amount;
        }
    }
    
    /**
     * @dev Get statistics about fee distributions
     * @return totalBurned_ Total tokens burned
     * @return totalJackpotFees_ Total tokens sent to jackpot
     * @return totalve69LPFees_ Total tokens sent to liquidity and development
     */
    function getFeeStats() external view returns (
        uint256 totalBurned_,
        uint256 totalJackpotFees_,
        uint256 totalve69LPFees_
    ) {
        return (
            totalBurned,
            totalJackpotFees,
            totalve69LPFees
        );
    }
    
    /**
     * @dev Record token holder for transparency
     * @param holder The address to track
     */
    function _recordHolder(address holder) private {
        if (holder != address(0) && holder != BURN_ADDRESS && holder != address(this)) {
            if (!_holders.contains(holder) && balanceOf(holder) > 0) {
                _holders.add(holder);
                totalHolders = _holders.length();
            } else if (_holders.contains(holder) && balanceOf(holder) == 0) {
                _holders.remove(holder);
                totalHolders = _holders.length();
            }
        }
    }
    
    /**
     * @dev Override _afterTokenTransfer to track holders
     */
    function _afterTokenTransfer(address from, address to, uint256 amount) internal virtual override {
        super._afterTokenTransfer(from, to, amount);
        
        // Track holders for transparency
        _recordHolder(from);
        _recordHolder(to);
        
        // Set launch timestamp on first transfer after trading enabled
        if (tradingEnabled && launchTimestamp == 0) {
            launchTimestamp = block.timestamp;
        }
    }
    
    /**
     * @dev Get holder at specific index (used for transparency dashboards)
     * @param index The index of the holder to retrieve
     * @return The address of the holder at the specified index
     */
    function getHolderAt(uint256 index) external view returns (address) {
        require(index < _holders.length(), "Index out of bounds");
        return _holders.at(index);
    }
    
    /**
     * @dev Get the total number of addresses holding the token
     * @return The number of unique holders
     */
    function getHolderCount() external view returns (uint256) {
        return _holders.length();
    }

    /**
     * @dev Sets the ve69LPAddress for the token
     * @param _ve69LPAddress New address for the ve69LPFeeDistributor
     */
    function setve69LPAddress(address _ve69LPAddress) external onlyOwner {
        require(_ve69LPAddress != address(0), "ve69LP address cannot be zero");
        ve69LPAddress = _ve69LPAddress;
        emit ve69LPAddressUpdated(_ve69LPAddress);
    }

    /**
     * @dev Schedule an update to the jackpot address
     * @param _newAddress The new jackpot address
     */
    function scheduleJackpotAddressUpdate(address _newAddress) external onlyOwner {
        require(_newAddress != address(0), "New address cannot be zero");
        bytes32 actionId = keccak256(abi.encodePacked("updateJackpotAddress", _newAddress));
        pendingActions[actionId] = block.timestamp + ADMIN_ACTION_DELAY;
        pendingActionDescriptions[actionId] = "Update jackpot address";
        emit ActionScheduled(actionId, "Update jackpot address", block.timestamp + ADMIN_ACTION_DELAY);
    }

    /**
     * @dev Execute a scheduled jackpot address update
     * @param _newAddress The new jackpot address
     */
    function executeJackpotAddressUpdate(address _newAddress) external onlyOwner {
        bytes32 actionId = keccak256(abi.encodePacked("updateJackpotAddress", _newAddress));
        require(pendingActions[actionId] > 0 && pendingActions[actionId] <= block.timestamp, "Action not ready or expired");
        jackpotAddress = _newAddress;
        delete pendingActions[actionId];
        emit ActionExecuted(actionId, "Update jackpot address");
    }

    /**
     * @dev Schedule an update to the ve69LP address
     * @param _newAddress The new ve69LP address
     */
    function scheduleve69LPAddressUpdate(address _newAddress) external onlyOwner {
        require(_newAddress != address(0), "New address cannot be zero");
        bytes32 actionId = keccak256(abi.encodePacked("updateve69LPAddress", _newAddress));
        pendingActions[actionId] = block.timestamp + ADMIN_ACTION_DELAY;
        pendingActionDescriptions[actionId] = "Update ve69LP address";
        emit ActionScheduled(actionId, "Update ve69LP address", block.timestamp + ADMIN_ACTION_DELAY);
    }

    /**
     * @dev Execute a scheduled ve69LP address update
     * @param _newAddress The new ve69LP address
     */
    function executeve69LPAddressUpdate(address _newAddress) external onlyOwner {
        bytes32 actionId = keccak256(abi.encodePacked("updateve69LPAddress", _newAddress));
        require(pendingActions[actionId] > 0 && pendingActions[actionId] <= block.timestamp, "Action not ready or expired");
        ve69LPAddress = _newAddress;
        delete pendingActions[actionId];
        emit ActionExecuted(actionId, "Update ve69LP address");
        emit ve69LPAddressUpdated(_newAddress);
    }

    /**
     * @dev Schedule a fee update
     * @param newJackpotFee New jackpot fee
     * @param newBurnFee New burn fee
     * @param newve69LPFee New ve69LP fee
     */
    function scheduleFeeUpdate(uint256 newJackpotFee, uint256 newBurnFee, uint256 newve69LPFee) external onlyOwner {
        uint256 totalNewFee = newJackpotFee + newBurnFee + newve69LPFee;
        require(totalNewFee <= 1000, "Total fee cannot exceed 10%");
        bytes32 actionId = keccak256(abi.encodePacked("updateFees", newJackpotFee, newBurnFee, newve69LPFee));
        pendingActions[actionId] = block.timestamp + FEE_UPDATE_DELAY;
        pendingActionDescriptions[actionId] = "Update fees";
        emit ActionScheduled(actionId, "Update fees", block.timestamp + FEE_UPDATE_DELAY);
    }

    /**
     * @dev Execute a scheduled fee update
     * @param newJackpotFee New jackpot fee
     * @param newBurnFee New burn fee
     * @param newve69LPFee New ve69LP fee
     */
    function executeFeeUpdate(uint256 newJackpotFee, uint256 newBurnFee, uint256 newve69LPFee) external onlyOwner {
        bytes32 actionId = keccak256(abi.encodePacked("updateFees", newJackpotFee, newBurnFee, newve69LPFee));
        require(pendingActions[actionId] > 0 && pendingActions[actionId] <= block.timestamp, "Action not ready or expired");
        jackpotFee = newJackpotFee;
        burnFee = newBurnFee;
        ve69LPFee = newve69LPFee;
        totalFee = newJackpotFee + newBurnFee + newve69LPFee;
        delete pendingActions[actionId];
        emit ActionExecuted(actionId, "Update fees");
    }

    /**
     * @dev Sets the router address for token swaps
     * @param _router The new router address
     */
    function setRouter(address _router) external onlyOwner {
        require(_router != address(0), "Router address cannot be zero");
        router = IUniswapV2Router(_router);
        emit RouterUpdated(_router);
    }

    /**
     * @dev Allows burning tokens
     * @param amount Amount of tokens to burn
     */
    function burn(uint256 amount) external {
        _burn(msg.sender, amount);
        totalBurned += amount;
        _trackFeeDistribution(3, amount);
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.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 anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

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

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

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)

pragma solidity ^0.8.0;

/**
 * @dev Contract module that helps prevent reentrant calls to a function.
 *
 * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
 * available, which can be applied to functions to make sure there are no nested
 * (reentrant) calls to them.
 *
 * Note that because there is a single `nonReentrant` guard, functions marked as
 * `nonReentrant` may not call one another. This can be worked around by making
 * those functions `private`, and then adding `external` `nonReentrant` entry
 * points to them.
 *
 * TIP: If you would like to learn more about reentrancy and alternative ways
 * to protect against it, check out our blog post
 * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
 */
abstract contract ReentrancyGuard {
    // Booleans are more expensive than uint256 or any type that takes up a full
    // word because each write operation emits an extra SLOAD to first read the
    // slot's contents, replace the bits taken up by the boolean, and then write
    // back. This is the compiler's defense against contract upgrades and
    // pointer aliasing, and it cannot be disabled.

    // The values being non-zero value makes deployment a bit more expensive,
    // but in exchange the refund on every call to nonReentrant will be lower in
    // amount. Since refunds are capped to a percentage of the total
    // transaction's gas, it is best to keep them low in cases like this one, to
    // increase the likelihood of the full refund coming into effect.
    uint256 private constant _NOT_ENTERED = 1;
    uint256 private constant _ENTERED = 2;

    uint256 private _status;

    constructor() {
        _status = _NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and making it call a
     * `private` function that does the actual work.
     */
    modifier nonReentrant() {
        _nonReentrantBefore();
        _;
        _nonReentrantAfter();
    }

    function _nonReentrantBefore() private {
        // On the first call to nonReentrant, _status will be _NOT_ENTERED
        require(_status != _ENTERED, "ReentrancyGuard: reentrant call");

        // Any calls to nonReentrant after this point will fail
        _status = _ENTERED;
    }

    function _nonReentrantAfter() private {
        // By storing the original value once again, a refund is triggered (see
        // https://eips.ethereum.org/EIPS/eip-2200)
        _status = _NOT_ENTERED;
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/ERC20.sol)

pragma solidity ^0.8.0;

import "./IERC20.sol";
import "./extensions/IERC20Metadata.sol";
import "../../utils/Context.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin Contracts guidelines: functions revert
 * instead returning `false` on failure. This behavior is nonetheless
 * conventional and does not conflict with the expectations of ERC20
 * applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20, IERC20Metadata {
    mapping(address => uint256) private _balances;

    mapping(address => mapping(address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @dev Sets the values for {name} and {symbol}.
     *
     * The default value of {decimals} is 18. To select a different value for
     * {decimals} you should overload it.
     *
     * All two of these values are immutable: they can only be set once during
     * construction.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5.05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless this function is
     * overridden;
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual override returns (uint8) {
        return 18;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address to, uint256 amount) public virtual override returns (bool) {
        address owner = _msgSender();
        _transfer(owner, to, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on
     * `transferFrom`. This is semantically equivalent to an infinite approval.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        address owner = _msgSender();
        _approve(owner, spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20}.
     *
     * NOTE: Does not update the allowance if the current allowance
     * is the maximum `uint256`.
     *
     * Requirements:
     *
     * - `from` and `to` cannot be the zero address.
     * - `from` must have a balance of at least `amount`.
     * - the caller must have allowance for ``from``'s tokens of at least
     * `amount`.
     */
    function transferFrom(
        address from,
        address to,
        uint256 amount
    ) public virtual override returns (bool) {
        address spender = _msgSender();
        _spendAllowance(from, spender, amount);
        _transfer(from, to, amount);
        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        address owner = _msgSender();
        _approve(owner, spender, allowance(owner, spender) + addedValue);
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        address owner = _msgSender();
        uint256 currentAllowance = allowance(owner, spender);
        require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero");
        unchecked {
            _approve(owner, spender, currentAllowance - subtractedValue);
        }

        return true;
    }

    /**
     * @dev Moves `amount` of tokens from `from` to `to`.
     *
     * This internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `from` must have a balance of at least `amount`.
     */
    function _transfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {
        require(from != address(0), "ERC20: transfer from the zero address");
        require(to != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(from, to, amount);

        uint256 fromBalance = _balances[from];
        require(fromBalance >= amount, "ERC20: transfer amount exceeds balance");
        unchecked {
            _balances[from] = fromBalance - amount;
            // Overflow not possible: the sum of all balances is capped by totalSupply, and the sum is preserved by
            // decrementing then incrementing.
            _balances[to] += amount;
        }

        emit Transfer(from, to, amount);

        _afterTokenTransfer(from, to, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply += amount;
        unchecked {
            // Overflow not possible: balance + amount is at most totalSupply + amount, which is checked above.
            _balances[account] += amount;
        }
        emit Transfer(address(0), account, amount);

        _afterTokenTransfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        unchecked {
            _balances[account] = accountBalance - amount;
            // Overflow not possible: amount <= accountBalance <= totalSupply.
            _totalSupply -= amount;
        }

        emit Transfer(account, address(0), amount);

        _afterTokenTransfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(
        address owner,
        address spender,
        uint256 amount
    ) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Updates `owner` s allowance for `spender` based on spent `amount`.
     *
     * Does not update the allowance amount in case of infinite allowance.
     * Revert if not enough allowance is available.
     *
     * Might emit an {Approval} event.
     */
    function _spendAllowance(
        address owner,
        address spender,
        uint256 amount
    ) internal virtual {
        uint256 currentAllowance = allowance(owner, spender);
        if (currentAllowance != type(uint256).max) {
            require(currentAllowance >= amount, "ERC20: insufficient allowance");
            unchecked {
                _approve(owner, spender, currentAllowance - amount);
            }
        }
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {}

    /**
     * @dev Hook that is called after any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * has been transferred to `to`.
     * - when `from` is zero, `amount` tokens have been minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens have been burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {}
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
 * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
 *
 * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
 * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't
 * need to send a transaction, and thus is not required to hold Ether at all.
 */
interface IERC20Permit {
    /**
     * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,
     * given ``owner``'s signed approval.
     *
     * IMPORTANT: The same issues {IERC20-approve} has related to transaction
     * ordering also apply here.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `deadline` must be a timestamp in the future.
     * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
     * over the EIP712-formatted function arguments.
     * - the signature must use ``owner``'s current nonce (see {nonces}).
     *
     * For more information on the signature format, see the
     * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
     * section].
     */
    function permit(
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) external;

    /**
     * @dev Returns the current nonce for `owner`. This value must be
     * included whenever a signature is generated for {permit}.
     *
     * Every successful call to {permit} increases ``owner``'s nonce by one. This
     * prevents a signature from being used multiple times.
     */
    function nonces(address owner) external view returns (uint256);

    /**
     * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.
     */
    // solhint-disable-next-line func-name-mixedcase
    function DOMAIN_SEPARATOR() external view returns (bytes32);
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC20/extensions/ERC20Burnable.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev Extension of {ERC20} that allows token holders to destroy both their own
 * tokens and those that they have an allowance for, in a way that can be
 * recognized off-chain (via event analysis).
 */
abstract contract ERC20Burnable is Context, ERC20 {
    /**
     * @dev Destroys `amount` tokens from the caller.
     *
     * See {ERC20-_burn}.
     */
    function burn(uint256 amount) public virtual {
        _burn(_msgSender(), amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, deducting from the caller's
     * allowance.
     *
     * See {ERC20-_burn} and {ERC20-allowance}.
     *
     * Requirements:
     *
     * - the caller must have allowance for ``accounts``'s tokens of at least
     * `amount`.
     */
    function burnFrom(address account, uint256 amount) public virtual {
        _spendAllowance(account, _msgSender(), amount);
        _burn(account, amount);
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";

/**
 * @dev Interface for the optional metadata functions from the ERC20 standard.
 *
 * _Available since v4.1._
 */
interface IERC20Metadata is IERC20 {
    /**
     * @dev Returns the name of the token.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the symbol of the token.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the decimals places of the token.
     */
    function decimals() external view returns (uint8);
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);

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

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `from` to `to` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 amount
    ) external returns (bool);
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../extensions/draft-IERC20Permit.sol";
import "../../../utils/Address.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
        }
    }

    function safePermit(
        IERC20Permit token,
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) internal {
        uint256 nonceBefore = token.nonces(owner);
        token.permit(owner, spender, value, deadline, v, r, s);
        uint256 nonceAfter = token.nonces(owner);
        require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed");
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) {
            // Return data is optional
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
     * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
     *
     * _Available since v4.8._
     */
    function verifyCallResultFromTarget(
        address target,
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        if (success) {
            if (returndata.length == 0) {
                // only check isContract if the call was successful and the return data is empty
                // otherwise we already know that it was a contract
                require(isContract(target), "Address: call to non-contract");
            }
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    /**
     * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason or using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    function _revert(bytes memory returndata, string memory errorMessage) private pure {
        // Look for revert reason and bubble it up if present
        if (returndata.length > 0) {
            // The easiest way to bubble the revert reason is using memory via assembly
            /// @solidity memory-safe-assembly
            assembly {
                let returndata_size := mload(returndata)
                revert(add(32, returndata), returndata_size)
            }
        } else {
            revert(errorMessage);
        }
    }
}

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

pragma solidity ^0.8.0;

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

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

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)

pragma solidity ^0.8.0;

/**
 * @dev Standard math utilities missing in the Solidity language.
 */
library Math {
    enum Rounding {
        Down, // Toward negative infinity
        Up, // Toward infinity
        Zero // Toward zero
    }

    /**
     * @dev Returns the largest of two numbers.
     */
    function max(uint256 a, uint256 b) internal pure returns (uint256) {
        return a > b ? a : b;
    }

    /**
     * @dev Returns the smallest of two numbers.
     */
    function min(uint256 a, uint256 b) internal pure returns (uint256) {
        return a < b ? a : b;
    }

    /**
     * @dev Returns the average of two numbers. The result is rounded towards
     * zero.
     */
    function average(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b) / 2 can overflow.
        return (a & b) + (a ^ b) / 2;
    }

    /**
     * @dev Returns the ceiling of the division of two numbers.
     *
     * This differs from standard division with `/` in that it rounds up instead
     * of rounding down.
     */
    function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b - 1) / b can overflow on addition, so we distribute.
        return a == 0 ? 0 : (a - 1) / b + 1;
    }

    /**
     * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0
     * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)
     * with further edits by Uniswap Labs also under MIT license.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator
    ) internal pure returns (uint256 result) {
        unchecked {
            // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
            // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
            // variables such that product = prod1 * 2^256 + prod0.
            uint256 prod0; // Least significant 256 bits of the product
            uint256 prod1; // Most significant 256 bits of the product
            assembly {
                let mm := mulmod(x, y, not(0))
                prod0 := mul(x, y)
                prod1 := sub(sub(mm, prod0), lt(mm, prod0))
            }

            // Handle non-overflow cases, 256 by 256 division.
            if (prod1 == 0) {
                return prod0 / denominator;
            }

            // Make sure the result is less than 2^256. Also prevents denominator == 0.
            require(denominator > prod1);

            ///////////////////////////////////////////////
            // 512 by 256 division.
            ///////////////////////////////////////////////

            // Make division exact by subtracting the remainder from [prod1 prod0].
            uint256 remainder;
            assembly {
                // Compute remainder using mulmod.
                remainder := mulmod(x, y, denominator)

                // Subtract 256 bit number from 512 bit number.
                prod1 := sub(prod1, gt(remainder, prod0))
                prod0 := sub(prod0, remainder)
            }

            // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.
            // See https://cs.stackexchange.com/q/138556/92363.

            // Does not overflow because the denominator cannot be zero at this stage in the function.
            uint256 twos = denominator & (~denominator + 1);
            assembly {
                // Divide denominator by twos.
                denominator := div(denominator, twos)

                // Divide [prod1 prod0] by twos.
                prod0 := div(prod0, twos)

                // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
                twos := add(div(sub(0, twos), twos), 1)
            }

            // Shift in bits from prod1 into prod0.
            prod0 |= prod1 * twos;

            // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
            // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
            // four bits. That is, denominator * inv = 1 mod 2^4.
            uint256 inverse = (3 * denominator) ^ 2;

            // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works
            // in modular arithmetic, doubling the correct bits in each step.
            inverse *= 2 - denominator * inverse; // inverse mod 2^8
            inverse *= 2 - denominator * inverse; // inverse mod 2^16
            inverse *= 2 - denominator * inverse; // inverse mod 2^32
            inverse *= 2 - denominator * inverse; // inverse mod 2^64
            inverse *= 2 - denominator * inverse; // inverse mod 2^128
            inverse *= 2 - denominator * inverse; // inverse mod 2^256

            // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
            // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
            // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
            // is no longer required.
            result = prod0 * inverse;
            return result;
        }
    }

    /**
     * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator,
        Rounding rounding
    ) internal pure returns (uint256) {
        uint256 result = mulDiv(x, y, denominator);
        if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {
            result += 1;
        }
        return result;
    }

    /**
     * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.
     *
     * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
     */
    function sqrt(uint256 a) internal pure returns (uint256) {
        if (a == 0) {
            return 0;
        }

        // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
        //
        // We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
        // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
        //
        // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
        // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
        // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
        //
        // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
        uint256 result = 1 << (log2(a) >> 1);

        // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
        // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
        // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
        // into the expected uint128 result.
        unchecked {
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            return min(result, a / result);
        }
    }

    /**
     * @notice Calculates sqrt(a), following the selected rounding direction.
     */
    function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = sqrt(a);
            return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 2, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 128;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 64;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 32;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 16;
            }
            if (value >> 8 > 0) {
                value >>= 8;
                result += 8;
            }
            if (value >> 4 > 0) {
                value >>= 4;
                result += 4;
            }
            if (value >> 2 > 0) {
                value >>= 2;
                result += 2;
            }
            if (value >> 1 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 2, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log2(value);
            return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 10, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >= 10**64) {
                value /= 10**64;
                result += 64;
            }
            if (value >= 10**32) {
                value /= 10**32;
                result += 32;
            }
            if (value >= 10**16) {
                value /= 10**16;
                result += 16;
            }
            if (value >= 10**8) {
                value /= 10**8;
                result += 8;
            }
            if (value >= 10**4) {
                value /= 10**4;
                result += 4;
            }
            if (value >= 10**2) {
                value /= 10**2;
                result += 2;
            }
            if (value >= 10**1) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log10(value);
            return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 256, rounded down, of a positive value.
     * Returns 0 if given 0.
     *
     * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
     */
    function log256(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 16;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 8;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 4;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 2;
            }
            if (value >> 8 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log256(value);
            return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);
        }
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (utils/math/SafeMath.sol)

pragma solidity ^0.8.0;

// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.

/**
 * @dev Wrappers over Solidity's arithmetic operations.
 *
 * NOTE: `SafeMath` is generally not needed starting with Solidity 0.8, since the compiler
 * now has built in overflow checking.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            uint256 c = a + b;
            if (c < a) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b > a) return (false, 0);
            return (true, a - b);
        }
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
            // benefit is lost if 'b' is also tested.
            // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
            if (a == 0) return (true, 0);
            uint256 c = a * b;
            if (c / a != b) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the division of two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a / b);
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a % b);
        }
    }

    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        return a + b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return a - b;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        return a * b;
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator.
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return a % b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {trySub}.
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b <= a, errorMessage);
            return a - b;
        }
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a / b;
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a % b;
        }
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/structs/EnumerableSet.sol)
// This file was procedurally generated from scripts/generate/templates/EnumerableSet.js.

pragma solidity ^0.8.0;

/**
 * @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.
 *
 * ```
 * 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 of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping(bytes32 => uint256) _indexes;
    }

    /**
     * @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._indexes[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 read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 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 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            if (lastIndex != toDeleteIndex) {
                bytes32 lastValue = set._values[lastIndex];

                // Move the last value to the index where the value to delete is
                set._values[toDeleteIndex] = lastValue;
                // Update the index for the moved value
                set._indexes[lastValue] = valueIndex; // Replace lastValue's index to valueIndex
            }

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[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._indexes[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;

        /// @solidity memory-safe-assembly
        assembly {
            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;

        /// @solidity memory-safe-assembly
        assembly {
            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;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }
}

File 15 of 16 : IDragonLotterySwap.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.9;

/**
 * @dev Interface for DragonLotterySwap contract
 */
interface IDragonLotterySwap {
    /**
     * @dev Processes a buy and checks for lottery win
     * @param user Address of the user
     * @param wsAmount Amount of wS tokens involved
     */
    function processBuy(address user, uint256 wsAmount) external;
    
    /**
     * @dev Processes a sell transaction (potentially affecting global pity boost)
     * @param user Address of the user
     * @param wsAmount Amount of wS tokens involved
     */
    function processSell(address user, uint256 wsAmount) external;
    
    /**
     * @dev Increases the jackpot by depositing wS tokens
     * @param amount Amount of wS tokens to add to the jackpot
     */
    function addToJackpot(uint256 amount) external;
    
    /**
     * @dev Sets token's voting power in the lottery for boost calculation
     * @param user User address
     * @param votingPower Amount of voting power
     */
    function setUserVotingPower(address user, uint256 votingPower) external;
    
    /**
     * @dev Gets the current jackpot size
     * @return Current jackpot size in wS
     */
    function jackpot() external view returns (uint256);
    
    /**
     * @dev Gets the current total accumulated boost
     * @return Current accumulated boost percentage
     */
    function accumulatedWSBoost() external view returns (uint256);

    /**
     * @dev Process random words from VRF
     * @param requestId The request ID
     * @param randomWords The random values
     */
    function processRandomWords(uint256 requestId, uint256[] memory randomWords) external;
    
    /**
     * @dev Calculate win chance based on amount and user's voting power
     * @param user User address
     * @param wsAmount wSonic amount
     * @return winChance Win chance in basis points (e.g., 100 = 1%)
     */
    function calculateWinChance(address user, uint256 wsAmount) external view returns (uint256);
    
    /**
     * @dev Enter the lottery on behalf of a user
     * @param user User address to enter the lottery for
     * @param tickets Number of tickets to purchase
     */
    function enterLotteryFor(address user, uint256 tickets) external;
    
    function getCurrentJackpot() external view returns (uint256);
    function getStats() external view returns (uint256 winners, uint256 payouts, uint256 current);
    function getSwapLimits() external view returns (uint256 min, uint256 max, bool isUsdMode);
    function getJackpotTokenSymbol() external view returns (string memory);
    function isLotteryEnabled() external view returns (bool);

    function secureProcessBuy(address user, uint256 amount) external;
    function updateProbability(uint256 newProbability) external;
    function setExchangePair(address _exchangePair) external;
    function getLastWinner() external view returns (address);
    function getLastWinAmount() external view returns (uint256);
    function isVrfEnabled() external view returns (bool);
    function getVrfConfiguration() external view returns (
        address vrfCoordinator,
        bytes32 keyHash,
        uint64 subscriptionId
    );
    
    // Governance functions for USD mode
    function proposePriceOracle(address _priceOracle) external;
    function executePriceOracle(address _priceOracle) external;
    function proposeUseUsdEntryAmounts(bool _useUsdEntryAmounts) external;
    function executeUseUsdEntryAmounts(bool _useUsdEntryAmounts) external;
    
    // Flash loan protection
    function recordLpAcquisition(address user, uint256 amount) external;
    
    // Security checks
    function isSecureContext(address user) external view returns (bool);

    function toggleUsdMode() external;
    function setRouterUsdPriceMode(bool enable) external;
    function setJackpotWithdraw(bool enable) external;
    function setPriceUpdateGovernance(address governance) external;
    function distributeJackpot(address winner, uint256 amount) external;
    
    // Security/checks
    function isFlashLoanAttack(address from, address to) external returns (bool);
}

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.9;

interface IUniswapV2Router {
    function swapExactTokensForTokens(
        uint256 amountIn,
        uint256 amountOutMin,
        address[] calldata path,
        address to,
        uint256 deadline
    ) external returns (uint256[] memory amounts);
    
    function getAmountsOut(
        uint256 amountIn, 
        address[] calldata path
    ) external view returns (uint256[] memory amounts);
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "evmVersion": "paris",
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"address","name":"_jackpotAddress","type":"address"},{"internalType":"address","name":"_ve69LPAddress","type":"address"},{"internalType":"address","name":"_burnAddress","type":"address"},{"internalType":"address","name":"_wrappedSonicAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"actionId","type":"bytes32"},{"indexed":false,"internalType":"string","name":"actionDescription","type":"string"}],"name":"ActionCancelled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"actionId","type":"bytes32"},{"indexed":false,"internalType":"string","name":"actionDescription","type":"string"}],"name":"ActionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"actionId","type":"bytes32"},{"indexed":false,"internalType":"string","name":"actionDescription","type":"string"},{"indexed":false,"internalType":"uint256","name":"executionTime","type":"uint256"}],"name":"ActionScheduled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"burnFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"jackpotFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"ve69LPFee","type":"uint256"}],"name":"BuyFeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pair","type":"address"}],"name":"ExchangePairSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"burnAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"jackpotAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"ve69LPAmount","type":"uint256"}],"name":"FeeCollected","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"bool","name":"exempt","type":"bool"}],"name":"FeeExemptUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"FeesDistributed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"duration","type":"uint256"}],"name":"OwnershipLocked","type":"event"},{"anonymous":false,"inputs":[],"name":"OwnershipRenounced","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"newRouter","type":"address"}],"name":"RouterUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"burnFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"jackpotFee","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"ve69LPFee","type":"uint256"}],"name":"SellFeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"SpecialTransactionPeriodEnded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"message","type":"string"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"SwapDebug","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"bool","name":"isWStoTokenSwap","type":"bool"},{"indexed":false,"internalType":"uint256","name":"wsAmount","type":"uint256"}],"name":"SwapDetected","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"transferAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"burnAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"jackpotAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"veAmount","type":"uint256"}],"name":"TokensTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"enabled","type":"bool"}],"name":"TradingEnabled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"newAddress","type":"address"}],"name":"ve69LPAddressUpdated","type":"event"},{"inputs":[],"name":"ADMIN_ACTION_DELAY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BURN_ADDRESS","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FEE_DENOMINATOR","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FEE_UPDATE_DELAY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"INITIAL_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_LOCK_DURATION","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_SPECIAL_TRANSACTION_AMOUNT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_TOTAL_FEE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_TRANSACTION_AMOUNT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"POST_SPECIAL_WALLET_LIMIT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"POST_SPECIAL_WALLET_LIMIT_PERCENT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SPECIAL_LIMIT_TRANSACTIONS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SPECIAL_TRANSACTION_COUNT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SPECIAL_WALLET_LIMIT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SPECIAL_WALLET_LIMIT_PERCENT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"burnAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"burnFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"burnFeeRegular","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"buyBurnFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"buyJackpotFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"buyve69LPFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"actionId","type":"bytes32"}],"name":"cancelAction","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"enableTrading","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exchangePair","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"newJackpotFee","type":"uint256"},{"internalType":"uint256","name":"newBurnFee","type":"uint256"},{"internalType":"uint256","name":"newve69LPFee","type":"uint256"}],"name":"executeFeeUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newAddress","type":"address"}],"name":"executeJackpotAddressUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newAddress","type":"address"}],"name":"executeve69LPAddressUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"functionSig","type":"string"},{"internalType":"bytes","name":"params","type":"bytes"}],"name":"getActionId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getContractConfiguration","outputs":[{"internalType":"address","name":"jackpotAddress_","type":"address"},{"internalType":"address","name":"ve69LPAddress_","type":"address"},{"internalType":"address","name":"burnAddress_","type":"address"},{"internalType":"address","name":"wrappedSonicAddress_","type":"address"},{"internalType":"address","name":"lotteryAddress_","type":"address"},{"internalType":"address","name":"exchangePair_","type":"address"},{"internalType":"bool","name":"tradingEnabled_","type":"bool"},{"internalType":"bool","name":"ownershipLocked_","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentTransactionLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentWalletLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getDetailedFeeInfo","outputs":[{"internalType":"uint256","name":"jackpotFeeBuy_","type":"uint256"},{"internalType":"uint256","name":"burnFeeBuy_","type":"uint256"},{"internalType":"uint256","name":"ve69LPFeeBuy_","type":"uint256"},{"internalType":"uint256","name":"totalFeeBuy_","type":"uint256"},{"internalType":"uint256","name":"jackpotFeeSell_","type":"uint256"},{"internalType":"uint256","name":"burnFeeSell_","type":"uint256"},{"internalType":"uint256","name":"ve69LPFeeSell_","type":"uint256"},{"internalType":"uint256","name":"totalFeeSell_","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getFeeStats","outputs":[{"internalType":"uint256","name":"totalBurned_","type":"uint256"},{"internalType":"uint256","name":"totalJackpotFees_","type":"uint256"},{"internalType":"uint256","name":"totalve69LPFees_","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getHolderAt","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getHolderCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLimitsInfo","outputs":[{"internalType":"uint256","name":"currentTxLimit","type":"uint256"},{"internalType":"uint256","name":"currentWalletLimit","type":"uint256"},{"internalType":"uint256","name":"specialTxRemaining","type":"uint256"},{"internalType":"uint256","name":"currentTxCount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getRemainingSpecialTransactions","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"wsAmount","type":"uint256"}],"name":"handleSwapFromWS","outputs":[{"internalType":"uint256","name":"dragonAmount","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"dragonAmount","type":"uint256"}],"name":"handleSwapToWS","outputs":[{"internalType":"uint256","name":"wsAmount","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"actionId","type":"bytes32"}],"name":"isActionReady","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isFeeExempt","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"jackpotAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"jackpotFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"jackpotFeeRegular","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lastFeeUpdate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastTransferTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"launchTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_lockDuration","type":"uint256"}],"name":"lockOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"lotteryAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ownershipLocked","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"pendingActionDescriptions","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"pendingActions","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnershipWithTimelock","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"router","outputs":[{"internalType":"contract IUniswapV2Router","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"actionId","type":"bytes32"},{"internalType":"string","name":"description","type":"string"}],"name":"scheduleAction","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newJackpotFee","type":"uint256"},{"internalType":"uint256","name":"newBurnFee","type":"uint256"},{"internalType":"uint256","name":"newve69LPFee","type":"uint256"}],"name":"scheduleFeeUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newAddress","type":"address"}],"name":"scheduleJackpotAddressUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newAddress","type":"address"}],"name":"scheduleve69LPAddressUpdate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"sellBurnFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"sellJackpotFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"sellve69LPFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"burnFee_","type":"uint256"},{"internalType":"uint256","name":"jackpotFee_","type":"uint256"},{"internalType":"uint256","name":"ve69LPFee_","type":"uint256"}],"name":"setBuyFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_exchangePair","type":"address"}],"name":"setExchangePair","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_exchangePair","type":"address"}],"name":"setExchangePairWithTimelock","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"bool","name":"_exempt","type":"bool"}],"name":"setFeeExempt","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bool","name":"exempt","type":"bool"}],"name":"setFeeExemptWithTimelock","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_inSwap","type":"bool"}],"name":"setInSwap","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_lotteryAddress","type":"address"}],"name":"setLotteryAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_lotteryAddress","type":"address"}],"name":"setLotteryAddressWithTimelock","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bool","name":"enabled","type":"bool"}],"name":"setOptimizedTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_router","type":"address"}],"name":"setRouter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"burnFee_","type":"uint256"},{"internalType":"uint256","name":"jackpotFee_","type":"uint256"},{"internalType":"uint256","name":"ve69LPFee_","type":"uint256"}],"name":"setSellFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_enabled","type":"bool"}],"name":"setTradingEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"enabled","type":"bool"}],"name":"setTransferOptimization","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_ve69LPAddress","type":"address"}],"name":"setve69LPAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBurned","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalFeeBuy","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalFeeRegular","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalFeeSell","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalHolders","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalJackpotFees","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalve69LPFees","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tradingEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tradingEnabledPermanently","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"transactionCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"ve69LPAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ve69LPFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ve69LPFeeRegular","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wrappedSonic","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wrappedSonicAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

0x6080604052604560128190556102b2601381905560f160148190556103e860158190556016939093556017919091556018556019556027805464ffffffffff60a01b1916600160b81b1790553480156200005857600080fd5b5060405162004ed038038062004ed08339810160408190526200007b916200079c565b60405180604001604052806006815260200165223930b3b7b760d11b81525060405180604001604052806006815260200165222920a3a7a760d11b8152508160039081620000ca91906200089d565b506004620000d982826200089d565b505050620000f6620000f06200038160201b60201c565b62000385565b60016006556001600160a01b038416620001575760405162461bcd60e51b815260206004820152601e60248201527f4a61636b706f7420616464726573732063616e6e6f74206265207a65726f000060448201526064015b60405180910390fd5b6001600160a01b038316620001af5760405162461bcd60e51b815260206004820152601d60248201527f766536394c5020616464726573732063616e6e6f74206265207a65726f00000060448201526064016200014e565b6001600160a01b038216620002075760405162461bcd60e51b815260206004820152601b60248201527f4275726e20616464726573732063616e6e6f74206265207a65726f000000000060448201526064016200014e565b6001600160a01b0381166200026b5760405162461bcd60e51b8152602060048201526024808201527f5772617070656420536f6e696320616464726573732063616e6e6f74206265206044820152637a65726f60e01b60648201526084016200014e565b602280546001600160a01b038087166001600160a01b03199283161790925560238054868416908316179055602480548584169083161790556025805492841692821683179055602d80549091169091179055306000908152602860205260409020805460ff1916600117905560f16014819055601254601354620002f191906200097f565b620002fd91906200097f565b6015556102b260178190556045601681905560f16018819055916200032391906200097f565b6200032f91906200097f565b6019556045601a8190556007601b8190556018601c8190556064601d819055601e93909355601f9190915560205560215562000377336a05be0692f63baaf6c00000620003d7565b50505050620009d7565b3390565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b0382166200042f5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016200014e565b80600260008282546200044391906200097f565b90915550506001600160a01b038216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3620004a460008383620004ad565b5050565b505050565b620004b883620004ec565b620004c382620004ec565b602754600160a01b900460ff168015620004dd5750600c54155b15620004a85742600c55505050565b6001600160a01b038116158015906200051057506001600160a01b03811661dead14155b80156200052657506001600160a01b0381163014155b15620005c65762000539602e82620005c9565b1580156200055d57506001600160a01b038116600090815260208190526040812054115b15620005835762000570602e82620005f0565b506200057d602e62000607565b600d5550565b62000590602e82620005c9565b8015620005b357506001600160a01b038116600090815260208190526040902054155b15620005c65762000570602e8262000612565b50565b6001600160a01b038116600090815260018301602052604081205415155b90505b92915050565b6000620005e7836001600160a01b03841662000629565b6000620005ea825490565b6000620005e7836001600160a01b0384166200067b565b60008181526001830160205260408120546200067257508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155620005ea565b506000620005ea565b6000818152600183016020526040812054801562000774576000620006a260018362000995565b8554909150600090620006b89060019062000995565b905081811462000724576000866000018281548110620006dc57620006dc620009ab565b9060005260206000200154905080876000018481548110620007025762000702620009ab565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080620007385762000738620009c1565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050620005ea565b6000915050620005ea565b80516001600160a01b03811681146200079757600080fd5b919050565b60008060008060808587031215620007b357600080fd5b620007be856200077f565b9350620007ce602086016200077f565b9250620007de604086016200077f565b9150620007ee606086016200077f565b905092959194509250565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200082457607f821691505b6020821081036200084557634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620004a857600081815260208120601f850160051c81016020861015620008745750805b601f850160051c820191505b81811015620008955782815560010162000880565b505050505050565b81516001600160401b03811115620008b957620008b9620007f9565b620008d181620008ca84546200080f565b846200084b565b602080601f831160018114620009095760008415620008f05750858301515b600019600386901b1c1916600185901b17855562000895565b600085815260208120601f198616915b828110156200093a5788860151825594840194600190910190840162000919565b5085821015620009595787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b634e487b7160e01b600052601160045260246000fd5b80820180821115620005ea57620005ea62000969565b81810381811115620005ea57620005ea62000969565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b6144e980620009e76000396000f3fe608060405234801561001057600080fd5b506004361061063e5760003560e01c80639850b4a811610336578063cbb5558e116101c3578063e71dc3f51161010f578063f701801e116100ad578063f896c48d11610087578063f896c48d14610d64578063fb5f27fb14610d76578063fccc281314610d7f578063fce589d814610d8857600080fd5b8063f701801e14610cf2578063f713d5e414610d44578063f887ea4014610d4c57600080fd5b8063ed14ebc9116100e9578063ed14ebc914610cf2578063f28ab2be14610cfa578063f2fde38b14610d1e578063f5d38ed114610d3157600080fd5b8063e71dc3f514610ce0578063e987443614610ce9578063ea2ff7341461099757600080fd5b8063dae0fed41161017c578063e07f37a711610156578063e07f37a714610c86578063e253f87b14610c9a578063e30569e514610cad578063e5d0bbfb14610ccd57600080fd5b8063dae0fed414610c58578063dc2a2c6f14610c6b578063dd62ed3e14610c7357600080fd5b8063cbb5558e14610c22578063ce75d56514610c2b578063d079d20e14610c3e578063d4a06c8f14610702578063d73792a914610c46578063d89135cd14610c4f57600080fd5b8063b7b31c9c11610282578063c078606f1161023b578063c14fe5de11610215578063c14fe5de14610b70578063c21a750314610b83578063c28907cf14610bfc578063c2e5ec0414610c0f57600080fd5b8063c078606f14610b42578063c086afd614610b55578063c0d7865514610b5d57600080fd5b8063b7b31c9c14610af0578063b84a9a3e14610b03578063b96bedb214610b0c578063ba6610a014610b15578063bda9924b14610b28578063bea047f314610b3157600080fd5b8063a457c2d7116102ef578063adb873bd116102c9578063adb873bd14610ac1578063add74c7414610aca578063aeeedb1314610ade578063b77bf60014610ae757600080fd5b8063a457c2d714610a88578063a53f883d14610a9b578063a9059cbb14610aae57600080fd5b80639850b4a814610a355780639bd67a1f14610a3e5780639cb9cd4814610a465780639d26fdf914610a4f578063a0ef4ee714610a62578063a217723f14610a7557600080fd5b806353d74fdf116104cf5780637455df621161041b5780638a8c523c116103b95780638ebfc796116103935780638ebfc796146109e757806391e11e30146109fa57806391fc1f2c14610a0d57806395d89b4114610a2d57600080fd5b80638a8c523c146109bb5780638da5cb5b146109c35780638dbcdda9146109d457600080fd5b806378f00be0116103f557806378f00be0146109845780637f635cc0146109975780638464f53c146109a0578063870f3e35146109b357600080fd5b80637455df6214610955578063781cc3d31461095e578063783db4981461097157600080fd5b80636bc0b3ba1161048857806370d5ae051161046257806370d5ae05146108df5780637136982b146108f25780637147238f146108fa578063715018a61461094d57600080fd5b80636bc0b3ba1461087b5780636f013db91461088e57806370a08231146108b657600080fd5b806353d74fdf1461083157806354dbba471461083a578063569672be1461084d57806364beb7451461085657806365cf7c9b1461086957806369faf8c51461087257600080fd5b80632a332b2a1161058e5780633beedf6d116105475780634ada218b116105215780634ada218b146108005780634f1bfc9e146108145780634f3472521461081f578063531484161461082857600080fd5b80633beedf6d146107b75780633f4218e0146107ca57806342966c68146107ed57600080fd5b80632a332b2a146107325780632ff2e9dc1461074557806330d4cd6014610757578063313ce5671461076a57806339509351146107795780633ab037841461078c57600080fd5b806313de8019116105fb5780631df4ccfc116105d55780631df4ccfc146106f95780631e7877501461070257806323b872dd1461070c57806323e7b0ba1461071f57600080fd5b806313de8019146106cb57806314bef93e146106de57806318160ddd146106f157600080fd5b806306fdde031461064357806309523c6b14610661578063095ea7b3146106775780630b5530a71461069a5780630d075d9c146106a35780630f683e90146106b8575b600080fd5b61064b610d91565b6040516106589190613d0d565b60405180910390f35b610669610e23565b604051908152602001610658565b61068a610685366004613d3c565b610e48565b6040519015158152602001610658565b610669601a5481565b6106b66106b1366004613d66565b610e62565b005b6106b66106c6366004613d66565b610f20565b61068a6106d9366004613d92565b610fd0565b6106b66106ec366004613dab565b610ff5565b600254610669565b61066960215481565b6106696201518081565b61068a61071a366004613dc6565b6110a9565b6106b661072d366004613dab565b6110cd565b6106b6610740366004613dab565b6111f0565b6106696a05be0692f63baaf6c0000081565b61064b610765366004613d92565b611270565b60405160128152602001610658565b61068a610787366004613d3c565b61130a565b60275461079f906001600160a01b031681565b6040516001600160a01b039091168152602001610658565b60265461079f906001600160a01b031681565b61068a6107d8366004613dab565b60286020526000908152604090205460ff1681565b6106b66107fb366004613d92565b61132c565b60275461068a90600160a01b900460ff1681565b6106696301e1338081565b610669600a5481565b61066960195481565b610669600d5481565b6106b6610848366004613dab565b61135c565b610669600b5481565b6106b6610864366004613d92565b611404565b610669600c5481565b610669601b5481565b60225461079f906001600160a01b031681565b61089661150e565b604080519485526020850193909352918301526060820152608001610658565b6106696108c4366004613dab565b6001600160a01b031660009081526020819052604090205490565b60245461079f906001600160a01b031681565b61066961153d565b601354601254601454601554601754601654601854601954604080519889526020890197909752958701949094526060860192909252608085015260a084015260c083015260e082015261010001610658565b6106b6611549565b61066960135481565b6106b661096c366004613d92565b61155d565b6106b661097f366004613d66565b6116a7565b6106b6610992366004613dab565b6117a4565b6106696103e881565b6106b66109ae366004613dab565b6118ba565b610669611a44565b6106b6611a6b565b6005546001600160a01b031661079f565b6106696109e2366004613eae565b611b18565b6106b66109f5366004613f34565b611b4b565b610669610a08366004613d3c565b611bab565b610669610a1b366004613dab565b60296020526000908152604090205481565b61064b611ea4565b610669601d5481565b610669611eb3565b61066960175481565b6106b6610a5d366004613dab565b611efd565b6106b6610a70366004613f6b565b611fc2565b610669610a83366004613d3c565b611fe8565b61068a610a96366004613d3c565b61228c565b6106b6610aa9366004613d66565b612307565b61068a610abc366004613d3c565b612455565b61066960165481565b60275461068a90600160a81b900460ff1681565b61066960185481565b61066960075481565b6106b6610afe366004613f6b565b61246b565b610669601c5481565b61066960085481565b6106b6610b23366004613f34565b6124e3565b61066960145481565b61066969d3c21bcecceda100000081565b60255461079f906001600160a01b031681565b610669612654565b6106b6610b6b366004613dab565b61269c565b6106b6610b7e366004613dab565b61274c565b602254602354602454602554602654602754604080516001600160a01b03978816815295871660208701529386169385019390935290841660608401528316608083015291821660a082015260ff600160a01b83048116151560c0830152600160c01b909204909116151560e082015261010001610658565b6106b6610c0a366004613f88565b612851565b6106b6610c1d366004613f6b565b612967565b61066960205481565b602d5461079f906001600160a01b031681565b610669606481565b61066961271081565b61066960095481565b6106b6610c66366004613f34565b612a16565b6106b6612a49565b610669610c81366004613fc5565b612b3d565b60275461068a90600160c01b900460ff1681565b61079f610ca8366004613d92565b612b68565b610669610cbb366004613d92565b602b6020526000908152604090205481565b6106b6610cdb366004613dab565b612bc3565b61066960125481565b610669601e5481565b610669604581565b600954600a54600b5460408051938452602084019290925290820152606001610658565b6106b6610d2c366004613dab565b612d0c565b60235461079f906001600160a01b031681565b610669612d82565b60315461079f9061010090046001600160a01b031681565b6106696a084595161401484a00000081565b61066960155481565b61079f61dead81565b610669601f5481565b606060038054610da090613ff8565b80601f0160208091040260200160405190810160405280929190818152602001828054610dcc90613ff8565b8015610e195780601f10610dee57610100808354040283529160200191610e19565b820191906000526020600020905b815481529060010190602001808311610dfc57829003601f168201915b5050505050905090565b6000604560075410610e355750600090565b600754610e43906045614048565b905090565b600033610e56818585612d9b565b60019150505b92915050565b610e6a612ebf565b6103e881610e78848661405b565b610e82919061405b565b1115610eca5760405162461bcd60e51b81526020600482015260126024820152710a8dee8c2d840cccaca40e8dede40d0d2ced60731b60448201526064015b60405180910390fd5b60128390556013829055601481905560408051848152602081018490529081018290527fa7266bdfb6dddf05c6d4c2b1c0a92e32c7f0a8815840290ee04b4dab3c6ff01d906060015b60405180910390a1505050565b610f28612ebf565b6103e881610f36848661405b565b610f40919061405b565b1115610f835760405162461bcd60e51b81526020600482015260126024820152710a8dee8c2d840cccaca40e8dede40d0d2ced60731b6044820152606401610ec1565b60168390556017829055601881905560408051848152602081018490529081018290527f448e0e14dd61faacf0f8f7dded9eb48b249502327415f15dc735243d76a8586290606001610f13565b6000818152602b60205260408120548015801590610fee5750804210155b9392505050565b610ffd612ebf565b6001600160a01b03811661105f5760405162461bcd60e51b8152602060048201526024808201527f45786368616e676520706169722063616e6e6f74206265207a65726f206164646044820152637265737360e01b6064820152608401610ec1565b602780546001600160a01b0319166001600160a01b0383169081179091556040517f68b85316b4a002f17128f82dca3d48c7fc2e824a841943465b56000c3ddb041490600090a250565b6000336110b7858285612f19565b6110c2858585612f93565b506001949350505050565b6110d5612ebf565b6001600160a01b03811661112b5760405162461bcd60e51b815260206004820152601a60248201527f4e657720616464726573732063616e6e6f74206265207a65726f0000000000006044820152606401610ec1565b60008160405160200161113e919061406e565b6040516020818303038152906040528051906020012090506201518042611165919061405b565b6000828152602b6020908152604080832093909355825180840184526016815275557064617465206a61636b706f74206164647265737360501b81830152848352602c909152919020906111b990826140f1565b50806000805160206144748339815191526111d7620151804261405b565b6040516111e491906141b1565b60405180910390a25050565b6111f8612ebf565b6001600160a01b03811661124e5760405162461bcd60e51b815260206004820152601e60248201527f4c6f747465727920616464726573732063616e6e6f74206265207a65726f00006044820152606401610ec1565b602680546001600160a01b0319166001600160a01b0392909216919091179055565b602c602052600090815260409020805461128990613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546112b590613ff8565b80156113025780601f106112d757610100808354040283529160200191611302565b820191906000526020600020905b8154815290600101906020018083116112e557829003601f168201915b505050505081565b600033610e5681858561131d8383612b3d565b611327919061405b565b612d9b565b61133633826131d6565b8060096000828254611348919061405b565b90915550611359905060038261330f565b50565b611364612ebf565b6001600160a01b0381166113ba5760405162461bcd60e51b815260206004820152601d60248201527f766536394c5020616464726573732063616e6e6f74206265207a65726f0000006044820152606401610ec1565b602380546001600160a01b0319166001600160a01b0383169081179091556040517f492e9d77c9c06355a063aefae50abdb906672c13c38f227bc6f0eea08e75fd5e90600090a250565b61140c612ebf565b602754600160c01b900460ff16156114665760405162461bcd60e51b815260206004820152601860248201527f4f776e65727368697020616c7265616479206c6f636b656400000000000000006044820152606401610ec1565b60008111801561147a57506301e133808111155b6114be5760405162461bcd60e51b815260206004820152601560248201527424b73b30b634b2103637b1b590323ab930ba34b7b760591b6044820152606401610ec1565b6027805460ff60c01b1916600160c01b1790556040517f12ea4a831c30198a4f20f64c4e0f34d55f5a8663ea776afac53eed1ebc166da5906115039083815260200190565b60405180910390a150565b60008060008061151c611eb3565b611524612654565b61152c610e23565b600754935093509350935090919293565b6000610e43602e61337b565b611551612ebf565b61155b6000613385565b565b611565612ebf565b6000818152602b60205260409020546115b75760405162461bcd60e51b81526020600482015260146024820152731058dd1a5bdb881b9bdd081cd8da19591d5b195960621b6044820152606401610ec1565b6000818152602c6020526040812080546115d090613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546115fc90613ff8565b80156116495780601f1061161e57610100808354040283529160200191611649565b820191906000526020600020905b81548152906001019060200180831161162c57829003601f168201915b5050506000858152602b60209081526040808320839055602c90915281209394506116779392509050613c6f565b817f4133f12238d9c77b6b2a20ea59f935ab7d3df1c520364ca5f9b062cf7d9fc3fe826040516111e49190613d0d565b6116af612ebf565b604051697570646174654665657360b01b6020820152602a8101849052604a8101839052606a8101829052600090608a0160408051601f1981840301815291815281516020928301206000818152602b9093529120549091501580159061172457506000818152602b60205260409020544210155b6117405760405162461bcd60e51b8152600401610ec1906141f5565b601e849055601f83905560208290558161175a848661405b565b611764919061405b565b6021556000818152602b602052604080822091909155518190600080516020614494833981519152906117969061422c565b60405180910390a250505050565b6117ac612ebf565b6001600160a01b0381166118025760405162461bcd60e51b815260206004820152601a60248201527f4e657720616464726573732063616e6e6f74206265207a65726f0000000000006044820152606401610ec1565b6000816040516020016118159190614257565b604051602081830303815290604052805190602001209050620151804261183c919061405b565b6000828152602b602090815260408083209390935582518084018452601581527455706461746520766536394c50206164647265737360581b81830152848352602c9091529190209061188f90826140f1565b50806000805160206144748339815191526118ad620151804261405b565b6040516111e4919061428b565b6118c2612ebf565b6000611929604051806040016040528060118152602001707365744c6f74746572794164647265737360781b81525083604051602001611915919060609190911b6001600160601b031916815260140190565b604051602081830303815290604052611b18565b905061193481610fd0565b6119505760405162461bcd60e51b8152600401610ec1906142c0565b6000818152602b60209081526040808320839055602c9091528120805461197690613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546119a290613ff8565b80156119ef5780601f106119c4576101008083540402835291602001916119ef565b820191906000526020600020905b8154815290600101906020018083116119d257829003601f168201915b5050506000858152602c60205260408120939450611a109392509050613c6f565b611a19836111f8565b8160008051602061449483398151915282604051611a379190613d0d565b60405180910390a2505050565b612710611a5e6a05be0692f63baaf6c000006101a46142ee565b611a689190614305565b81565b611a73612ebf565b602754600160a01b900460ff1615611acd5760405162461bcd60e51b815260206004820152601760248201527f54726164696e6720616c726561647920656e61626c65640000000000000000006044820152606401610ec1565b6027805461ffff60a01b191661010160a01b179055604051600181527fbeda7dca7bc1b3e80b871f4818129ec73b771581f803d553aeb3484098e5f65a9060200160405180910390a1565b60008282604051602001611b2d929190614327565b60405160208183030381529060405280519060200120905092915050565b611b53612ebf565b6001600160a01b038216600081815260286020908152604091829020805460ff191685151590811790915591519182527f4d5771454588f51370a8a2e7e151354b6de0dc3159b14821b4ad76bc04c28bc791016111e4565b6027546000906001600160a01b03163314611c085760405162461bcd60e51b815260206004820181905260248201527f4f6e6c792065786368616e676520706169722063616e2063616c6c20746869736044820152606401610ec1565b60008211611c585760405162461bcd60e51b815260206004820181905260248201527f416d6f756e74206d7573742062652067726561746572207468616e207a65726f6044820152606401610ec1565b6000612710611c69846102b26142ee565b611c739190614305565b90506000612710611c858560f16142ee565b611c8f9190614305565b90506000611c9d828461405b565b90506000611cab8287614048565b90508315611d4757602254602d54611cd2916001600160a01b03918216918a9116876133d7565b611cdd60018561330f565b6026546001600160a01b031615611d4757602654604051635bda81a960e11b8152600481018690526001600160a01b039091169063b7b5035290602401600060405180830381600087803b158015611d3457600080fd5b505af1925050508015611d45575060015b505b8215611d7757602354602d54611d6c916001600160a01b03918216918a9116866133d7565b611d7760028461330f565b602754602d54611d96916001600160a01b03918216918a9116846133d7565b9350836000612710611da98360456142ee565b611db39190614305565b90506000611dc18288614048565b9050611dcf61dead83613431565b611dd98982613431565b8160096000828254611deb919061405b565b90915550611dfc905060038361330f565b6026546001600160a01b031615801590611e1e57506001600160a01b03891632145b8015611e3257506001600160a01b0389163b155b15611e985760265460405163ea274a6b60e01b81526001600160a01b038b81166004830152602482018b90529091169063ea274a6b90604401600060405180830381600087803b158015611e8557600080fd5b505af1925050508015611e96575060015b505b98975050505050505050565b606060048054610da090613ff8565b600060456007541015611ee357612710611ed96a05be0692f63baaf6c0000060456142ee565b610e439190614305565b612710611ed96a05be0692f63baaf6c000006101a46142ee565b611f05612ebf565b600081604051602001611f18919061406e565b60408051601f1981840301815291815281516020928301206000818152602b90935291205490915015801590611f5c57506000818152602b60205260409020544210155b611f785760405162461bcd60e51b8152600401610ec1906141f5565b602280546001600160a01b0319166001600160a01b0384161790556000818152602b602052604080822091909155518190600080516020614494833981519152906111e490614356565b611fca612ebf565b60278054911515600160b81b0260ff60b81b19909216919091179055565b6027546000906001600160a01b031633146120455760405162461bcd60e51b815260206004820181905260248201527f4f6e6c792065786368616e676520706169722063616e2063616c6c20746869736044820152606401610ec1565b600082116120955760405162461bcd60e51b815260206004820181905260248201527f416d6f756e74206d7573742062652067726561746572207468616e207a65726f6044820152606401610ec1565b60006127106120a58460456142ee565b6120af9190614305565b905060006120bd8285614048565b90506120c985836131d6565b81600960008282546120db919061405b565b909155506120ec905060038361330f565b6027546121049086906001600160a01b0316836134f8565b806000612710612116836102b26142ee565b6121209190614305565b905060006127106121328460f16142ee565b61213c9190614305565b9050600061214a828461405b565b90506121568185614048565b965082156121d35761216960018461330f565b6026546001600160a01b0316156121d357602654604051635bda81a960e11b8152600481018590526001600160a01b039091169063b7b5035290602401600060405180830381600087803b1580156121c057600080fd5b505af19250505080156121d1575060015b505b81156121e4576121e460028361330f565b6026546001600160a01b03161580159061220657506001600160a01b03891632145b801561221a57506001600160a01b0389163b155b156122805760265460405163012ca9e760e51b81526001600160a01b038b81166004830152602482018a9052909116906325953ce090604401600060405180830381600087803b15801561226d57600080fd5b505af192505050801561227e575060015b505b50505050505092915050565b6000338161229a8286612b3d565b9050838110156122fa5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610ec1565b6110c28286868403612d9b565b61230f612ebf565b60008161231c848661405b565b612326919061405b565b90506103e881111561237a5760405162461bcd60e51b815260206004820152601b60248201527f546f74616c206665652063616e6e6f74206578636565642031302500000000006044820152606401610ec1565b604051697570646174654665657360b01b6020820152602a8101859052604a8101849052606a8101839052600090608a0160405160208183030381529060405280519060200120905062015180426123d2919061405b565b6000828152602b602090815260408083209390935582518084018452600b81526a557064617465206665657360a81b81830152848352602c9091529190209061241b90826140f1565b5080600080516020614474833981519152612439620151804261405b565b604051612446919061438c565b60405180910390a25050505050565b6000612462338484612f93565b50600192915050565b6027546001600160a01b031633146124c55760405162461bcd60e51b815260206004820152601860248201527f4f6e6c7920706169722063616e2073657420696e5377617000000000000000006044820152606401610ec1565b60278054911515600160b01b0260ff60b01b19909216919091179055565b6124eb612ebf565b60006125456040518060400160405280600c81526020016b1cd95d119959515e195b5c1d60a21b815250848460405160200161191592919060609290921b6001600160601b0319168252151560f81b601482015260150190565b905061255081610fd0565b61256c5760405162461bcd60e51b8152600401610ec1906142c0565b6000818152602b60209081526040808320839055602c9091528120805461259290613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546125be90613ff8565b801561260b5780601f106125e05761010080835404028352916020019161260b565b820191906000526020600020905b8154815290600101906020018083116125ee57829003601f168201915b5050506000858152602c6020526040812093945061262c9392509050613c6f565b61263684846136a2565b81600080516020614494833981519152826040516117969190613d0d565b60008061266060025490565b90506045600754101561268a5761268461271061267e836064613723565b9061372f565b91505090565b61268461271061267e836103e8613723565b6126a4612ebf565b6001600160a01b0381166126fa5760405162461bcd60e51b815260206004820152601d60248201527f526f7574657220616464726573732063616e6e6f74206265207a65726f0000006044820152606401610ec1565b60318054610100600160a81b0319166101006001600160a01b038416908102919091179091556040517f7aed1d3e8155a07ccf395e44ea3109a0e2d6c9b29bbbe9f142d9790596f4dc8090600090a250565b612754612ebf565b6000816040516020016127679190614257565b60408051601f1981840301815291815281516020928301206000818152602b909352912054909150158015906127ab57506000818152602b60205260409020544210155b6127c75760405162461bcd60e51b8152600401610ec1906141f5565b602380546001600160a01b0319166001600160a01b0384161790556000818152602b60205260408082209190915551819060008051602061449483398151915290612811906143b7565b60405180910390a26040516001600160a01b038316907f492e9d77c9c06355a063aefae50abdb906672c13c38f227bc6f0eea08e75fd5e90600090a25050565b612859612ebf565b6000828152602b6020526040902054156128b55760405162461bcd60e51b815260206004820152601860248201527f416374696f6e20616c7265616479207363686564756c656400000000000000006044820152606401610ec1565b602754600160c01b900460ff16156129055760405162461bcd60e51b815260206004820152601360248201527213dddb995c9cda1a5c081a5cc81b1bd8dad959606a1b6044820152606401610ec1565b612912620151804261405b565b6000838152602b6020908152604080832093909355602c90522061293682826140f1565b506000828152602b6020526040908190205490518391600080516020614474833981519152916111e49185916143ec565b61296f612ebf565b602754600160a81b900460ff16156129c95760405162461bcd60e51b815260206004820152601e60248201527f54726164696e67206973207065726d616e656e746c7920656e61626c656400006044820152606401610ec1565b60278054821515600160a01b0260ff60a01b199091161790556040517fbeda7dca7bc1b3e80b871f4818129ec73b771581f803d553aeb3484098e5f65a9061150390831515815260200190565b612a1e612ebf565b6001600160a01b03919091166000908152602a60205260409020805460ff1916911515919091179055565b612a51612ebf565b6000612a9560405180604001604052806011815260200170072656e6f756e63654f776e65727368697607c1b81525060405180602001604052806000815250611b18565b9050612aa081610fd0565b612abc5760405162461bcd60e51b8152600401610ec1906142c0565b612ac66000613385565b6040517fd1f66c3d2bc1993a86be5e3d33709d98f0442381befcedd29f578b9b2506b1ce90600090a180600080516020614494833981519152604051612b3290602080825260129082015271052656e6f756e6365206f776e6572736869760741b604082015260600190565b60405180910390a250565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b6000612b74602e61337b565b8210612bb85760405162461bcd60e51b8152602060048201526013602482015272496e646578206f7574206f6620626f756e647360681b6044820152606401610ec1565b610e5c602e8361373b565b612bcb612ebf565b6000612c1c6040518060400160405280600f81526020016e39b2ba22bc31b430b733b2a830b4b960891b81525083604051602001611915919060609190911b6001600160601b031916815260140190565b9050612c2781610fd0565b612c435760405162461bcd60e51b8152600401610ec1906142c0565b6000818152602b60209081526040808320839055602c90915281208054612c6990613ff8565b80601f0160208091040260200160405190810160405280929190818152602001828054612c9590613ff8565b8015612ce25780601f10612cb757610100808354040283529160200191612ce2565b820191906000526020600020905b815481529060010190602001808311612cc557829003601f168201915b5050506000858152602c60205260408120939450612d039392509050613c6f565b611a1983610ffd565b612d14612ebf565b6001600160a01b038116612d795760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610ec1565b61135981613385565b612710611a5e6a05be0692f63baaf6c0000060456142ee565b6001600160a01b038316612dfd5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610ec1565b6001600160a01b038216612e5e5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610ec1565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6005546001600160a01b0316331461155b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ec1565b6000612f258484612b3d565b90506000198114612f8d5781811015612f805760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610ec1565b612f8d8484848403612d9b565b50505050565b6001600160a01b038316612fe95760405162461bcd60e51b815260206004820152601a60248201527f5472616e736665722066726f6d207a65726f20616464726573730000000000006044820152606401610ec1565b6001600160a01b03821661303f5760405162461bcd60e51b815260206004820152601860248201527f5472616e7366657220746f207a65726f206164647265737300000000000000006044820152606401610ec1565b600081116130a15760405162461bcd60e51b815260206004820152602960248201527f5472616e7366657220616d6f756e74206d7573742062652067726561746572206044820152687468616e207a65726f60b81b6064820152608401610ec1565b602754600160a01b900460ff161580156130d457506001600160a01b03831660009081526028602052604090205460ff16155b80156130f957506001600160a01b03821660009081526028602052604090205460ff16155b156131465760405162461bcd60e51b815260206004820152601760248201527f54726164696e67206e6f742079657420656e61626c65640000000000000000006044820152606401610ec1565b6001600160a01b03808416600090815260296020526040808220429081905592851682529020556131788383836134f8565b6001600160a01b03831660009081526028602052604090205460ff161580156131ba57506001600160a01b03821660009081526028602052604090205460ff16155b156131d1576007546131cd906001613747565b6007555b505050565b6001600160a01b0382166132365760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610ec1565b6001600160a01b038216600090815260208190526040902054818110156132aa5760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610ec1565b6001600160a01b0383166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a36131d183600084613753565b8160ff166001036133375780600a600082825461332c919061405b565b909155506133779050565b8160ff166002036133545780600b600082825461332c919061405b565b8160ff16600303613377578060096000828254613371919061405b565b90915550505b5050565b6000610e5c825490565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052612f8d90859061378c565b6001600160a01b0382166134875760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610ec1565b8060026000828254613499919061405b565b90915550506001600160a01b038216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a361337760008383613753565b6001600160a01b03831661355c5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610ec1565b6001600160a01b0382166135be5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610ec1565b6001600160a01b038316600090815260208190526040902054818110156136365760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610ec1565b6001600160a01b03848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3612f8d848484613753565b6001600160a01b0382166136f85760405162461bcd60e51b815260206004820152601a60248201527f43616e6e6f74206578656d7074207a65726f20616464726573730000000000006044820152606401610ec1565b6001600160a01b03919091166000908152602860205260409020805460ff1916911515919091179055565b6000610fee82846142ee565b6000610fee8284614305565b6000610fee838361385e565b6000610fee828461405b565b61375c83613888565b61376582613888565b602754600160a01b900460ff16801561377e5750600c54155b156131d15742600c55505050565b60006137e1826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166139519092919063ffffffff16565b8051909150156131d157808060200190518101906137ff919061440e565b6131d15760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610ec1565b60008260000182815481106138755761387561442b565b9060005260206000200154905092915050565b6001600160a01b038116158015906138ab57506001600160a01b03811661dead14155b80156138c057506001600160a01b0381163014155b15611359576138d0602e82613968565b1580156138f357506001600160a01b038116600090815260208190526040812054115b1561391457613903602e8261398a565b5061390e602e61337b565b600d5550565b61391f602e82613968565b801561394157506001600160a01b038116600090815260208190526040902054155b1561135957613903602e8261399f565b606061396084846000856139b4565b949350505050565b6001600160a01b03811660009081526001830160205260408120541515610fee565b6000610fee836001600160a01b038416613a8f565b6000610fee836001600160a01b038416613ade565b606082471015613a155760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610ec1565b600080866001600160a01b03168587604051613a319190614441565b60006040518083038185875af1925050503d8060008114613a6e576040519150601f19603f3d011682016040523d82523d6000602084013e613a73565b606091505b5091509150613a8487838387613bd1565b979650505050505050565b6000818152600183016020526040812054613ad657508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610e5c565b506000610e5c565b60008181526001830160205260408120548015613bc7576000613b02600183614048565b8554909150600090613b1690600190614048565b9050818114613b7b576000866000018281548110613b3657613b3661442b565b9060005260206000200154905080876000018481548110613b5957613b5961442b565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613b8c57613b8c61445d565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610e5c565b6000915050610e5c565b60608315613c40578251600003613c39576001600160a01b0385163b613c395760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610ec1565b5081613960565b6139608383815115613c555781518083602001fd5b8060405162461bcd60e51b8152600401610ec19190613d0d565b508054613c7b90613ff8565b6000825580601f10613c8b575050565b601f01602090049060005260206000209081019061135991905b80821115613cb95760008155600101613ca5565b5090565b60005b83811015613cd8578181015183820152602001613cc0565b50506000910152565b60008151808452613cf9816020860160208601613cbd565b601f01601f19169290920160200192915050565b602081526000610fee6020830184613ce1565b80356001600160a01b0381168114613d3757600080fd5b919050565b60008060408385031215613d4f57600080fd5b613d5883613d20565b946020939093013593505050565b600080600060608486031215613d7b57600080fd5b505081359360208301359350604090920135919050565b600060208284031215613da457600080fd5b5035919050565b600060208284031215613dbd57600080fd5b610fee82613d20565b600080600060608486031215613ddb57600080fd5b613de484613d20565b9250613df260208501613d20565b9150604084013590509250925092565b634e487b7160e01b600052604160045260246000fd5b600067ffffffffffffffff80841115613e3357613e33613e02565b604051601f8501601f19908116603f01168101908282118183101715613e5b57613e5b613e02565b81604052809350858152868686011115613e7457600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112613e9f57600080fd5b610fee83833560208501613e18565b60008060408385031215613ec157600080fd5b823567ffffffffffffffff80821115613ed957600080fd5b613ee586838701613e8e565b93506020850135915080821115613efb57600080fd5b508301601f81018513613f0d57600080fd5b613f1c85823560208401613e18565b9150509250929050565b801515811461135957600080fd5b60008060408385031215613f4757600080fd5b613f5083613d20565b91506020830135613f6081613f26565b809150509250929050565b600060208284031215613f7d57600080fd5b8135610fee81613f26565b60008060408385031215613f9b57600080fd5b82359150602083013567ffffffffffffffff811115613fb957600080fd5b613f1c85828601613e8e565b60008060408385031215613fd857600080fd5b613fe183613d20565b9150613fef60208401613d20565b90509250929050565b600181811c9082168061400c57607f821691505b60208210810361402c57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b81810381811115610e5c57610e5c614032565b80820180821115610e5c57610e5c614032565b737570646174654a61636b706f744164647265737360601b815260609190911b6001600160601b031916601482015260280190565b601f8211156131d157600081815260208120601f850160051c810160208610156140ca5750805b601f850160051c820191505b818110156140e9578281556001016140d6565b505050505050565b815167ffffffffffffffff81111561410b5761410b613e02565b61411f816141198454613ff8565b846140a3565b602080601f831160018114614154576000841561413c5750858301515b600019600386901b1c1916600185901b1785556140e9565b600085815260208120601f198616915b8281101561418357888601518255948401946001909101908401614164565b50858210156141a15787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6040815260006141e7604083016016815275557064617465206a61636b706f74206164647265737360501b602082015260400190565b905082602083015292915050565b6020808252601b908201527f416374696f6e206e6f74207265616479206f7220657870697265640000000000604082015260600190565b602081526000610e5c60208301600b81526a557064617465206665657360a81b602082015260400190565b72757064617465766536394c504164647265737360681b815260609190911b6001600160601b031916601382015260270190565b6040815260006141e760408301601581527455706461746520766536394c50206164647265737360581b602082015260400190565b602080825260149082015273151a5b595b1bd8dac81b9bdd08195e1c1a5c995960621b604082015260600190565b8082028115828204841417610e5c57610e5c614032565b60008261432257634e487b7160e01b600052601260045260246000fd5b500490565b60008351614339818460208801613cbd565b83519083019061434d818360208801613cbd565b01949350505050565b602081526000610e5c602083016016815275557064617465206a61636b706f74206164647265737360501b602082015260400190565b6040815260006141e760408301600b81526a557064617465206665657360a81b602082015260400190565b602081526000610e5c60208301601581527455706461746520766536394c50206164647265737360581b602082015260400190565b6040815260006143ff6040830185613ce1565b90508260208301529392505050565b60006020828403121561442057600080fd5b8151610fee81613f26565b634e487b7160e01b600052603260045260246000fd5b60008251614453818460208701613cbd565b9190910192915050565b634e487b7160e01b600052603160045260246000fdfe74178a809360af06601aec28d5c6558ea658a63de4a67d01134709fff40a26f24a88ca0fefd66d59f32a22d49b86e48beed962046c13cd78d78ce14c4928ace3a26469706673582212203071c80cbfc8ed9e28f9b6f793202ea5b4a7b082a01698ef102bfac5bebde93964736f6c63430008140033000000000000000000000000b05cf01231cf2ff99499682e64d3780d57c80fdd000000000000000000000000b05cf01231cf2ff99499682e64d3780d57c80fdd000000000000000000000000000000000000000000000000000000000000dead000000000000000000000000039e2fb66102314ce7b64ce5ce3e5183bc94ad38

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061063e5760003560e01c80639850b4a811610336578063cbb5558e116101c3578063e71dc3f51161010f578063f701801e116100ad578063f896c48d11610087578063f896c48d14610d64578063fb5f27fb14610d76578063fccc281314610d7f578063fce589d814610d8857600080fd5b8063f701801e14610cf2578063f713d5e414610d44578063f887ea4014610d4c57600080fd5b8063ed14ebc9116100e9578063ed14ebc914610cf2578063f28ab2be14610cfa578063f2fde38b14610d1e578063f5d38ed114610d3157600080fd5b8063e71dc3f514610ce0578063e987443614610ce9578063ea2ff7341461099757600080fd5b8063dae0fed41161017c578063e07f37a711610156578063e07f37a714610c86578063e253f87b14610c9a578063e30569e514610cad578063e5d0bbfb14610ccd57600080fd5b8063dae0fed414610c58578063dc2a2c6f14610c6b578063dd62ed3e14610c7357600080fd5b8063cbb5558e14610c22578063ce75d56514610c2b578063d079d20e14610c3e578063d4a06c8f14610702578063d73792a914610c46578063d89135cd14610c4f57600080fd5b8063b7b31c9c11610282578063c078606f1161023b578063c14fe5de11610215578063c14fe5de14610b70578063c21a750314610b83578063c28907cf14610bfc578063c2e5ec0414610c0f57600080fd5b8063c078606f14610b42578063c086afd614610b55578063c0d7865514610b5d57600080fd5b8063b7b31c9c14610af0578063b84a9a3e14610b03578063b96bedb214610b0c578063ba6610a014610b15578063bda9924b14610b28578063bea047f314610b3157600080fd5b8063a457c2d7116102ef578063adb873bd116102c9578063adb873bd14610ac1578063add74c7414610aca578063aeeedb1314610ade578063b77bf60014610ae757600080fd5b8063a457c2d714610a88578063a53f883d14610a9b578063a9059cbb14610aae57600080fd5b80639850b4a814610a355780639bd67a1f14610a3e5780639cb9cd4814610a465780639d26fdf914610a4f578063a0ef4ee714610a62578063a217723f14610a7557600080fd5b806353d74fdf116104cf5780637455df621161041b5780638a8c523c116103b95780638ebfc796116103935780638ebfc796146109e757806391e11e30146109fa57806391fc1f2c14610a0d57806395d89b4114610a2d57600080fd5b80638a8c523c146109bb5780638da5cb5b146109c35780638dbcdda9146109d457600080fd5b806378f00be0116103f557806378f00be0146109845780637f635cc0146109975780638464f53c146109a0578063870f3e35146109b357600080fd5b80637455df6214610955578063781cc3d31461095e578063783db4981461097157600080fd5b80636bc0b3ba1161048857806370d5ae051161046257806370d5ae05146108df5780637136982b146108f25780637147238f146108fa578063715018a61461094d57600080fd5b80636bc0b3ba1461087b5780636f013db91461088e57806370a08231146108b657600080fd5b806353d74fdf1461083157806354dbba471461083a578063569672be1461084d57806364beb7451461085657806365cf7c9b1461086957806369faf8c51461087257600080fd5b80632a332b2a1161058e5780633beedf6d116105475780634ada218b116105215780634ada218b146108005780634f1bfc9e146108145780634f3472521461081f578063531484161461082857600080fd5b80633beedf6d146107b75780633f4218e0146107ca57806342966c68146107ed57600080fd5b80632a332b2a146107325780632ff2e9dc1461074557806330d4cd6014610757578063313ce5671461076a57806339509351146107795780633ab037841461078c57600080fd5b806313de8019116105fb5780631df4ccfc116105d55780631df4ccfc146106f95780631e7877501461070257806323b872dd1461070c57806323e7b0ba1461071f57600080fd5b806313de8019146106cb57806314bef93e146106de57806318160ddd146106f157600080fd5b806306fdde031461064357806309523c6b14610661578063095ea7b3146106775780630b5530a71461069a5780630d075d9c146106a35780630f683e90146106b8575b600080fd5b61064b610d91565b6040516106589190613d0d565b60405180910390f35b610669610e23565b604051908152602001610658565b61068a610685366004613d3c565b610e48565b6040519015158152602001610658565b610669601a5481565b6106b66106b1366004613d66565b610e62565b005b6106b66106c6366004613d66565b610f20565b61068a6106d9366004613d92565b610fd0565b6106b66106ec366004613dab565b610ff5565b600254610669565b61066960215481565b6106696201518081565b61068a61071a366004613dc6565b6110a9565b6106b661072d366004613dab565b6110cd565b6106b6610740366004613dab565b6111f0565b6106696a05be0692f63baaf6c0000081565b61064b610765366004613d92565b611270565b60405160128152602001610658565b61068a610787366004613d3c565b61130a565b60275461079f906001600160a01b031681565b6040516001600160a01b039091168152602001610658565b60265461079f906001600160a01b031681565b61068a6107d8366004613dab565b60286020526000908152604090205460ff1681565b6106b66107fb366004613d92565b61132c565b60275461068a90600160a01b900460ff1681565b6106696301e1338081565b610669600a5481565b61066960195481565b610669600d5481565b6106b6610848366004613dab565b61135c565b610669600b5481565b6106b6610864366004613d92565b611404565b610669600c5481565b610669601b5481565b60225461079f906001600160a01b031681565b61089661150e565b604080519485526020850193909352918301526060820152608001610658565b6106696108c4366004613dab565b6001600160a01b031660009081526020819052604090205490565b60245461079f906001600160a01b031681565b61066961153d565b601354601254601454601554601754601654601854601954604080519889526020890197909752958701949094526060860192909252608085015260a084015260c083015260e082015261010001610658565b6106b6611549565b61066960135481565b6106b661096c366004613d92565b61155d565b6106b661097f366004613d66565b6116a7565b6106b6610992366004613dab565b6117a4565b6106696103e881565b6106b66109ae366004613dab565b6118ba565b610669611a44565b6106b6611a6b565b6005546001600160a01b031661079f565b6106696109e2366004613eae565b611b18565b6106b66109f5366004613f34565b611b4b565b610669610a08366004613d3c565b611bab565b610669610a1b366004613dab565b60296020526000908152604090205481565b61064b611ea4565b610669601d5481565b610669611eb3565b61066960175481565b6106b6610a5d366004613dab565b611efd565b6106b6610a70366004613f6b565b611fc2565b610669610a83366004613d3c565b611fe8565b61068a610a96366004613d3c565b61228c565b6106b6610aa9366004613d66565b612307565b61068a610abc366004613d3c565b612455565b61066960165481565b60275461068a90600160a81b900460ff1681565b61066960185481565b61066960075481565b6106b6610afe366004613f6b565b61246b565b610669601c5481565b61066960085481565b6106b6610b23366004613f34565b6124e3565b61066960145481565b61066969d3c21bcecceda100000081565b60255461079f906001600160a01b031681565b610669612654565b6106b6610b6b366004613dab565b61269c565b6106b6610b7e366004613dab565b61274c565b602254602354602454602554602654602754604080516001600160a01b03978816815295871660208701529386169385019390935290841660608401528316608083015291821660a082015260ff600160a01b83048116151560c0830152600160c01b909204909116151560e082015261010001610658565b6106b6610c0a366004613f88565b612851565b6106b6610c1d366004613f6b565b612967565b61066960205481565b602d5461079f906001600160a01b031681565b610669606481565b61066961271081565b61066960095481565b6106b6610c66366004613f34565b612a16565b6106b6612a49565b610669610c81366004613fc5565b612b3d565b60275461068a90600160c01b900460ff1681565b61079f610ca8366004613d92565b612b68565b610669610cbb366004613d92565b602b6020526000908152604090205481565b6106b6610cdb366004613dab565b612bc3565b61066960125481565b610669601e5481565b610669604581565b600954600a54600b5460408051938452602084019290925290820152606001610658565b6106b6610d2c366004613dab565b612d0c565b60235461079f906001600160a01b031681565b610669612d82565b60315461079f9061010090046001600160a01b031681565b6106696a084595161401484a00000081565b61066960155481565b61079f61dead81565b610669601f5481565b606060038054610da090613ff8565b80601f0160208091040260200160405190810160405280929190818152602001828054610dcc90613ff8565b8015610e195780601f10610dee57610100808354040283529160200191610e19565b820191906000526020600020905b815481529060010190602001808311610dfc57829003601f168201915b5050505050905090565b6000604560075410610e355750600090565b600754610e43906045614048565b905090565b600033610e56818585612d9b565b60019150505b92915050565b610e6a612ebf565b6103e881610e78848661405b565b610e82919061405b565b1115610eca5760405162461bcd60e51b81526020600482015260126024820152710a8dee8c2d840cccaca40e8dede40d0d2ced60731b60448201526064015b60405180910390fd5b60128390556013829055601481905560408051848152602081018490529081018290527fa7266bdfb6dddf05c6d4c2b1c0a92e32c7f0a8815840290ee04b4dab3c6ff01d906060015b60405180910390a1505050565b610f28612ebf565b6103e881610f36848661405b565b610f40919061405b565b1115610f835760405162461bcd60e51b81526020600482015260126024820152710a8dee8c2d840cccaca40e8dede40d0d2ced60731b6044820152606401610ec1565b60168390556017829055601881905560408051848152602081018490529081018290527f448e0e14dd61faacf0f8f7dded9eb48b249502327415f15dc735243d76a8586290606001610f13565b6000818152602b60205260408120548015801590610fee5750804210155b9392505050565b610ffd612ebf565b6001600160a01b03811661105f5760405162461bcd60e51b8152602060048201526024808201527f45786368616e676520706169722063616e6e6f74206265207a65726f206164646044820152637265737360e01b6064820152608401610ec1565b602780546001600160a01b0319166001600160a01b0383169081179091556040517f68b85316b4a002f17128f82dca3d48c7fc2e824a841943465b56000c3ddb041490600090a250565b6000336110b7858285612f19565b6110c2858585612f93565b506001949350505050565b6110d5612ebf565b6001600160a01b03811661112b5760405162461bcd60e51b815260206004820152601a60248201527f4e657720616464726573732063616e6e6f74206265207a65726f0000000000006044820152606401610ec1565b60008160405160200161113e919061406e565b6040516020818303038152906040528051906020012090506201518042611165919061405b565b6000828152602b6020908152604080832093909355825180840184526016815275557064617465206a61636b706f74206164647265737360501b81830152848352602c909152919020906111b990826140f1565b50806000805160206144748339815191526111d7620151804261405b565b6040516111e491906141b1565b60405180910390a25050565b6111f8612ebf565b6001600160a01b03811661124e5760405162461bcd60e51b815260206004820152601e60248201527f4c6f747465727920616464726573732063616e6e6f74206265207a65726f00006044820152606401610ec1565b602680546001600160a01b0319166001600160a01b0392909216919091179055565b602c602052600090815260409020805461128990613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546112b590613ff8565b80156113025780601f106112d757610100808354040283529160200191611302565b820191906000526020600020905b8154815290600101906020018083116112e557829003601f168201915b505050505081565b600033610e5681858561131d8383612b3d565b611327919061405b565b612d9b565b61133633826131d6565b8060096000828254611348919061405b565b90915550611359905060038261330f565b50565b611364612ebf565b6001600160a01b0381166113ba5760405162461bcd60e51b815260206004820152601d60248201527f766536394c5020616464726573732063616e6e6f74206265207a65726f0000006044820152606401610ec1565b602380546001600160a01b0319166001600160a01b0383169081179091556040517f492e9d77c9c06355a063aefae50abdb906672c13c38f227bc6f0eea08e75fd5e90600090a250565b61140c612ebf565b602754600160c01b900460ff16156114665760405162461bcd60e51b815260206004820152601860248201527f4f776e65727368697020616c7265616479206c6f636b656400000000000000006044820152606401610ec1565b60008111801561147a57506301e133808111155b6114be5760405162461bcd60e51b815260206004820152601560248201527424b73b30b634b2103637b1b590323ab930ba34b7b760591b6044820152606401610ec1565b6027805460ff60c01b1916600160c01b1790556040517f12ea4a831c30198a4f20f64c4e0f34d55f5a8663ea776afac53eed1ebc166da5906115039083815260200190565b60405180910390a150565b60008060008061151c611eb3565b611524612654565b61152c610e23565b600754935093509350935090919293565b6000610e43602e61337b565b611551612ebf565b61155b6000613385565b565b611565612ebf565b6000818152602b60205260409020546115b75760405162461bcd60e51b81526020600482015260146024820152731058dd1a5bdb881b9bdd081cd8da19591d5b195960621b6044820152606401610ec1565b6000818152602c6020526040812080546115d090613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546115fc90613ff8565b80156116495780601f1061161e57610100808354040283529160200191611649565b820191906000526020600020905b81548152906001019060200180831161162c57829003601f168201915b5050506000858152602b60209081526040808320839055602c90915281209394506116779392509050613c6f565b817f4133f12238d9c77b6b2a20ea59f935ab7d3df1c520364ca5f9b062cf7d9fc3fe826040516111e49190613d0d565b6116af612ebf565b604051697570646174654665657360b01b6020820152602a8101849052604a8101839052606a8101829052600090608a0160408051601f1981840301815291815281516020928301206000818152602b9093529120549091501580159061172457506000818152602b60205260409020544210155b6117405760405162461bcd60e51b8152600401610ec1906141f5565b601e849055601f83905560208290558161175a848661405b565b611764919061405b565b6021556000818152602b602052604080822091909155518190600080516020614494833981519152906117969061422c565b60405180910390a250505050565b6117ac612ebf565b6001600160a01b0381166118025760405162461bcd60e51b815260206004820152601a60248201527f4e657720616464726573732063616e6e6f74206265207a65726f0000000000006044820152606401610ec1565b6000816040516020016118159190614257565b604051602081830303815290604052805190602001209050620151804261183c919061405b565b6000828152602b602090815260408083209390935582518084018452601581527455706461746520766536394c50206164647265737360581b81830152848352602c9091529190209061188f90826140f1565b50806000805160206144748339815191526118ad620151804261405b565b6040516111e4919061428b565b6118c2612ebf565b6000611929604051806040016040528060118152602001707365744c6f74746572794164647265737360781b81525083604051602001611915919060609190911b6001600160601b031916815260140190565b604051602081830303815290604052611b18565b905061193481610fd0565b6119505760405162461bcd60e51b8152600401610ec1906142c0565b6000818152602b60209081526040808320839055602c9091528120805461197690613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546119a290613ff8565b80156119ef5780601f106119c4576101008083540402835291602001916119ef565b820191906000526020600020905b8154815290600101906020018083116119d257829003601f168201915b5050506000858152602c60205260408120939450611a109392509050613c6f565b611a19836111f8565b8160008051602061449483398151915282604051611a379190613d0d565b60405180910390a2505050565b612710611a5e6a05be0692f63baaf6c000006101a46142ee565b611a689190614305565b81565b611a73612ebf565b602754600160a01b900460ff1615611acd5760405162461bcd60e51b815260206004820152601760248201527f54726164696e6720616c726561647920656e61626c65640000000000000000006044820152606401610ec1565b6027805461ffff60a01b191661010160a01b179055604051600181527fbeda7dca7bc1b3e80b871f4818129ec73b771581f803d553aeb3484098e5f65a9060200160405180910390a1565b60008282604051602001611b2d929190614327565b60405160208183030381529060405280519060200120905092915050565b611b53612ebf565b6001600160a01b038216600081815260286020908152604091829020805460ff191685151590811790915591519182527f4d5771454588f51370a8a2e7e151354b6de0dc3159b14821b4ad76bc04c28bc791016111e4565b6027546000906001600160a01b03163314611c085760405162461bcd60e51b815260206004820181905260248201527f4f6e6c792065786368616e676520706169722063616e2063616c6c20746869736044820152606401610ec1565b60008211611c585760405162461bcd60e51b815260206004820181905260248201527f416d6f756e74206d7573742062652067726561746572207468616e207a65726f6044820152606401610ec1565b6000612710611c69846102b26142ee565b611c739190614305565b90506000612710611c858560f16142ee565b611c8f9190614305565b90506000611c9d828461405b565b90506000611cab8287614048565b90508315611d4757602254602d54611cd2916001600160a01b03918216918a9116876133d7565b611cdd60018561330f565b6026546001600160a01b031615611d4757602654604051635bda81a960e11b8152600481018690526001600160a01b039091169063b7b5035290602401600060405180830381600087803b158015611d3457600080fd5b505af1925050508015611d45575060015b505b8215611d7757602354602d54611d6c916001600160a01b03918216918a9116866133d7565b611d7760028461330f565b602754602d54611d96916001600160a01b03918216918a9116846133d7565b9350836000612710611da98360456142ee565b611db39190614305565b90506000611dc18288614048565b9050611dcf61dead83613431565b611dd98982613431565b8160096000828254611deb919061405b565b90915550611dfc905060038361330f565b6026546001600160a01b031615801590611e1e57506001600160a01b03891632145b8015611e3257506001600160a01b0389163b155b15611e985760265460405163ea274a6b60e01b81526001600160a01b038b81166004830152602482018b90529091169063ea274a6b90604401600060405180830381600087803b158015611e8557600080fd5b505af1925050508015611e96575060015b505b98975050505050505050565b606060048054610da090613ff8565b600060456007541015611ee357612710611ed96a05be0692f63baaf6c0000060456142ee565b610e439190614305565b612710611ed96a05be0692f63baaf6c000006101a46142ee565b611f05612ebf565b600081604051602001611f18919061406e565b60408051601f1981840301815291815281516020928301206000818152602b90935291205490915015801590611f5c57506000818152602b60205260409020544210155b611f785760405162461bcd60e51b8152600401610ec1906141f5565b602280546001600160a01b0319166001600160a01b0384161790556000818152602b602052604080822091909155518190600080516020614494833981519152906111e490614356565b611fca612ebf565b60278054911515600160b81b0260ff60b81b19909216919091179055565b6027546000906001600160a01b031633146120455760405162461bcd60e51b815260206004820181905260248201527f4f6e6c792065786368616e676520706169722063616e2063616c6c20746869736044820152606401610ec1565b600082116120955760405162461bcd60e51b815260206004820181905260248201527f416d6f756e74206d7573742062652067726561746572207468616e207a65726f6044820152606401610ec1565b60006127106120a58460456142ee565b6120af9190614305565b905060006120bd8285614048565b90506120c985836131d6565b81600960008282546120db919061405b565b909155506120ec905060038361330f565b6027546121049086906001600160a01b0316836134f8565b806000612710612116836102b26142ee565b6121209190614305565b905060006127106121328460f16142ee565b61213c9190614305565b9050600061214a828461405b565b90506121568185614048565b965082156121d35761216960018461330f565b6026546001600160a01b0316156121d357602654604051635bda81a960e11b8152600481018590526001600160a01b039091169063b7b5035290602401600060405180830381600087803b1580156121c057600080fd5b505af19250505080156121d1575060015b505b81156121e4576121e460028361330f565b6026546001600160a01b03161580159061220657506001600160a01b03891632145b801561221a57506001600160a01b0389163b155b156122805760265460405163012ca9e760e51b81526001600160a01b038b81166004830152602482018a9052909116906325953ce090604401600060405180830381600087803b15801561226d57600080fd5b505af192505050801561227e575060015b505b50505050505092915050565b6000338161229a8286612b3d565b9050838110156122fa5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b6064820152608401610ec1565b6110c28286868403612d9b565b61230f612ebf565b60008161231c848661405b565b612326919061405b565b90506103e881111561237a5760405162461bcd60e51b815260206004820152601b60248201527f546f74616c206665652063616e6e6f74206578636565642031302500000000006044820152606401610ec1565b604051697570646174654665657360b01b6020820152602a8101859052604a8101849052606a8101839052600090608a0160405160208183030381529060405280519060200120905062015180426123d2919061405b565b6000828152602b602090815260408083209390935582518084018452600b81526a557064617465206665657360a81b81830152848352602c9091529190209061241b90826140f1565b5080600080516020614474833981519152612439620151804261405b565b604051612446919061438c565b60405180910390a25050505050565b6000612462338484612f93565b50600192915050565b6027546001600160a01b031633146124c55760405162461bcd60e51b815260206004820152601860248201527f4f6e6c7920706169722063616e2073657420696e5377617000000000000000006044820152606401610ec1565b60278054911515600160b01b0260ff60b01b19909216919091179055565b6124eb612ebf565b60006125456040518060400160405280600c81526020016b1cd95d119959515e195b5c1d60a21b815250848460405160200161191592919060609290921b6001600160601b0319168252151560f81b601482015260150190565b905061255081610fd0565b61256c5760405162461bcd60e51b8152600401610ec1906142c0565b6000818152602b60209081526040808320839055602c9091528120805461259290613ff8565b80601f01602080910402602001604051908101604052809291908181526020018280546125be90613ff8565b801561260b5780601f106125e05761010080835404028352916020019161260b565b820191906000526020600020905b8154815290600101906020018083116125ee57829003601f168201915b5050506000858152602c6020526040812093945061262c9392509050613c6f565b61263684846136a2565b81600080516020614494833981519152826040516117969190613d0d565b60008061266060025490565b90506045600754101561268a5761268461271061267e836064613723565b9061372f565b91505090565b61268461271061267e836103e8613723565b6126a4612ebf565b6001600160a01b0381166126fa5760405162461bcd60e51b815260206004820152601d60248201527f526f7574657220616464726573732063616e6e6f74206265207a65726f0000006044820152606401610ec1565b60318054610100600160a81b0319166101006001600160a01b038416908102919091179091556040517f7aed1d3e8155a07ccf395e44ea3109a0e2d6c9b29bbbe9f142d9790596f4dc8090600090a250565b612754612ebf565b6000816040516020016127679190614257565b60408051601f1981840301815291815281516020928301206000818152602b909352912054909150158015906127ab57506000818152602b60205260409020544210155b6127c75760405162461bcd60e51b8152600401610ec1906141f5565b602380546001600160a01b0319166001600160a01b0384161790556000818152602b60205260408082209190915551819060008051602061449483398151915290612811906143b7565b60405180910390a26040516001600160a01b038316907f492e9d77c9c06355a063aefae50abdb906672c13c38f227bc6f0eea08e75fd5e90600090a25050565b612859612ebf565b6000828152602b6020526040902054156128b55760405162461bcd60e51b815260206004820152601860248201527f416374696f6e20616c7265616479207363686564756c656400000000000000006044820152606401610ec1565b602754600160c01b900460ff16156129055760405162461bcd60e51b815260206004820152601360248201527213dddb995c9cda1a5c081a5cc81b1bd8dad959606a1b6044820152606401610ec1565b612912620151804261405b565b6000838152602b6020908152604080832093909355602c90522061293682826140f1565b506000828152602b6020526040908190205490518391600080516020614474833981519152916111e49185916143ec565b61296f612ebf565b602754600160a81b900460ff16156129c95760405162461bcd60e51b815260206004820152601e60248201527f54726164696e67206973207065726d616e656e746c7920656e61626c656400006044820152606401610ec1565b60278054821515600160a01b0260ff60a01b199091161790556040517fbeda7dca7bc1b3e80b871f4818129ec73b771581f803d553aeb3484098e5f65a9061150390831515815260200190565b612a1e612ebf565b6001600160a01b03919091166000908152602a60205260409020805460ff1916911515919091179055565b612a51612ebf565b6000612a9560405180604001604052806011815260200170072656e6f756e63654f776e65727368697607c1b81525060405180602001604052806000815250611b18565b9050612aa081610fd0565b612abc5760405162461bcd60e51b8152600401610ec1906142c0565b612ac66000613385565b6040517fd1f66c3d2bc1993a86be5e3d33709d98f0442381befcedd29f578b9b2506b1ce90600090a180600080516020614494833981519152604051612b3290602080825260129082015271052656e6f756e6365206f776e6572736869760741b604082015260600190565b60405180910390a250565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b6000612b74602e61337b565b8210612bb85760405162461bcd60e51b8152602060048201526013602482015272496e646578206f7574206f6620626f756e647360681b6044820152606401610ec1565b610e5c602e8361373b565b612bcb612ebf565b6000612c1c6040518060400160405280600f81526020016e39b2ba22bc31b430b733b2a830b4b960891b81525083604051602001611915919060609190911b6001600160601b031916815260140190565b9050612c2781610fd0565b612c435760405162461bcd60e51b8152600401610ec1906142c0565b6000818152602b60209081526040808320839055602c90915281208054612c6990613ff8565b80601f0160208091040260200160405190810160405280929190818152602001828054612c9590613ff8565b8015612ce25780601f10612cb757610100808354040283529160200191612ce2565b820191906000526020600020905b815481529060010190602001808311612cc557829003601f168201915b5050506000858152602c60205260408120939450612d039392509050613c6f565b611a1983610ffd565b612d14612ebf565b6001600160a01b038116612d795760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610ec1565b61135981613385565b612710611a5e6a05be0692f63baaf6c0000060456142ee565b6001600160a01b038316612dfd5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610ec1565b6001600160a01b038216612e5e5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610ec1565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6005546001600160a01b0316331461155b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ec1565b6000612f258484612b3d565b90506000198114612f8d5781811015612f805760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610ec1565b612f8d8484848403612d9b565b50505050565b6001600160a01b038316612fe95760405162461bcd60e51b815260206004820152601a60248201527f5472616e736665722066726f6d207a65726f20616464726573730000000000006044820152606401610ec1565b6001600160a01b03821661303f5760405162461bcd60e51b815260206004820152601860248201527f5472616e7366657220746f207a65726f206164647265737300000000000000006044820152606401610ec1565b600081116130a15760405162461bcd60e51b815260206004820152602960248201527f5472616e7366657220616d6f756e74206d7573742062652067726561746572206044820152687468616e207a65726f60b81b6064820152608401610ec1565b602754600160a01b900460ff161580156130d457506001600160a01b03831660009081526028602052604090205460ff16155b80156130f957506001600160a01b03821660009081526028602052604090205460ff16155b156131465760405162461bcd60e51b815260206004820152601760248201527f54726164696e67206e6f742079657420656e61626c65640000000000000000006044820152606401610ec1565b6001600160a01b03808416600090815260296020526040808220429081905592851682529020556131788383836134f8565b6001600160a01b03831660009081526028602052604090205460ff161580156131ba57506001600160a01b03821660009081526028602052604090205460ff16155b156131d1576007546131cd906001613747565b6007555b505050565b6001600160a01b0382166132365760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b6064820152608401610ec1565b6001600160a01b038216600090815260208190526040902054818110156132aa5760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b6064820152608401610ec1565b6001600160a01b0383166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a36131d183600084613753565b8160ff166001036133375780600a600082825461332c919061405b565b909155506133779050565b8160ff166002036133545780600b600082825461332c919061405b565b8160ff16600303613377578060096000828254613371919061405b565b90915550505b5050565b6000610e5c825490565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052612f8d90859061378c565b6001600160a01b0382166134875760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610ec1565b8060026000828254613499919061405b565b90915550506001600160a01b038216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a361337760008383613753565b6001600160a01b03831661355c5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610ec1565b6001600160a01b0382166135be5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610ec1565b6001600160a01b038316600090815260208190526040902054818110156136365760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610ec1565b6001600160a01b03848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3612f8d848484613753565b6001600160a01b0382166136f85760405162461bcd60e51b815260206004820152601a60248201527f43616e6e6f74206578656d7074207a65726f20616464726573730000000000006044820152606401610ec1565b6001600160a01b03919091166000908152602860205260409020805460ff1916911515919091179055565b6000610fee82846142ee565b6000610fee8284614305565b6000610fee838361385e565b6000610fee828461405b565b61375c83613888565b61376582613888565b602754600160a01b900460ff16801561377e5750600c54155b156131d15742600c55505050565b60006137e1826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166139519092919063ffffffff16565b8051909150156131d157808060200190518101906137ff919061440e565b6131d15760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610ec1565b60008260000182815481106138755761387561442b565b9060005260206000200154905092915050565b6001600160a01b038116158015906138ab57506001600160a01b03811661dead14155b80156138c057506001600160a01b0381163014155b15611359576138d0602e82613968565b1580156138f357506001600160a01b038116600090815260208190526040812054115b1561391457613903602e8261398a565b5061390e602e61337b565b600d5550565b61391f602e82613968565b801561394157506001600160a01b038116600090815260208190526040902054155b1561135957613903602e8261399f565b606061396084846000856139b4565b949350505050565b6001600160a01b03811660009081526001830160205260408120541515610fee565b6000610fee836001600160a01b038416613a8f565b6000610fee836001600160a01b038416613ade565b606082471015613a155760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610ec1565b600080866001600160a01b03168587604051613a319190614441565b60006040518083038185875af1925050503d8060008114613a6e576040519150601f19603f3d011682016040523d82523d6000602084013e613a73565b606091505b5091509150613a8487838387613bd1565b979650505050505050565b6000818152600183016020526040812054613ad657508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610e5c565b506000610e5c565b60008181526001830160205260408120548015613bc7576000613b02600183614048565b8554909150600090613b1690600190614048565b9050818114613b7b576000866000018281548110613b3657613b3661442b565b9060005260206000200154905080876000018481548110613b5957613b5961442b565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613b8c57613b8c61445d565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610e5c565b6000915050610e5c565b60608315613c40578251600003613c39576001600160a01b0385163b613c395760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610ec1565b5081613960565b6139608383815115613c555781518083602001fd5b8060405162461bcd60e51b8152600401610ec19190613d0d565b508054613c7b90613ff8565b6000825580601f10613c8b575050565b601f01602090049060005260206000209081019061135991905b80821115613cb95760008155600101613ca5565b5090565b60005b83811015613cd8578181015183820152602001613cc0565b50506000910152565b60008151808452613cf9816020860160208601613cbd565b601f01601f19169290920160200192915050565b602081526000610fee6020830184613ce1565b80356001600160a01b0381168114613d3757600080fd5b919050565b60008060408385031215613d4f57600080fd5b613d5883613d20565b946020939093013593505050565b600080600060608486031215613d7b57600080fd5b505081359360208301359350604090920135919050565b600060208284031215613da457600080fd5b5035919050565b600060208284031215613dbd57600080fd5b610fee82613d20565b600080600060608486031215613ddb57600080fd5b613de484613d20565b9250613df260208501613d20565b9150604084013590509250925092565b634e487b7160e01b600052604160045260246000fd5b600067ffffffffffffffff80841115613e3357613e33613e02565b604051601f8501601f19908116603f01168101908282118183101715613e5b57613e5b613e02565b81604052809350858152868686011115613e7457600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112613e9f57600080fd5b610fee83833560208501613e18565b60008060408385031215613ec157600080fd5b823567ffffffffffffffff80821115613ed957600080fd5b613ee586838701613e8e565b93506020850135915080821115613efb57600080fd5b508301601f81018513613f0d57600080fd5b613f1c85823560208401613e18565b9150509250929050565b801515811461135957600080fd5b60008060408385031215613f4757600080fd5b613f5083613d20565b91506020830135613f6081613f26565b809150509250929050565b600060208284031215613f7d57600080fd5b8135610fee81613f26565b60008060408385031215613f9b57600080fd5b82359150602083013567ffffffffffffffff811115613fb957600080fd5b613f1c85828601613e8e565b60008060408385031215613fd857600080fd5b613fe183613d20565b9150613fef60208401613d20565b90509250929050565b600181811c9082168061400c57607f821691505b60208210810361402c57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b81810381811115610e5c57610e5c614032565b80820180821115610e5c57610e5c614032565b737570646174654a61636b706f744164647265737360601b815260609190911b6001600160601b031916601482015260280190565b601f8211156131d157600081815260208120601f850160051c810160208610156140ca5750805b601f850160051c820191505b818110156140e9578281556001016140d6565b505050505050565b815167ffffffffffffffff81111561410b5761410b613e02565b61411f816141198454613ff8565b846140a3565b602080601f831160018114614154576000841561413c5750858301515b600019600386901b1c1916600185901b1785556140e9565b600085815260208120601f198616915b8281101561418357888601518255948401946001909101908401614164565b50858210156141a15787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6040815260006141e7604083016016815275557064617465206a61636b706f74206164647265737360501b602082015260400190565b905082602083015292915050565b6020808252601b908201527f416374696f6e206e6f74207265616479206f7220657870697265640000000000604082015260600190565b602081526000610e5c60208301600b81526a557064617465206665657360a81b602082015260400190565b72757064617465766536394c504164647265737360681b815260609190911b6001600160601b031916601382015260270190565b6040815260006141e760408301601581527455706461746520766536394c50206164647265737360581b602082015260400190565b602080825260149082015273151a5b595b1bd8dac81b9bdd08195e1c1a5c995960621b604082015260600190565b8082028115828204841417610e5c57610e5c614032565b60008261432257634e487b7160e01b600052601260045260246000fd5b500490565b60008351614339818460208801613cbd565b83519083019061434d818360208801613cbd565b01949350505050565b602081526000610e5c602083016016815275557064617465206a61636b706f74206164647265737360501b602082015260400190565b6040815260006141e760408301600b81526a557064617465206665657360a81b602082015260400190565b602081526000610e5c60208301601581527455706461746520766536394c50206164647265737360581b602082015260400190565b6040815260006143ff6040830185613ce1565b90508260208301529392505050565b60006020828403121561442057600080fd5b8151610fee81613f26565b634e487b7160e01b600052603260045260246000fd5b60008251614453818460208701613cbd565b9190910192915050565b634e487b7160e01b600052603160045260246000fdfe74178a809360af06601aec28d5c6558ea658a63de4a67d01134709fff40a26f24a88ca0fefd66d59f32a22d49b86e48beed962046c13cd78d78ce14c4928ace3a26469706673582212203071c80cbfc8ed9e28f9b6f793202ea5b4a7b082a01698ef102bfac5bebde93964736f6c63430008140033

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.