mirror of
https://github.com/nostr-protocol/nips.git
synced 2024-12-23 17:05:51 -05:00
fixes variable names
This commit is contained in:
parent
0d06150f3f
commit
b0c79bc60a
16
73.md
16
73.md
|
@ -88,16 +88,16 @@ The viewing private key is a new Nostr Private Key in hex, NIP-44-encrypted to e
|
|||
The `.content` is then encrypted by a conversation key between the new author's private key and the viewing public key.
|
||||
|
||||
```js
|
||||
val keyPair = nostr.generateKeyPair()
|
||||
val viewingKeyPair = nostr.generateKeyPair()
|
||||
|
||||
{
|
||||
"pubkey": author.pubkey
|
||||
"kind": 35337,
|
||||
"tags": [
|
||||
["d", "<unique identifier>"]
|
||||
["p", "<pubkey 1>", "<relay url>", nip44Encrypt(keyPair.privateKeyHex, author.privateKey, "<pubkey 1>") ]
|
||||
["p", "<pubkey 2>", "<relay url>", nip44Encrypt(keyPair.privateKeyHex, author.privateKey, "<pubkey 2>") ]
|
||||
["p", "<pubkey 3>", "<relay url>", nip44Encrypt(keyPair.privateKeyHex, author.privateKey, "<pubkey 3>") ]
|
||||
["p", "<pubkey 1>", "<relay url>", nip44Encrypt(viewingKeyPair.privateKeyHex, author.privateKey, "<pubkey 1>") ]
|
||||
["p", "<pubkey 2>", "<relay url>", nip44Encrypt(viewingKeyPair.privateKeyHex, author.privateKey, "<pubkey 2>") ]
|
||||
["p", "<pubkey 3>", "<relay url>", nip44Encrypt(viewingKeyPair.privateKeyHex, author.privateKey, "<pubkey 3>") ]
|
||||
],
|
||||
"content": nip44Encrypt([
|
||||
["title", "Name of this spreadsheet"], // private title
|
||||
|
@ -105,7 +105,7 @@ val keyPair = nostr.generateKeyPair()
|
|||
["data", "<sheet name>", "<column letter>", "<row number>", "<value>", "<style>"],
|
||||
["style", "<TBD>"], // Need to specify all options here.
|
||||
// ... other tags
|
||||
], author.privateKey, keyPair.publicKey),
|
||||
], author.privateKey, viewingKeyPair.publicKey),
|
||||
"sig": signWith(author.privateKey)
|
||||
// ...
|
||||
}
|
||||
|
@ -132,9 +132,9 @@ val viewingKeyPair = nostr.generateKeyPair()
|
|||
"kind": 35337,
|
||||
"tags": [
|
||||
["d", "<unique identifier>"]
|
||||
["p", "<pubkey 1>", "<relay url>", nip44Encrypt(edittingKeyPair.privateKeyHex, edittingKeyPair.privateKeyHex, "<pubkey 1>") ]
|
||||
["p", "<pubkey 2>", "<relay url>", nip44Encrypt(edittingKeyPair.privateKeyHex, edittingKeyPair.privateKeyHex, "<pubkey 2>") ]
|
||||
["p", "<pubkey 3>", "<relay url>", nip44Encrypt(viewingKeyPair.privateKeyHex, edittingKeyPair.privateKeyHex, "<pubkey 3>") ] // view only
|
||||
["p", "<pubkey 1>", "<relay url>", nip44Encrypt(edittingKeyPair.privateKeyHex, edittingKeyPair.privateKey, "<pubkey 1>") ]
|
||||
["p", "<pubkey 2>", "<relay url>", nip44Encrypt(edittingKeyPair.privateKeyHex, edittingKeyPair.privateKey, "<pubkey 2>") ]
|
||||
["p", "<pubkey 3>", "<relay url>", nip44Encrypt(viewingKeyPair.privateKeyHex, edittingKeyPair.privateKey, "<pubkey 3>") ] // view only
|
||||
],
|
||||
"content": nip44Encrypt([
|
||||
["title", "Name of this spreadsheet"], // private title
|
||||
|
|
Loading…
Reference in New Issue
Block a user