relay-core 0.1.1-alpha.0

The core components of the Relay Protocol.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use serde::{Deserialize, Serialize};

/// Information about the cryptography used to encrypt the message.
#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)]
pub struct CryptoMeta {
    /// Algorithm used for encryption (e.g., "x25519-hkdf-sha256-xchacha20poly1305").
    pub alg: String,
    /// Recipient identifier (e.g., public key, fingerprint, or address).
    pub recipient: String,
    /// The sender's ephemeral public key used in the encryption process.
    pub sender_ephemeral: Vec<u8>,
    /// Nonce used for the encryption.
    pub nonce: Vec<u8>,
}