Giter VIP home page Giter VIP logo

tns's Introduction

TomoChain Name Service

πŸ“–πŸ” Documents of the TomoChain Name Service.

Overview

πŸ’‘ What is TomoChain?

TomoChain is a public blockchain for dApps. The mission is to be a leading force in building the Internet of Value, designing its infrastructure and working to create an alternative financial system which is more secure, transparent, efficient, inclusive and equitable for everyone.

πŸ’‘ What is BNS?

BNS – or blockchain name system – is the protocol on the internet that turns human-comprehensible decentralized website names such as β€˜website.perl’ or β€˜mywebsite.eth’ into addresses understandable by decentralized network machines.

πŸ“ Description

TNS is the TomoChain Name Service, a distributed, open, and extensible naming system based on the TomoChain blockchain.

πŸ“š Documents

Table of Contents

πŸ“ Guideline

πŸ—‚οΈ TomoChain Technical Stack

TomoChain Name Service (TNS) is governed by three smart contract components, registrar, registry, and resolver. The three smart contracts contain the core logic for the TomoChain Name Service implementation, from the ownership managment for a domain, to the global resolving layer that is reposible for connecting different tech stacks and enhances the usability for different infrastructures. TomoChain Tech Stack

State Layer

State layer is where user’s β€œstate”, or user’s information and behavior, is stored. TomoChain is where these data are stored, and gives users the ability to control their own state. TomoChain State

Computation Layer

TomoChain uses EVM (Ethereum Virtual Machine) in its computation layer, which is responsible for executing complicated calculations. It is in charge of managing, checking the code of smart contract on TomoChain. When a transaction occurs on TomoChain, the logic designed in EVM will determine its path that cannot be altered. Portal Network will be deploying TNS (Smart Contract Standard) on this layer that consists 3 major components. TomoChain Computation

Component Layer

The design of digital assets can have more functions through combing the State Layer and Computation Layer, such as : crypto assets, and identities. Those programmable assets has many more potential usages and sub-economies within. TNS includes three major component:

A registry component stores all the information relative to a domain, and can operate the set of logics to map between the TomoChain domains and its owners. A registrar component governs the domain purchase through the customized auction or trading rules. A resolver component processes the corresponding resources from wallet address to decentralized application or website on TomoChain. TomoChain Component

Protocol Layer

On the Protocol Layer, we will be presenting our BNS (Blockchain Name Service) standards that can make the TNS more efficient and applicable. With the state, computation and component layers behind the scene, protocol layer serve as a gateway for users and developers to interact with our TNS standard. TomoChain Protocol

User Control Layer

User control layer is in charge of managing private keys to communicate with the state layer. TNS empowers users to control, set up and manage their digital asset with an easier and readable text, which could be further utilized in the next application layer. TomoChain User

Application Layer

TNS can be implemented into many other applications on TomoChain, such as wallet that can resolve TNS, dApp that utilize TNS for users identity and many more. We believe that it is an essential components to provide a better environment for both technical and non-technical users. TomoChain Application

βš™οΈ TNS smart contract test coverage

Continuous updating

Coverage

Launched testrpc on port 8555
Running: truffle test
(this can take a few seconds)...
Using network 'development'.



  Contract: TNS
    βœ“ should allow registration of names (103ms)
    βœ“ should register a domain (125ms)
    βœ“ should check resolver interfaces (99ms)
    βœ“ should not support a random interface
    βœ“ should set resolver for node (138ms)
    βœ“ should set text (207ms)
    βœ“ should set address (185ms)
    βœ“ should set multihash (200ms)


  8 passing (3s)

-------------------|----------|----------|----------|----------|----------------|
File               |  % Stmts | % Branch |  % Funcs |  % Lines |Uncovered Lines |
-------------------|----------|----------|----------|----------|----------------|
 contracts/        |       75 |       50 |       76 |     77.5 |                |
  TNS.sol          |      100 |      100 |      100 |      100 |                |
  TNSRegistrar.sol |      100 |       50 |      100 |      100 |                |
  TNSRegistry.sol  |    78.57 |       50 |    77.78 |       80 |       68,69,96 |
  TNSResolver.sol  |    66.67 |       50 |    69.23 |    68.42 |... ,99,130,141 |
-------------------|----------|----------|----------|----------|----------------|
All files          |       75 |       50 |       76 |     77.5 |                |
-------------------|----------|----------|----------|----------|----------------|

Istanbul coverage reports generated
Cleaning up...
Shutting down testrpc-sc (pid 83549)
Done.

🎯 TNS Deploy

TNS Contracts

TNS Contract Network Contract Address Transaction Hash
Registry Testnet 0xdf9e5ce912412ab6af0dd46acff0ffc112bbe36e 0x971c1ae1ccc10bf97bdebf24deb455362d847011d3cccb6fd517dd0e974ec490
Registrar Testnet 0xb4cc8deec867c8352ec8f86afc945590629ae260 0xdf41eb54713ba8c931ef9c64a677b55759ee874606f3bb51e9b0f52434e68014
Resolver Testnet 0x89e77b691c8e3718b808015dbca094d35d7c37cc 0xd66e858bbde4f95e30886c1d4d9dbaa76ea14d85628db4dcb50d087a8a86de22

Claim TOMO from faucet

Link: https://faucet.testnet.tomochain.com/

Faucet

Smart contract Deploy

Source code compiler tool

Publish and verify by Tomoscan

Step 1. Send transaction through myetherwallet

Paste the bytecode from Remix of the smart contract MyEtherWallet

Step 2. Check the transaction hash of smart contract

Step2

Step 3. Verify the smart contract

Step3

Step 4. View the verified smart contract

TNS Registry Registry TNS Registrar Regsitrar TNS Resolver Resolver

πŸ—ƒ Changelog

See CHANGELOG.md.

πŸ“£ Contributing

See CONTRIBUTING.md for how to help out.

πŸ—’ Licence

See LICENSE for details.

tns's People

Contributors

andyparktw avatar goodvincenttu avatar mrblocktw avatar phyrextsai avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

mrblocktw

tns's Issues

TNS SDK

Checklist

  • TNS registry
  • TNS registrar
  • TNS resolver
  • Wrap Web3

Documentation

  • SDK document
  • Upload to npm

TNS deploy flow documentation

Test

  • Deploy TNSRegistry and test
  • Deploy TNSRegistrar and test
  • Deploy TNSResolver and test
  • Set subnode on TNSRegistrar

Documentation

  • Deploy flow

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.