Contract Address Details
0xcd318b31a37fBD569E06A20df158905D3464eEb2
- Token
- DogeBank (BANK)
- Creator
- 0x9092d3–bad729 at 0x78288c–bb4c8a
- Balance
- 10,059.140995149613675846 Doge
- Tokens
-
Fetching tokens...
- Transactions
- 907 Transactions
- Transfers
- 503 Transfers
- Gas Used
- 49,320,479
- Last Balance Update
- 26904170
Transactions
Token Transfers
Tokens
Internal Transactions
Coin Balance History
Logs
Code
Read Contract
Write Contract
- Contract name:
- DogeBank
- Optimization enabled
- true
- Compiler version
- v0.8.0+commit.c7dfd78e
- Optimization runs
- 1500
- EVM Version
- default
- Verified at
- 2022-08-15T11:34:45.922653Z
Contract source code
// File: @openzeppelin/contracts/token/ERC20/IERC20.sol // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @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 `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, 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 `sender` to `recipient` 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 sender, address recipient, uint256 amount ) external returns (bool); /** * @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); } // File: @openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol pragma solidity ^0.8.0; /** * @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); } // File: @openzeppelin/contracts/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; } } // File: @openzeppelin/contracts/token/ERC20/ERC20.sol pragma solidity ^0.8.0; /** * @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.zeppelin.solutions/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: * * - `recipient` cannot be the zero address. * - the caller must have a balance of at least `amount`. */ function transfer(address recipient, uint256 amount) public virtual override returns (bool) { _transfer(_msgSender(), recipient, 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}. * * Requirements: * * - `spender` cannot be the zero address. */ function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(_msgSender(), 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}. * * Requirements: * * - `sender` and `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. * - the caller must have allowance for ``sender``'s tokens of at least * `amount`. */ function transferFrom( address sender, address recipient, uint256 amount ) public virtual override returns (bool) { _transfer(sender, recipient, amount); uint256 currentAllowance = _allowances[sender][_msgSender()]; require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance"); unchecked { _approve(sender, _msgSender(), currentAllowance - 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) { _approve(_msgSender(), spender, _allowances[_msgSender()][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) { uint256 currentAllowance = _allowances[_msgSender()][spender]; require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); unchecked { _approve(_msgSender(), spender, currentAllowance - subtractedValue); } return true; } /** * @dev Moves `amount` of tokens from `sender` to `recipient`. * * 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: * * - `sender` cannot be the zero address. * - `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. */ function _transfer( address sender, address recipient, uint256 amount ) internal virtual { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); _beforeTokenTransfer(sender, recipient, amount); uint256 senderBalance = _balances[sender]; require(senderBalance >= amount, "ERC20: transfer amount exceeds balance"); unchecked { _balances[sender] = senderBalance - amount; } _balances[recipient] += amount; emit Transfer(sender, recipient, amount); _afterTokenTransfer(sender, recipient, 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; _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; } _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 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 {} } // File: @openzeppelin/contracts/access/Ownable.sol pragma solidity ^0.8.0; /** * @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() { _setOwner(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { 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 { _setOwner(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"); _setOwner(newOwner); } function _setOwner(address newOwner) private { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } } // File: @openzeppelin/contracts/utils/Address.sol pragma solidity ^0.8.0; /** * @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 * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 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 functionCall(target, data, "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"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(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) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(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) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason 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 { // 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 assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } } // File: contracts/ISwapRouter.sol pragma solidity >=0.6.2; interface ISwapRouter { function factory() external pure returns (address); function WWDOGE() external pure returns (address); function addLiquidity( address tokenA, address tokenB, uint amountADesired, uint amountBDesired, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB, uint liquidity); function addLiquidityWDOGE( address token, uint amountTokenDesired, uint amountTokenMin, uint amountWDOGEMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountWDOGE, uint liquidity); function removeLiquidity( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB); function removeLiquidityWDOGE( address token, uint liquidity, uint amountTokenMin, uint amountWDOGEMin, address to, uint deadline ) external returns (uint amountToken, uint amountWDOGE); function removeLiquidityWithPermit( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountA, uint amountB); function removeLiquidityWDOGEWithPermit( address token, uint liquidity, uint amountTokenMin, uint amountWDOGEMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountToken, uint amountWDOGE); function swapExactTokensForTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapTokensForExactTokens( uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapExactWDOGEForTokens(uint amountOutMin, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function swapTokensForExactWDOGE(uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapExactTokensForWDOGE(uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapWDOGEForExactTokens(uint amountOut, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function quote(uint amountA, uint reserveA, uint reserveB) external pure returns (uint amountB); function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) external pure returns (uint amountOut); function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) external pure returns (uint amountIn); function getAmountsOut(uint amountIn, address[] calldata path) external view returns (uint[] memory amounts); function getAmountsIn(uint amountOut, address[] calldata path) external view returns (uint[] memory amounts); function removeLiquidityWDOGESupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountWDOGEMin, address to, uint deadline ) external returns (uint amountWDOGE); function removeLiquidityWDOGEWithPermitSupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountWDOGEMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountWDOGE); function swapExactTokensForTokensSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function swapExactWDOGEForTokensSupportingFeeOnTransferTokens( uint amountOutMin, address[] calldata path, address to, uint deadline ) external payable; function swapExactTokensForWDOGESupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; } // File: contracts/ISwapFactory.sol pragma solidity >=0.6.2; interface ISwapFactory { function getPair(address tokenA, address tokenB) external view returns (address pair); function createPair(address tokenA, address tokenB) external view returns (address pair); } // File: contracts/BANK.sol pragma solidity ^0.8.0; contract DogeBank is Context, IERC20, Ownable { using Address for address; mapping (address => uint256) private _rOwned; mapping (address => uint256) private _tOwned; mapping (address => mapping (address => uint256)) private _allowances; mapping (address => bool) private _isExcludedFromFee; mapping (address => bool) private _isExcluded; address[] private _excluded; uint256 private constant MAX = ~uint256(0); uint256 private _tTotal = 999999999999999 * 10**18; uint256 private _rTotal = (MAX - (MAX % _tTotal)); uint256 private _tFeeTotal; string private _name = "DogeBank"; string private _symbol = "BANK"; uint8 private _decimals = 18; uint256 public _taxFee = 5; uint256 private _previousTaxFee = _taxFee; uint256 public _liquidityFee = 5; uint256 private _previousLiquidityFee = _liquidityFee; ISwapRouter public router; address public lpPair; bool inSwapAndLiquify; bool public swapAndLiquifyEnabled = true; uint256 public _maxTxAmount = 222222222222222 * 10**18; uint256 private numTokensSellToAddToLiquidity = 555555555555 * 10**18; event MinTokensBeforeSwapUpdated(uint256 minTokensBeforeSwap); event SwapAndLiquifyEnabledUpdated(bool enabled); event SwapAndLiquify( uint256 tokensSwapped, uint256 ethReceived, uint256 tokensIntoLiqudity ); modifier lockTheSwap { inSwapAndLiquify = true; _; inSwapAndLiquify = false; } constructor() { _rOwned[address(this)] = _rTotal; ISwapRouter _router = ISwapRouter(0xa4EE06Ce40cb7e8c04E127c1F7D3dFB7F7039C81); // set the rest of the contract variables router = _router; //exclude owner and this contract from fee _isExcludedFromFee[owner()] = true; _isExcludedFromFee[address(this)] = true; excludeFromReward(address(this)); emit Transfer(address(0), address(this), _tTotal); } /* ADMIN */ /** * @notice : deploys liquidity to router, and sends LP tokens to deployer */ function deployLiquidity() public payable onlyOwner { _approve(address(this), address(router), totalSupply()); router.addLiquidityWDOGE{ value: msg.value }( address(this), totalSupply(), 0, 0, msg.sender, block.timestamp + 1000 ); lpPair = ISwapFactory(router.factory()).getPair(router.WWDOGE(), address(this)); } function name() public view returns (string memory) { return _name; } function symbol() public view returns (string memory) { return _symbol; } function decimals() public view returns (uint8) { return _decimals; } function totalSupply() public view override returns (uint256) { return _tTotal; } function balanceOf(address account) public view override returns (uint256) { if (_isExcluded[account]) return _tOwned[account]; return tokenFromReflection(_rOwned[account]); } function transfer(address recipient, uint256 amount) public override returns (bool) { _transfer(_msgSender(), recipient, amount); return true; } function allowance(address owner, address spender) public view override returns (uint256) { return _allowances[owner][spender]; } function approve(address spender, uint256 amount) public override returns (bool) { _approve(_msgSender(), spender, amount); return true; } function transferFrom(address sender, address recipient, uint256 amount) public override returns (bool) { _transfer(sender, recipient, amount); _approve(sender, _msgSender(), _allowances[sender][_msgSender()] - amount); return true; } function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue); return true; } function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender] - subtractedValue); return true; } function isExcludedFromReward(address account) public view returns (bool) { return _isExcluded[account]; } function totalFees() public view returns (uint256) { return _tFeeTotal; } function deliver(uint256 tAmount) public { address sender = _msgSender(); require(!_isExcluded[sender], "Excluded addresses cannot call this function"); (uint256 rAmount,,,,,) = _getValues(tAmount); _rOwned[sender] = _rOwned[sender] - rAmount; _rTotal = _rTotal - rAmount; _tFeeTotal = _tFeeTotal + tAmount; } function reflectionFromToken(uint256 tAmount, bool deductTransferFee) public view returns(uint256) { require(tAmount <= _tTotal, "Amount must be less than supply"); if (!deductTransferFee) { (uint256 rAmount,,,,,) = _getValues(tAmount); return rAmount; } else { (,uint256 rTransferAmount,,,,) = _getValues(tAmount); return rTransferAmount; } } function tokenFromReflection(uint256 rAmount) public view returns(uint256) { require(rAmount <= _rTotal, "Amount must be less than total reflections"); uint256 currentRate = _getRate(); return rAmount / currentRate; } function excludeFromReward(address account) public onlyOwner() { // require(account != 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D, 'We can not exclude Uniswap router.'); require(!_isExcluded[account], "Account is already excluded"); if(_rOwned[account] > 0) { _tOwned[account] = tokenFromReflection(_rOwned[account]); } _isExcluded[account] = true; _excluded.push(account); } function includeInReward(address account) external onlyOwner() { require(_isExcluded[account], "Account is already excluded"); for (uint256 i = 0; i < _excluded.length; i++) { if (_excluded[i] == account) { _excluded[i] = _excluded[_excluded.length - 1]; _tOwned[account] = 0; _isExcluded[account] = false; _excluded.pop(); break; } } } function _transferBothExcluded(address sender, address recipient, uint256 tAmount) private { (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount); _tOwned[sender] = _tOwned[sender] - tAmount; _rOwned[sender] = _rOwned[sender] - rAmount; _tOwned[recipient] = _tOwned[recipient] + tTransferAmount; _rOwned[recipient] = _rOwned[recipient] + rTransferAmount; _takeLiquidity(tLiquidity); _reflectFee(rFee, tFee); emit Transfer(sender, recipient, tTransferAmount); } function excludeFromFee(address account) public onlyOwner { _isExcludedFromFee[account] = true; } function includeInFee(address account) public onlyOwner { _isExcludedFromFee[account] = false; } function setTaxFeePercent(uint256 taxFee) external onlyOwner() { _taxFee = taxFee; } function setLiquidityFeePercent(uint256 liquidityFee) external onlyOwner() { _liquidityFee = liquidityFee; } function setMaxTxPercent(uint256 maxTxPercent) external onlyOwner() { _maxTxAmount = _tTotal * maxTxPercent / 10**2; } function setSwapAndLiquifyEnabled(bool _enabled) public onlyOwner { swapAndLiquifyEnabled = _enabled; emit SwapAndLiquifyEnabledUpdated(_enabled); } //to recieve WDOGE from router when swaping receive() external payable {} function _reflectFee(uint256 rFee, uint256 tFee) private { _rTotal = _rTotal - rFee; _tFeeTotal = _tFeeTotal + tFee; } function _getValues(uint256 tAmount) private view returns (uint256, uint256, uint256, uint256, uint256, uint256) { (uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getTValues(tAmount); (uint256 rAmount, uint256 rTransferAmount, uint256 rFee) = _getRValues(tAmount, tFee, tLiquidity, _getRate()); return (rAmount, rTransferAmount, rFee, tTransferAmount, tFee, tLiquidity); } function _getTValues(uint256 tAmount) private view returns (uint256, uint256, uint256) { uint256 tFee = calculateTaxFee(tAmount); uint256 tLiquidity = calculateLiquidityFee(tAmount); uint256 tTransferAmount = tAmount - tFee - tLiquidity; return (tTransferAmount, tFee, tLiquidity); } function _getRValues(uint256 tAmount, uint256 tFee, uint256 tLiquidity, uint256 currentRate) private pure returns (uint256, uint256, uint256) { uint256 rAmount = tAmount * currentRate; uint256 rFee = tFee * currentRate; uint256 rLiquidity = tLiquidity * currentRate; uint256 rTransferAmount = rAmount - rFee - rLiquidity; return (rAmount, rTransferAmount, rFee); } function _getRate() private view returns(uint256) { (uint256 rSupply, uint256 tSupply) = _getCurrentSupply(); return rSupply / tSupply; } function _getCurrentSupply() private view returns(uint256, uint256) { uint256 rSupply = _rTotal; uint256 tSupply = _tTotal; for (uint256 i = 0; i < _excluded.length; i++) { if (_rOwned[_excluded[i]] > rSupply || _tOwned[_excluded[i]] > tSupply) return (_rTotal, _tTotal); rSupply = rSupply - _rOwned[_excluded[i]]; tSupply = tSupply - _tOwned[_excluded[i]]; } if (rSupply < _rTotal / _tTotal) return (_rTotal, _tTotal); return (rSupply, tSupply); } function _takeLiquidity(uint256 tLiquidity) private { uint256 currentRate = _getRate(); uint256 rLiquidity = tLiquidity * (currentRate); _rOwned[address(this)] = _rOwned[address(this)] + rLiquidity; if(_isExcluded[address(this)]) _tOwned[address(this)] = _tOwned[address(this)] + tLiquidity; } function calculateTaxFee(uint256 _amount) private view returns (uint256) { return _amount * _taxFee / 10**2; } function calculateLiquidityFee(uint256 _amount) private view returns (uint256) { return _amount * _liquidityFee / 10**2; } function removeAllFee() private { if(_taxFee == 0 && _liquidityFee == 0) return; _previousTaxFee = _taxFee; _previousLiquidityFee = _liquidityFee; _taxFee = 0; _liquidityFee = 0; } function restoreAllFee() private { _taxFee = _previousTaxFee; _liquidityFee = _previousLiquidityFee; } function isExcludedFromFee(address account) public view returns(bool) { return _isExcludedFromFee[account]; } function _approve(address owner, address spender, uint256 amount) private { 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); } function _transfer( address from, address to, uint256 amount ) private { require(from != address(0), "ERC20: transfer from the zero address"); require(to != address(0), "ERC20: transfer to the zero address"); require(amount > 0, "Transfer amount must be greater than zero"); if(from != address(this)) require(amount <= _maxTxAmount, "Transfer amount exceeds the maxTxAmount."); // is the token balance of this contract address over the min number of // tokens that we need to initiate a swap + liquidity lock? // also, don't get caught in a circular liquidity event. // also, don't swap & liquify if sender is lp pair. uint256 contractTokenBalance = balanceOf(address(this)); if(contractTokenBalance >= _maxTxAmount) contractTokenBalance = _maxTxAmount; bool overMinTokenBalance = contractTokenBalance >= numTokensSellToAddToLiquidity; if ( overMinTokenBalance && !inSwapAndLiquify && lpPair != address(0) && from != lpPair && swapAndLiquifyEnabled ) { contractTokenBalance = numTokensSellToAddToLiquidity; //add liquidity swapAndLiquify(contractTokenBalance); } //indicates if fee should be deducted from transfer bool takeFee = true; //if any account belongs to _isExcludedFromFee account then remove the fee if(_isExcludedFromFee[from] || _isExcludedFromFee[to]){ takeFee = false; } //transfer amount, it will take tax, burn, liquidity fee _tokenTransfer(from,to,amount,takeFee); } function swapAndLiquify(uint256 contractTokenBalance) private lockTheSwap { // split the contract balance into halves uint256 half = contractTokenBalance / 2; uint256 otherHalf = contractTokenBalance - half; // capture the contract's current WDOGE balance. // this is so that we can capture exactly the amount of WDOGE that the // swap creates, and not make the liquidity event include any WDOGE that // has been manually sent to the contract uint256 initialBalance = address(this).balance; // swap tokens for WDOGE swapTokensForWDOGE(half); // how much WDOGE did we just swap into? uint256 newBalance = address(this).balance - initialBalance; // add liquidity to uniswap addLiquidity(otherHalf, newBalance); emit SwapAndLiquify(half, newBalance, otherHalf); } function swapTokensForWDOGE(uint256 tokenAmount) private { // generate the pair path of token -> wwdoge address[] memory path = new address[](2); path[0] = address(this); path[1] = router.WWDOGE(); _approve(address(this), address(router), tokenAmount); // make the swap router.swapExactTokensForWDOGESupportingFeeOnTransferTokens( tokenAmount, 0, // accept any amount of WDOGE path, address(this), block.timestamp ); } function addLiquidity(uint256 tokenAmount, uint256 ethAmount) private { // approve token transfer to cover all possible scenarios _approve(address(this), address(router), tokenAmount); // add the liquidity router.addLiquidityWDOGE{value: ethAmount}( address(this), tokenAmount, 0, // slippage is unavoidable 0, // slippage is unavoidable owner(), block.timestamp ); } //this method is responsible for taking all fee, if takeFee is true function _tokenTransfer(address sender, address recipient, uint256 amount,bool takeFee) private { if(!takeFee) removeAllFee(); if (_isExcluded[sender] && !_isExcluded[recipient]) { _transferFromExcluded(sender, recipient, amount); } else if (!_isExcluded[sender] && _isExcluded[recipient]) { _transferToExcluded(sender, recipient, amount); } else if (!_isExcluded[sender] && !_isExcluded[recipient]) { _transferStandard(sender, recipient, amount); } else if (_isExcluded[sender] && _isExcluded[recipient]) { _transferBothExcluded(sender, recipient, amount); } else { _transferStandard(sender, recipient, amount); } if(!takeFee) restoreAllFee(); } function _transferStandard(address sender, address recipient, uint256 tAmount) private { (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount); _rOwned[sender] = _rOwned[sender] - rAmount; _rOwned[recipient] = _rOwned[recipient] + rTransferAmount; _takeLiquidity(tLiquidity); _reflectFee(rFee, tFee); emit Transfer(sender, recipient, tTransferAmount); } function _transferToExcluded(address sender, address recipient, uint256 tAmount) private { (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount); _rOwned[sender] = _rOwned[sender] - rAmount; _tOwned[recipient] = _tOwned[recipient] + tTransferAmount; _rOwned[recipient] = _rOwned[recipient] + rTransferAmount; _takeLiquidity(tLiquidity); _reflectFee(rFee, tFee); emit Transfer(sender, recipient, tTransferAmount); } function _transferFromExcluded(address sender, address recipient, uint256 tAmount) private { (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount); _tOwned[sender] = _tOwned[sender] - tAmount; _rOwned[sender] = _rOwned[sender] - rAmount; _rOwned[recipient] = _rOwned[recipient] + rTransferAmount; _takeLiquidity(tLiquidity); _reflectFee(rFee, tFee); emit Transfer(sender, recipient, tTransferAmount); } }
Contract ABI
[{"type":"constructor","stateMutability":"nonpayable","inputs":[]},{"type":"event","name":"Approval","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"spender","internalType":"address","indexed":true},{"type":"uint256","name":"value","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"MinTokensBeforeSwapUpdated","inputs":[{"type":"uint256","name":"minTokensBeforeSwap","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"SwapAndLiquify","inputs":[{"type":"uint256","name":"tokensSwapped","internalType":"uint256","indexed":false},{"type":"uint256","name":"ethReceived","internalType":"uint256","indexed":false},{"type":"uint256","name":"tokensIntoLiqudity","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"SwapAndLiquifyEnabledUpdated","inputs":[{"type":"bool","name":"enabled","internalType":"bool","indexed":false}],"anonymous":false},{"type":"event","name":"Transfer","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256","name":"value","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"_liquidityFee","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"_maxTxAmount","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"_taxFee","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"allowance","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"address","name":"spender","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"approve","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"balanceOf","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint8","name":"","internalType":"uint8"}],"name":"decimals","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"decreaseAllowance","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"subtractedValue","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"deliver","inputs":[{"type":"uint256","name":"tAmount","internalType":"uint256"}]},{"type":"function","stateMutability":"payable","outputs":[],"name":"deployLiquidity","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"excludeFromFee","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"excludeFromReward","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"includeInFee","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"includeInReward","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"increaseAllowance","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"addedValue","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isExcludedFromFee","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isExcludedFromReward","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"lpPair","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"name","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"reflectionFromToken","inputs":[{"type":"uint256","name":"tAmount","internalType":"uint256"},{"type":"bool","name":"deductTransferFee","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"contract ISwapRouter"}],"name":"router","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setLiquidityFeePercent","inputs":[{"type":"uint256","name":"liquidityFee","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setMaxTxPercent","inputs":[{"type":"uint256","name":"maxTxPercent","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setSwapAndLiquifyEnabled","inputs":[{"type":"bool","name":"_enabled","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setTaxFeePercent","inputs":[{"type":"uint256","name":"taxFee","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"swapAndLiquifyEnabled","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"symbol","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"tokenFromReflection","inputs":[{"type":"uint256","name":"rAmount","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalFees","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSupply","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"transfer","inputs":[{"type":"address","name":"recipient","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"transferFrom","inputs":[{"type":"address","name":"sender","internalType":"address"},{"type":"address","name":"recipient","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]},{"type":"receive","stateMutability":"payable"}]
Contract Creation Code
0x60806040526d314dc6448d932ae0a456589c000060078190556200002690600019620007d6565b620000349060001962000761565b60089081556040805180820190915281815267446f676542616e6b60c01b60209091019081526200006991600a9190620005e5565b506040805180820190915260048082526342414e4b60e01b60209092019182526200009791600b91620005e5565b50600c805460ff191660129081179091556005600d819055600e819055600f819055601055805460ff60a81b1916600160a81b1790556d0af4d6b9e6927b4e5d68857800006013556c070318c8e574c41eac8dac0000601455348015620000fd57600080fd5b50620001126200010c620001f5565b620001f9565b600854306000908152600160208190526040822092909255601180546001600160a01b03191673a4ee06ce40cb7e8c04e127c1f7d3dfb7f7039c8190811790915591906004906200016262000249565b6001600160a01b0316815260208082019290925260409081016000908120805494151560ff19958616179055308082526004909352208054909216600117909155620001ae9062000258565b60075460405130916000917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91620001e69162000741565b60405180910390a35062000819565b3390565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000546001600160a01b031690565b62000262620001f5565b6001600160a01b03166200027562000249565b6001600160a01b031614620002a75760405162461bcd60e51b81526004016200029e906200070c565b60405180910390fd5b6001600160a01b03811660009081526005602052604090205460ff1615620002e35760405162461bcd60e51b81526004016200029e90620006d5565b6001600160a01b0381166000908152600160205260409020541562000340576001600160a01b0381166000908152600160205260409020546200032690620003a6565b6001600160a01b0382166000908152600260205260409020555b6001600160a01b03166000818152600560205260408120805460ff191660019081179091556006805491820181559091527ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f0180546001600160a01b0319169091179055565b6000600854821115620003cd5760405162461bcd60e51b81526004016200029e906200068b565b6000620003d9620003ee565b9050620003e781846200074a565b9392505050565b60008080620003fc62000414565b90925090506200040d81836200074a565b9250505090565b6008546007546000918291825b600654811015620005ae578260016000600684815481106200045357634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020541180620004ce5750816002600060068481548110620004a757634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054115b15620004e75760085460075494509450505050620005e1565b60016000600683815481106200050d57634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020546200053e908462000761565b925060026000600683815481106200056657634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b0316835282019290925260400190205462000597908362000761565b915080620005a581620007b8565b91505062000421565b50600754600854620005c191906200074a565b821015620005db57600854600754935093505050620005e1565b90925090505b9091565b828054620005f3906200077b565b90600052602060002090601f01602090048101928262000617576000855562000662565b82601f106200063257805160ff191683800117855562000662565b8280016001018555821562000662579182015b828111156200066257825182559160200191906001019062000645565b506200067092915062000674565b5090565b5b8082111562000670576000815560010162000675565b6020808252602a908201527f416d6f756e74206d757374206265206c657373207468616e20746f74616c207260408201526965666c656374696f6e7360b01b606082015260800190565b6020808252601b908201527f4163636f756e7420697320616c7265616479206578636c756465640000000000604082015260600190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b90815260200190565b6000826200075c576200075c62000803565b500490565b600082821015620007765762000776620007ed565b500390565b6002810460018216806200079057607f821691505b60208210811415620007b257634e487b7160e01b600052602260045260246000fd5b50919050565b6000600019821415620007cf57620007cf620007ed565b5060010190565b600082620007e857620007e862000803565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b61299b80620008296000396000f3fe6080604052600436106102385760003560e01c806352390c021161013857806395d89b41116100b0578063d543dbeb1161007f578063ea2f0b3711610064578063ea2f0b37146105f4578063f2fde38b14610614578063f887ea40146106345761023f565b8063d543dbeb146105b4578063dd62ed3e146105d45761023f565b806395d89b411461053f578063a457c2d714610554578063a9059cbb14610574578063c49b9a80146105945761023f565b8063715018a61161010757806388f82020116100ec57806388f82020146104ea5780638da5cb5b1461050a5780638ee88c531461051f5761023f565b8063715018a6146104c05780637d1db4a5146104d55761023f565b806352390c021461044b5780635342acb41461046b5780636bc87c3a1461048b57806370a08231146104a05761023f565b80633685d419116101cb5780634086bf891161019a578063452ed4f11161017f578063452ed4f1146103f45780634549b039146104165780634a74bb02146104365761023f565b80634086bf89146103cc578063437823ec146103d45761023f565b80633685d4191461035757806339509351146103775780633b124fe7146103975780633bd5d173146103ac5761023f565b806318160ddd1161020757806318160ddd146102e057806323b872dd146102f55780632d83811914610315578063313ce567146103355761023f565b8063061c82d01461024457806306fdde0314610266578063095ea7b31461029157806313114a9d146102be5761023f565b3661023f57005b600080fd5b34801561025057600080fd5b5061026461025f3660046122ba565b610649565b005b34801561027257600080fd5b5061027b610696565b604051610288919061239e565b60405180910390f35b34801561029d57600080fd5b506102b16102ac366004612275565b610728565b6040516102889190612393565b3480156102ca57600080fd5b506102d3610746565b60405161028891906127d9565b3480156102ec57600080fd5b506102d361074c565b34801561030157600080fd5b506102b1610310366004612235565b610752565b34801561032157600080fd5b506102d36103303660046122ba565b6107c7565b34801561034157600080fd5b5061034a61080a565b6040516102889190612868565b34801561036357600080fd5b506102646103723660046121be565b610813565b34801561038357600080fd5b506102b1610392366004612275565b610a02565b3480156103a357600080fd5b506102d3610a51565b3480156103b857600080fd5b506102646103c73660046122ba565b610a57565b610264610b14565b3480156103e057600080fd5b506102646103ef3660046121be565b610dd4565b34801561040057600080fd5b50610409610e37565b604051610288919061232a565b34801561042257600080fd5b506102d36104313660046122d2565b610e46565b34801561044257600080fd5b506102b1610ea3565b34801561045757600080fd5b506102646104663660046121be565b610eb3565b34801561047757600080fd5b506102b16104863660046121be565b610ff8565b34801561049757600080fd5b506102d3611016565b3480156104ac57600080fd5b506102d36104bb3660046121be565b61101c565b3480156104cc57600080fd5b5061026461107e565b3480156104e157600080fd5b506102d36110c9565b3480156104f657600080fd5b506102b16105053660046121be565b6110cf565b34801561051657600080fd5b506104096110ed565b34801561052b57600080fd5b5061026461053a3660046122ba565b6110fc565b34801561054b57600080fd5b5061027b611140565b34801561056057600080fd5b506102b161056f366004612275565b61114f565b34801561058057600080fd5b506102b161058f366004612275565b61119e565b3480156105a057600080fd5b506102646105af3660046122a0565b6111b2565b3480156105c057600080fd5b506102646105cf3660046122ba565b61125e565b3480156105e057600080fd5b506102d36105ef3660046121fd565b6112bd565b34801561060057600080fd5b5061026461060f3660046121be565b6112e8565b34801561062057600080fd5b5061026461062f3660046121be565b611348565b34801561064057600080fd5b506104096113b9565b6106516113c8565b6001600160a01b03166106626110ed565b6001600160a01b0316146106915760405162461bcd60e51b815260040161068890612630565b60405180910390fd5b600d55565b6060600a80546106a5906128e4565b80601f01602080910402602001604051908101604052809291908181526020018280546106d1906128e4565b801561071e5780601f106106f35761010080835404028352916020019161071e565b820191906000526020600020905b81548152906001019060200180831161070157829003601f168201915b5050505050905090565b600061073c6107356113c8565b84846113cc565b5060015b92915050565b60095490565b60075490565b600061075f848484611480565b6107bd8461076b6113c8565b6001600160a01b0387166000908152600360205260408120869161078d6113c8565b6001600160a01b03166001600160a01b03168152602001908152602001600020546107b891906128cd565b6113cc565b5060019392505050565b60006008548211156107eb5760405162461bcd60e51b81526004016106889061244e565b60006107f561161f565b9050610801818461288e565b9150505b919050565b600c5460ff1690565b61081b6113c8565b6001600160a01b031661082c6110ed565b6001600160a01b0316146108525760405162461bcd60e51b815260040161068890612630565b6001600160a01b03811660009081526005602052604090205460ff1661088a5760405162461bcd60e51b815260040161068890612565565b60005b6006548110156109fe57816001600160a01b0316600682815481106108c257634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b031614156109ec57600680546108ed906001906128cd565b8154811061090b57634e487b7160e01b600052603260045260246000fd5b600091825260209091200154600680546001600160a01b03909216918390811061094557634e487b7160e01b600052603260045260246000fd5b6000918252602080832091909101805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b039485161790559184168152600282526040808220829055600590925220805460ff1916905560068054806109b857634e487b7160e01b600052603160045260246000fd5b6000828152602090208101600019908101805473ffffffffffffffffffffffffffffffffffffffff191690550190556109fe565b806109f68161291f565b91505061088d565b5050565b600061073c610a0f6113c8565b848460036000610a1d6113c8565b6001600160a01b03908116825260208083019390935260409182016000908120918b16815292529020546107b89190612876565b600d5481565b6000610a616113c8565b6001600160a01b03811660009081526005602052604090205490915060ff1615610a9d5760405162461bcd60e51b81526004016106889061277c565b6000610aa883611642565b505050506001600160a01b038416600090815260016020526040902054919250610ad4918391506128cd565b6001600160a01b038316600090815260016020526040902055600854610afb9082906128cd565b600855600954610b0c908490612876565b600955505050565b610b1c6113c8565b6001600160a01b0316610b2d6110ed565b6001600160a01b031614610b535760405162461bcd60e51b815260040161068890612630565b601154610b6d9030906001600160a01b03166107b861074c565b6011546001600160a01b031663e6529ab43430610b8861074c565b60008033610b98426103e8612876565b6040518863ffffffff1660e01b8152600401610bb996959493929190612358565b6060604051808303818588803b158015610bd257600080fd5b505af1158015610be6573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190610c0b91906122fd565b5050601154604080517fc45a015500000000000000000000000000000000000000000000000000000000815290516001600160a01b03909216925063c45a0155916004808301926020929190829003018186803b158015610c6b57600080fd5b505afa158015610c7f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ca391906121e1565b6001600160a01b031663e6a43905601160009054906101000a90046001600160a01b03166001600160a01b0316634ed154606040518163ffffffff1660e01b815260040160206040518083038186803b158015610cff57600080fd5b505afa158015610d13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d3791906121e1565b306040518363ffffffff1660e01b8152600401610d5592919061233e565b60206040518083038186803b158015610d6d57600080fd5b505afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da591906121e1565b6012805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b610ddc6113c8565b6001600160a01b0316610ded6110ed565b6001600160a01b031614610e135760405162461bcd60e51b815260040161068890612630565b6001600160a01b03166000908152600460205260409020805460ff19166001179055565b6012546001600160a01b031681565b6000600754831115610e6a5760405162461bcd60e51b81526004016106889061259c565b81610e89576000610e7a84611642565b50939550610740945050505050565b6000610e9484611642565b50929550610740945050505050565b601254600160a81b900460ff1681565b610ebb6113c8565b6001600160a01b0316610ecc6110ed565b6001600160a01b031614610ef25760405162461bcd60e51b815260040161068890612630565b6001600160a01b03811660009081526005602052604090205460ff1615610f2b5760405162461bcd60e51b815260040161068890612565565b6001600160a01b03811660009081526001602052604090205415610f85576001600160a01b038116600090815260016020526040902054610f6b906107c7565b6001600160a01b0382166000908152600260205260409020555b6001600160a01b03166000818152600560205260408120805460ff191660019081179091556006805491820181559091527ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f01805473ffffffffffffffffffffffffffffffffffffffff19169091179055565b6001600160a01b031660009081526004602052604090205460ff1690565b600f5481565b6001600160a01b03811660009081526005602052604081205460ff161561105c57506001600160a01b038116600090815260026020526040902054610805565b6001600160a01b038216600090815260016020526040902054610740906107c7565b6110866113c8565b6001600160a01b03166110976110ed565b6001600160a01b0316146110bd5760405162461bcd60e51b815260040161068890612630565b6110c76000611691565b565b60135481565b6001600160a01b031660009081526005602052604090205460ff1690565b6000546001600160a01b031690565b6111046113c8565b6001600160a01b03166111156110ed565b6001600160a01b03161461113b5760405162461bcd60e51b815260040161068890612630565b600f55565b6060600b80546106a5906128e4565b600061073c61115c6113c8565b84846003600061116a6113c8565b6001600160a01b03908116825260208083019390935260409182016000908120918b16815292529020546107b891906128cd565b600061073c6111ab6113c8565b8484611480565b6111ba6113c8565b6001600160a01b03166111cb6110ed565b6001600160a01b0316146111f15760405162461bcd60e51b815260040161068890612630565b601280547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16600160a81b831515021790556040517f53726dfcaf90650aa7eb35524f4d3220f07413c8d6cb404cc8c18bf5591bc15990611253908390612393565b60405180910390a150565b6112666113c8565b6001600160a01b03166112776110ed565b6001600160a01b03161461129d5760405162461bcd60e51b815260040161068890612630565b6064816007546112ad91906128ae565b6112b7919061288e565b60135550565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205490565b6112f06113c8565b6001600160a01b03166113016110ed565b6001600160a01b0316146113275760405162461bcd60e51b815260040161068890612630565b6001600160a01b03166000908152600460205260409020805460ff19169055565b6113506113c8565b6001600160a01b03166113616110ed565b6001600160a01b0316146113875760405162461bcd60e51b815260040161068890612630565b6001600160a01b0381166113ad5760405162461bcd60e51b8152600401610688906124ab565b6113b681611691565b50565b6011546001600160a01b031681565b3390565b6001600160a01b0383166113f25760405162461bcd60e51b81526004016106889061271f565b6001600160a01b0382166114185760405162461bcd60e51b815260040161068890612508565b6001600160a01b0380841660008181526003602090815260408083209487168084529490915290819020849055517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925906114739085906127d9565b60405180910390a3505050565b6001600160a01b0383166114a65760405162461bcd60e51b8152600401610688906126c2565b6001600160a01b0382166114cc5760405162461bcd60e51b8152600401610688906123f1565b600081116114ec5760405162461bcd60e51b815260040161068890612665565b6001600160a01b038316301461151e5760135481111561151e5760405162461bcd60e51b8152600401610688906125d3565b60006115293061101c565b9050601354811061153957506013545b60145481108015908190611568575060125474010000000000000000000000000000000000000000900460ff16155b801561157e57506012546001600160a01b031615155b801561159857506012546001600160a01b03868116911614155b80156115ad5750601254600160a81b900460ff165b156115c05760145491506115c0826116ee565b6001600160a01b03851660009081526004602052604090205460019060ff168061160257506001600160a01b03851660009081526004602052604090205460ff165b1561160b575060005b611617868686846117d6565b505050505050565b600080600061162c61194a565b909250905061163b818361288e565b9250505090565b60008060008060008060008060006116598a611b08565b92509250925060008060006116778d868661167261161f565b611b4b565b919f909e50909c50959a5093985091965092945050505050565b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b601280547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1674010000000000000000000000000000000000000000179055600061173a60028361288e565b9050600061174882846128cd565b90504761175483611ba2565b600061176082476128cd565b905061176c8382611d51565b7f17bbfb9a6069321b6ded73bd96327c9e6b7212a5cd51ff219cd61370acafb56184828560405161179f93929190612852565b60405180910390a15050601280547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055505050565b806117e3576117e3611e03565b6001600160a01b03841660009081526005602052604090205460ff16801561182457506001600160a01b03831660009081526005602052604090205460ff16155b1561183957611834848484611e34565b611937565b6001600160a01b03841660009081526005602052604090205460ff1615801561187a57506001600160a01b03831660009081526005602052604090205460ff165b1561188a57611834848484611f5b565b6001600160a01b03841660009081526005602052604090205460ff161580156118cc57506001600160a01b03831660009081526005602052604090205460ff16155b156118dc57611834848484612007565b6001600160a01b03841660009081526005602052604090205460ff16801561191c57506001600160a01b03831660009081526005602052604090205460ff165b1561192c5761183484848461204c565b611937848484612007565b80611944576119446120c1565b50505050565b6008546007546000918291825b600654811015611ad55782600160006006848154811061198757634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020541180611a0057508160026000600684815481106119d957634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054115b15611a175760085460075494509450505050611b04565b6001600060068381548110611a3c57634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054611a6b90846128cd565b92506002600060068381548110611a9257634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054611ac190836128cd565b915080611acd8161291f565b915050611957565b50600754600854611ae6919061288e565b821015611afe57600854600754935093505050611b04565b90925090505b9091565b600080600080611b17856120cf565b90506000611b24866120eb565b9050600081611b3384896128cd565b611b3d91906128cd565b979296509094509092505050565b6000808080611b5a85896128ae565b90506000611b6886896128ae565b90506000611b7687896128ae565b9050600081611b8584866128cd565b611b8f91906128cd565b939b939a50919850919650505050505050565b6040805160028082526060820183526000926020830190803683370190505090503081600081518110611be557634e487b7160e01b600052603260045260246000fd5b6001600160a01b03928316602091820292909201810191909152601154604080517f4ed1546000000000000000000000000000000000000000000000000000000000815290519190931692634ed15460926004808301939192829003018186803b158015611c5257600080fd5b505afa158015611c66573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c8a91906121e1565b81600181518110611cab57634e487b7160e01b600052603260045260246000fd5b6001600160a01b039283166020918202929092010152601154611cd191309116846113cc565b6011546040517fb43d9bbb0000000000000000000000000000000000000000000000000000000081526001600160a01b039091169063b43d9bbb90611d239085906000908690309042906004016127e2565b600060405180830381600087803b158015611d3d57600080fd5b505af1158015611617573d6000803e3d6000fd5b601154611d699030906001600160a01b0316846113cc565b6011546001600160a01b031663e6529ab4823085600080611d886110ed565b426040518863ffffffff1660e01b8152600401611daa96959493929190612358565b6060604051808303818588803b158015611dc357600080fd5b505af1158015611dd7573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190611dfc91906122fd565b5050505050565b600d54158015611e135750600f54155b15611e1d576110c7565b600d8054600e55600f805460105560009182905555565b600080600080600080611e4687611642565b6001600160a01b038f16600090815260026020526040902054959b50939950919750955093509150611e799088906128cd565b6001600160a01b038a16600090815260026020908152604080832093909355600190522054611ea99087906128cd565b6001600160a01b03808b1660009081526001602052604080822093909355908a1681522054611ed9908690612876565b6001600160a01b038916600090815260016020526040902055611efb816120fd565b611f058483612188565b876001600160a01b0316896001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef85604051611f4891906127d9565b60405180910390a3505050505050505050565b600080600080600080611f6d87611642565b6001600160a01b038f16600090815260016020526040902054959b50939950919750955093509150611fa09087906128cd565b6001600160a01b03808b16600090815260016020908152604080832094909455918b16815260029091522054611fd7908490612876565b6001600160a01b038916600090815260026020908152604080832093909355600190522054611ed9908690612876565b60008060008060008061201987611642565b6001600160a01b038f16600090815260016020526040902054959b50939950919750955093509150611ea99087906128cd565b60008060008060008061205e87611642565b6001600160a01b038f16600090815260026020526040902054959b509399509197509550935091506120919088906128cd565b6001600160a01b038a16600090815260026020908152604080832093909355600190522054611fa09087906128cd565b600e54600d55601054600f55565b60006064600d54836120e191906128ae565b610740919061288e565b60006064600f54836120e191906128ae565b600061210761161f565b9050600061211582846128ae565b30600090815260016020526040902054909150612133908290612876565b3060009081526001602090815260408083209390935560059052205460ff16156121835730600090815260026020526040902054612172908490612876565b306000908152600260205260409020555b505050565b8160085461219691906128cd565b6008556009546121a7908290612876565b6009555050565b8035801515811461080557600080fd5b6000602082840312156121cf578081fd5b81356121da81612950565b9392505050565b6000602082840312156121f2578081fd5b81516121da81612950565b6000806040838503121561220f578081fd5b823561221a81612950565b9150602083013561222a81612950565b809150509250929050565b600080600060608486031215612249578081fd5b833561225481612950565b9250602084013561226481612950565b929592945050506040919091013590565b60008060408385031215612287578182fd5b823561229281612950565b946020939093013593505050565b6000602082840312156122b1578081fd5b6121da826121ae565b6000602082840312156122cb578081fd5b5035919050565b600080604083850312156122e4578182fd5b823591506122f4602084016121ae565b90509250929050565b600080600060608486031215612311578283fd5b8351925060208401519150604084015190509250925092565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039687168152602081019590955260408501939093526060840191909152909216608082015260a081019190915260c00190565b901515815260200190565b6000602080835283518082850152825b818110156123ca578581018301518582016040015282016123ae565b818111156123db5783604083870101525b50601f01601f1916929092016040019392505050565b60208082526023908201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260408201527f6573730000000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252602a908201527f416d6f756e74206d757374206265206c657373207468616e20746f74616c207260408201527f65666c656374696f6e7300000000000000000000000000000000000000000000606082015260800190565b60208082526026908201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160408201527f6464726573730000000000000000000000000000000000000000000000000000606082015260800190565b60208082526022908201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560408201527f7373000000000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252601b908201527f4163636f756e7420697320616c7265616479206578636c756465640000000000604082015260600190565b6020808252601f908201527f416d6f756e74206d757374206265206c657373207468616e20737570706c7900604082015260600190565b60208082526028908201527f5472616e7366657220616d6f756e74206578636565647320746865206d61785460408201527f78416d6f756e742e000000000000000000000000000000000000000000000000606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526029908201527f5472616e7366657220616d6f756e74206d75737420626520677265617465722060408201527f7468616e207a65726f0000000000000000000000000000000000000000000000606082015260800190565b60208082526025908201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460408201527f6472657373000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526024908201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460408201527f7265737300000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252602c908201527f4578636c75646564206164647265737365732063616e6e6f742063616c6c207460408201527f6869732066756e6374696f6e0000000000000000000000000000000000000000606082015260800190565b90815260200190565b600060a082018783526020878185015260a0604085015281875180845260c0860191508289019350845b818110156128315784516001600160a01b03168352938301939183019160010161280c565b50506001600160a01b03969096166060850152505050608001529392505050565b9283526020830191909152604082015260600190565b60ff91909116815260200190565b600082198211156128895761288961293a565b500190565b6000826128a957634e487b7160e01b81526012600452602481fd5b500490565b60008160001904831182151516156128c8576128c861293a565b500290565b6000828210156128df576128df61293a565b500390565b6002810460018216806128f857607f821691505b6020821081141561291957634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156129335761293361293a565b5060010190565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b03811681146113b657600080fdfea26469706673582212207d8a1a36c715820a6902582a532254d78101cb3ac22dc9520249fa86bb087dff64736f6c63430008000033
Deployed ByteCode
0x6080604052600436106102385760003560e01c806352390c021161013857806395d89b41116100b0578063d543dbeb1161007f578063ea2f0b3711610064578063ea2f0b37146105f4578063f2fde38b14610614578063f887ea40146106345761023f565b8063d543dbeb146105b4578063dd62ed3e146105d45761023f565b806395d89b411461053f578063a457c2d714610554578063a9059cbb14610574578063c49b9a80146105945761023f565b8063715018a61161010757806388f82020116100ec57806388f82020146104ea5780638da5cb5b1461050a5780638ee88c531461051f5761023f565b8063715018a6146104c05780637d1db4a5146104d55761023f565b806352390c021461044b5780635342acb41461046b5780636bc87c3a1461048b57806370a08231146104a05761023f565b80633685d419116101cb5780634086bf891161019a578063452ed4f11161017f578063452ed4f1146103f45780634549b039146104165780634a74bb02146104365761023f565b80634086bf89146103cc578063437823ec146103d45761023f565b80633685d4191461035757806339509351146103775780633b124fe7146103975780633bd5d173146103ac5761023f565b806318160ddd1161020757806318160ddd146102e057806323b872dd146102f55780632d83811914610315578063313ce567146103355761023f565b8063061c82d01461024457806306fdde0314610266578063095ea7b31461029157806313114a9d146102be5761023f565b3661023f57005b600080fd5b34801561025057600080fd5b5061026461025f3660046122ba565b610649565b005b34801561027257600080fd5b5061027b610696565b604051610288919061239e565b60405180910390f35b34801561029d57600080fd5b506102b16102ac366004612275565b610728565b6040516102889190612393565b3480156102ca57600080fd5b506102d3610746565b60405161028891906127d9565b3480156102ec57600080fd5b506102d361074c565b34801561030157600080fd5b506102b1610310366004612235565b610752565b34801561032157600080fd5b506102d36103303660046122ba565b6107c7565b34801561034157600080fd5b5061034a61080a565b6040516102889190612868565b34801561036357600080fd5b506102646103723660046121be565b610813565b34801561038357600080fd5b506102b1610392366004612275565b610a02565b3480156103a357600080fd5b506102d3610a51565b3480156103b857600080fd5b506102646103c73660046122ba565b610a57565b610264610b14565b3480156103e057600080fd5b506102646103ef3660046121be565b610dd4565b34801561040057600080fd5b50610409610e37565b604051610288919061232a565b34801561042257600080fd5b506102d36104313660046122d2565b610e46565b34801561044257600080fd5b506102b1610ea3565b34801561045757600080fd5b506102646104663660046121be565b610eb3565b34801561047757600080fd5b506102b16104863660046121be565b610ff8565b34801561049757600080fd5b506102d3611016565b3480156104ac57600080fd5b506102d36104bb3660046121be565b61101c565b3480156104cc57600080fd5b5061026461107e565b3480156104e157600080fd5b506102d36110c9565b3480156104f657600080fd5b506102b16105053660046121be565b6110cf565b34801561051657600080fd5b506104096110ed565b34801561052b57600080fd5b5061026461053a3660046122ba565b6110fc565b34801561054b57600080fd5b5061027b611140565b34801561056057600080fd5b506102b161056f366004612275565b61114f565b34801561058057600080fd5b506102b161058f366004612275565b61119e565b3480156105a057600080fd5b506102646105af3660046122a0565b6111b2565b3480156105c057600080fd5b506102646105cf3660046122ba565b61125e565b3480156105e057600080fd5b506102d36105ef3660046121fd565b6112bd565b34801561060057600080fd5b5061026461060f3660046121be565b6112e8565b34801561062057600080fd5b5061026461062f3660046121be565b611348565b34801561064057600080fd5b506104096113b9565b6106516113c8565b6001600160a01b03166106626110ed565b6001600160a01b0316146106915760405162461bcd60e51b815260040161068890612630565b60405180910390fd5b600d55565b6060600a80546106a5906128e4565b80601f01602080910402602001604051908101604052809291908181526020018280546106d1906128e4565b801561071e5780601f106106f35761010080835404028352916020019161071e565b820191906000526020600020905b81548152906001019060200180831161070157829003601f168201915b5050505050905090565b600061073c6107356113c8565b84846113cc565b5060015b92915050565b60095490565b60075490565b600061075f848484611480565b6107bd8461076b6113c8565b6001600160a01b0387166000908152600360205260408120869161078d6113c8565b6001600160a01b03166001600160a01b03168152602001908152602001600020546107b891906128cd565b6113cc565b5060019392505050565b60006008548211156107eb5760405162461bcd60e51b81526004016106889061244e565b60006107f561161f565b9050610801818461288e565b9150505b919050565b600c5460ff1690565b61081b6113c8565b6001600160a01b031661082c6110ed565b6001600160a01b0316146108525760405162461bcd60e51b815260040161068890612630565b6001600160a01b03811660009081526005602052604090205460ff1661088a5760405162461bcd60e51b815260040161068890612565565b60005b6006548110156109fe57816001600160a01b0316600682815481106108c257634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b031614156109ec57600680546108ed906001906128cd565b8154811061090b57634e487b7160e01b600052603260045260246000fd5b600091825260209091200154600680546001600160a01b03909216918390811061094557634e487b7160e01b600052603260045260246000fd5b6000918252602080832091909101805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b039485161790559184168152600282526040808220829055600590925220805460ff1916905560068054806109b857634e487b7160e01b600052603160045260246000fd5b6000828152602090208101600019908101805473ffffffffffffffffffffffffffffffffffffffff191690550190556109fe565b806109f68161291f565b91505061088d565b5050565b600061073c610a0f6113c8565b848460036000610a1d6113c8565b6001600160a01b03908116825260208083019390935260409182016000908120918b16815292529020546107b89190612876565b600d5481565b6000610a616113c8565b6001600160a01b03811660009081526005602052604090205490915060ff1615610a9d5760405162461bcd60e51b81526004016106889061277c565b6000610aa883611642565b505050506001600160a01b038416600090815260016020526040902054919250610ad4918391506128cd565b6001600160a01b038316600090815260016020526040902055600854610afb9082906128cd565b600855600954610b0c908490612876565b600955505050565b610b1c6113c8565b6001600160a01b0316610b2d6110ed565b6001600160a01b031614610b535760405162461bcd60e51b815260040161068890612630565b601154610b6d9030906001600160a01b03166107b861074c565b6011546001600160a01b031663e6529ab43430610b8861074c565b60008033610b98426103e8612876565b6040518863ffffffff1660e01b8152600401610bb996959493929190612358565b6060604051808303818588803b158015610bd257600080fd5b505af1158015610be6573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190610c0b91906122fd565b5050601154604080517fc45a015500000000000000000000000000000000000000000000000000000000815290516001600160a01b03909216925063c45a0155916004808301926020929190829003018186803b158015610c6b57600080fd5b505afa158015610c7f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ca391906121e1565b6001600160a01b031663e6a43905601160009054906101000a90046001600160a01b03166001600160a01b0316634ed154606040518163ffffffff1660e01b815260040160206040518083038186803b158015610cff57600080fd5b505afa158015610d13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d3791906121e1565b306040518363ffffffff1660e01b8152600401610d5592919061233e565b60206040518083038186803b158015610d6d57600080fd5b505afa158015610d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610da591906121e1565b6012805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b610ddc6113c8565b6001600160a01b0316610ded6110ed565b6001600160a01b031614610e135760405162461bcd60e51b815260040161068890612630565b6001600160a01b03166000908152600460205260409020805460ff19166001179055565b6012546001600160a01b031681565b6000600754831115610e6a5760405162461bcd60e51b81526004016106889061259c565b81610e89576000610e7a84611642565b50939550610740945050505050565b6000610e9484611642565b50929550610740945050505050565b601254600160a81b900460ff1681565b610ebb6113c8565b6001600160a01b0316610ecc6110ed565b6001600160a01b031614610ef25760405162461bcd60e51b815260040161068890612630565b6001600160a01b03811660009081526005602052604090205460ff1615610f2b5760405162461bcd60e51b815260040161068890612565565b6001600160a01b03811660009081526001602052604090205415610f85576001600160a01b038116600090815260016020526040902054610f6b906107c7565b6001600160a01b0382166000908152600260205260409020555b6001600160a01b03166000818152600560205260408120805460ff191660019081179091556006805491820181559091527ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f01805473ffffffffffffffffffffffffffffffffffffffff19169091179055565b6001600160a01b031660009081526004602052604090205460ff1690565b600f5481565b6001600160a01b03811660009081526005602052604081205460ff161561105c57506001600160a01b038116600090815260026020526040902054610805565b6001600160a01b038216600090815260016020526040902054610740906107c7565b6110866113c8565b6001600160a01b03166110976110ed565b6001600160a01b0316146110bd5760405162461bcd60e51b815260040161068890612630565b6110c76000611691565b565b60135481565b6001600160a01b031660009081526005602052604090205460ff1690565b6000546001600160a01b031690565b6111046113c8565b6001600160a01b03166111156110ed565b6001600160a01b03161461113b5760405162461bcd60e51b815260040161068890612630565b600f55565b6060600b80546106a5906128e4565b600061073c61115c6113c8565b84846003600061116a6113c8565b6001600160a01b03908116825260208083019390935260409182016000908120918b16815292529020546107b891906128cd565b600061073c6111ab6113c8565b8484611480565b6111ba6113c8565b6001600160a01b03166111cb6110ed565b6001600160a01b0316146111f15760405162461bcd60e51b815260040161068890612630565b601280547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16600160a81b831515021790556040517f53726dfcaf90650aa7eb35524f4d3220f07413c8d6cb404cc8c18bf5591bc15990611253908390612393565b60405180910390a150565b6112666113c8565b6001600160a01b03166112776110ed565b6001600160a01b03161461129d5760405162461bcd60e51b815260040161068890612630565b6064816007546112ad91906128ae565b6112b7919061288e565b60135550565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205490565b6112f06113c8565b6001600160a01b03166113016110ed565b6001600160a01b0316146113275760405162461bcd60e51b815260040161068890612630565b6001600160a01b03166000908152600460205260409020805460ff19169055565b6113506113c8565b6001600160a01b03166113616110ed565b6001600160a01b0316146113875760405162461bcd60e51b815260040161068890612630565b6001600160a01b0381166113ad5760405162461bcd60e51b8152600401610688906124ab565b6113b681611691565b50565b6011546001600160a01b031681565b3390565b6001600160a01b0383166113f25760405162461bcd60e51b81526004016106889061271f565b6001600160a01b0382166114185760405162461bcd60e51b815260040161068890612508565b6001600160a01b0380841660008181526003602090815260408083209487168084529490915290819020849055517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925906114739085906127d9565b60405180910390a3505050565b6001600160a01b0383166114a65760405162461bcd60e51b8152600401610688906126c2565b6001600160a01b0382166114cc5760405162461bcd60e51b8152600401610688906123f1565b600081116114ec5760405162461bcd60e51b815260040161068890612665565b6001600160a01b038316301461151e5760135481111561151e5760405162461bcd60e51b8152600401610688906125d3565b60006115293061101c565b9050601354811061153957506013545b60145481108015908190611568575060125474010000000000000000000000000000000000000000900460ff16155b801561157e57506012546001600160a01b031615155b801561159857506012546001600160a01b03868116911614155b80156115ad5750601254600160a81b900460ff165b156115c05760145491506115c0826116ee565b6001600160a01b03851660009081526004602052604090205460019060ff168061160257506001600160a01b03851660009081526004602052604090205460ff165b1561160b575060005b611617868686846117d6565b505050505050565b600080600061162c61194a565b909250905061163b818361288e565b9250505090565b60008060008060008060008060006116598a611b08565b92509250925060008060006116778d868661167261161f565b611b4b565b919f909e50909c50959a5093985091965092945050505050565b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b601280547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1674010000000000000000000000000000000000000000179055600061173a60028361288e565b9050600061174882846128cd565b90504761175483611ba2565b600061176082476128cd565b905061176c8382611d51565b7f17bbfb9a6069321b6ded73bd96327c9e6b7212a5cd51ff219cd61370acafb56184828560405161179f93929190612852565b60405180910390a15050601280547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055505050565b806117e3576117e3611e03565b6001600160a01b03841660009081526005602052604090205460ff16801561182457506001600160a01b03831660009081526005602052604090205460ff16155b1561183957611834848484611e34565b611937565b6001600160a01b03841660009081526005602052604090205460ff1615801561187a57506001600160a01b03831660009081526005602052604090205460ff165b1561188a57611834848484611f5b565b6001600160a01b03841660009081526005602052604090205460ff161580156118cc57506001600160a01b03831660009081526005602052604090205460ff16155b156118dc57611834848484612007565b6001600160a01b03841660009081526005602052604090205460ff16801561191c57506001600160a01b03831660009081526005602052604090205460ff165b1561192c5761183484848461204c565b611937848484612007565b80611944576119446120c1565b50505050565b6008546007546000918291825b600654811015611ad55782600160006006848154811061198757634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020541180611a0057508160026000600684815481106119d957634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054115b15611a175760085460075494509450505050611b04565b6001600060068381548110611a3c57634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054611a6b90846128cd565b92506002600060068381548110611a9257634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054611ac190836128cd565b915080611acd8161291f565b915050611957565b50600754600854611ae6919061288e565b821015611afe57600854600754935093505050611b04565b90925090505b9091565b600080600080611b17856120cf565b90506000611b24866120eb565b9050600081611b3384896128cd565b611b3d91906128cd565b979296509094509092505050565b6000808080611b5a85896128ae565b90506000611b6886896128ae565b90506000611b7687896128ae565b9050600081611b8584866128cd565b611b8f91906128cd565b939b939a50919850919650505050505050565b6040805160028082526060820183526000926020830190803683370190505090503081600081518110611be557634e487b7160e01b600052603260045260246000fd5b6001600160a01b03928316602091820292909201810191909152601154604080517f4ed1546000000000000000000000000000000000000000000000000000000000815290519190931692634ed15460926004808301939192829003018186803b158015611c5257600080fd5b505afa158015611c66573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c8a91906121e1565b81600181518110611cab57634e487b7160e01b600052603260045260246000fd5b6001600160a01b039283166020918202929092010152601154611cd191309116846113cc565b6011546040517fb43d9bbb0000000000000000000000000000000000000000000000000000000081526001600160a01b039091169063b43d9bbb90611d239085906000908690309042906004016127e2565b600060405180830381600087803b158015611d3d57600080fd5b505af1158015611617573d6000803e3d6000fd5b601154611d699030906001600160a01b0316846113cc565b6011546001600160a01b031663e6529ab4823085600080611d886110ed565b426040518863ffffffff1660e01b8152600401611daa96959493929190612358565b6060604051808303818588803b158015611dc357600080fd5b505af1158015611dd7573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190611dfc91906122fd565b5050505050565b600d54158015611e135750600f54155b15611e1d576110c7565b600d8054600e55600f805460105560009182905555565b600080600080600080611e4687611642565b6001600160a01b038f16600090815260026020526040902054959b50939950919750955093509150611e799088906128cd565b6001600160a01b038a16600090815260026020908152604080832093909355600190522054611ea99087906128cd565b6001600160a01b03808b1660009081526001602052604080822093909355908a1681522054611ed9908690612876565b6001600160a01b038916600090815260016020526040902055611efb816120fd565b611f058483612188565b876001600160a01b0316896001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef85604051611f4891906127d9565b60405180910390a3505050505050505050565b600080600080600080611f6d87611642565b6001600160a01b038f16600090815260016020526040902054959b50939950919750955093509150611fa09087906128cd565b6001600160a01b03808b16600090815260016020908152604080832094909455918b16815260029091522054611fd7908490612876565b6001600160a01b038916600090815260026020908152604080832093909355600190522054611ed9908690612876565b60008060008060008061201987611642565b6001600160a01b038f16600090815260016020526040902054959b50939950919750955093509150611ea99087906128cd565b60008060008060008061205e87611642565b6001600160a01b038f16600090815260026020526040902054959b509399509197509550935091506120919088906128cd565b6001600160a01b038a16600090815260026020908152604080832093909355600190522054611fa09087906128cd565b600e54600d55601054600f55565b60006064600d54836120e191906128ae565b610740919061288e565b60006064600f54836120e191906128ae565b600061210761161f565b9050600061211582846128ae565b30600090815260016020526040902054909150612133908290612876565b3060009081526001602090815260408083209390935560059052205460ff16156121835730600090815260026020526040902054612172908490612876565b306000908152600260205260409020555b505050565b8160085461219691906128cd565b6008556009546121a7908290612876565b6009555050565b8035801515811461080557600080fd5b6000602082840312156121cf578081fd5b81356121da81612950565b9392505050565b6000602082840312156121f2578081fd5b81516121da81612950565b6000806040838503121561220f578081fd5b823561221a81612950565b9150602083013561222a81612950565b809150509250929050565b600080600060608486031215612249578081fd5b833561225481612950565b9250602084013561226481612950565b929592945050506040919091013590565b60008060408385031215612287578182fd5b823561229281612950565b946020939093013593505050565b6000602082840312156122b1578081fd5b6121da826121ae565b6000602082840312156122cb578081fd5b5035919050565b600080604083850312156122e4578182fd5b823591506122f4602084016121ae565b90509250929050565b600080600060608486031215612311578283fd5b8351925060208401519150604084015190509250925092565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039687168152602081019590955260408501939093526060840191909152909216608082015260a081019190915260c00190565b901515815260200190565b6000602080835283518082850152825b818110156123ca578581018301518582016040015282016123ae565b818111156123db5783604083870101525b50601f01601f1916929092016040019392505050565b60208082526023908201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260408201527f6573730000000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252602a908201527f416d6f756e74206d757374206265206c657373207468616e20746f74616c207260408201527f65666c656374696f6e7300000000000000000000000000000000000000000000606082015260800190565b60208082526026908201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160408201527f6464726573730000000000000000000000000000000000000000000000000000606082015260800190565b60208082526022908201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560408201527f7373000000000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252601b908201527f4163636f756e7420697320616c7265616479206578636c756465640000000000604082015260600190565b6020808252601f908201527f416d6f756e74206d757374206265206c657373207468616e20737570706c7900604082015260600190565b60208082526028908201527f5472616e7366657220616d6f756e74206578636565647320746865206d61785460408201527f78416d6f756e742e000000000000000000000000000000000000000000000000606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526029908201527f5472616e7366657220616d6f756e74206d75737420626520677265617465722060408201527f7468616e207a65726f0000000000000000000000000000000000000000000000606082015260800190565b60208082526025908201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460408201527f6472657373000000000000000000000000000000000000000000000000000000606082015260800190565b60208082526024908201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460408201527f7265737300000000000000000000000000000000000000000000000000000000606082015260800190565b6020808252602c908201527f4578636c75646564206164647265737365732063616e6e6f742063616c6c207460408201527f6869732066756e6374696f6e0000000000000000000000000000000000000000606082015260800190565b90815260200190565b600060a082018783526020878185015260a0604085015281875180845260c0860191508289019350845b818110156128315784516001600160a01b03168352938301939183019160010161280c565b50506001600160a01b03969096166060850152505050608001529392505050565b9283526020830191909152604082015260600190565b60ff91909116815260200190565b600082198211156128895761288961293a565b500190565b6000826128a957634e487b7160e01b81526012600452602481fd5b500490565b60008160001904831182151516156128c8576128c861293a565b500290565b6000828210156128df576128df61293a565b500390565b6002810460018216806128f857607f821691505b6020821081141561291957634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156129335761293361293a565b5060010190565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b03811681146113b657600080fdfea26469706673582212207d8a1a36c715820a6902582a532254d78101cb3ac22dc9520249fa86bb087dff64736f6c63430008000033