Encrypt private media before fragmentation

This commit is contained in:
jack
2026-07-25 23:00:27 +02:00
committed by jack
parent 1d4c143bdc
commit a17f4abb02
25 changed files with 892 additions and 137 deletions
@@ -24,6 +24,9 @@ public struct PeerCapabilities: OptionSet, Equatable, Hashable, Sendable {
/// (uplink/downlink carriers for mesh-only peers). Advertised alongside
/// a `bridgeGeohash` TLV carrying the rendezvous cell.
public static let bridge = PeerCapabilities(rawValue: 1 << 7)
/// Finalized direct-message media encrypted as a `.privateFile` Noise
/// payload before outer BLE fragmentation.
public static let privateMedia = PeerCapabilities(rawValue: 1 << 8)
/// Minimal little-endian byte encoding; always at least one byte so an
/// empty set is distinguishable from an absent TLV.