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

@@ -1,9 +1,16 @@
module Nostr
class Crypto
BN_BASE: Integer
CIPHER_CURVE: String
CIPHER_ALGORITHM: String
def encrypt_text: (String, String, String) -> String
def decrypt_text: (String, String, String) -> String
def sign_event: (Event, String) -> Event
private
def compute_shared_key: (String, String) -> String
def hash_event:(Event) -> String
end
end