From 4068b77f53b78f680bbba20a243c3354cc57ee19 Mon Sep 17 00:00:00 2001 From: Michael Vines Date: Tue, 4 May 2021 10:20:01 -0700 Subject: [PATCH] Add name service to sidebar --- docs/sidebars.js | 1 + docs/src/name-service.md | 58 +++++++++++++++++++++++++++++++--------- 2 files changed, 47 insertions(+), 12 deletions(-) diff --git a/docs/sidebars.js b/docs/sidebars.js index d8e9ade7208..6e8a881ef78 100644 --- a/docs/sidebars.js +++ b/docs/sidebars.js @@ -8,6 +8,7 @@ module.exports = { "token-lending", "associated-token-account", "memo", + "name-service", "shared-memory", "stake-pool", "feature-proposal", diff --git a/docs/src/name-service.md b/docs/src/name-service.md index 3f03e51af3f..9dbcffd32b8 100644 --- a/docs/src/name-service.md +++ b/docs/src/name-service.md @@ -1,23 +1,57 @@ -# SPL Name Service +--- +title: Name Service +--- -A spl program for issuing and managing ownership of: domain names, Solana Pubkeys, URLs, twitter handles, ipfs cid's etc.. +A SPL program for issuing and managing ownership of: domain names, Solana Pubkeys, URLs, twitter handles, ipfs cid's etc.. + +This program could be used for dns, pubkey etc lookups via a browser extension +for example, the goal is to create an easy way to identify Solana public keys +with various links. -This program could be used for dns, pubkey etc lookups via a browser extension for example, the goal is to create an easy way to identify Solana public keys with various links. Broader use cases are also imaginable. -Key points: +Key points: - A Name is a string that maps to a record (program derived account) which can hold data. -- Each name is of a certain class and has a certain owner, both are identified by their pubkeys. The class of a name needs to sign the issuance of it. -- A name can have a parent name that is identified by the address of its record. The owner of the parent name (when it exists) needs to sign the issuance of the child name. -- The data of a name registry is controlled byb the class keypair or, when it is set to `Pubkey::default()`, by the name owner keypair. +- Each name is of a certain class and has a certain owner, both are identified + by their pubkeys. The class of a name needs to sign the issuance of it. +- A name can have a parent name that is identified by the address of its record. + The owner of the parent name (when it exists) needs to sign the issuance of + the child name. +- The data of a name registry is controlled byb the class keypair or, when it is + set to `Pubkey::default()`, by the name owner keypair. - Only the owner can delete a name registry. Remarks and use cases: -- Domain name declarations: One could arbitrarly set-up a class that we can call Top-Level-Domain names. Names in this class can only be issued with the permission of the class keypair, ie the administrator, who can enforce that TLD names are of the type `".something"`. From then on one could create and own the TLD `".sol"` and create a class of ".sol" sub-domains, administrating the issuance of the `"something.sol"` sub-domains that way (by setting tha parent name to the address of the `".sol"` registry).\ -An off-chain browser extension could then, similarly to DNS, parse the user SPL name service URL input and descend the chain of names, verifying that the names exist with the correct parenthood, and finally use the data of the last child name (or also a combination of the parents data) in order to resolve this call towards a real DNS URL or any kind of data.\ -Although the ownership and class system makes the administration a given class centralized, the creation of new classes is permissionless and as a class owner any kind of decentralized governance signing program could be used. +- Domain name declarations: One could arbitrarly set-up a class that we can call + Top-Level-Domain names. Names in this class can only be issued with the + permission of the class keypair, ie the administrator, who can enforce that + TLD names are of the type `".something"`. From then on one could create and + own the TLD `".sol"` and create a class of ".sol" sub-domains, administrating + the issuance of the `"something.sol"` sub-domains that way (by setting tha + parent name to the address of the `".sol"` registry). + +An off-chain browser extension could then, similarly to DNS, parse the user SPL +name service URL input and descend the chain of names, verifying that the names +exist with the correct parenthood, and finally use the data of the last child +name (or also a combination of the parents data) in order to resolve this call +towards a real DNS URL or any kind of data. -- Twitter handles can be added as names of one specific name class. The class authority of will therefore hold the right to add a twitter handle name. This enables the verification of twitter accounts for example by asking the user to tweet his pubkey or a signed message. A bot that holds the private issuing authority key can then sign the Create instruction (with a metadata_authority that is the tweeted pubkey) and send it back to the user who will then submit it to the program.\ +Although the ownership and class system makes the administration a given class +centralized, the creation of new classes is permissionless and as a class owner +any kind of decentralized governance signing program could be used. + +- Twitter handles can be added as names of one specific name class. The class + authority of will therefore hold the right to add a twitter handle name. This + enables the verification of twitter accounts for example by asking the user to + tweet his pubkey or a signed message. A bot that holds the private issuing + authority key can then sign the Create instruction (with a metadata_authority + that is the tweeted pubkey) and send it back to the user who will then submit + it to the program. In this case the class will still be able to control the data of the name registry, and not the user for example. -Therefore, another way of using this program would be to create a name (`"verified-twitter-handles"` for example) with the `Pubkey::default()` class and with the owner being the authority. That way verified twitter names could be issued as child names of this parent by the owner, leaving the user as being to able to modify the data of his twitter name registry. \ No newline at end of file + +Therefore, another way of using this program would be to create a name +(`"verified-twitter-handles"` for example) with the `Pubkey::default()` class +and with the owner being the authority. That way verified twitter names could be +issued as child names of this parent by the owner, leaving the user as being to +able to modify the data of his twitter name registry.