Update 90.md

updated based on comments
This commit is contained in:
starbuilder 2023-11-06 17:22:50 -05:00 committed by GitHub
parent 56dbb7722c
commit 7e3b7cd90c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 5 deletions

10
90.md
View File

@ -69,7 +69,7 @@ All tags are optional.
## Encrypted Params
If the user wants to keep the input parameters a secret, they can encrypt the `i` and `param` tags with the service provider's 'p' tag and add it to the content field. The user also indicates whether the output should be encrypted or not as one of the parameters.
If the user wants to keep the input parameters a secret, they can encrypt the `i` and `param` tags with the service provider's 'p' tag and add it to the content field. Add a tag `encrypted` as tags. Encryption for private tags will use [NIP-04 - Encrypted Direct Message encryption](https://github.com/nostr-protocol/nips/blob/master/04.md), using the user's private and service provider's public key for the shared secret
```json
[
@ -90,8 +90,8 @@ This param data will be encrypted and added to the `content` field and `p` tag s
```
"content": "BE2Y4xvS6HIY7TozIgbEl3sAHkdZoXyLRRkZv4fLPh3R7LtviLKAJM5qpkC7D6VtMbgIt4iNcMpLtpo...",
"tags": [
[`p`, `04f74530a6ede6b24731b976b8e78fb449ea61f40ff10e3d869a3030c4edc91f`],
[`encrypted`]
["p", "04f74530a6ede6b24731b976b8e78fb449ea61f40ff10e3d869a3030c4edc91f"],
["encrypted"]
]
@ -123,7 +123,7 @@ Service providers publish job results, providing the output of the job result. T
## Encrypted Output
If the request has encrypted params, then output should be encrypted and placed in `content` field with `p` tag. If the output is encrypted, then avoid including `i` tag with input-data as clear text.
If the request has encrypted params, then output should be encrypted and placed in `content` field. If the output is encrypted, then avoid including `i` tag with input-data as clear text.
Add a tag encrypted to mark the output content as `encrypted`
```json
{
@ -135,7 +135,7 @@ Add a tag encrypted to mark the output content as `encrypted`
[ "e", "<job-request-id>", "<relay-hint>" ],
[ "p", "<customer's-pubkey>" ],
[ "amount", "requested-payment-amount", "<optional-bolt11>" ],
[`encrypted`]
["encrypted"]
]
}