Implement NIP-04: Encrypted Direct Messages

This commit is contained in:
Wilson Silva
2023-02-25 17:26:28 +07:00
parent 0df4dbb979
commit 857bf0ce8e
12 changed files with 343 additions and 0 deletions

View File

@@ -31,5 +31,13 @@ module Nostr
# @return [Integer]
#
CONTACT_LIST = 3
# A special event with kind 4, meaning "encrypted direct message". An event of this kind has its +content+
# equal to the base64-encoded, aes-256-cbc encrypted string of anything a user wants to write, encrypted using a
# shared cipher generated by combining the recipient's public-key with the sender's private-key.
#
# @return [Integer]
#
ENCRYPTED_DIRECT_MESSAGE = 4
end
end