From cab55281f3a609f3adbc917554bde4630c4e7930 Mon Sep 17 00:00:00 2001 From: Christian Krueger Date: Thu, 19 Oct 2023 09:53:39 -0600 Subject: [PATCH] Update 108.md NIP-04 takes the users sk and the gated note creator's pk Co-authored-by: Asai Toshiya --- 108.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/108.md b/108.md index e724105e..f073f2f8 100644 --- a/108.md +++ b/108.md @@ -121,7 +121,7 @@ APP.get("/:noteId/:paymentHash") ### Encryption/Decryption -To encrypt/decrypt `kind:56` key notes, we use [NIP-04](https://github.com/nostr-protocol/nips/blob/master/04.md)'s encrypt/decrypt functions between the gated note's creator's pubkey and your pubkey. +To encrypt/decrypt `kind:56` key notes, we use [NIP-04](https://github.com/nostr-protocol/nips/blob/master/04.md)'s encrypt/decrypt functions between the gated note's creator's pubkey and your prikey. To encrypt/decrypt the gated note, we use `aes-256-cbc`. Below is a simple implementation in ts: