Contract

0xF0168Da5adfbBaE45e652736d593476523d2AB7d

Overview

S Balance

Sonic LogoSonic LogoSonic Logo0 S

S Value

-

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To

There are no matching entries

Please try again later

Parent Transaction Hash Block From To
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
ReferralReader

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 14 runs

Other Settings:
istanbul EvmVersion, MIT license
File 1 of 2 : ReferralReader.sol
// SPDX-License-Identifier: MIT

pragma solidity 0.6.12;

import "./interfaces/IReferralStorage.sol";

contract ReferralReader {
    function getCodeOwners(IReferralStorage _referralStorage, bytes32[] memory _codes) public view returns (address[] memory) {
        address[] memory owners = new address[](_codes.length);

        for (uint256 i = 0; i < _codes.length; i++) {
            bytes32 code = _codes[i];
            owners[i] = _referralStorage.codeOwners(code);
        }

        return owners;
    }
}

File 2 of 2 : IReferralStorage.sol
// SPDX-License-Identifier: MIT

pragma solidity 0.6.12;

interface IReferralStorage {
    function codeOwners(bytes32 _code) external view returns (address);
    function traderReferralCodes(address _account) external view returns (bytes32);
    function referrerDiscountShares(address _account) external view returns (uint256);
    function referrerTiers(address _account) external view returns (uint256);
    function getTraderReferralInfo(address _account) external view returns (bytes32, address);
    function setTraderReferralCode(address _account, bytes32 _code) external;
    function setTier(uint256 _tierId, uint256 _totalRebate, uint256 _discountShare) external;
    function setReferrerTier(address _referrer, uint256 _tierId) external;
    function govSetCodeOwner(bytes32 _code, address _newAccount) external;
}

Settings
{
  "evmVersion": "istanbul",
  "libraries": {},
  "metadata": {
    "bytecodeHash": "ipfs",
    "useLiteralContent": true
  },
  "optimizer": {
    "enabled": true,
    "runs": 14
  },
  "remappings": [],
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract IReferralStorage","name":"_referralStorage","type":"address"},{"internalType":"bytes32[]","name":"_codes","type":"bytes32[]"}],"name":"getCodeOwners","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b50610279806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c80630f6803c014610030575b600080fd5b6100e16004803603604081101561004657600080fd5b6001600160a01b038235169190810190604081016020820135600160201b81111561007057600080fd5b82018360208201111561008257600080fd5b803590602001918460208302840111600160201b831117156100a357600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550610131945050505050565b60408051602080825283518183015283519192839290830191858101910280838360005b8381101561011d578181015183820152602001610105565b505050509050019250505060405180910390f35b60608082516001600160401b038111801561014b57600080fd5b50604051908082528060200260200182016040528015610175578160200160208202803683370190505b50905060005b835181101561023b57600084828151811061019257fe5b60200260200101519050856001600160a01b031663c8b3c460826040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156101e057600080fd5b505afa1580156101f4573d6000803e3d6000fd5b505050506040513d602081101561020a57600080fd5b5051835184908490811061021a57fe5b6001600160a01b03909216602092830291909101909101525060010161017b565b50939250505056fea2646970667358221220c3ee624f60dba69803232860274ad34669abc4da1093b59009fd876f73f54c1b64736f6c634300060c0033

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061002b5760003560e01c80630f6803c014610030575b600080fd5b6100e16004803603604081101561004657600080fd5b6001600160a01b038235169190810190604081016020820135600160201b81111561007057600080fd5b82018360208201111561008257600080fd5b803590602001918460208302840111600160201b831117156100a357600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550610131945050505050565b60408051602080825283518183015283519192839290830191858101910280838360005b8381101561011d578181015183820152602001610105565b505050509050019250505060405180910390f35b60608082516001600160401b038111801561014b57600080fd5b50604051908082528060200260200182016040528015610175578160200160208202803683370190505b50905060005b835181101561023b57600084828151811061019257fe5b60200260200101519050856001600160a01b031663c8b3c460826040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156101e057600080fd5b505afa1580156101f4573d6000803e3d6000fd5b505050506040513d602081101561020a57600080fd5b5051835184908490811061021a57fe5b6001600160a01b03909216602092830291909101909101525060010161017b565b50939250505056fea2646970667358221220c3ee624f60dba69803232860274ad34669abc4da1093b59009fd876f73f54c1b64736f6c634300060c0033

Block Transaction Gas Used Reward
view all blocks produced

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

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits

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.