Source Code
Overview
ETH Balance
0 ETH
ETH Value
$0.00
Cross-Chain Transactions
Loading...
Loading
Contract Name:
Otoken
Compiler Version
v0.6.10+commit.00c0fcaf
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
/* SPDX-License-Identifier: UNLICENSED */
pragma solidity =0.6.10;
import {ERC20Upgradeable} from "../packages/oz/upgradeability/ERC20Upgradeable.sol";
import {ERC20PermitUpgradeable} from "../packages/oz/upgradeability/erc20-permit/ERC20PermitUpgradeable.sol";
import {Strings} from "../packages/oz/Strings.sol";
import {BokkyPooBahsDateTimeLibrary} from "../packages/BokkyPooBahsDateTimeLibrary.sol";
import {AddressBookInterface} from "../interfaces/AddressBookInterface.sol";
/**
* @title Otoken
* @author Opyn Team
* @notice Otoken is the ERC20 token for an option
* @dev The Otoken inherits ERC20Upgradeable because we need to use the init instead of constructor
*/
contract Otoken is ERC20PermitUpgradeable {
/// @notice address of the Controller module
address public controller;
/// @notice asset that the option references
address public underlyingAsset;
/// @notice asset that the strike price is denominated in
address public strikeAsset;
/// @notice asset that is held as collateral against short/written options
address public collateralAsset;
/// @notice strike price with decimals = 8
uint256 public strikePrice;
/// @notice expiration timestamp of the option, represented as a unix timestamp
uint256 public expiryTimestamp;
/// @notice True if a put option, False if a call option
bool public isPut;
uint256 private constant STRIKE_PRICE_SCALE = 1e8;
uint256 private constant STRIKE_PRICE_DIGITS = 8;
/**
* @notice initialize the oToken
* @param _addressBook addressbook module
* @param _underlyingAsset asset that the option references
* @param _strikeAsset asset that the strike price is denominated in
* @param _collateralAsset asset that is held as collateral against short/written options
* @param _strikePrice strike price with decimals = 8
* @param _expiryTimestamp expiration timestamp of the option, represented as a unix timestamp
* @param _isPut True if a put option, False if a call option
*/
function init(
address _addressBook,
address _underlyingAsset,
address _strikeAsset,
address _collateralAsset,
uint256 _strikePrice,
uint256 _expiryTimestamp,
bool _isPut
) external initializer {
controller = AddressBookInterface(_addressBook).getController();
underlyingAsset = _underlyingAsset;
strikeAsset = _strikeAsset;
collateralAsset = _collateralAsset;
strikePrice = _strikePrice;
expiryTimestamp = _expiryTimestamp;
isPut = _isPut;
(string memory tokenName, string memory tokenSymbol) = _getNameAndSymbol();
__ERC20_init_unchained(tokenName, tokenSymbol);
__ERC20Permit_init(tokenName);
_setupDecimals(8);
}
function getOtokenDetails()
external
view
returns (
address,
address,
address,
uint256,
uint256,
bool
)
{
return (collateralAsset, underlyingAsset, strikeAsset, strikePrice, expiryTimestamp, isPut);
}
/**
* @notice mint oToken for an account
* @dev Controller only method where access control is taken care of by _beforeTokenTransfer hook
* @param account account to mint token to
* @param amount amount to mint
*/
function mintOtoken(address account, uint256 amount) external {
require(msg.sender == controller, "Otoken: Only Controller can mint Otokens");
_mint(account, amount);
}
/**
* @notice burn oToken from an account.
* @dev Controller only method where access control is taken care of by _beforeTokenTransfer hook
* @param account account to burn token from
* @param amount amount to burn
*/
function burnOtoken(address account, uint256 amount) external {
require(msg.sender == controller, "Otoken: Only Controller can burn Otokens");
_burn(account, amount);
}
/**
* @notice generates the name and symbol for an option
* @dev this function uses a named return variable to avoid the stack-too-deep error
* @return tokenName (ex: ETHUSDC 05-September-2020 200 Put USDC Collateral)
* @return tokenSymbol (ex: oETHUSDC-05SEP20-200P)
*/
function _getNameAndSymbol() internal view returns (string memory tokenName, string memory tokenSymbol) {
string memory underlying = ERC20Upgradeable(underlyingAsset).symbol();
string memory strike = ERC20Upgradeable(strikeAsset).symbol();
string memory collateral = ERC20Upgradeable(collateralAsset).symbol();
string memory displayStrikePrice = _getDisplayedStrikePrice(strikePrice);
// convert expiry to a readable string
(uint256 year, uint256 month, uint256 day) = BokkyPooBahsDateTimeLibrary.timestampToDate(expiryTimestamp);
// get option type string
(string memory typeSymbol, string memory typeFull) = _getOptionType(isPut);
//get option month string
(string memory monthSymbol, string memory monthFull) = _getMonth(month);
// concatenated name string: ETHUSDC 05-September-2020 200 Put USDC Collateral
tokenName = string(
abi.encodePacked(
underlying,
strike,
" ",
_uintTo2Chars(day),
"-",
monthFull,
"-",
Strings.toString(year),
" ",
displayStrikePrice,
typeFull,
" ",
collateral,
" Collateral"
)
);
// concatenated symbol string: oETHUSDC/USDC-05SEP20-200P
tokenSymbol = string(
abi.encodePacked(
"o",
underlying,
strike,
"/",
collateral,
"-",
_uintTo2Chars(day),
monthSymbol,
_uintTo2Chars(year),
"-",
displayStrikePrice,
typeSymbol
)
);
}
/**
* @dev convert strike price scaled by 1e8 to human readable number string
* @param _strikePrice strike price scaled by 1e8
* @return strike price string
*/
function _getDisplayedStrikePrice(uint256 _strikePrice) internal pure returns (string memory) {
uint256 remainder = _strikePrice.mod(STRIKE_PRICE_SCALE);
uint256 quotient = _strikePrice.div(STRIKE_PRICE_SCALE);
string memory quotientStr = Strings.toString(quotient);
if (remainder == 0) return quotientStr;
uint256 trailingZeroes;
while (remainder.mod(10) == 0) {
remainder = remainder / 10;
trailingZeroes += 1;
}
// pad the number with "1 + starting zeroes"
remainder += 10**(STRIKE_PRICE_DIGITS - trailingZeroes);
string memory tmpStr = Strings.toString(remainder);
tmpStr = _slice(tmpStr, 1, 1 + STRIKE_PRICE_DIGITS - trailingZeroes);
string memory completeStr = string(abi.encodePacked(quotientStr, ".", tmpStr));
return completeStr;
}
/**
* @dev return a representation of a number using 2 characters, adds a leading 0 if one digit, uses two trailing digits if a 3 digit number
* @return 2 characters that corresponds to a number
*/
function _uintTo2Chars(uint256 number) internal pure returns (string memory) {
if (number > 99) number = number % 100;
string memory str = Strings.toString(number);
if (number < 10) {
return string(abi.encodePacked("0", str));
}
return str;
}
/**
* @dev return string representation of option type
* @return shortString a 1 character representation of option type (P or C)
* @return longString a full length string of option type (Put or Call)
*/
function _getOptionType(bool _isPut) internal pure returns (string memory shortString, string memory longString) {
if (_isPut) {
return ("P", "Put");
} else {
return ("C", "Call");
}
}
/**
* @dev cut string s into s[start:end]
* @param _s the string to cut
* @param _start the starting index
* @param _end the ending index (excluded in the substring)
*/
function _slice(
string memory _s,
uint256 _start,
uint256 _end
) internal pure returns (string memory) {
bytes memory a = new bytes(_end - _start);
for (uint256 i = 0; i < _end - _start; i++) {
a[i] = bytes(_s)[_start + i];
}
return string(a);
}
/**
* @dev return string representation of a month
* @return shortString a 3 character representation of a month (ex: SEP, DEC, etc)
* @return longString a full length string of a month (ex: September, December, etc)
*/
function _getMonth(uint256 _month) internal pure returns (string memory shortString, string memory longString) {
if (_month == 1) {
return ("JAN", "January");
} else if (_month == 2) {
return ("FEB", "February");
} else if (_month == 3) {
return ("MAR", "March");
} else if (_month == 4) {
return ("APR", "April");
} else if (_month == 5) {
return ("MAY", "May");
} else if (_month == 6) {
return ("JUN", "June");
} else if (_month == 7) {
return ("JUL", "July");
} else if (_month == 8) {
return ("AUG", "August");
} else if (_month == 9) {
return ("SEP", "September");
} else if (_month == 10) {
return ("OCT", "October");
} else if (_month == 11) {
return ("NOV", "November");
} else {
return ("DEC", "December");
}
}
}// SPDX-License-Identifier: MIT
// solhint-disable
pragma solidity ^0.6.0;
// ----------------------------------------------------------------------------
// BokkyPooBah's DateTime Library v1.01
//
// A gas-efficient Solidity date and time library
//
// https://github.com/bokkypoobah/BokkyPooBahsDateTimeLibrary
//
// Tested date range 1970/01/01 to 2345/12/31
//
// Conventions:
// Unit | Range | Notes
// :-------- |:-------------:|:-----
// timestamp | >= 0 | Unix timestamp, number of seconds since 1970/01/01 00:00:00 UTC
// year | 1970 ... 2345 |
// month | 1 ... 12 |
// day | 1 ... 31 |
// hour | 0 ... 23 |
// minute | 0 ... 59 |
// second | 0 ... 59 |
// dayOfWeek | 1 ... 7 | 1 = Monday, ..., 7 = Sunday
//
//
// Enjoy. (c) BokkyPooBah / Bok Consulting Pty Ltd 2018-2019. The MIT Licence.
// ----------------------------------------------------------------------------
// version v1.01
library BokkyPooBahsDateTimeLibrary {
uint256 constant SECONDS_PER_DAY = 24 * 60 * 60;
int256 constant OFFSET19700101 = 2440588;
// ------------------------------------------------------------------------
// Calculate year/month/day from the number of days since 1970/01/01 using
// the date conversion algorithm from
// http://aa.usno.navy.mil/faq/docs/JD_Formula.php
// and adding the offset 2440588 so that 1970/01/01 is day 0
//
// int L = days + 68569 + offset
// int N = 4 * L / 146097
// L = L - (146097 * N + 3) / 4
// year = 4000 * (L + 1) / 1461001
// L = L - 1461 * year / 4 + 31
// month = 80 * L / 2447
// dd = L - 2447 * month / 80
// L = month / 11
// month = month + 2 - 12 * L
// year = 100 * (N - 49) + year + L
// ------------------------------------------------------------------------
function _daysToDate(uint256 _days)
internal
pure
returns (
uint256 year,
uint256 month,
uint256 day
)
{
int256 __days = int256(_days);
int256 L = __days + 68569 + OFFSET19700101;
int256 N = (4 * L) / 146097;
L = L - (146097 * N + 3) / 4;
int256 _year = (4000 * (L + 1)) / 1461001;
L = L - (1461 * _year) / 4 + 31;
int256 _month = (80 * L) / 2447;
int256 _day = L - (2447 * _month) / 80;
L = _month / 11;
_month = _month + 2 - 12 * L;
_year = 100 * (N - 49) + _year + L;
year = uint256(_year);
month = uint256(_month);
day = uint256(_day);
}
function timestampToDate(uint256 timestamp)
internal
pure
returns (
uint256 year,
uint256 month,
uint256 day
)
{
(year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY);
}
}// SPDX-License-Identifier: UNLICENSED
pragma solidity 0.6.10;
interface AddressBookInterface {
/* Getters */
function getOtokenImpl() external view returns (address);
function getOtokenFactory() external view returns (address);
function getWhitelist() external view returns (address);
function getController() external view returns (address);
function getOracle() external view returns (address);
function getMarginPool() external view returns (address);
function getMarginCalculator() external view returns (address);
function getLiquidationManager() external view returns (address);
function getAddress(bytes32 _id) external view returns (address);
/* Setters */
function setOtokenImpl(address _otokenImpl) external;
function setOtokenFactory(address _factory) external;
function setOracleImpl(address _otokenImpl) external;
function setWhitelist(address _whitelist) external;
function setController(address _controller) external;
function setMarginPool(address _marginPool) external;
function setMarginCalculator(address _calculator) external;
function setLiquidationManager(address _liquidationManager) external;
function setAddress(bytes32 _id, address _newImpl) external;
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
import "./GSN/ContextUpgradeable.sol";
import "./IERC20Upgradeable.sol";
import "./math/SafeMathUpgradeable.sol";
import "./Initializable.sol";
/**
* @dev Implementation of the {IERC20} interface.
*
* This implementation is agnostic to the way tokens are created. This means
* that a supply mechanism has to be added in a derived contract using {_mint}.
* For a generic mechanism see {ERC20PresetMinterPauser}.
*
* TIP: For a detailed writeup see our guide
* https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
* to implement supply mechanisms].
*
* We have followed general OpenZeppelin guidelines: functions revert instead
* of 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 ERC20Upgradeable is Initializable, ContextUpgradeable, IERC20Upgradeable {
using SafeMathUpgradeable for uint256;
mapping(address => uint256) private _balances;
mapping(address => mapping(address => uint256)) private _allowances;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
/**
* @dev Sets the values for {name} and {symbol}, initializes {decimals} with
* a default value of 18.
*
* To select a different value for {decimals}, use {_setupDecimals}.
*
* All three of these values are immutable: they can only be set once during
* construction.
*/
function __ERC20_init(string memory name_, string memory symbol_) internal initializer {
__Context_init_unchained();
__ERC20_init_unchained(name_, symbol_);
}
function __ERC20_init_unchained(string memory name_, string memory symbol_) internal initializer {
_name = name_;
_symbol = symbol_;
_decimals = 18;
}
/**
* @dev Returns the name of the token.
*/
function name() public view returns (string memory) {
return _name;
}
/**
* @dev Returns the symbol of the token, usually a shorter version of the
* name.
*/
function symbol() public view 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 {_setupDecimals} is
* called.
*
* 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 returns (uint8) {
return _decimals;
}
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSupply() public view override returns (uint256) {
return _totalSupply;
}
/**
* @dev See {IERC20-balanceOf}.
*/
function balanceOf(address account) public view 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);
_approve(
sender,
_msgSender(),
_allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance")
);
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].add(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) {
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero")
);
return true;
}
/**
* @dev Moves tokens `amount` from `sender` to `recipient`.
*
* This is 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);
_balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exceeds balance");
_balances[recipient] = _balances[recipient].add(amount);
emit Transfer(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:
*
* - `to` 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 = _totalSupply.add(amount);
_balances[account] = _balances[account].add(amount);
emit Transfer(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);
_balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance");
_totalSupply = _totalSupply.sub(amount);
emit Transfer(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 Sets {decimals} to a value other than the default one of 18.
*
* WARNING: This function should only be called from the constructor. Most
* applications that interact with token contracts will not expect
* {decimals} to ever change, and may work incorrectly if it does.
*/
function _setupDecimals(uint8 decimals_) internal {
_decimals = decimals_;
}
/**
* @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 to 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 {}
uint256[44] private __gap;
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts v3.1.0
/* solhint-disable */
pragma solidity =0.6.10;
/**
* @dev String operations.
*/
library Strings {
/**
* @dev Converts a `uint256` to its ASCII `string` representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
// Inspired by OraclizeAPI's implementation - MIT licence
// https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol
if (value == 0) {
return "0";
}
uint256 temp = value;
uint256 digits;
while (temp != 0) {
digits++;
temp /= 10;
}
bytes memory buffer = new bytes(digits);
uint256 index = digits - 1;
temp = value;
while (temp != 0) {
buffer[index--] = bytes1(uint8(48 + (temp % 10)));
temp /= 10;
}
return string(buffer);
}
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.5 <0.8.0;
import "../ERC20Upgradeable.sol";
import "./IERC20PermitUpgradeable.sol";
import "../cryptography/ECDSAUpgradeable.sol";
import "../utils/CountersUpgradeable.sol";
import "./EIP712Upgradeable.sol";
import "../Initializable.sol";
/**
* @dev Implementation of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
* https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
*
* Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
* presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't
* need to send a transaction, and thus is not required to hold Ether at all.
*/
abstract contract ERC20PermitUpgradeable is
Initializable,
ERC20Upgradeable,
IERC20PermitUpgradeable,
EIP712Upgradeable
{
using CountersUpgradeable for CountersUpgradeable.Counter;
mapping(address => CountersUpgradeable.Counter) private _nonces;
// solhint-disable-next-line var-name-mixedcase
bytes32 private _PERMIT_TYPEHASH;
/**
* @dev Initializes the {EIP712} domain separator using the `name` parameter, and setting `version` to `"1"`.
*
* It's a good idea to use the same `name` that is defined as the ERC20 token name.
*/
function __ERC20Permit_init(string memory name) internal initializer {
__Context_init_unchained();
__EIP712_init_unchained(name, "1");
__ERC20Permit_init_unchained(name);
}
function __ERC20Permit_init_unchained(string memory name) internal initializer {
_PERMIT_TYPEHASH = keccak256(
"Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"
);
}
/**
* @dev See {IERC20Permit-permit}.
*/
function permit(
address owner,
address spender,
uint256 amount,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) public virtual override {
// solhint-disable-next-line not-rely-on-time
require(block.timestamp <= deadline, "ERC20Permit: expired deadline");
bytes32 structHash = keccak256(
abi.encode(_PERMIT_TYPEHASH, owner, spender, amount, _nonces[owner].current(), deadline)
);
bytes32 hash = _hashTypedDataV4(structHash);
address signer = ECDSAUpgradeable.recover(hash, v, r, s);
require(signer == owner, "ERC20Permit: invalid signature");
_nonces[owner].increment();
_approve(owner, spender, amount);
}
/**
* @dev See {IERC20Permit-nonces}.
*/
function nonces(address owner) public view override returns (uint256) {
return _nonces[owner].current();
}
/**
* @dev See {IERC20Permit-DOMAIN_SEPARATOR}.
*/
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view override returns (bytes32) {
return _domainSeparatorV4();
}
uint256[49] private __gap;
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
/**
* @dev Interface of the ERC20 standard as defined in the EIP.
*/
interface IERC20Upgradeable {
/**
* @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);
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
/* solhint-disable */
pragma solidity >=0.4.24 <0.7.0;
/**
* @title Initializable
*
* @dev Helper contract to support initializer functions. To use it, replace
* the constructor with a function that has the `initializer` modifier.
* WARNING: Unlike constructors, initializer functions must be manually
* invoked. This applies both to deploying an Initializable contract, as well
* as extending an Initializable contract via inheritance.
* WARNING: When used with inheritance, manual care must be taken to not invoke
* a parent initializer twice, or ensure that all initializers are idempotent,
* because this is not dealt with automatically as with constructors.
*/
contract Initializable {
/**
* @dev Indicates that the contract has been initialized.
*/
bool private initialized;
/**
* @dev Indicates that the contract is in the process of being initialized.
*/
bool private initializing;
/**
* @dev Modifier to use in the initializer function of a contract.
*/
modifier initializer() {
require(initializing || isConstructor() || !initialized, "Contract instance has already been initialized");
bool isTopLevelCall = !initializing;
if (isTopLevelCall) {
initializing = true;
initialized = true;
}
_;
if (isTopLevelCall) {
initializing = false;
}
}
/// @dev Returns true if and only if the function is running in the constructor
function isConstructor() private view returns (bool) {
// extcodesize checks the size of the code stored in an address, and
// address returns the current address. Since the code is still not
// deployed when running a constructor, any checks on its code size will
// yield zero, making it an effective way to detect if a contract is
// under construction or not.
address self = address(this);
uint256 cs;
assembly {
cs := extcodesize(self)
}
return cs == 0;
}
// Reserved storage space to allow for layout changes in the future.
uint256[50] private ______gap;
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
import "../Initializable.sol";
/*
* @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 GSN 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 ContextUpgradeable is Initializable {
function __Context_init() internal initializer {
__Context_init_unchained();
}
function __Context_init_unchained() internal initializer {}
function _msgSender() internal view virtual returns (address payable) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes memory) {
this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
return msg.data;
}
uint256[50] private __gap;
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
/**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming languages.
* `SafeMath` restores this intuition by reverting the transaction when an
* operation overflows.
*
* Using this library instead of the unchecked operations eliminates an entire
* class of bugs, so it's recommended to use it always.
*/
library SafeMathUpgradeable {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a + b;
require(c >= a, "SafeMath: addition overflow");
return c;
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(uint256 a, uint256 b) internal pure returns (uint256) {
return sub(a, b, "SafeMath: subtraction overflow");
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting with custom message on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(
uint256 a,
uint256 b,
string memory errorMessage
) internal pure returns (uint256) {
require(b <= a, errorMessage);
uint256 c = a - b;
return c;
}
/**
* @dev Returns the multiplication of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `*` operator.
*
* Requirements:
*
* - Multiplication cannot overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
// Gas optimization: this is cheaper than requiring 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
// See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b, "SafeMath: multiplication overflow");
return c;
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator. Note: this function uses a
* `revert` opcode (which leaves remaining gas untouched) while Solidity
* uses an invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function div(uint256 a, uint256 b) internal pure returns (uint256) {
return div(a, b, "SafeMath: division by zero");
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts with custom message on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator. Note: this function uses a
* `revert` opcode (which leaves remaining gas untouched) while Solidity
* uses an invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function div(
uint256 a,
uint256 b,
string memory errorMessage
) internal pure returns (uint256) {
require(b > 0, errorMessage);
uint256 c = a / b;
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
return c;
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts when dividing by zero.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function mod(uint256 a, uint256 b) internal pure returns (uint256) {
return mod(a, b, "SafeMath: modulo by zero");
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts with custom message when dividing by zero.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function mod(
uint256 a,
uint256 b,
string memory errorMessage
) internal pure returns (uint256) {
require(b != 0, errorMessage);
return a % b;
}
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
/**
* @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
* https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
*
* Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
* presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't
* need to send a transaction, and thus is not required to hold Ether at all.
*/
interface IERC20PermitUpgradeable {
/**
* @dev Sets `amount` as the allowance of `spender` over `owner`'s tokens,
* given `owner`'s signed approval.
*
* IMPORTANT: The same issues {IERC20-approve} has related to transaction
* ordering also apply here.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - `spender` cannot be the zero address.
* - `deadline` must be a timestamp in the future.
* - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
* over the EIP712-formatted function arguments.
* - the signature must use ``owner``'s current nonce (see {nonces}).
*
* For more information on the signature format, see the
* https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
* section].
*/
function permit(
address owner,
address spender,
uint256 amount,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) external;
/**
* @dev Returns the current nonce for `owner`. This value must be
* included whenever a signature is generated for {permit}.
*
* Every successful call to {permit} increases ``owner``'s nonce by one. This
* prevents a signature from being used multiple times.
*/
function nonces(address owner) external view returns (uint256);
/**
* @dev Returns the domain separator used in the encoding of the signature for `permit`, as defined by {EIP712}.
*/
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view returns (bytes32);
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
import "../math/SafeMathUpgradeable.sol";
/**
* @title Counters
* @author Matt Condon (@shrugs)
* @dev Provides counters that can only be incremented or decremented by one. This can be used e.g. to track the number
* of elements in a mapping, issuing ERC721 ids, or counting request ids.
*
* Include with `using Counters for Counters.Counter;`
* Since it is not possible to overflow a 256 bit integer with increments of one, `increment` can skip the {SafeMath}
* overflow check, thereby saving gas. This does assume however correct usage, in that the underlying `_value` is never
* directly accessed.
*/
library CountersUpgradeable {
using SafeMathUpgradeable for uint256;
struct Counter {
// This variable should never be directly accessed by users of the library: interactions must be restricted to
// the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add
// this feature: see https://github.com/ethereum/solidity/issues/4637
uint256 _value; // default: 0
}
function current(Counter storage counter) internal view returns (uint256) {
return counter._value;
}
function increment(Counter storage counter) internal {
// The {SafeMath} overflow check can be skipped here, see the comment at the top
counter._value += 1;
}
function decrement(Counter storage counter) internal {
counter._value = counter._value.sub(1);
}
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
import "../Initializable.sol";
/**
* @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.
*
* The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible,
* thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding
* they need in their contracts using a combination of `abi.encode` and `keccak256`.
*
* This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding
* scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA
* ({_hashTypedDataV4}).
*
* The implementation of the domain separator was designed to be as efficient as possible while still properly updating
* the chain id to protect against replay attacks on an eventual fork of the chain.
*
* NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method
* https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].
*/
abstract contract EIP712Upgradeable is Initializable {
/* solhint-disable var-name-mixedcase */
bytes32 private _HASHED_NAME;
bytes32 private _HASHED_VERSION;
bytes32 private constant _TYPE_HASH =
keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)");
/* solhint-enable var-name-mixedcase */
/**
* @dev Initializes the domain separator and parameter caches.
*
* The meaning of `name` and `version` is specified in
* https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]:
*
* - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol.
* - `version`: the current major version of the signing domain.
*
* NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart
* contract upgrade].
*/
function __EIP712_init(string memory name, string memory version) internal initializer {
__EIP712_init_unchained(name, version);
}
function __EIP712_init_unchained(string memory name, string memory version) internal initializer {
bytes32 hashedName = keccak256(bytes(name));
bytes32 hashedVersion = keccak256(bytes(version));
_HASHED_NAME = hashedName;
_HASHED_VERSION = hashedVersion;
}
/**
* @dev Returns the domain separator for the current chain.
*/
function _domainSeparatorV4() internal view returns (bytes32) {
return _buildDomainSeparator(_TYPE_HASH, _EIP712NameHash(), _EIP712VersionHash());
}
function _buildDomainSeparator(
bytes32 typeHash,
bytes32 name,
bytes32 version
) private view returns (bytes32) {
return keccak256(abi.encode(typeHash, name, version, _getChainId(), address(this)));
}
/**
* @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this
* function returns the hash of the fully encoded EIP712 message for this domain.
*
* This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example:
*
* ```solidity
* bytes32 digest = _hashTypedDataV4(keccak256(abi.encode(
* keccak256("Mail(address to,string contents)"),
* mailTo,
* keccak256(bytes(mailContents))
* )));
* address signer = ECDSA.recover(digest, signature);
* ```
*/
function _hashTypedDataV4(bytes32 structHash) internal view returns (bytes32) {
return keccak256(abi.encodePacked("\x19\x01", _domainSeparatorV4(), structHash));
}
function _getChainId() private view returns (uint256 chainId) {
this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
// solhint-disable-next-line no-inline-assembly
assembly {
chainId := chainid()
}
}
/**
* @dev The hash of the name parameter for the EIP712 domain.
*
* NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs
* are a concern.
*/
function _EIP712NameHash() internal view virtual returns (bytes32) {
return _HASHED_NAME;
}
/**
* @dev The hash of the version parameter for the EIP712 domain.
*
* NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs
* are a concern.
*/
function _EIP712VersionHash() internal view virtual returns (bytes32) {
return _HASHED_VERSION;
}
uint256[50] private __gap;
}// SPDX-License-Identifier: MIT
// openzeppelin-contracts-upgradeable v3.0.0
pragma solidity >=0.6.0 <0.8.0;
/**
* @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.
*
* These functions can be used to verify that a message was signed by the holder
* of the private keys of a given address.
*/
library ECDSAUpgradeable {
/**
* @dev Returns the address that signed a hashed message (`hash`) with
* `signature`. This address can then be used for verification purposes.
*
* The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:
* this function rejects them by requiring the `s` value to be in the lower
* half order, and the `v` value to be either 27 or 28.
*
* IMPORTANT: `hash` _must_ be the result of a hash operation for the
* verification to be secure: it is possible to craft signatures that
* recover to arbitrary addresses for non-hashed data. A safe way to ensure
* this is by receiving a hash of the original message (which may otherwise
* be too long), and then calling {toEthSignedMessageHash} on it.
*/
function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {
// Check the signature length
if (signature.length != 65) {
revert("ECDSA: invalid signature length");
}
// Divide the signature in r, s and v variables
bytes32 r;
bytes32 s;
uint8 v;
// ecrecover takes the signature parameters, and the only way to get them
// currently is to use assembly.
// solhint-disable-next-line no-inline-assembly
assembly {
r := mload(add(signature, 0x20))
s := mload(add(signature, 0x40))
v := byte(0, mload(add(signature, 0x60)))
}
return recover(hash, v, r, s);
}
/**
* @dev Overload of {ECDSA-recover-bytes32-bytes-} that receives the `v`,
* `r` and `s` signature fields separately.
*/
function recover(
bytes32 hash,
uint8 v,
bytes32 r,
bytes32 s
) internal pure returns (address) {
// EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature
// unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines
// the valid range for s in (281): 0 < s < secp256k1n ÷ 2 + 1, and for v in (282): v ∈ {27, 28}. Most
// signatures from current libraries generate a unique signature with an s-value in the lower half order.
//
// If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value
// with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or
// vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept
// these malleable signatures as well.
require(
uint256(s) <= 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0,
"ECDSA: invalid signature 's' value"
);
require(v == 27 || v == 28, "ECDSA: invalid signature 'v' value");
// If the signature is valid (and not malleable), return the signer address
address signer = ecrecover(hash, v, r, s);
require(signer != address(0), "ECDSA: invalid signature");
return signer;
}
/**
* @dev Returns an Ethereum Signed Message, created from a `hash`. This
* replicates the behavior of the
* https://github.com/ethereum/wiki/wiki/JSON-RPC#eth_sign[`eth_sign`]
* JSON-RPC method.
*
* See {recover}.
*/
function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {
// 32 is the length in bytes of hash,
// enforced by the type signature above
return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash));
}
}{
"optimizer": {
"enabled": true,
"runs": 200
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"metadata": {
"useLiteralContent": true
},
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burnOtoken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"collateralAsset","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"controller","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"expiryTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getOtokenDetails","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_addressBook","type":"address"},{"internalType":"address","name":"_underlyingAsset","type":"address"},{"internalType":"address","name":"_strikeAsset","type":"address"},{"internalType":"address","name":"_collateralAsset","type":"address"},{"internalType":"uint256","name":"_strikePrice","type":"uint256"},{"internalType":"uint256","name":"_expiryTimestamp","type":"uint256"},{"internalType":"bool","name":"_isPut","type":"bool"}],"name":"init","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isPut","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mintOtoken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"nonces","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"permit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"strikeAsset","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"strikePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"underlyingAsset","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]Contract Creation Code
608060405234801561001057600080fd5b50612f89806100206000396000f3fe608060405234801561001057600080fd5b50600436106101735760003560e01c80637ecebe00116100de578063af0968fc11610097578063dd62ed3e11610071578063dd62ed3e146104bc578063f3c274a6146104ea578063f630df34146104f2578063f77c47911461054657610173565b8063af0968fc14610419578063c52987cf14610463578063d505accf1461046b57610173565b80637ecebe001461038357806395d89b41146103a9578063a457c2d7146103b1578063a9059cbb146103dd578063aabaecd614610409578063ade6e2aa1461041157610173565b80633644e515116101305780633644e515146102c757806339509351146102cf57806351b0a410146102fb57806356d878f71461032957806370a08231146103555780637158da7c1461037b57610173565b806306fdde0314610178578063095ea7b3146101f557806317d69bc81461023557806318160ddd1461025957806323b872dd14610273578063313ce567146102a9575b600080fd5b61018061054e565b6040805160208082528351818301528351919283929083019185019080838360005b838110156101ba5781810151838201526020016101a2565b50505050905090810190601f1680156101e75780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6102216004803603604081101561020b57600080fd5b506001600160a01b0381351690602001356105e5565b604080519115158252519081900360200190f35b61023d610602565b604080516001600160a01b039092168252519081900360200190f35b610261610612565b60408051918252519081900360200190f35b6102216004803603606081101561028957600080fd5b506001600160a01b03813581169160208101359091169060400135610618565b6102b16106a5565b6040805160ff9092168252519081900360200190f35b6102616106ae565b610221600480360360408110156102e557600080fd5b506001600160a01b0381351690602001356106bd565b6103276004803603604081101561031157600080fd5b506001600160a01b038135169060200135610711565b005b6103276004803603604081101561033f57600080fd5b506001600160a01b038135169060200135610768565b6102616004803603602081101561036b57600080fd5b50356001600160a01b03166107bb565b61023d6107da565b6102616004803603602081101561039957600080fd5b50356001600160a01b03166107e9565b610180610810565b610221600480360360408110156103c757600080fd5b506001600160a01b038135169060200135610871565b610221600480360360408110156103f357600080fd5b506001600160a01b0381351690602001356108df565b61023d6108f3565b610261610903565b61042161090a565b604080516001600160a01b039788168152958716602087015293909516848401526060840191909152608083015291151560a082015290519081900360c00190f35b610261610940565b610327600480360360e081101561048157600080fd5b506001600160a01b03813581169160208101359091169060408101359060608101359060ff6080820135169060a08101359060c00135610947565b610261600480360360408110156104d257600080fd5b506001600160a01b0381358116916020013516610adf565b610221610b0a565b610327600480360360e081101561050857600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359091169060808101359060a08101359060c001351515610b14565b61023d610cb4565b60688054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156105da5780601f106105af576101008083540402835291602001916105da565b820191906000526020600020905b8154815290600101906020018083116105bd57829003601f168201915b505050505090505b90565b60006105f96105f2610cc3565b8484610cc7565b50600192915050565b610100546001600160a01b031681565b60675490565b6000610625848484610db3565b61069b84610631610cc3565b61069685604051806060016040528060288152602001612e6f602891396001600160a01b038a1660009081526066602052604081209061066f610cc3565b6001600160a01b03168152602081019190915260400160002054919063ffffffff610f1c16565b610cc7565b5060019392505050565b606a5460ff1690565b60006106b8610fb3565b905090565b60006105f96106ca610cc3565b8461069685606660006106db610cc3565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549063ffffffff610fe616565b60fe546001600160a01b0316331461075a5760405162461bcd60e51b8152600401808060200182810382526028815260200180612df56028913960400191505060405180910390fd5b6107648282611047565b5050565b60fe546001600160a01b031633146107b15760405162461bcd60e51b8152600401808060200182810382526028815260200180612d596028913960400191505060405180910390fd5b6107648282611145565b6001600160a01b0381166000908152606560205260409020545b919050565b60ff546001600160a01b031681565b6001600160a01b038116600090815260cb6020526040812061080a9061124d565b92915050565b60698054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156105da5780601f106105af576101008083540402835291602001916105da565b60006105f961087e610cc3565b8461069685604051806060016040528060258152602001612f2f60259139606660006108a8610cc3565b6001600160a01b03908116825260208083019390935260409182016000908120918d1681529252902054919063ffffffff610f1c16565b60006105f96108ec610cc3565b8484610db3565b610101546001600160a01b031681565b6101035481565b6101015460ff8054610100546101025461010354610104546001600160a01b039687169794871696909316949193909290911690565b6101025481565b8342111561099c576040805162461bcd60e51b815260206004820152601d60248201527f45524332305065726d69743a206578706972656420646561646c696e65000000604482015290519081900360640190fd5b600060cc548888886109d160cb60008e6001600160a01b03166001600160a01b0316815260200190815260200160002061124d565b604080516020808201979097526001600160a01b0395861681830152939094166060840152608083019190915260a082015260c08082018990528251808303909101815260e0909101909152805191012090506000610a2f82611251565b90506000610a3f8287878761129d565b9050896001600160a01b0316816001600160a01b031614610aa7576040805162461bcd60e51b815260206004820152601e60248201527f45524332305065726d69743a20696e76616c6964207369676e61747572650000604482015290519081900360640190fd5b6001600160a01b038a16600090815260cb60205260409020610ac890611417565b610ad38a8a8a610cc7565b50505050505050505050565b6001600160a01b03918216600090815260666020908152604080832093909416825291909152205490565b6101045460ff1681565b600054610100900460ff1680610b2d5750610b2d611420565b80610b3b575060005460ff16155b610b765760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015610ba1576000805460ff1961ff0019909116610100171660011790555b876001600160a01b0316633018205f6040518163ffffffff1660e01b815260040160206040518083038186803b158015610bda57600080fd5b505afa158015610bee573d6000803e3d6000fd5b505050506040513d6020811015610c0457600080fd5b505160fe80546001600160a01b03199081166001600160a01b039384161790915560ff805482168a8416179055610100805482168984161790556101018054909116918716919091179055610102849055610103839055610104805460ff1916831515179055606080610c75611426565b91509150610c838282611dd9565b610c8c82611eb2565b610c966008611f88565b50508015610caa576000805461ff00191690555b5050505050505050565b60fe546001600160a01b031681565b3390565b6001600160a01b038316610d0c5760405162461bcd60e51b8152600401808060200182810382526024815260200180612f0b6024913960400191505060405180910390fd5b6001600160a01b038216610d515760405162461bcd60e51b8152600401808060200182810382526022815260200180612cef6022913960400191505060405180910390fd5b6001600160a01b03808416600081815260666020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b6001600160a01b038316610df85760405162461bcd60e51b8152600401808060200182810382526025815260200180612ee66025913960400191505060405180910390fd5b6001600160a01b038216610e3d5760405162461bcd60e51b8152600401808060200182810382526023815260200180612caa6023913960400191505060405180910390fd5b610e48838383611ead565b610e8b81604051806060016040528060268152602001612d11602691396001600160a01b038616600090815260656020526040902054919063ffffffff610f1c16565b6001600160a01b038085166000908152606560205260408082209390935590841681522054610ec0908263ffffffff610fe616565b6001600160a01b0380841660008181526065602090815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b60008184841115610fab5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f70578181015183820152602001610f58565b50505050905090810190601f168015610f9d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b60006106b86040518080612e1d6052913960520190506040518091039020610fd9611f9e565b610fe1611fa4565b611faa565b600082820183811015611040576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b6001600160a01b0382166110a2576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b6110ae60008383611ead565b6067546110c1908263ffffffff610fe616565b6067556001600160a01b0382166000908152606560205260409020546110ed908263ffffffff610fe616565b6001600160a01b03831660008181526065602090815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b6001600160a01b03821661118a5760405162461bcd60e51b8152600401808060200182810382526021815260200180612ec56021913960400191505060405180910390fd5b61119682600083611ead565b6111d981604051806060016040528060228152602001612ccd602291396001600160a01b038516600090815260656020526040902054919063ffffffff610f1c16565b6001600160a01b038316600090815260656020526040902055606754611205908263ffffffff61200016565b6067556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b5490565b600061125b610fb3565b82604051602001808061190160f01b81525060020183815260200182815260200192505050604051602081830303815290604052805190602001209050919050565b60007f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08211156112fe5760405162461bcd60e51b8152600401808060200182810382526022815260200180612d376022913960400191505060405180910390fd5b8360ff16601b148061131357508360ff16601c145b61134e5760405162461bcd60e51b8152600401808060200182810382526022815260200180612dd36022913960400191505060405180910390fd5b604080516000808252602080830180855289905260ff88168385015260608301879052608083018690529251909260019260a080820193601f1981019281900390910190855afa1580156113a6573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b03811661140e576040805162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e61747572650000000000000000604482015290519081900360640190fd5b95945050505050565b80546001019055565b303b1590565b606080606060ff60009054906101000a90046001600160a01b03166001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b15801561147957600080fd5b505afa15801561148d573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156114b657600080fd5b81019080805160405193929190846401000000008211156114d657600080fd5b9083019060208201858111156114eb57600080fd5b825164010000000081118282018810171561150557600080fd5b82525081516020918201929091019080838360005b8381101561153257818101518382015260200161151a565b50505050905090810190601f16801561155f5780820380516001836020036101000a031916815260200191505b506040818152610100546395d89b4160e01b835290519596506060956001600160a01b0390911694506395d89b41935060048083019350600092829003018186803b1580156115ad57600080fd5b505afa1580156115c1573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156115ea57600080fd5b810190808051604051939291908464010000000082111561160a57600080fd5b90830190602082018581111561161f57600080fd5b825164010000000081118282018810171561163957600080fd5b82525081516020918201929091019080838360005b8381101561166657818101518382015260200161164e565b50505050905090810190601f1680156116935780820380516001836020036101000a031916815260200191505b506040818152610101546395d89b4160e01b835290519596506060956001600160a01b0390911694506395d89b41935060048083019350600092829003018186803b1580156116e157600080fd5b505afa1580156116f5573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052602081101561171e57600080fd5b810190808051604051939291908464010000000082111561173e57600080fd5b90830190602082018581111561175357600080fd5b825164010000000081118282018810171561176d57600080fd5b82525081516020918201929091019080838360005b8381101561179a578181015183820152602001611782565b50505050905090810190601f1680156117c75780820380516001836020036101000a031916815260200191505b50604052505050905060606117de61010254612042565b905060008060006117f1610103546121b4565b610104549295509093509150606090819061180e9060ff166121d3565b9150915060608061181e8661225c565b915091508a8a61182d876125f4565b836118378b612697565b8c888f6040516020018089805190602001908083835b6020831061186c5780518252601f19909201916020918201910161184d565b51815160209384036101000a60001901801990921691161790528b5191909301928b0191508083835b602083106118b45780518252601f199092019160209182019101611895565b6001836020036101000a03801982511681845116808217855250505050505090500180600160fd1b81525060010187805190602001908083835b6020831061190d5780518252601f1990920191602091820191016118ee565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010186805190602001908083835b602083106119665780518252601f199092019160209182019101611947565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010185805190602001908083835b602083106119bf5780518252601f1990920191602091820191016119a0565b6001836020036101000a03801982511681845116808217855250505050505090500180600160fd1b81525060010184805190602001908083835b60208310611a185780518252601f1990920191602091820191016119f9565b51815160209384036101000a600019018019909216911617905286519190930192860191508083835b60208310611a605780518252601f199092019160209182019101611a41565b6001836020036101000a03801982511681845116808217855250505050505090500180600160fd1b81525060010182805190602001908083835b60208310611ab95780518252601f199092019160209182019101611a9a565b6001836020036101000a038019825116818451168082178552505050505050905001806a0810dbdb1b185d195c985b60aa1b815250600b01985050505050505050506040516020818303038152906040529c508a8a8a611b18886125f4565b85611b228c6125f4565b8d8a6040516020018080606f60f81b81525060010189805190602001908083835b60208310611b625780518252601f199092019160209182019101611b43565b51815160209384036101000a60001901801990921691161790528b5191909301928b0191508083835b60208310611baa5780518252601f199092019160209182019101611b8b565b6001836020036101000a03801982511681845116808217855250505050505090500180602f60f81b81525060010187805190602001908083835b60208310611c035780518252601f199092019160209182019101611be4565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010186805190602001908083835b60208310611c5c5780518252601f199092019160209182019101611c3d565b51815160209384036101000a600019018019909216911617905288519190930192880191508083835b60208310611ca45780518252601f199092019160209182019101611c85565b51815160209384036101000a600019018019909216911617905287519190930192870191508083835b60208310611cec5780518252601f199092019160209182019101611ccd565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010183805190602001908083835b60208310611d455780518252601f199092019160209182019101611d26565b51815160209384036101000a600019018019909216911617905285519190930192850191508083835b60208310611d8d5780518252601f199092019160209182019101611d6e565b6001836020036101000a038019825116818451168082178552505050505050905001985050505050505050506040516020818303038152906040529b5050505050505050505050509091565b600054610100900460ff1680611df25750611df2611420565b80611e00575060005460ff16155b611e3b5760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015611e66576000805460ff1961ff0019909116610100171660011790555b8251611e79906068906020860190612c11565b508151611e8d906069906020850190612c11565b50606a805460ff191660121790558015611ead576000805461ff00191690555b505050565b600054610100900460ff1680611ecb5750611ecb611420565b80611ed9575060005460ff16155b611f145760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015611f3f576000805460ff1961ff0019909116610100171660011790555b611f47612772565b611f6a82604051806040016040528060018152602001603160f81b815250612814565b611f73826128d4565b8015610764576000805461ff00191690555050565b606a805460ff191660ff92909216919091179055565b60975490565b60985490565b6000838383611fb7612991565b6040805160208082019690965280820194909452606084019290925260808301523060a0808401919091528151808403909101815260c090920190528051910120949350505050565b600061104083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610f1c565b6060600061205a836305f5e10063ffffffff61299516565b90506000612072846305f5e10063ffffffff6129d716565b9050606061207f82612697565b9050826120905792506107d5915050565b60005b6120a484600a63ffffffff61299516565b6120b657600a84049350600101612093565b80600803600a0a8401935060606120cc85612697565b90506120de8160016009859003612a19565b9050606083826040516020018083805190602001908083835b602083106121165780518252601f1990920191602091820191016120f7565b6001836020036101000a03801982511681845116808217855250505050505090500180601760f91b81525060010182805190602001908083835b6020831061216f5780518252601f199092019160209182019101612150565b6001836020036101000a038019825116818451168082178552505050505050905001925050506040516020818303038152906040529050809650505050505050919050565b600080806121c6620151808504612ab4565b9196909550909350915050565b606080821561221b57604051806040016040528060018152602001600560fc1b81525060405180604001604052806003815260200162141d5d60ea1b81525091509150612257565b604051806040016040528060018152602001604360f81b8152506040518060400160405280600481526020016310d85b1b60e21b815250915091505b915091565b60608082600114156122ad57604051806040016040528060038152602001622520a760e91b815250604051806040016040528060078152602001664a616e7561727960c81b81525091509150612257565b82600214156122fc57604051806040016040528060038152602001622322a160e91b81525060405180604001604052806008815260200167466562727561727960c01b81525091509150612257565b8260031415612348576040518060400160405280600381526020016226a0a960e91b8152506040518060400160405280600581526020016409ac2e4c6d60db1b81525091509150612257565b8260041415612394576040518060400160405280600381526020016220a82960e91b81525060405180604001604052806005815260200164105c1c9a5b60da1b81525091509150612257565b82600514156123de57604051806040016040528060038152602001624d415960e81b815250604051806040016040528060038152602001624d617960e81b81525091509150612257565b82600614156124295760405180604001604052806003815260200162252aa760e91b815250604051806040016040528060048152602001634a756e6560e01b81525091509150612257565b8260071415612474576040518060400160405280600381526020016212955360ea1b815250604051806040016040528060048152602001634a756c7960e01b81525091509150612257565b82600814156124c1576040518060400160405280600381526020016241554760e81b81525060405180604001604052806006815260200165105d59dd5cdd60d21b81525091509150612257565b8260091415612511576040518060400160405280600381526020016205345560ec1b8152506040518060400160405280600981526020016829b2b83a32b6b132b960b91b81525091509150612257565b82600a141561255f576040518060400160405280600381526020016213d0d560ea1b8152506040518060400160405280600781526020016627b1ba37b132b960c91b81525091509150612257565b82600b14156125ae57604051806040016040528060038152602001622727ab60e91b815250604051806040016040528060088152602001672737bb32b6b132b960c11b81525091509150612257565b6040518060400160405280600381526020016244454360e81b815250604051806040016040528060088152602001672232b1b2b6b132b960c11b81525091509150612257565b60606063821115612606576064820691505b606061261183612697565b9050600a83101561080a57806040516020018080600360fc1b81525060010182805190602001908083835b6020831061265b5780518252601f19909201916020918201910161263c565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040529150506107d5565b6060816126bc57506040805180820190915260018152600360fc1b60208201526107d5565b8160005b81156126d457600101600a820491506126c0565b60608167ffffffffffffffff811180156126ed57600080fd5b506040519080825280601f01601f191660200182016040528015612718576020820181803683370190505b50859350905060001982015b831561276957600a840660300160f81b8282806001900393508151811061274757fe5b60200101906001600160f81b031916908160001a905350600a84049350612724565b50949350505050565b600054610100900460ff168061278b575061278b611420565b80612799575060005460ff16155b6127d45760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff161580156127ff576000805460ff1961ff0019909116610100171660011790555b8015612811576000805461ff00191690555b50565b600054610100900460ff168061282d575061282d611420565b8061283b575060005460ff16155b6128765760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff161580156128a1576000805460ff1961ff0019909116610100171660011790555b82516020808501919091208351918401919091206097919091556098558015611ead576000805461ff0019169055505050565b600054610100900460ff16806128ed57506128ed611420565b806128fb575060005460ff16155b6129365760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015612961576000805460ff1961ff0019909116610100171660011790555b604051806052612d81823960405190819003605201902060cc55508015610764576000805461ff00191690555050565b4690565b600061104083836040518060400160405280601881526020017f536166654d6174683a206d6f64756c6f206279207a65726f0000000000000000815250612b4a565b600061104083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612bac565b60608083830367ffffffffffffffff81118015612a3557600080fd5b506040519080825280601f01601f191660200182016040528015612a60576020820181803683370190505b50905060005b848403811015612769578581860181518110612a7e57fe5b602001015160f81c60f81b828281518110612a9557fe5b60200101906001600160f81b031916908160001a905350600101612a66565b60008080836226496581018262023ab1600483020590506004600362023ab18302010590910390600062164b09610fa0600185010205905060046105b58202058303601f019250600061098f8460500281612b0b57fe5b0590506000605061098f83020585039050600b820560301994909401606402929092018301996002600c90940290910392909201975095509350505050565b60008183612b995760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f70578181015183820152602001610f58565b50828481612ba357fe5b06949350505050565b60008183612bfb5760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f70578181015183820152602001610f58565b506000838581612c0757fe5b0495945050505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10612c5257805160ff1916838001178555612c7f565b82800160010185558215612c7f579182015b82811115612c7f578251825591602001919060010190612c64565b50612c8b929150612c8f565b5090565b6105e291905b80821115612c8b5760008155600101612c9556fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545434453413a20696e76616c6964207369676e6174757265202773272076616c75654f746f6b656e3a204f6e6c7920436f6e74726f6c6c65722063616e206275726e204f746f6b656e735065726d69742861646472657373206f776e65722c61646472657373207370656e6465722c75696e743235362076616c75652c75696e74323536206e6f6e63652c75696e7432353620646561646c696e652945434453413a20696e76616c6964207369676e6174757265202776272076616c75654f746f6b656e3a204f6e6c7920436f6e74726f6c6c65722063616e206d696e74204f746f6b656e73454950373132446f6d61696e28737472696e67206e616d652c737472696e672076657273696f6e2c75696e7432353620636861696e49642c6164647265737320766572696679696e67436f6e74726163742945524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e6365436f6e747261637420696e7374616e63652068617320616c7265616479206265656e20696e697469616c697a656445524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa2646970667358221220ac6f856a0630a33099b1c469f118432db260f3a51b3b98a614550cd11993bcce64736f6c634300060a0033
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106101735760003560e01c80637ecebe00116100de578063af0968fc11610097578063dd62ed3e11610071578063dd62ed3e146104bc578063f3c274a6146104ea578063f630df34146104f2578063f77c47911461054657610173565b8063af0968fc14610419578063c52987cf14610463578063d505accf1461046b57610173565b80637ecebe001461038357806395d89b41146103a9578063a457c2d7146103b1578063a9059cbb146103dd578063aabaecd614610409578063ade6e2aa1461041157610173565b80633644e515116101305780633644e515146102c757806339509351146102cf57806351b0a410146102fb57806356d878f71461032957806370a08231146103555780637158da7c1461037b57610173565b806306fdde0314610178578063095ea7b3146101f557806317d69bc81461023557806318160ddd1461025957806323b872dd14610273578063313ce567146102a9575b600080fd5b61018061054e565b6040805160208082528351818301528351919283929083019185019080838360005b838110156101ba5781810151838201526020016101a2565b50505050905090810190601f1680156101e75780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6102216004803603604081101561020b57600080fd5b506001600160a01b0381351690602001356105e5565b604080519115158252519081900360200190f35b61023d610602565b604080516001600160a01b039092168252519081900360200190f35b610261610612565b60408051918252519081900360200190f35b6102216004803603606081101561028957600080fd5b506001600160a01b03813581169160208101359091169060400135610618565b6102b16106a5565b6040805160ff9092168252519081900360200190f35b6102616106ae565b610221600480360360408110156102e557600080fd5b506001600160a01b0381351690602001356106bd565b6103276004803603604081101561031157600080fd5b506001600160a01b038135169060200135610711565b005b6103276004803603604081101561033f57600080fd5b506001600160a01b038135169060200135610768565b6102616004803603602081101561036b57600080fd5b50356001600160a01b03166107bb565b61023d6107da565b6102616004803603602081101561039957600080fd5b50356001600160a01b03166107e9565b610180610810565b610221600480360360408110156103c757600080fd5b506001600160a01b038135169060200135610871565b610221600480360360408110156103f357600080fd5b506001600160a01b0381351690602001356108df565b61023d6108f3565b610261610903565b61042161090a565b604080516001600160a01b039788168152958716602087015293909516848401526060840191909152608083015291151560a082015290519081900360c00190f35b610261610940565b610327600480360360e081101561048157600080fd5b506001600160a01b03813581169160208101359091169060408101359060608101359060ff6080820135169060a08101359060c00135610947565b610261600480360360408110156104d257600080fd5b506001600160a01b0381358116916020013516610adf565b610221610b0a565b610327600480360360e081101561050857600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359091169060808101359060a08101359060c001351515610b14565b61023d610cb4565b60688054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156105da5780601f106105af576101008083540402835291602001916105da565b820191906000526020600020905b8154815290600101906020018083116105bd57829003601f168201915b505050505090505b90565b60006105f96105f2610cc3565b8484610cc7565b50600192915050565b610100546001600160a01b031681565b60675490565b6000610625848484610db3565b61069b84610631610cc3565b61069685604051806060016040528060288152602001612e6f602891396001600160a01b038a1660009081526066602052604081209061066f610cc3565b6001600160a01b03168152602081019190915260400160002054919063ffffffff610f1c16565b610cc7565b5060019392505050565b606a5460ff1690565b60006106b8610fb3565b905090565b60006105f96106ca610cc3565b8461069685606660006106db610cc3565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549063ffffffff610fe616565b60fe546001600160a01b0316331461075a5760405162461bcd60e51b8152600401808060200182810382526028815260200180612df56028913960400191505060405180910390fd5b6107648282611047565b5050565b60fe546001600160a01b031633146107b15760405162461bcd60e51b8152600401808060200182810382526028815260200180612d596028913960400191505060405180910390fd5b6107648282611145565b6001600160a01b0381166000908152606560205260409020545b919050565b60ff546001600160a01b031681565b6001600160a01b038116600090815260cb6020526040812061080a9061124d565b92915050565b60698054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156105da5780601f106105af576101008083540402835291602001916105da565b60006105f961087e610cc3565b8461069685604051806060016040528060258152602001612f2f60259139606660006108a8610cc3565b6001600160a01b03908116825260208083019390935260409182016000908120918d1681529252902054919063ffffffff610f1c16565b60006105f96108ec610cc3565b8484610db3565b610101546001600160a01b031681565b6101035481565b6101015460ff8054610100546101025461010354610104546001600160a01b039687169794871696909316949193909290911690565b6101025481565b8342111561099c576040805162461bcd60e51b815260206004820152601d60248201527f45524332305065726d69743a206578706972656420646561646c696e65000000604482015290519081900360640190fd5b600060cc548888886109d160cb60008e6001600160a01b03166001600160a01b0316815260200190815260200160002061124d565b604080516020808201979097526001600160a01b0395861681830152939094166060840152608083019190915260a082015260c08082018990528251808303909101815260e0909101909152805191012090506000610a2f82611251565b90506000610a3f8287878761129d565b9050896001600160a01b0316816001600160a01b031614610aa7576040805162461bcd60e51b815260206004820152601e60248201527f45524332305065726d69743a20696e76616c6964207369676e61747572650000604482015290519081900360640190fd5b6001600160a01b038a16600090815260cb60205260409020610ac890611417565b610ad38a8a8a610cc7565b50505050505050505050565b6001600160a01b03918216600090815260666020908152604080832093909416825291909152205490565b6101045460ff1681565b600054610100900460ff1680610b2d5750610b2d611420565b80610b3b575060005460ff16155b610b765760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015610ba1576000805460ff1961ff0019909116610100171660011790555b876001600160a01b0316633018205f6040518163ffffffff1660e01b815260040160206040518083038186803b158015610bda57600080fd5b505afa158015610bee573d6000803e3d6000fd5b505050506040513d6020811015610c0457600080fd5b505160fe80546001600160a01b03199081166001600160a01b039384161790915560ff805482168a8416179055610100805482168984161790556101018054909116918716919091179055610102849055610103839055610104805460ff1916831515179055606080610c75611426565b91509150610c838282611dd9565b610c8c82611eb2565b610c966008611f88565b50508015610caa576000805461ff00191690555b5050505050505050565b60fe546001600160a01b031681565b3390565b6001600160a01b038316610d0c5760405162461bcd60e51b8152600401808060200182810382526024815260200180612f0b6024913960400191505060405180910390fd5b6001600160a01b038216610d515760405162461bcd60e51b8152600401808060200182810382526022815260200180612cef6022913960400191505060405180910390fd5b6001600160a01b03808416600081815260666020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b6001600160a01b038316610df85760405162461bcd60e51b8152600401808060200182810382526025815260200180612ee66025913960400191505060405180910390fd5b6001600160a01b038216610e3d5760405162461bcd60e51b8152600401808060200182810382526023815260200180612caa6023913960400191505060405180910390fd5b610e48838383611ead565b610e8b81604051806060016040528060268152602001612d11602691396001600160a01b038616600090815260656020526040902054919063ffffffff610f1c16565b6001600160a01b038085166000908152606560205260408082209390935590841681522054610ec0908263ffffffff610fe616565b6001600160a01b0380841660008181526065602090815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b60008184841115610fab5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f70578181015183820152602001610f58565b50505050905090810190601f168015610f9d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b60006106b86040518080612e1d6052913960520190506040518091039020610fd9611f9e565b610fe1611fa4565b611faa565b600082820183811015611040576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b6001600160a01b0382166110a2576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b6110ae60008383611ead565b6067546110c1908263ffffffff610fe616565b6067556001600160a01b0382166000908152606560205260409020546110ed908263ffffffff610fe616565b6001600160a01b03831660008181526065602090815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b6001600160a01b03821661118a5760405162461bcd60e51b8152600401808060200182810382526021815260200180612ec56021913960400191505060405180910390fd5b61119682600083611ead565b6111d981604051806060016040528060228152602001612ccd602291396001600160a01b038516600090815260656020526040902054919063ffffffff610f1c16565b6001600160a01b038316600090815260656020526040902055606754611205908263ffffffff61200016565b6067556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b5490565b600061125b610fb3565b82604051602001808061190160f01b81525060020183815260200182815260200192505050604051602081830303815290604052805190602001209050919050565b60007f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08211156112fe5760405162461bcd60e51b8152600401808060200182810382526022815260200180612d376022913960400191505060405180910390fd5b8360ff16601b148061131357508360ff16601c145b61134e5760405162461bcd60e51b8152600401808060200182810382526022815260200180612dd36022913960400191505060405180910390fd5b604080516000808252602080830180855289905260ff88168385015260608301879052608083018690529251909260019260a080820193601f1981019281900390910190855afa1580156113a6573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b03811661140e576040805162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e61747572650000000000000000604482015290519081900360640190fd5b95945050505050565b80546001019055565b303b1590565b606080606060ff60009054906101000a90046001600160a01b03166001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b15801561147957600080fd5b505afa15801561148d573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156114b657600080fd5b81019080805160405193929190846401000000008211156114d657600080fd5b9083019060208201858111156114eb57600080fd5b825164010000000081118282018810171561150557600080fd5b82525081516020918201929091019080838360005b8381101561153257818101518382015260200161151a565b50505050905090810190601f16801561155f5780820380516001836020036101000a031916815260200191505b506040818152610100546395d89b4160e01b835290519596506060956001600160a01b0390911694506395d89b41935060048083019350600092829003018186803b1580156115ad57600080fd5b505afa1580156115c1573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156115ea57600080fd5b810190808051604051939291908464010000000082111561160a57600080fd5b90830190602082018581111561161f57600080fd5b825164010000000081118282018810171561163957600080fd5b82525081516020918201929091019080838360005b8381101561166657818101518382015260200161164e565b50505050905090810190601f1680156116935780820380516001836020036101000a031916815260200191505b506040818152610101546395d89b4160e01b835290519596506060956001600160a01b0390911694506395d89b41935060048083019350600092829003018186803b1580156116e157600080fd5b505afa1580156116f5573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052602081101561171e57600080fd5b810190808051604051939291908464010000000082111561173e57600080fd5b90830190602082018581111561175357600080fd5b825164010000000081118282018810171561176d57600080fd5b82525081516020918201929091019080838360005b8381101561179a578181015183820152602001611782565b50505050905090810190601f1680156117c75780820380516001836020036101000a031916815260200191505b50604052505050905060606117de61010254612042565b905060008060006117f1610103546121b4565b610104549295509093509150606090819061180e9060ff166121d3565b9150915060608061181e8661225c565b915091508a8a61182d876125f4565b836118378b612697565b8c888f6040516020018089805190602001908083835b6020831061186c5780518252601f19909201916020918201910161184d565b51815160209384036101000a60001901801990921691161790528b5191909301928b0191508083835b602083106118b45780518252601f199092019160209182019101611895565b6001836020036101000a03801982511681845116808217855250505050505090500180600160fd1b81525060010187805190602001908083835b6020831061190d5780518252601f1990920191602091820191016118ee565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010186805190602001908083835b602083106119665780518252601f199092019160209182019101611947565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010185805190602001908083835b602083106119bf5780518252601f1990920191602091820191016119a0565b6001836020036101000a03801982511681845116808217855250505050505090500180600160fd1b81525060010184805190602001908083835b60208310611a185780518252601f1990920191602091820191016119f9565b51815160209384036101000a600019018019909216911617905286519190930192860191508083835b60208310611a605780518252601f199092019160209182019101611a41565b6001836020036101000a03801982511681845116808217855250505050505090500180600160fd1b81525060010182805190602001908083835b60208310611ab95780518252601f199092019160209182019101611a9a565b6001836020036101000a038019825116818451168082178552505050505050905001806a0810dbdb1b185d195c985b60aa1b815250600b01985050505050505050506040516020818303038152906040529c508a8a8a611b18886125f4565b85611b228c6125f4565b8d8a6040516020018080606f60f81b81525060010189805190602001908083835b60208310611b625780518252601f199092019160209182019101611b43565b51815160209384036101000a60001901801990921691161790528b5191909301928b0191508083835b60208310611baa5780518252601f199092019160209182019101611b8b565b6001836020036101000a03801982511681845116808217855250505050505090500180602f60f81b81525060010187805190602001908083835b60208310611c035780518252601f199092019160209182019101611be4565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010186805190602001908083835b60208310611c5c5780518252601f199092019160209182019101611c3d565b51815160209384036101000a600019018019909216911617905288519190930192880191508083835b60208310611ca45780518252601f199092019160209182019101611c85565b51815160209384036101000a600019018019909216911617905287519190930192870191508083835b60208310611cec5780518252601f199092019160209182019101611ccd565b6001836020036101000a03801982511681845116808217855250505050505090500180602d60f81b81525060010183805190602001908083835b60208310611d455780518252601f199092019160209182019101611d26565b51815160209384036101000a600019018019909216911617905285519190930192850191508083835b60208310611d8d5780518252601f199092019160209182019101611d6e565b6001836020036101000a038019825116818451168082178552505050505050905001985050505050505050506040516020818303038152906040529b5050505050505050505050509091565b600054610100900460ff1680611df25750611df2611420565b80611e00575060005460ff16155b611e3b5760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015611e66576000805460ff1961ff0019909116610100171660011790555b8251611e79906068906020860190612c11565b508151611e8d906069906020850190612c11565b50606a805460ff191660121790558015611ead576000805461ff00191690555b505050565b600054610100900460ff1680611ecb5750611ecb611420565b80611ed9575060005460ff16155b611f145760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015611f3f576000805460ff1961ff0019909116610100171660011790555b611f47612772565b611f6a82604051806040016040528060018152602001603160f81b815250612814565b611f73826128d4565b8015610764576000805461ff00191690555050565b606a805460ff191660ff92909216919091179055565b60975490565b60985490565b6000838383611fb7612991565b6040805160208082019690965280820194909452606084019290925260808301523060a0808401919091528151808403909101815260c090920190528051910120949350505050565b600061104083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610f1c565b6060600061205a836305f5e10063ffffffff61299516565b90506000612072846305f5e10063ffffffff6129d716565b9050606061207f82612697565b9050826120905792506107d5915050565b60005b6120a484600a63ffffffff61299516565b6120b657600a84049350600101612093565b80600803600a0a8401935060606120cc85612697565b90506120de8160016009859003612a19565b9050606083826040516020018083805190602001908083835b602083106121165780518252601f1990920191602091820191016120f7565b6001836020036101000a03801982511681845116808217855250505050505090500180601760f91b81525060010182805190602001908083835b6020831061216f5780518252601f199092019160209182019101612150565b6001836020036101000a038019825116818451168082178552505050505050905001925050506040516020818303038152906040529050809650505050505050919050565b600080806121c6620151808504612ab4565b9196909550909350915050565b606080821561221b57604051806040016040528060018152602001600560fc1b81525060405180604001604052806003815260200162141d5d60ea1b81525091509150612257565b604051806040016040528060018152602001604360f81b8152506040518060400160405280600481526020016310d85b1b60e21b815250915091505b915091565b60608082600114156122ad57604051806040016040528060038152602001622520a760e91b815250604051806040016040528060078152602001664a616e7561727960c81b81525091509150612257565b82600214156122fc57604051806040016040528060038152602001622322a160e91b81525060405180604001604052806008815260200167466562727561727960c01b81525091509150612257565b8260031415612348576040518060400160405280600381526020016226a0a960e91b8152506040518060400160405280600581526020016409ac2e4c6d60db1b81525091509150612257565b8260041415612394576040518060400160405280600381526020016220a82960e91b81525060405180604001604052806005815260200164105c1c9a5b60da1b81525091509150612257565b82600514156123de57604051806040016040528060038152602001624d415960e81b815250604051806040016040528060038152602001624d617960e81b81525091509150612257565b82600614156124295760405180604001604052806003815260200162252aa760e91b815250604051806040016040528060048152602001634a756e6560e01b81525091509150612257565b8260071415612474576040518060400160405280600381526020016212955360ea1b815250604051806040016040528060048152602001634a756c7960e01b81525091509150612257565b82600814156124c1576040518060400160405280600381526020016241554760e81b81525060405180604001604052806006815260200165105d59dd5cdd60d21b81525091509150612257565b8260091415612511576040518060400160405280600381526020016205345560ec1b8152506040518060400160405280600981526020016829b2b83a32b6b132b960b91b81525091509150612257565b82600a141561255f576040518060400160405280600381526020016213d0d560ea1b8152506040518060400160405280600781526020016627b1ba37b132b960c91b81525091509150612257565b82600b14156125ae57604051806040016040528060038152602001622727ab60e91b815250604051806040016040528060088152602001672737bb32b6b132b960c11b81525091509150612257565b6040518060400160405280600381526020016244454360e81b815250604051806040016040528060088152602001672232b1b2b6b132b960c11b81525091509150612257565b60606063821115612606576064820691505b606061261183612697565b9050600a83101561080a57806040516020018080600360fc1b81525060010182805190602001908083835b6020831061265b5780518252601f19909201916020918201910161263c565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040529150506107d5565b6060816126bc57506040805180820190915260018152600360fc1b60208201526107d5565b8160005b81156126d457600101600a820491506126c0565b60608167ffffffffffffffff811180156126ed57600080fd5b506040519080825280601f01601f191660200182016040528015612718576020820181803683370190505b50859350905060001982015b831561276957600a840660300160f81b8282806001900393508151811061274757fe5b60200101906001600160f81b031916908160001a905350600a84049350612724565b50949350505050565b600054610100900460ff168061278b575061278b611420565b80612799575060005460ff16155b6127d45760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff161580156127ff576000805460ff1961ff0019909116610100171660011790555b8015612811576000805461ff00191690555b50565b600054610100900460ff168061282d575061282d611420565b8061283b575060005460ff16155b6128765760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff161580156128a1576000805460ff1961ff0019909116610100171660011790555b82516020808501919091208351918401919091206097919091556098558015611ead576000805461ff0019169055505050565b600054610100900460ff16806128ed57506128ed611420565b806128fb575060005460ff16155b6129365760405162461bcd60e51b815260040180806020018281038252602e815260200180612e97602e913960400191505060405180910390fd5b600054610100900460ff16158015612961576000805460ff1961ff0019909116610100171660011790555b604051806052612d81823960405190819003605201902060cc55508015610764576000805461ff00191690555050565b4690565b600061104083836040518060400160405280601881526020017f536166654d6174683a206d6f64756c6f206279207a65726f0000000000000000815250612b4a565b600061104083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612bac565b60608083830367ffffffffffffffff81118015612a3557600080fd5b506040519080825280601f01601f191660200182016040528015612a60576020820181803683370190505b50905060005b848403811015612769578581860181518110612a7e57fe5b602001015160f81c60f81b828281518110612a9557fe5b60200101906001600160f81b031916908160001a905350600101612a66565b60008080836226496581018262023ab1600483020590506004600362023ab18302010590910390600062164b09610fa0600185010205905060046105b58202058303601f019250600061098f8460500281612b0b57fe5b0590506000605061098f83020585039050600b820560301994909401606402929092018301996002600c90940290910392909201975095509350505050565b60008183612b995760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f70578181015183820152602001610f58565b50828481612ba357fe5b06949350505050565b60008183612bfb5760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f70578181015183820152602001610f58565b506000838581612c0757fe5b0495945050505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10612c5257805160ff1916838001178555612c7f565b82800160010185558215612c7f579182015b82811115612c7f578251825591602001919060010190612c64565b50612c8b929150612c8f565b5090565b6105e291905b80821115612c8b5760008155600101612c9556fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545434453413a20696e76616c6964207369676e6174757265202773272076616c75654f746f6b656e3a204f6e6c7920436f6e74726f6c6c65722063616e206275726e204f746f6b656e735065726d69742861646472657373206f776e65722c61646472657373207370656e6465722c75696e743235362076616c75652c75696e74323536206e6f6e63652c75696e7432353620646561646c696e652945434453413a20696e76616c6964207369676e6174757265202776272076616c75654f746f6b656e3a204f6e6c7920436f6e74726f6c6c65722063616e206d696e74204f746f6b656e73454950373132446f6d61696e28737472696e67206e616d652c737472696e672076657273696f6e2c75696e7432353620636861696e49642c6164647265737320766572696679696e67436f6e74726163742945524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e6365436f6e747261637420696e7374616e63652068617320616c7265616479206265656e20696e697469616c697a656445524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa2646970667358221220ac6f856a0630a33099b1c469f118432db260f3a51b3b98a614550cd11993bcce64736f6c634300060a0033
Loading...
Loading
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.