Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 32 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Withdraw | 18598479 | 286 days ago | IN | 0 ETH | 0.00048945 | ||||
Subscribe | 18443523 | 308 days ago | IN | 0.124444 ETH | 0.0008985 | ||||
Subscribe | 18443522 | 308 days ago | IN | 0.124444 ETH | 0.00352938 | ||||
Withdraw | 17258236 | 474 days ago | IN | 0 ETH | 0.00119197 | ||||
Subscribe | 17075944 | 500 days ago | IN | 0.35172162 ETH | 0.01352709 | ||||
Subscribe | 17075937 | 500 days ago | IN | 0.35204181 ETH | 0.00186989 | ||||
Subscribe | 17075935 | 500 days ago | IN | 0.35204181 ETH | 0.00195855 | ||||
Withdraw | 16832682 | 534 days ago | IN | 0 ETH | 0.0006621 | ||||
Subscribe | 16615361 | 565 days ago | IN | 0.60093226 ETH | 0.0040695 | ||||
Subscribe | 16609737 | 566 days ago | IN | 0.60159554 ETH | 0.00307999 | ||||
Withdraw | 16600361 | 567 days ago | IN | 0 ETH | 0.00060383 | ||||
Subscribe | 16496424 | 582 days ago | IN | 1.89786552 ETH | 0.00369284 | ||||
Subscribe | 16496400 | 582 days ago | IN | 1.89786552 ETH | 0.00390342 | ||||
Withdraw | 16421695 | 592 days ago | IN | 0 ETH | 0.00085784 | ||||
Owner Subscribe | 16371661 | 599 days ago | IN | 0 ETH | 0.00481624 | ||||
Owner Subscribe | 16371643 | 599 days ago | IN | 0 ETH | 0.00508342 | ||||
Owner Subscribe | 16371625 | 599 days ago | IN | 0 ETH | 0.00508029 | ||||
Owner Subscribe | 16371623 | 599 days ago | IN | 0 ETH | 0.00452411 | ||||
Owner Subscribe | 16371616 | 599 days ago | IN | 0 ETH | 0.00559697 | ||||
Owner Subscribe | 16371613 | 599 days ago | IN | 0 ETH | 0.00545476 | ||||
Owner Subscribe | 16371595 | 599 days ago | IN | 0 ETH | 0.00618402 | ||||
Subscribe | 16357666 | 601 days ago | IN | 0.79055376 ETH | 0.00323072 | ||||
Subscribe | 16290656 | 610 days ago | IN | 2.50048527 ETH | 0.00886764 | ||||
Subscribe | 16234252 | 618 days ago | IN | 2.4685246 ETH | 0.0054849 | ||||
Subscribe | 16233188 | 618 days ago | IN | 0.82264317 ETH | 0.00368041 |
Loading...
Loading
Contract Name:
SubscriptionsManager
Compiler Version
v0.8.12+commit.f00d7308
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import '../../libraries/interfaces/ISubscriptions.sol'; import '../../libraries/interfaces/ISubscriptionsManager.sol'; import '@openzeppelin/contracts/access/Ownable.sol'; import '@openzeppelin/contracts/security/ReentrancyGuard.sol'; import '@openzeppelin/contracts/utils/cryptography/ECDSA.sol'; import '@openzeppelin/contracts/utils/Strings.sol'; /// @title Redlion Subscription Manager /// @author Gui "Qruz" Rodrigues /// @notice Management of payments and info of subcriptions /// @dev Portal contract to all subscriptions tokens of REDLION /* Each user is allowed to have a single subscription active, It is not possible to have a normal subscription and a super subscription simultaneously The following features are locked when the user is subscribed : - Transfer from (if subscription is SUPER) => The user is still allowed to burn their token Doing so will invalidate the subscription and every feature that comes the associated token - Transfer to - Subscrption via contract Users still mainting 100% ownership of their tokens, they can sell them or give them but not hold multiple subscription tokens. Subscribed status : User is defined as subscribed whenever he holds a subscription token. */ contract SubscriptionsManager is Ownable, ReentrancyGuard, ISubscriptionsManager { using Strings for uint256; using ECDSA for bytes32; mapping(SubType => uint256) PRICE; address SIGNER; address RED_ADDRESS; address GOLD_ADDRESS; /// @notice Construtor function defining basic parameters /// @dev subscription contract addresses can be null /// @param _red Super subscription contract address /// @param _gold Normal Subscroption contract address constructor(address _red, address _gold) { RED_ADDRESS = _red; GOLD_ADDRESS = _gold; setSubPrice(SubType.NORMAL, 99900); setSubPrice(SubType.SUPER, 299900); } /*/////////////////////////////////////////////////////////////// EVENTS ///////////////////////////////////////////////////////////////*/ /// @notice Event emited when a user subscribes to a SuperSubscription /// @param to the subscriber address /// @param subType the type of subscription event Subscribe(address indexed to, SubType indexed subType); /*/////////////////////////////////////////////////////////////// SUBSCRIPTIONS ///////////////////////////////////////////////////////////////*/ /// @notice Function subscribing the user depending on params /// @dev Internal function /// @param to target address /// @param subType Type of subscription function _subscribe(address to, SubType subType) internal { require(isSubscribed(to) == false, 'WALLET_ALREADY_SUBSCRIBED'); if (subType == SubType.SUPER) { ISubscriptions(RED_ADDRESS).subscribe(to); } else if (subType == SubType.NORMAL) { ISubscriptions(GOLD_ADDRESS).subscribe(to); } else { revert('INVALID_SUB_TYPE'); } emit Subscribe(to, subType); } /** This function was created with the intent of setting the price off chain. Although there's a PRICE mapping for each subscription type, these are only used as a signle source of truth that can be verified by the user. We're allowed to create discounts by changing the price in the signature. The price value in the signature should match the value of the transaction. Signature structure : - target address - contract address (in case we deploy a different subscription manager or use same signer in the future for different contract using the same logic) - Susbcription type (number id of enum) - Value (ethers price) - Timestamp of signature creation (seconds) @dev The signature contains data validating : price, valdiity (time) and contract address (contract) to avoid exploits @param subType the type of subscription @param timestamp the timestamp (seconds) when the signature was created @param signature the signature validating the subscription */ function subscribe( SubType subType, uint256 timestamp, bytes memory signature ) public payable nonReentrant { require(block.timestamp < timestamp + 10 minutes, 'INVALID_TIMESTAMP'); // Validate signature bytes32 inputHash = keccak256( abi.encodePacked( msg.sender, address(this), uint256(subType), msg.value, timestamp ) ); require(_validSignature(signature, inputHash), 'BAD_SIGNATURE'); _subscribe(msg.sender, subType); } /*/////////////////////////////////////////////////////////////// SUB STATE ///////////////////////////////////////////////////////////////*/ function isSubscribed( address target ) public view override(ISubscriptionsManager) returns (bool) { return ISubscriptions(RED_ADDRESS).isSubscribed(target) || ISubscriptions(GOLD_ADDRESS).isSubscribed(target); } function whichType(address target) public view returns (SubType) { if (ISubscriptions(RED_ADDRESS).isSubscribed(target)) return SubType.SUPER; else if (ISubscriptions(GOLD_ADDRESS).isSubscribed(target)) return SubType.NORMAL; return SubType.NONE; } function subscriptionInfo( address target ) public view override(ISubscriptionsManager) returns (SubInfo memory) { SubInfo memory info = SubInfo(false, SubType.NONE, 0, ''); ISubscriptions superSubs = ISubscriptions(RED_ADDRESS); ISubscriptions normalSubs = ISubscriptions(GOLD_ADDRESS); if (normalSubs.isSubscribed(target)) { info.timestamp = normalSubs.when(target); info.subscribed = true; info.subType = SubType.NORMAL; info.subId = normalSubs.subscriptionId(target); } else if (superSubs.isSubscribed(target)) { info.timestamp = superSubs.when(target); info.subscribed = true; info.subType = SubType.SUPER; info.subId = superSubs.subscriptionId(target); } return info; } /*/////////////////////////////////////////////////////////////// OWNER FUNCTIONS ///////////////////////////////////////////////////////////////*/ function withdraw() public onlyOwner { uint balance = address(this).balance; payable(msg.sender).transfer(balance); } /// @notice Owner subscription function /// @dev Bypasses signature verification (owner only) /// @param to the target address /// @param subType the subscription type function ownerSubscribe(address to, SubType subType) public onlyOwner { _subscribe(to, subType); } /*/////////////////////////////////////////////////////////////// UTILITY ///////////////////////////////////////////////////////////////*/ function _isValidSubType(SubType _subType) internal pure { require( _subType == SubType.NORMAL || _subType == SubType.SUPER, 'INVALID_SUB_TYPE' ); } /// @notice Sets the new signer address /// @dev this function is used when the current signer address has been compromised or access lost /// @param _address the new signer address function setSigner(address _address) public onlyOwner { SIGNER = _address; } /// @notice Set normal subscriptions contract address /// @param _contractAddress the new contract adddress function setSubscriptions(address _contractAddress) public onlyOwner { GOLD_ADDRESS = _contractAddress; } /// @notice Set super subscriptions contract address /// @param _contractAddress the new contract adddress function setSuperSubscriptions(address _contractAddress) public onlyOwner { RED_ADDRESS = _contractAddress; } /// @notice Set price for a specific subscription type /// @param _subType the subscription type /// @param _price the new price function setSubPrice(SubType _subType, uint256 _price) public onlyOwner { _isValidSubType(_subType); PRICE[_subType] = _price; } /// @notice Getter for a specific subscription type price /// @param _subType the subscription type id /// @return uint256 the subcription's price function getPrice(SubType _subType) external view returns (uint256) { _isValidSubType(_subType); return PRICE[_subType]; } function _validSignature( bytes memory signature, bytes32 msgHash ) internal view returns (bool) { return msgHash.toEthSignedMessageHash().recover(signature) == SIGNER; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol) pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @dev Converts a `uint256` to its ASCII `string` decimal 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); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.3) (utils/cryptography/ECDSA.sol) pragma solidity ^0.8.0; import "../Strings.sol"; /** * @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 ECDSA { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS, InvalidSignatureV } function _throwError(RecoverError error) private pure { if (error == RecoverError.NoError) { return; // no error: do nothing } else if (error == RecoverError.InvalidSignature) { revert("ECDSA: invalid signature"); } else if (error == RecoverError.InvalidSignatureLength) { revert("ECDSA: invalid signature length"); } else if (error == RecoverError.InvalidSignatureS) { revert("ECDSA: invalid signature 's' value"); } else if (error == RecoverError.InvalidSignatureV) { revert("ECDSA: invalid signature 'v' value"); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature` or error string. 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. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] * * _Available since v4.3._ */ function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) { if (signature.length == 65) { bytes32 r; bytes32 s; uint8 v; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. /// @solidity memory-safe-assembly assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else { return (address(0), RecoverError.InvalidSignatureLength); } } /** * @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) { (address recovered, RecoverError error) = tryRecover(hash, signature); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] * * _Available since v4.3._ */ function tryRecover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address, RecoverError) { bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); uint8 v = uint8((uint256(vs) >> 255) + 27); return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. * * _Available since v4.2._ */ function recover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, r, vs); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. * * _Available since v4.3._ */ function tryRecover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address, RecoverError) { // 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 (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): 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. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { return (address(0), RecoverError.InvalidSignatureS); } if (v != 27 && v != 28) { return (address(0), RecoverError.InvalidSignatureV); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { return (address(0), RecoverError.InvalidSignature); } return (signer, RecoverError.NoError); } /** * @dev Overload of {ECDSA-recover} that receives the `v`, * `r` and `s` signature fields separately. */ function recover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, v, r, s); _throwError(error); return recovered; } /** * @dev Returns an Ethereum Signed Message, created from a `hash`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * 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)); } /** * @dev Returns an Ethereum Signed Message, created from `s`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s)); } /** * @dev Returns an Ethereum Signed Typed Data, created from a * `domainSeparator` and a `structHash`. This produces hash corresponding * to the one signed with the * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] * JSON-RPC method as part of EIP-712. * * See {recover}. */ function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash)); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; interface ISubscriptions { function subscribe(address to) external; function isSubscribed(address target) external view returns (bool); function subscribers() external view returns (address[] memory); function subscriptionId(address target) external view returns (bytes memory); function when(address target) external view returns (uint256); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; interface ISubscriptionsManager { enum SubType { NORMAL, SUPER, NONE } struct SubInfo { bool subscribed; SubType subType; uint256 timestamp; bytes subId; } function isSubscribed(address target) external view returns (bool); function subscriptionInfo( address target ) external view returns (SubInfo memory); }
{ "evmVersion": "london", "libraries": {}, "metadata": { "bytecodeHash": "ipfs", "useLiteralContent": true }, "optimizer": { "enabled": true, "runs": 200 }, "remappings": [], "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_red","type":"address"},{"internalType":"address","name":"_gold","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"enum ISubscriptionsManager.SubType","name":"subType","type":"uint8"}],"name":"Subscribe","type":"event"},{"inputs":[{"internalType":"enum ISubscriptionsManager.SubType","name":"_subType","type":"uint8"}],"name":"getPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"isSubscribed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"enum ISubscriptionsManager.SubType","name":"subType","type":"uint8"}],"name":"ownerSubscribe","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"setSigner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum ISubscriptionsManager.SubType","name":"_subType","type":"uint8"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"setSubPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_contractAddress","type":"address"}],"name":"setSubscriptions","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_contractAddress","type":"address"}],"name":"setSuperSubscriptions","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum ISubscriptionsManager.SubType","name":"subType","type":"uint8"},{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"subscribe","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"subscriptionInfo","outputs":[{"components":[{"internalType":"bool","name":"subscribed","type":"bool"},{"internalType":"enum ISubscriptionsManager.SubType","name":"subType","type":"uint8"},{"internalType":"uint256","name":"timestamp","type":"uint256"},{"internalType":"bytes","name":"subId","type":"bytes"}],"internalType":"struct ISubscriptionsManager.SubInfo","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"whichType","outputs":[{"internalType":"enum ISubscriptionsManager.SubType","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040523480156200001157600080fd5b50604051620017f1380380620017f183398101604081905262000034916200023e565b6200003f336200009b565b60018055600480546001600160a01b038085166001600160a01b03199283161790925560058054928416929091169190911790556200008360006201863c620000eb565b6200009360016204937c620000eb565b50506200028c565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b620000f562000143565b6200010082620001a5565b80600260008460028111156200011a576200011a62000276565b60028111156200012e576200012e62000276565b81526020810191909152604001600020555050565b6000546001600160a01b03163314620001a35760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b565b6000816002811115620001bc57620001bc62000276565b1480620001dd57506001816002811115620001db57620001db62000276565b145b6200021e5760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f5355425f5459504560801b60448201526064016200019a565b50565b80516001600160a01b03811681146200023957600080fd5b919050565b600080604083850312156200025257600080fd5b6200025d8362000221565b91506200026d6020840162000221565b90509250929050565b634e487b7160e01b600052602160045260246000fd5b611555806200029c6000396000f3fe6080604052600436106100dd5760003560e01c80636c19e7831161007f5780639c4f7d59116100595780639c4f7d591461022d578063b92ae87c1461024d578063d83f6e561461027d578063f2fde38b146102aa57600080fd5b80636c19e783146101d0578063715018a6146101f05780638da5cb5b1461020557600080fd5b80632b12d2c1116100bb5780632b12d2c11461013757806337f1e7f21461016d5780633ccfd60b1461019b57806359dedeee146101b057600080fd5b80631a49774f146100e257806322cb889e1461010457806328bd856214610117575b600080fd5b3480156100ee57600080fd5b506101026100fd3660046111ba565b6102ca565b005b61010261011236600461125a565b6102f4565b34801561012357600080fd5b506101026101323660046112f4565b610465565b34801561014357600080fd5b506101576101523660046111ba565b6104b3565b6040516101649190611356565b60405180910390f35b34801561017957600080fd5b5061018d610188366004611364565b6105b7565b604051908152602001610164565b3480156101a757600080fd5b506101026105ff565b3480156101bc57600080fd5b506101026101cb36600461137f565b61063a565b3480156101dc57600080fd5b506101026101eb3660046111ba565b61064c565b3480156101fc57600080fd5b50610102610676565b34801561021157600080fd5b506000546040516001600160a01b039091168152602001610164565b34801561023957600080fd5b506101026102483660046111ba565b61068a565b34801561025957600080fd5b5061026d6102683660046111ba565b6106b4565b6040519015158152602001610164565b34801561028957600080fd5b5061029d6102983660046111ba565b6107a2565b60405161016491906113e2565b3480156102b657600080fd5b506101026102c53660046111ba565b610ad0565b6102d2610b49565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b6002600154141561034c5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b600260015561035d82610258611447565b421061039f5760405162461bcd60e51b81526020600482015260116024820152700494e56414c49445f54494d455354414d5607c1b6044820152606401610343565b600033308560028111156103b5576103b561131e565b6040516bffffffffffffffffffffffff19606094851b811660208301529290931b909116603483015260488201523460688201526088810184905260a8016040516020818303038152906040528051906020012090506104158282610ba3565b6104515760405162461bcd60e51b815260206004820152600d60248201526c4241445f5349474e415455524560981b6044820152606401610343565b61045b3385610c24565b5050600180555050565b61046d610b49565b61047682610dcc565b806002600084600281111561048d5761048d61131e565b600281111561049e5761049e61131e565b81526020810191909152604001600020555050565b60048054604051632e4aba1f60e21b81526001600160a01b03848116938201939093526000929091169063b92ae87c90602401602060405180830381865afa158015610503573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610527919061146d565b1561053457506001919050565b600554604051632e4aba1f60e21b81526001600160a01b0384811660048301529091169063b92ae87c90602401602060405180830381865afa15801561057e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105a2919061146d565b156105af57506000919050565b506002919050565b60006105c282610dcc565b600260008360028111156105d8576105d861131e565b60028111156105e9576105e961131e565b8152602001908152602001600020549050919050565b610607610b49565b6040514790339082156108fc029083906000818181858888f19350505050158015610636573d6000803e3d6000fd5b5050565b610642610b49565b6106368282610c24565b610654610b49565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b61067e610b49565b6106886000610e3c565b565b610692610b49565b600580546001600160a01b0319166001600160a01b0392909216919091179055565b60048054604051632e4aba1f60e21b81526001600160a01b03848116938201939093526000929091169063b92ae87c90602401602060405180830381865afa158015610704573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610728919061146d565b8061079c5750600554604051632e4aba1f60e21b81526001600160a01b0384811660048301529091169063b92ae87c90602401602060405180830381865afa158015610778573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079c919061146d565b92915050565b60408051608081018252600080825260208201819052918101919091526060808201526040805160808101825260008082526002602080840191909152828401829052835190810184529081526060820152600480546005549351632e4aba1f60e21b81526001600160a01b0387811693820193909352929390821692911690819063b92ae87c90602401602060405180830381865afa15801561084a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061086e919061146d565b1561096857604051636d43da9d60e11b81526001600160a01b03868116600483015282169063da87b53a90602401602060405180830381865afa1580156108b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108dd919061148f565b604084015260018352600060208401819052506040516305f289dd60e21b81526001600160a01b0386811660048301528216906317ca277490602401600060405180830381865afa158015610936573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261095e91908101906114a8565b6060840152610ac7565b604051632e4aba1f60e21b81526001600160a01b03868116600483015283169063b92ae87c90602401602060405180830381865afa1580156109ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109d2919061146d565b15610ac757604051636d43da9d60e11b81526001600160a01b03868116600483015283169063da87b53a90602401602060405180830381865afa158015610a1d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a41919061148f565b6040840152600180845260208401819052506040516305f289dd60e21b81526001600160a01b0386811660048301528316906317ca277490602401600060405180830381865afa158015610a99573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ac191908101906114a8565b60608401525b50909392505050565b610ad8610b49565b6001600160a01b038116610b3d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610343565b610b4681610e3c565b50565b6000546001600160a01b031633146106885760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610343565b6003546000906001600160a01b0316610c1384610c0d856040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b90610e8c565b6001600160a01b0316149392505050565b610c2d826106b4565b15610c7a5760405162461bcd60e51b815260206004820152601960248201527f57414c4c45545f414c52454144595f53554253435249424544000000000000006044820152606401610343565b6001816002811115610c8e57610c8e61131e565b1415610cfb57600480546040516320d3b93560e11b81526001600160a01b03858116938201939093529116906341a7726a906024015b600060405180830381600087803b158015610cde57600080fd5b505af1158015610cf2573d6000803e3d6000fd5b50505050610d82565b6000816002811115610d0f57610d0f61131e565b1415610d47576005546040516320d3b93560e11b81526001600160a01b038481166004830152909116906341a7726a90602401610cc4565b60405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f5355425f5459504560801b6044820152606401610343565b806002811115610d9457610d9461131e565b6040516001600160a01b038416907f059489ce65642e6c094afec2c94486ad064070e20905e0c9f960dc85ddb0b38090600090a35050565b6000816002811115610de057610de061131e565b1480610dfd57506001816002811115610dfb57610dfb61131e565b145b610b465760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f5355425f5459504560801b6044820152606401610343565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000806000610e9b8585610eb0565b91509150610ea881610ef6565b509392505050565b600080825160411415610ee75760208301516040840151606085015160001a610edb878285856110b1565b94509450505050610eef565b506000905060025b9250929050565b6000816004811115610f0a57610f0a61131e565b1415610f135750565b6001816004811115610f2757610f2761131e565b1415610f755760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610343565b6002816004811115610f8957610f8961131e565b1415610fd75760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610343565b6003816004811115610feb57610feb61131e565b14156110445760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b6064820152608401610343565b60048160048111156110585761105861131e565b1415610b465760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b6064820152608401610343565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311156110e85750600090506003611195565b8460ff16601b1415801561110057508460ff16601c14155b156111115750600090506004611195565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015611165573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b03811661118e57600060019250925050611195565b9150600090505b94509492505050565b80356001600160a01b03811681146111b557600080fd5b919050565b6000602082840312156111cc57600080fd5b6111d58261119e565b9392505050565b8035600381106111b557600080fd5b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561122a5761122a6111eb565b604052919050565b600067ffffffffffffffff82111561124c5761124c6111eb565b50601f01601f191660200190565b60008060006060848603121561126f57600080fd5b611278846111dc565b925060208401359150604084013567ffffffffffffffff81111561129b57600080fd5b8401601f810186136112ac57600080fd5b80356112bf6112ba82611232565b611201565b8181528760208385010111156112d457600080fd5b816020840160208301376000602083830101528093505050509250925092565b6000806040838503121561130757600080fd5b611310836111dc565b946020939093013593505050565b634e487b7160e01b600052602160045260246000fd5b6003811061135257634e487b7160e01b600052602160045260246000fd5b9052565b6020810161079c8284611334565b60006020828403121561137657600080fd5b6111d5826111dc565b6000806040838503121561139257600080fd5b61139b8361119e565b91506113a9602084016111dc565b90509250929050565b60005b838110156113cd5781810151838201526020016113b5565b838111156113dc576000848401525b50505050565b60208152815115156020820152600060208301516114036040840182611334565b5060408301516060830152606083015160808084015280518060a08501526114328160c08601602085016113b2565b601f01601f19169290920160c0019392505050565b6000821982111561146857634e487b7160e01b600052601160045260246000fd5b500190565b60006020828403121561147f57600080fd5b815180151581146111d557600080fd5b6000602082840312156114a157600080fd5b5051919050565b6000602082840312156114ba57600080fd5b815167ffffffffffffffff8111156114d157600080fd5b8201601f810184136114e257600080fd5b80516114f06112ba82611232565b81815285602083850101111561150557600080fd5b6115168260208301602086016113b2565b9594505050505056fea2646970667358221220bdfa87b7211d3a86dbc25ed83ef96dd4c7b501c152e451d7382e2631297ad8cd64736f6c634300080c003300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x6080604052600436106100dd5760003560e01c80636c19e7831161007f5780639c4f7d59116100595780639c4f7d591461022d578063b92ae87c1461024d578063d83f6e561461027d578063f2fde38b146102aa57600080fd5b80636c19e783146101d0578063715018a6146101f05780638da5cb5b1461020557600080fd5b80632b12d2c1116100bb5780632b12d2c11461013757806337f1e7f21461016d5780633ccfd60b1461019b57806359dedeee146101b057600080fd5b80631a49774f146100e257806322cb889e1461010457806328bd856214610117575b600080fd5b3480156100ee57600080fd5b506101026100fd3660046111ba565b6102ca565b005b61010261011236600461125a565b6102f4565b34801561012357600080fd5b506101026101323660046112f4565b610465565b34801561014357600080fd5b506101576101523660046111ba565b6104b3565b6040516101649190611356565b60405180910390f35b34801561017957600080fd5b5061018d610188366004611364565b6105b7565b604051908152602001610164565b3480156101a757600080fd5b506101026105ff565b3480156101bc57600080fd5b506101026101cb36600461137f565b61063a565b3480156101dc57600080fd5b506101026101eb3660046111ba565b61064c565b3480156101fc57600080fd5b50610102610676565b34801561021157600080fd5b506000546040516001600160a01b039091168152602001610164565b34801561023957600080fd5b506101026102483660046111ba565b61068a565b34801561025957600080fd5b5061026d6102683660046111ba565b6106b4565b6040519015158152602001610164565b34801561028957600080fd5b5061029d6102983660046111ba565b6107a2565b60405161016491906113e2565b3480156102b657600080fd5b506101026102c53660046111ba565b610ad0565b6102d2610b49565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b6002600154141561034c5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b600260015561035d82610258611447565b421061039f5760405162461bcd60e51b81526020600482015260116024820152700494e56414c49445f54494d455354414d5607c1b6044820152606401610343565b600033308560028111156103b5576103b561131e565b6040516bffffffffffffffffffffffff19606094851b811660208301529290931b909116603483015260488201523460688201526088810184905260a8016040516020818303038152906040528051906020012090506104158282610ba3565b6104515760405162461bcd60e51b815260206004820152600d60248201526c4241445f5349474e415455524560981b6044820152606401610343565b61045b3385610c24565b5050600180555050565b61046d610b49565b61047682610dcc565b806002600084600281111561048d5761048d61131e565b600281111561049e5761049e61131e565b81526020810191909152604001600020555050565b60048054604051632e4aba1f60e21b81526001600160a01b03848116938201939093526000929091169063b92ae87c90602401602060405180830381865afa158015610503573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610527919061146d565b1561053457506001919050565b600554604051632e4aba1f60e21b81526001600160a01b0384811660048301529091169063b92ae87c90602401602060405180830381865afa15801561057e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105a2919061146d565b156105af57506000919050565b506002919050565b60006105c282610dcc565b600260008360028111156105d8576105d861131e565b60028111156105e9576105e961131e565b8152602001908152602001600020549050919050565b610607610b49565b6040514790339082156108fc029083906000818181858888f19350505050158015610636573d6000803e3d6000fd5b5050565b610642610b49565b6106368282610c24565b610654610b49565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b61067e610b49565b6106886000610e3c565b565b610692610b49565b600580546001600160a01b0319166001600160a01b0392909216919091179055565b60048054604051632e4aba1f60e21b81526001600160a01b03848116938201939093526000929091169063b92ae87c90602401602060405180830381865afa158015610704573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610728919061146d565b8061079c5750600554604051632e4aba1f60e21b81526001600160a01b0384811660048301529091169063b92ae87c90602401602060405180830381865afa158015610778573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061079c919061146d565b92915050565b60408051608081018252600080825260208201819052918101919091526060808201526040805160808101825260008082526002602080840191909152828401829052835190810184529081526060820152600480546005549351632e4aba1f60e21b81526001600160a01b0387811693820193909352929390821692911690819063b92ae87c90602401602060405180830381865afa15801561084a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061086e919061146d565b1561096857604051636d43da9d60e11b81526001600160a01b03868116600483015282169063da87b53a90602401602060405180830381865afa1580156108b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108dd919061148f565b604084015260018352600060208401819052506040516305f289dd60e21b81526001600160a01b0386811660048301528216906317ca277490602401600060405180830381865afa158015610936573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261095e91908101906114a8565b6060840152610ac7565b604051632e4aba1f60e21b81526001600160a01b03868116600483015283169063b92ae87c90602401602060405180830381865afa1580156109ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109d2919061146d565b15610ac757604051636d43da9d60e11b81526001600160a01b03868116600483015283169063da87b53a90602401602060405180830381865afa158015610a1d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a41919061148f565b6040840152600180845260208401819052506040516305f289dd60e21b81526001600160a01b0386811660048301528316906317ca277490602401600060405180830381865afa158015610a99573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ac191908101906114a8565b60608401525b50909392505050565b610ad8610b49565b6001600160a01b038116610b3d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610343565b610b4681610e3c565b50565b6000546001600160a01b031633146106885760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610343565b6003546000906001600160a01b0316610c1384610c0d856040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b90610e8c565b6001600160a01b0316149392505050565b610c2d826106b4565b15610c7a5760405162461bcd60e51b815260206004820152601960248201527f57414c4c45545f414c52454144595f53554253435249424544000000000000006044820152606401610343565b6001816002811115610c8e57610c8e61131e565b1415610cfb57600480546040516320d3b93560e11b81526001600160a01b03858116938201939093529116906341a7726a906024015b600060405180830381600087803b158015610cde57600080fd5b505af1158015610cf2573d6000803e3d6000fd5b50505050610d82565b6000816002811115610d0f57610d0f61131e565b1415610d47576005546040516320d3b93560e11b81526001600160a01b038481166004830152909116906341a7726a90602401610cc4565b60405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f5355425f5459504560801b6044820152606401610343565b806002811115610d9457610d9461131e565b6040516001600160a01b038416907f059489ce65642e6c094afec2c94486ad064070e20905e0c9f960dc85ddb0b38090600090a35050565b6000816002811115610de057610de061131e565b1480610dfd57506001816002811115610dfb57610dfb61131e565b145b610b465760405162461bcd60e51b815260206004820152601060248201526f494e56414c49445f5355425f5459504560801b6044820152606401610343565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000806000610e9b8585610eb0565b91509150610ea881610ef6565b509392505050565b600080825160411415610ee75760208301516040840151606085015160001a610edb878285856110b1565b94509450505050610eef565b506000905060025b9250929050565b6000816004811115610f0a57610f0a61131e565b1415610f135750565b6001816004811115610f2757610f2761131e565b1415610f755760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610343565b6002816004811115610f8957610f8961131e565b1415610fd75760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610343565b6003816004811115610feb57610feb61131e565b14156110445760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b6064820152608401610343565b60048160048111156110585761105861131e565b1415610b465760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b6064820152608401610343565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311156110e85750600090506003611195565b8460ff16601b1415801561110057508460ff16601c14155b156111115750600090506004611195565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015611165573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b03811661118e57600060019250925050611195565b9150600090505b94509492505050565b80356001600160a01b03811681146111b557600080fd5b919050565b6000602082840312156111cc57600080fd5b6111d58261119e565b9392505050565b8035600381106111b557600080fd5b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561122a5761122a6111eb565b604052919050565b600067ffffffffffffffff82111561124c5761124c6111eb565b50601f01601f191660200190565b60008060006060848603121561126f57600080fd5b611278846111dc565b925060208401359150604084013567ffffffffffffffff81111561129b57600080fd5b8401601f810186136112ac57600080fd5b80356112bf6112ba82611232565b611201565b8181528760208385010111156112d457600080fd5b816020840160208301376000602083830101528093505050509250925092565b6000806040838503121561130757600080fd5b611310836111dc565b946020939093013593505050565b634e487b7160e01b600052602160045260246000fd5b6003811061135257634e487b7160e01b600052602160045260246000fd5b9052565b6020810161079c8284611334565b60006020828403121561137657600080fd5b6111d5826111dc565b6000806040838503121561139257600080fd5b61139b8361119e565b91506113a9602084016111dc565b90509250929050565b60005b838110156113cd5781810151838201526020016113b5565b838111156113dc576000848401525b50505050565b60208152815115156020820152600060208301516114036040840182611334565b5060408301516060830152606083015160808084015280518060a08501526114328160c08601602085016113b2565b601f01601f19169290920160c0019392505050565b6000821982111561146857634e487b7160e01b600052601160045260246000fd5b500190565b60006020828403121561147f57600080fd5b815180151581146111d557600080fd5b6000602082840312156114a157600080fd5b5051919050565b6000602082840312156114ba57600080fd5b815167ffffffffffffffff8111156114d157600080fd5b8201601f810184136114e257600080fd5b80516114f06112ba82611232565b81815285602083850101111561150557600080fd5b6115168260208301602086016113b2565b9594505050505056fea2646970667358221220bdfa87b7211d3a86dbc25ed83ef96dd4c7b501c152e451d7382e2631297ad8cd64736f6c634300080c0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _red (address): 0x0000000000000000000000000000000000000000
Arg [1] : _gold (address): 0x0000000000000000000000000000000000000000
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 26 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.