{"id":28347346,"url":"https://github.com/4cadia-foundation/jns","last_synced_at":"2025-08-26T23:38:30.508Z","repository":{"id":87141680,"uuid":"213744740","full_name":"4cadia-foundation/jns","owner":"4cadia-foundation","description":"JNS is a decentralized TLD and domain registry","archived":false,"fork":false,"pushed_at":"2019-11-04T22:02:43.000Z","size":5877,"stargazers_count":3,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-08-09T17:55:51.676Z","etag":null,"topics":["blockchain","dapp","decentralized-applications","decentralized-dns","ethereum","name-service","smart-contracts","solidity","tld","web3"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"unlicense","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/4cadia-foundation.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-10-08T20:16:50.000Z","updated_at":"2025-05-06T15:33:19.000Z","dependencies_parsed_at":"2023-03-07T05:16:08.553Z","dependency_job_id":null,"html_url":"https://github.com/4cadia-foundation/jns","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/4cadia-foundation/jns","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/4cadia-foundation%2Fjns","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/4cadia-foundation%2Fjns/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/4cadia-foundation%2Fjns/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/4cadia-foundation%2Fjns/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/4cadia-foundation","download_url":"https://codeload.github.com/4cadia-foundation/jns/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/4cadia-foundation%2Fjns/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272267821,"owners_count":24903784,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-26T02:00:07.904Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["blockchain","dapp","decentralized-applications","decentralized-dns","ethereum","name-service","smart-contracts","solidity","tld","web3"],"created_at":"2025-05-27T16:11:07.657Z","updated_at":"2025-08-26T23:38:30.500Z","avatar_url":"https://github.com/4cadia-foundation.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JNS\n\nDecentralized Name Service for the Web 3.0.\n\n## Overview\n\nJNS builds upon traditional DNS architecture, allowing users to register TLDs and domains that are currently stored in a [Ethereum](https://ethereum.org/) smart contract.\n\nThere are some ongoing research aiming to review such architecture to create a standard that is more suited to the Web 3.0. For more details, see [EIP 2193](https://eips.ethereum.org/EIPS/eip-2193).\n\nWhile JNS is open to comply to new architectural standards that may arise, at the moment we decided to stick to the current DNS standard to ease user adoption, even though it has some known issues.\n\n## Functionalities\n\nTo know how to use this application, please refer to the [User Guide](./USER-GUIDE.md).\n\n### 1. Register TLDs\n\n- Users **can** register any TLD they want. \n    - Only restrictions is the length of the name being registered.\n- By default TLD registration expires after 1 year.\n\n### 2. Renew TLDs\n\n- Users **may** renew a TLD they own.\n    - Expiration date will always be incremented 1 year at a time.\n\n### 3. Transfer TLDs\n\n- A user can transfer the ownership of a previously purchased TLD to any other valid Ethereum address.\n\n\n### 4. Register Domains\n\n- Users **can** register any domain they want.\n    - Only restriction is the length of the name being registered.\n- A domain **must** always be registered under a previously registered TLD.\n- A domain **must** be linked to a content\n    - Currently the only type of content supported is an [IPFS](https://ipfs.io/) hash.\n- By default domain registration expires after 1 year.\n\n### 5. Renew Domains\n\n- Users **may** renew a domain they own.\n    - Expiration date will always be incremented 1 year at a time.\n\n### 6. Transfer TLDs\n\n- A user can transfer the ownership of a previously purchased domain to any other valid Ethereum address.\n\n## Architectural Overview\n\nThis project is composed of 3 related, but independent packages:\n\n- `smartcontract`: contains the code of the smart contract which define the business rules and primarily governs JNS.\n- `core`: acts as a middleware between the UI and the smart contract, providing facilities like validation, to prevent loss of funds due to bad interactions with the contract.\n- `dapp`: is a sample UI implemented as an SPA which enables users to interact with JNS.\n\n## Run the Application\n\n### Pre-requisites\n\n- Yarn: `\u003e= 1.19.0`\n- Node: `\u003e= 10.0.0 \u003c12.0.0`\n- Metamask: `\u003e=7.3.1` (browser extension to interact with the dapp)\n\n### Clone the Project\n\n```\ngit clone https://github.com/4cadia-foundation/jns\n```\n\n### Install Dependencies\n\nInside the main folder of the project:\n```\nyarn install\n```\n\n### 1. Smart Contract Interaction\n\nJNS smart contract is currently deployed to the Rinkeby Test Network at address [0x3975F6345aF041cd858e9988b71EDC269B32337C](https://rinkeby.etherscan.io/address/0x3975F6345aF041cd858e9988b71EDC269B32337C). If you want to use this version, you can skip this section.\n\nTo deploy a local version of the smart contract, you will need to install either [`ganche-cli`](https://www.npmjs.com/package/ganache-cli) or [`geth`](https://geth.ethereum.org/downloads/).\n\n\u003cdetails\u003e\n\u003csummary\u003eClick here to see how\u003c/summary\u003e\n\u003cdiv\u003e\n\n#### 1a. Usage with `ganache-cli`\n\nIt is important to set `1234` as `networkId` in order to make it work properly.\n\n```sh\nganache-cli -i 1234\n```\n\nAlternatively, you can pass your Metamask mnemonic key to have you default accounts already populated with ether:\n\n```sh\nganache-cli -i 1234 -m \u003cMNEMONIC_KEY\u003e\n```\n\n#### 1b. Usage with `geth`\n\nThe recommended way to connect via geth is through a private development network:\n\n```sh\ngeth --dev --datadir \u003cDATA_DIRECTORY\u003e --networkid 1234 --rpc\n# e.g.: geth --dev --datadir /tmp/geth --networkid 1234 --rpc\n``` \n\nFor more details, please refer to the [geth docs](https://github.com/ethereum/go-ethereum/wiki/Private-network).\n\n#### Deploy a Local Contract\n\nFrom the repository root:\n```\ncd packages/smartcontract\nyarn deploy --network local\n```\n\n#### Set Metamask Network to Local\n\nIn your Metamask browser extension, set the default local network `localhost:8545`:\n\n![Metamask Local Network](./docs/metamask-local-network.png)\n\n\u003c/div\u003e\n\u003c/details\u003e\n\n### 2. Compile the Core Package\n\nFrom the repository root:\n\n```\ncd packages/core\nyarn build\n```\n\n### 3. Run the Dapp\n\nFrom the repository root:\n\n```\ncd packages/dapp\nyarn dev\n```\n\nThis will start a `webpack-dev-server` instance.\n\nAlternatively, if you want to use the production build, instead of `yarn dev`, run:\n\n```\nyarn build\n```\n\nAfter that, the production build will be available at the `dist/` directory. Then you can use something like [`http-server`](https://www.npmjs.com/package/http-server):\n\n```sh\nhttp-server dist/\n```\n\nIn both cases, the dapp will probably be available at:\n\n```\nhttp://localhost:8080\n```\n\n**IMPORTANT:** verify if your Metamask is connected to the correct network (Rinkeby or your local one);\n\n#### Troubleshooting\n\nIf port `8080` is busy, then both approaches will try to make it available at port `8081`. If this port is still unavailable, then `8082` and so on.\n\n### Run tests\n\nCurrently there are tests only in the `smartcontract` package:\n\n```\ncd packages/smartcontract\nyarn test\n```\n\n## Docker\n\n- [ ] TODO: Create a docker image to ease project setup\n\n## TODO List\n\n- [ ] Make it usable\n    - Should we keep using browser extensions?\n    - Should we implement a new browser with native support?\n- [ ] Allow users to change the content related to a domain. (_in progress_)\n- [ ] Implement full DNS funcionalities, with support for some commonly used [DNS Record Types](https://en.wikipedia.org/wiki/List_of_DNS_record_types).\n    - The currently implemented funcionality allows only for a single entry, which works roughly as `A` record whose target is the IPFS hash.\n- [ ] Introduce monetization policies\n    - How much charge for a TLD or domain registration?\n    - How much charge for renovation?\n    - Should a TLD owner be able to charge a fee for each domain registered under it? How much could it be?\n- [ ] Add some Game Theory bytes\n    - How to prevent first runners from hoarding TLDs and domains?\n    - Should we hold auctions for short names?\n- [ ] Make it ecosystem friendly\n    - Should we blacklist `.eth` TLD to prevent name collisions with [ENS](https://ens.domains/)?\n- [ ] Make it compliant with international intelectual property laws\n    - How to prevent users from registering TLDs and domains linked to registered trademarks? Should we even bother?\n\n## Previous Work in the Wild\n\n- [ENS](https://ens.domains/)\n- [Unstoppable Domains](https://unstoppabledomains.com/)\n\n### JNS vs ENS\n\nTODO.\n\n### JNS vs Unstoppable Domains\n\nTODO.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F4cadia-foundation%2Fjns","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F4cadia-foundation%2Fjns","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F4cadia-foundation%2Fjns/lists"}