Contract Overview
Balance: 0 Ether
Ether Value: $0
Transactions: 705 txns
 Latest 25 txns From a total of 705 Transactions

TxHash Age From To Value [TxFee]
0x69807a6eac3ee9d744dcd770e6bf35e058ba51bd75c0867e09aba98fc491e5e02 days 9 hrs ago0x4e764a1d088d4dbdc5566c164dec2c14fb0ded13  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000244596
0xce48af805617973c441cde1712e5d2694040560517c96f5934360c37e7192e973 days 5 hrs ago0x717dd8a85b67e9eef55cab3f8fa877545668003d  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000365166
0x32d3c0113f661ef95805d966ff5b63f93846f76a551a83b28537830f23edfc316 days 25 mins ago0x66c18ac12b1d4790939e84aa3476adfcd8284180  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000243788
0xee08a1207ecad0df86d2057503c743c90a9da90fa1530157ecb06a29ea155df76 days 9 hrs ago0x6acd05b717907ba4918c5293e0d8c327832783c2  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000366126
0x24e3eb57119fa7c6e5aa3fa4a56d12baf5915d6c73c248e3974d544a28d567417 days 3 hrs ago0xdf0f9bb2aa672682adf78d13e3781b3c251d4453  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000063882
0x2bbd0a4ef4e4e34f489f789cd02fe021e1eccb68d92ecbdfbabc4a824480b90c7 days 4 hrs ago0xdf0f9bb2aa672682adf78d13e3781b3c251d4453  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.00036549
0x40f24ee8d5ee51f71a586ebbd8895a94f286b4b9a8b83d4d1f1316e1844600c97 days 4 hrs ago0x55e8bb2adffb704fff861caeca211e7103227432  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70.01 Ether0.00021
0x2f6843fd350a5752204b28389776be97cc964d4ccfa133797481f410c960d26e7 days 12 hrs ago0x93cdb0a93fc36f6a53ed21ecf6305ab80d06beca  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.00060915
0xa2cd06caf73508b2a0f1e9de62c8ebe09f42b317c4b527f5c9fb8bf5e46a4dd08 days 39 mins ago0xb176fd3a9d84deea6e5cddbc96629420e4b41d3c  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000364398
0x558bb6ea10c9b8f23a314e590402f75cbbc44431b9e8eef24e9eeda852c0b62d9 days 19 hrs ago0xf5982c56554da213b71bcf137837d57559c53ed1  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000244812
0x1e68f280027deea8c1d25e2dee56cd088ff7b7c596425ebafe3ff0e77204275a9 days 23 hrs ago0x2d87120de3a5eecca208bbbf43a7ff53d65c7fd6  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.0000060851
0xd910de8d997f026299f7582e482c01979e967645b70ba3fe8f2ff535ca050e3e11 days 23 hrs ago0x1efac25945563516328b328bb92561eff44714f2  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000365166
0xa709a60999f5ab1ba51512bc1cd714cd1350b914319423c1e12b80f49ee349dc13 days 3 hrs ago0xcc09d45e3cdac675ccda6ec2cf8ac612b566fb99  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.00122554
0x19e82f33fd0d313b0157a4489629cb3bfd9bfc10b348b9b337bef1c0e64aae8a13 days 4 hrs ago0xefc96589c54674dbad515ff165d5951ec85164ac  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.0015953966
0x55ad92b2481f5557693c42948979a9ad6bdf53d54b01b91496628d8c4e345c5d13 days 4 hrs ago0xefc96589c54674dbad515ff165d5951ec85164ac  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.0013690208
0x55b56c670b5af1d3af7d91e596e6d4edab6184588c2bad23d167fea3e9310ee513 days 22 hrs ago0xefe65ffbe16e5a6017b3a3b0d88179f2c4cd1c38  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.001460664
0x537ef2cc32aca7e2a6e34ca41a965491045584e4cc4d8af80d12e34328815e6d13 days 22 hrs ago0xefe65ffbe16e5a6017b3a3b0d88179f2c4cd1c38  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.001342462
0x564d25c43c01fc77c6e673eda6dc3ee6588b57501087588599931d45d5b6833014 days 4 hrs ago0x67b84fc1b67fecec6a070a202a64a2694c59a109  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.001946208
0x9900818fcd4918fbb040779c500f80f6d45b5aa988f75ee1b824bc0f36596e7214 days 5 hrs ago0x06dbc2a657f7fea67a89c7f267bfcc722e014494  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.00243316
0xd54e517870ad933baa9437c074c06e3f691de5a91d979cc0a45efb99da81e7ae20 days 11 hrs ago0xf08debe207092d007b03cf66ebe94c3fa557fc12  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000733668
0xa82798766910896e29dacafa371e292d0c2ee12a5067d845d28636d3e11d4d6921 days 10 hrs ago0x6c15d0e99a7651450e8bcdab7d92ad1dc5123a54  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000365298
0x9ace7f096626ca469b57cc8c982d078f62f5a8fd88347d1ef42f51e15aecb8fe24 days 14 hrs ago0xccf5f5c462386c9055c5bf5d008681cf808799f1  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.00293208
0x2aa8321455119e04240cf2524c0aa2fc0e4a3d5f5b9b221e09c1988da59bc49224 days 14 hrs ago0xccf5f5c462386c9055c5bf5d008681cf808799f1  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.005836512
0xb7e980981bc3d8047ec5b715f966346b230dbb35619598af9207573c9bafb13f24 days 23 hrs ago0xb2853233e308fd574e82896c80a44f86e127ea24  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000255885
0x80f20f02359780e267342e8422faaa73f45719869fdf5ee66ba7abeabeb4c91625 days 8 hrs ago0x83e81d747529f0eb6145b149c438ab7f9bbd651c  IN   0xfa6512358d241b636edf5f8ccaaf86676dec21a70 Ether0.000729564
[ Download CSV Export  ] 
 Internal Transactions as a result of Contract Execution
 Latest 25 Internal Txns, Click Here To View More View All
ParentTxHash Block Age From To Value
0x406240b4ea12ae0322afcbc072ae5c2508ca49509d2f10bd054058093df5c00b627325441 days 1 hr ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.0027 Ether
0x406240b4ea12ae0322afcbc072ae5c2508ca49509d2f10bd054058093df5c00b627325441 days 1 hr ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xdecaf9cd2367cdbb726e904cd6397edfcae6068d0.0003 Ether
0xa4f724388006ed611d10becd9cf6ae3f532285a28d8c7723f51e5928a952974b621401951 days 49 mins ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.002565 Ether
0xa4f724388006ed611d10becd9cf6ae3f532285a28d8c7723f51e5928a952974b621401951 days 49 mins ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x052cd8f0423759e025e1a77e244e87f62eab9b320.000135 Ether
0xb1504064c57f38be5db35d4f487aca1fcbdeaa9908577471fe53b709464e93d7619520654 days 5 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.0027 Ether
0xb1504064c57f38be5db35d4f487aca1fcbdeaa9908577471fe53b709464e93d7619520654 days 5 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x052cd8f0423759e025e1a77e244e87f62eab9b320.0003 Ether
0x1d211761cf50a09749a9b8a4a87b8e7de9d4441e88890254b98634190cd464c2616876458 days 16 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.0027 Ether
0x1d211761cf50a09749a9b8a4a87b8e7de9d4441e88890254b98634190cd464c2616876458 days 16 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x0904dac3347ea47d208f3fd67402d039a3b998590.0003 Ether
0x1270cfc25c207c35cc33d71602d27fc6ea2f947dd9071a1a8762f3dc4b4b5745616502759 days 7 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.002565 Ether
0x1270cfc25c207c35cc33d71602d27fc6ea2f947dd9071a1a8762f3dc4b4b5745616502759 days 7 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x052cd8f0423759e025e1a77e244e87f62eab9b320.000135 Ether
0xbca22a650a7ec91877771bcc791122ec57228ba99d34751d5d25caeedcd7b0ff616432559 days 10 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xcbf177a8487b4fcdb9014c64b9b51a1af83cc05d0.00475 Ether
0xbca22a650a7ec91877771bcc791122ec57228ba99d34751d5d25caeedcd7b0ff616432559 days 10 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x052cd8f0423759e025e1a77e244e87f62eab9b320.00025 Ether
0xa28fa2447ef1670a4e1e9012bc59e48cc12a92b04735a2efe39e8fd7fe560034615431661 days 3 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xcbf177a8487b4fcdb9014c64b9b51a1af83cc05d0.00475 Ether
0xa28fa2447ef1670a4e1e9012bc59e48cc12a92b04735a2efe39e8fd7fe560034615431661 days 3 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x0904dac3347ea47d208f3fd67402d039a3b998590.00025 Ether
0xf96e4aeb3d006c0021c49d44f45f16972dd226515d7075952f9c5a87d5b04f5f613778163 days 22 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.002565 Ether
0xf96e4aeb3d006c0021c49d44f45f16972dd226515d7075952f9c5a87d5b04f5f613778163 days 22 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xdecaf9cd2367cdbb726e904cd6397edfcae6068d0.000135 Ether
0x365c2f5b383365c41fe5bfbaa8b8ce82353948e2df30737e5be6f74ff0f647a9613754663 days 23 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xcbf177a8487b4fcdb9014c64b9b51a1af83cc05d0.00475 Ether
0x365c2f5b383365c41fe5bfbaa8b8ce82353948e2df30737e5be6f74ff0f647a9613754663 days 23 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x0904dac3347ea47d208f3fd67402d039a3b998590.00025 Ether
0x692e081ed13436a2777c8f222c6c285c6d40ebe50ac36dcdfca99da23d71988f613068765 days 3 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.0027 Ether
0x692e081ed13436a2777c8f222c6c285c6d40ebe50ac36dcdfca99da23d71988f613068765 days 3 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x0904dac3347ea47d208f3fd67402d039a3b998590.0003 Ether
0x68e1cf5b39d7ed29ad5ad34849a528ee11b4a55af818c30ac5787f7bfa0637c8612865765 days 11 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xcbf177a8487b4fcdb9014c64b9b51a1af83cc05d0.00475 Ether
0x68e1cf5b39d7ed29ad5ad34849a528ee11b4a55af818c30ac5787f7bfa0637c8612865765 days 11 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x052cd8f0423759e025e1a77e244e87f62eab9b320.00025 Ether
0xc7bc3a0f180687b5b436bf26c8cc4b719d1b1be6b75e299ac9b979eaf1001e3b611771967 days 7 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.0027 Ether
0xc7bc3a0f180687b5b436bf26c8cc4b719d1b1be6b75e299ac9b979eaf1001e3b611771967 days 7 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70x0904dac3347ea47d208f3fd67402d039a3b998590.0003 Ether
0x47720b857c1c1c6fd543ea3f6e55f84159472300dcf884f535492887359fe59d606102376 days 21 hrs ago0xfa6512358d241b636edf5f8ccaaf86676dec21a70xe08c5c6d17be3ab837b421723e9215bb9902c9f10.0027 Ether
[ Download CSV Export  ] 
Warning: The Compiled Contract might be susceptible to ExpExponentCleanup (medium/high-severity), EventStructWrongData (very low-severity), NestedArrayFunctionCallDecoder (medium-severity) SolidityCompiler Bugs.

Contract Source Code Verified (Exact Match)
Contract Name: SubdomainRegistrar
Compiler Text: v0.4.18+commit.9cf6e910
Optimization Enabled: No
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts

pragma solidity ^0.4.4;

/**
 * The ENS registry contract.
 */
contract ENS {
    // Logged when the owner of a node assigns a new owner to a subnode.
    event NewOwner(bytes32 indexed node, bytes32 indexed label, address owner);

    // Logged when the owner of a node transfers ownership to a new account.
    event Transfer(bytes32 indexed node, address owner);

    // Logged when the resolver for a node changes.
    event NewResolver(bytes32 indexed node, address resolver);

    // Logged when the TTL of a node changes
    event NewTTL(bytes32 indexed node, uint64 ttl);

    struct Record {
        address owner;
        address resolver;
        uint64 ttl;
    }

    mapping(bytes32=>Record) records;

    // Permits modifications only by the owner of the specified node.
    modifier only_owner(bytes32 node) {
        if (records[node].owner != msg.sender) throw;
        _;
    }

    /**
     * Constructs a new ENS registrar.
     */
    function ENS() {
        records[0].owner = msg.sender;
    }

    /**
     * Returns the address that owns the specified node.
     */
    function owner(bytes32 node) constant returns (address) {
        return records[node].owner;
    }

    /**
     * Returns the address of the resolver for the specified node.
     */
    function resolver(bytes32 node) constant returns (address) {
        return records[node].resolver;
    }

    /**
     * Returns the TTL of a node, and any records associated with it.
     */
    function ttl(bytes32 node) constant returns (uint64) {
        return records[node].ttl;
    }

    /**
     * Transfers ownership of a node to a new address. May only be called by the current
     * owner of the node.
     * @param node The node to transfer ownership of.
     * @param owner The address of the new owner.
     */
    function setOwner(bytes32 node, address owner) only_owner(node) {
        Transfer(node, owner);
        records[node].owner = owner;
    }

    /**
     * Transfers ownership of a subnode sha3(node, label) to a new address. May only be
     * called by the owner of the parent node.
     * @param node The parent node.
     * @param label The hash of the label specifying the subnode.
     * @param owner The address of the new owner.
     */
    function setSubnodeOwner(bytes32 node, bytes32 label, address owner) only_owner(node) {
        var subnode = sha3(node, label);
        NewOwner(node, label, owner);
        records[subnode].owner = owner;
    }

    /**
     * Sets the resolver address for the specified node.
     * @param node The node to update.
     * @param resolver The address of the resolver.
     */
    function setResolver(bytes32 node, address resolver) only_owner(node) {
        NewResolver(node, resolver);
        records[node].resolver = resolver;
    }

    /**
     * Sets the TTL for the specified node.
     * @param node The node to update.
     * @param ttl The TTL in seconds.
     */
    function setTTL(bytes32 node, uint64 ttl) only_owner(node) {
        NewTTL(node, ttl);
        records[node].ttl = ttl;
    }
}

/**
 * @dev A basic interface for ENS resolvers.
 */
contract Resolver {
  function supportsInterface(bytes4 interfaceID) public pure returns (bool);
  function addr(bytes32 node) public view returns (address);
  function setAddr(bytes32 node, address addr) public;
}

contract RegistrarInterface {
  event OwnerChanged(bytes32 indexed label, address indexed oldOwner, address indexed newOwner);
  event DomainConfigured(bytes32 indexed label);
  event DomainUnlisted(bytes32 indexed label);
  event NewRegistration(bytes32 indexed label, string subdomain, address indexed owner, address indexed referrer, uint price);
  event RentPaid(bytes32 indexed label, string subdomain, uint amount, uint expirationDate);

  // InterfaceID of these four methods is 0xc1b15f5a
  function query(bytes32 label, string subdomain) view returns(string domain, uint signupFee, uint rent, uint referralFeePPM);
  function register(bytes32 label, string subdomain, address owner, address referrer, address resolver) public payable;

  function rentDue(bytes32 label, string subdomain) public view returns(uint timestamp);
  function payRent(bytes32 label, string subdomain) public payable;
}
/**
 * @dev Implements an ENS registrar that sells subdomains on behalf of their owners.
 *
 * Users may register a subdomain by calling `register` with the name of the domain
 * they wish to register under, and the label hash of the subdomain they want to
 * register. They must also specify the new owner of the domain, and the referrer,
 * who is paid an optional finder's fee. The registrar then configures a simple
 * default resolver, which resolves `addr` lookups to the new owner, and sets
 * the `owner` account as the owner of the subdomain in ENS.
 *
 * New domains may be added by calling `configureDomain`, then transferring
 * ownership in the ENS registry to this contract. Ownership in the contract
 * may be transferred using `transfer`, and a domain may be unlisted for sale
 * using `unlistDomain`. There is (deliberately) no way to recover ownership
 * in ENS once the name is transferred to this registrar.
 *
 * Critically, this contract does not check two key properties of a listed domain:
 *
 * - Is the name UTS46 normalised?
 * - Is the Deed held by an appropriate custodian contract?
 *
 * User applications MUST check these two elements for each domain before
 * offering them to users for registration.
 *
 * Applications should additionally check that the domains they are offering to
 * register are controlled by this registrar, since calls to `register` will
 * fail if this is not the case.
 */
contract SubdomainRegistrar is RegistrarInterface {
  // namehash('eth')
  bytes32 constant public TLD_NODE = 0x93cdeb708b7545dc668eb9280176169d1c33cfd8ed6f04690a0bcc88a93fc4ae;

  ENS public ens;

  struct Domain {
    string name;
    address owner;
    uint price;
    uint referralFeePPM;
  }

  mapping(bytes32=>Domain) domains;

  function SubdomainRegistrar(ENS _ens) public {
    ens = _ens;
  }

  /**
   * @dev owner returns the address of the account that controls a domain.
   *      Initially this is the owner of the name in ENS. If the name has been
   *      transferred to this contract, then the internal mapping is consulted
   *      to determine who controls it.
   * @param label The label hash of the deed to check.
   * @return The address owning the deed.
   */
  function owner(bytes32 label) public view returns(address ret) {
      ret = ens.owner(keccak256(TLD_NODE, label));
      if(ret == address(this)) {
        ret = domains[label].owner;
      }
  }

  modifier owner_only(bytes32 label) {
      require(owner(label) == msg.sender);
      _;
  }

  /**
   * @dev Transfers internal control of a name to a new account. Does not update
   *      ENS.
   * @param name The name to transfer.
   * @param newOwner The address of the new owner.
   */
  function transfer(string name, address newOwner) public owner_only(keccak256(name)) {
    var label = keccak256(name);
    OwnerChanged(keccak256(name), domains[label].owner, newOwner);
    domains[label].owner = newOwner;
  }

  /**
   * @dev Sets the resolver record for a name in ENS.
   * @param name The name to set the resolver for.
   * @param resolver The address of the resolver
   */
  function setResolver(string name, address resolver) public owner_only(keccak256(name)) {
    var label = keccak256(name);
    var node = keccak256(TLD_NODE, label);
    ens.setResolver(node, resolver);
  }

  /**
   * @dev Configures a domain for sale.
   * @param name The name to configure.
   * @param price The price in wei to charge for subdomain registrations
   * @param referralFeePPM The referral fee to offer, in parts per million
   */
  function configureDomain(string name, uint price, uint referralFeePPM) public owner_only(keccak256(name)) {
    var label = keccak256(name);
    var domain = domains[label];

    if(keccak256(domain.name) != label) {
      // New listing
      domain.name = name;
    }
    if(domain.owner != msg.sender) {
      domain.owner = msg.sender;
    }
    domain.price = price;
    domain.referralFeePPM = referralFeePPM;
    DomainConfigured(label);
  }

  /**
   * @dev Unlists a domain
   * May only be called by the owner.
   * @param name The name of the domain to unlist.
   */
  function unlistDomain(string name) public owner_only(keccak256(name)) {
    var label = keccak256(name);
    var domain = domains[label];
    DomainUnlisted(label);

    domain.name = '';
    domain.owner = owner(label);
    domain.price = 0;
    domain.referralFeePPM = 0;
  }

  /**
   * @dev Returns information about a subdomain.
   * @param label The label hash for the domain.
   * @param subdomain The label for the subdomain.
   * @return domain The name of the domain, or an empty string if the subdomain
   *                is unavailable.
   * @return price The price to register a subdomain, in wei.
   * @return rent The rent to retain a subdomain, in wei per second.
   * @return referralFeePPM The referral fee for the dapp, in ppm.
   */
  function query(bytes32 label, string subdomain) view returns(string domain, uint price, uint rent, uint referralFeePPM) {
    var node = keccak256(TLD_NODE, label);
    var subnode = keccak256(node, keccak256(subdomain));

    if(ens.owner(subnode) != 0) {
      return ('', 0, 0, 0);
    }

    var data = domains[label];
    return (data.name, data.price, 0, data.referralFeePPM);
  }

  /**
   * @dev Registers a subdomain.
   * @param label The label hash of the domain to register a subdomain of.
   * @param subdomain The desired subdomain label.
   * @param subdomainOwner The account that should own the newly configured subdomain.
   * @param referrer The address of the account to receive the referral fee.
   */
  function register(bytes32 label, string subdomain, address subdomainOwner, address resolver, address referrer) public payable {
    var domainNode = keccak256(TLD_NODE, label);
    var subdomainLabel = keccak256(subdomain);

    // Subdomain must not be registered already.
    require(ens.owner(keccak256(domainNode, subdomainLabel)) == address(0));

    var domain = domains[label];

    // Domain must be available for registration
    require(keccak256(domain.name) == label);

    // User must have paid enough
    require(msg.value >= domain.price);

    // Send any extra back
    if(msg.value > domain.price) {
      msg.sender.transfer(msg.value - domain.price);
    }

    // Send any referral fee
    var total = domain.price;
    if(domain.referralFeePPM * domain.price > 0 && referrer != 0 && referrer != domain.owner) {
      var referralFee = (domain.price * domain.referralFeePPM) / 1000000;
      referrer.transfer(referralFee);
      total -= referralFee;
    }

    // Send the registration fee
    if(total > 0) {
      domain.owner.transfer(total);
    }

    // Register the domain
    if(subdomainOwner == 0) {
      subdomainOwner = msg.sender;
    }
    doRegistration(domainNode, subdomainLabel, subdomainOwner, Resolver(resolver));

    NewRegistration(label, subdomain, subdomainOwner, referrer, domain.price);
  }

  function doRegistration(bytes32 node, bytes32 label, address subdomainOwner, Resolver resolver) internal {
    // Get the subdomain so we can configure it
    ens.setSubnodeOwner(node, label, this);

    var subnode = keccak256(node, label);
    // Set the subdomain's resolver
    ens.setResolver(subnode, resolver);

    // Set the address record on the resolver
    resolver.setAddr(subnode, subdomainOwner);

    // Pass ownership of the new subdomain to the registrant
    ens.setOwner(subnode, subdomainOwner);
  }

  function supportsInterface(bytes4 interfaceID) constant returns (bool) {
    return (
         (interfaceID == 0x01ffc9a7) // supportsInterface(bytes4)
      || (interfaceID == 0xc1b15f5a) // RegistrarInterface
    );
  }

  function rentDue(bytes32 label, string subdomain) public view returns(uint timestamp) {
    return 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF;
  }

  function payRent(bytes32 label, string subdomain) public payable {
    revert();
  }
}

    Contract ABI  
[{"constant":true,"inputs":[{"name":"interfaceID","type":"bytes4"}],"name":"supportsInterface","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"label","type":"bytes32"}],"name":"owner","outputs":[{"name":"ret","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"label","type":"bytes32"},{"name":"subdomain","type":"string"}],"name":"query","outputs":[{"name":"domain","type":"string"},{"name":"price","type":"uint256"},{"name":"rent","type":"uint256"},{"name":"referralFeePPM","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"ens","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"label","type":"bytes32"},{"name":"subdomain","type":"string"},{"name":"subdomainOwner","type":"address"},{"name":"resolver","type":"address"},{"name":"referrer","type":"address"}],"name":"register","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[{"name":"label","type":"bytes32"},{"name":"subdomain","type":"string"}],"name":"rentDue","outputs":[{"name":"timestamp","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"name","type":"string"},{"name":"resolver","type":"address"}],"name":"setResolver","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"TLD_NODE","outputs":[{"name":"","type":"bytes32"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"label","type":"bytes32"},{"name":"subdomain","type":"string"}],"name":"payRent","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":false,"inputs":[{"name":"name","type":"string"},{"name":"price","type":"uint256"},{"name":"referralFeePPM","type":"uint256"}],"name":"configureDomain","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"name","type":"string"}],"name":"unlistDomain","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"name","type":"string"},{"name":"newOwner","type":"address"}],"name":"transfer","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"inputs":[{"name":"_ens","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"name":"label","type":"bytes32"},{"indexed":true,"name":"oldOwner","type":"address"},{"indexed":true,"name":"newOwner","type":"address"}],"name":"OwnerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"label","type":"bytes32"}],"name":"DomainConfigured","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"label","type":"bytes32"}],"name":"DomainUnlisted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"label","type":"bytes32"},{"indexed":false,"name":"subdomain","type":"string"},{"indexed":true,"name":"owner","type":"address"},{"indexed":true,"name":"referrer","type":"address"},{"indexed":false,"name":"price","type":"uint256"}],"name":"NewRegistration","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"label","type":"bytes32"},{"indexed":false,"name":"subdomain","type":"string"},{"indexed":false,"name":"amount","type":"uint256"},{"indexed":false,"name":"expirationDate","type":"uint256"}],"name":"RentPaid","type":"event"}]

  Contract Creation Code Switch To Opcodes View
6060604052341561000f57600080fd5b604051602080611f8883398101604052808051906020019091905050806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050611f0d8061007b6000396000f3006060604052600436106100ba576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806301ffc9a7146100bf57806302571be3146101195780632eef3d65146101805780633f15457f146102785780634254b155146102cd578063660b7ad514610389578063733ccaba1461040757806396df354014610483578063cb01a9bf146104b4578063da1fe7d514610513578063e34e788914610582578063fbf58b3e146105df575b600080fd5b34156100ca57600080fd5b6100ff60048080357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690602001909190505061065b565b604051808215151515815260200191505060405180910390f35b341561012457600080fd5b61013e6004808035600019169060200190919050506106f5565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b341561018b57600080fd5b6101e860048080356000191690602001909190803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509190505061087f565b6040518080602001858152602001848152602001838152602001828103825286818151815260200191508051906020019080838360005b8381101561023a57808201518184015260208101905061021f565b50505050905090810190601f1680156102675780820380516001836020036101000a031916815260200191505b509550505050505060405180910390f35b341561028357600080fd5b61028b610b5f565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61038760048080356000191690602001909190803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509190803573ffffffffffffffffffffffffffffffffffffffff1690602001909190803573ffffffffffffffffffffffffffffffffffffffff1690602001909190803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610b84565b005b341561039457600080fd5b6103f160048080356000191690602001909190803590602001908201803590602001908080601f016020809104026020016040519081016040528093929190818152602001838380828437820191505050505050919050506110e8565b6040518082815260200191505060405180910390f35b341561041257600080fd5b610481600480803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509190803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050611113565b005b341561048e57600080fd5b610496611359565b60405180826000191660001916815260200191505060405180910390f35b61051160048080356000191690602001909190803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091905050611380565b005b341561051e57600080fd5b610580600480803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091908035906020019091908035906020019091905050611385565b005b341561058d57600080fd5b6105dd600480803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509190505061162d565b005b34156105ea57600080fd5b610659600480803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509190803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050611816565b005b60006301ffc9a77c010000000000000000000000000000000000000000000000000000000002827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614806106ee575063c1b15f5a7c010000000000000000000000000000000000000000000000000000000002827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b9050919050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166302571be37f93cdeb708b7545dc668eb9280176169d1c33cfd8ed6f04690a0bcc88a93fc4ae6001028460405180836000191660001916815260200182600019166000191681526020019250505060405180910390206000604051602001526040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808260001916600019168152602001915050602060405180830381600087803b15156107e757600080fd5b6102c65a03f115156107f857600080fd5b5050506040518051905090503073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141561087a5760016000836000191660001916815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690505b919050565b610887611e28565b6000806000806000807f93cdeb708b7545dc668eb9280176169d1c33cfd8ed6f04690a0bcc88a93fc4ae600102896040518083600019166000191681526020018260001916600019168152602001925050506040518091039020925082886040518082805190602001908083835b60208310151561091a57805182526020820191506020810190506020830392506108f5565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390206040518083600019166000191681526020018260001916600019168152602001925050506040518091039020915060008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166302571be3846000604051602001526040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808260001916600019168152602001915050602060405180830381600087803b1515610a1757600080fd5b6102c65a03f11515610a2857600080fd5b5050506040518051905073ffffffffffffffffffffffffffffffffffffffff16141515610a7e57600080600060206040519081016040528060008152509291908292508191508090509650965096509650610b53565b600160008a60001916600019168152602001908152602001600020905080600001816002015460008360030154838054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610b405780601f10610b1557610100808354040283529160200191610b40565b820191906000526020600020905b815481529060010190602001808311610b2357829003601f168201915b5050505050935081915096509650965096505b50505092959194509250565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008060008060007f93cdeb708b7545dc668eb9280176169d1c33cfd8ed6f04690a0bcc88a93fc4ae6001028a60405180836000191660001916815260200182600019166000191681526020019250505060405180910390209450886040518082805190602001908083835b602083101515610c155780518252602082019150602081019050602083039250610bf0565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390209350600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166302571be3878760405180836000191660001916815260200182600019166000191681526020019250505060405180910390206000604051602001526040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808260001916600019168152602001915050602060405180830381600087803b1515610d2957600080fd5b6102c65a03f11515610d3a57600080fd5b5050506040518051905073ffffffffffffffffffffffffffffffffffffffff16141515610d6657600080fd5b600160008b6000191660001916815260200190815260200160002092508960001916836000016040518082805460018160011615610100020316600290048015610de75780601f10610dc5576101008083540402835291820191610de7565b820191906000526020600020905b815481529060010190602001808311610dd3575b5050915050604051809103902060001916141515610e0457600080fd5b82600201543410151515610e1757600080fd5b8260020154341115610e6a573373ffffffffffffffffffffffffffffffffffffffff166108fc846002015434039081150290604051600060405180830381858888f193505050501515610e6957600080fd5b5b8260020154915060008360020154846003015402118015610ea2575060008673ffffffffffffffffffffffffffffffffffffffff1614155b8015610efe57508260010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614155b15610f6457620f42408360030154846002015402811515610f1b57fe5b0490508573ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f193505050501515610f5e57600080fd5b80820391505b6000821115610fd2578260010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108fc839081150290604051600060405180830381858888f193505050501515610fd157600080fd5b5b60008873ffffffffffffffffffffffffffffffffffffffff161415610ff5573397505b61100185858a8a611a84565b8573ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff168b600019167ffa38f9920801763ca6e4ee19135fb26a4fa11c0a34f7117455064991a1a3e6588c87600201546040518080602001838152602001828103825284818151815260200191508051906020019080838360005b838110156110a1578082015181840152602081019050611086565b50505050905090810190601f1680156110ce5780820380516001836020036101000a031916815260200191505b50935050505060405180910390a450505050505050505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff905092915050565b600080836040518082805190602001908083835b60208310151561114c5780518252602082019150602081019050602083039250611127565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390203373ffffffffffffffffffffffffffffffffffffffff16611199826106f5565b73ffffffffffffffffffffffffffffffffffffffff161415156111bb57600080fd5b846040518082805190602001908083835b6020831015156111f157805182526020820191506020810190506020830392506111cc565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051809103902092507f93cdeb708b7545dc668eb9280176169d1c33cfd8ed6f04690a0bcc88a93fc4ae60010283604051808360001916600019168152602001826000191660001916815260200192505050604051809103902091506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631896f70a83866040518363ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004018083600019166000191681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b151561133e57600080fd5b6102c65a03f1151561134f57600080fd5b5050505050505050565b7f93cdeb708b7545dc668eb9280176169d1c33cfd8ed6f04690a0bcc88a93fc4ae60010281565b600080fd5b600080846040518082805190602001908083835b6020831015156113be5780518252602082019150602081019050602083039250611399565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390203373ffffffffffffffffffffffffffffffffffffffff1661140b826106f5565b73ffffffffffffffffffffffffffffffffffffffff1614151561142d57600080fd5b856040518082805190602001908083835b602083101515611463578051825260208201915060208101905060208303925061143e565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390209250600160008460001916600019168152602001908152602001600020915082600019168260000160405180828054600181600116156101000203166002900480156115135780601f106114f1576101008083540402835291820191611513565b820191906000526020600020905b8154815290600101906020018083116114ff575b50509150506040518091039020600019161415156115455785826000019080519060200190611543929190611e3c565b505b3373ffffffffffffffffffffffffffffffffffffffff168260010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415156115e257338260010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b84826002018190555083826003018190555082600019167f1427993bb6b6c16d8953c450c37078c8f41196e2e2db1619cda06620143e2d9160405160405180910390a2505050505050565b600080826040518082805190602001908083835b6020831015156116665780518252602082019150602081019050602083039250611641565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390203373ffffffffffffffffffffffffffffffffffffffff166116b3826106f5565b73ffffffffffffffffffffffffffffffffffffffff161415156116d557600080fd5b836040518082805190602001908083835b60208310151561170b57805182526020820191506020810190506020830392506116e6565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390209250600160008460001916600019168152602001908152602001600020915082600019167f77f7b610de5055c8f704e6a3b12874468f5785f3a7d1007b67a8a4b4c7ed88fc60405160405180910390a260206040519081016040528060008152508260000190805190602001906117b0929190611e3c565b506117ba836106f5565b8260010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600082600201819055506000826003018190555050505050565b6000826040518082805190602001908083835b60208310151561184e5780518252602082019150602081019050602083039250611829565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390203373ffffffffffffffffffffffffffffffffffffffff1661189b826106f5565b73ffffffffffffffffffffffffffffffffffffffff161415156118bd57600080fd5b836040518082805190602001908083835b6020831015156118f357805182526020820191506020810190506020830392506118ce565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051809103902091508273ffffffffffffffffffffffffffffffffffffffff1660016000846000191660001916815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16856040518082805190602001908083835b6020831015156119c4578051825260208201915060208101905060208303925061199f565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040518091039020600019167f06e9c07310f63759634ddbb7257dbb19ca404f90bd6bdef1d3386fab033cebce60405160405180910390a48260016000846000191660001916815260200190815260200160002060010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166306ab59238686306040518463ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040180846000191660001916815260200183600019166000191681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019350505050600060405180830381600087803b1515611b6157600080fd5b6102c65a03f11515611b7257600080fd5b5050508484604051808360001916600019168152602001826000191660001916815260200192505050604051809103902090506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631896f70a82846040518363ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004018083600019166000191681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b1515611c7057600080fd5b6102c65a03f11515611c8157600080fd5b5050508173ffffffffffffffffffffffffffffffffffffffff1663d5fa2b0082856040518363ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004018083600019166000191681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b1515611d2e57600080fd5b6102c65a03f11515611d3f57600080fd5b5050506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635b0fc9c382856040518363ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004018083600019166000191681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b1515611e0d57600080fd5b6102c65a03f11515611e1e57600080fd5b5050505050505050565b602060405190810160405280600081525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10611e7d57805160ff1916838001178555611eab565b82800160010185558215611eab579182015b82811115611eaa578251825591602001919060010190611e8f565b5b509050611eb89190611ebc565b5090565b611ede91905b80821115611eda576000816000905550600101611ec2565b5090565b905600a165627a7a7230582041a6435dd93573935c3578cc0f72e50c975bca17258053e2ace2e23c9954730d0029000000000000000000000000314159265dd8dbb310642f98f50c066173c1259b

    Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000314159265dd8dbb310642f98f50c066173c1259b

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000314159265dd8dbb310642f98f50c066173c1259b


   Swarm Source:
bzzr://41a6435dd93573935c3578cc0f72e50c975bca17258053e2ace2e23c9954730d

 

View All
Block Age transaction Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.