Security Policy & Cryptography

Detailed disclosure of BitChat's cryptographic primitives, mutual Noise XX handshake, threat model, known limitations, and private vulnerability reporting process.

Independent Security Audit Notice: BitChat is an independent open-source software project. It has not yet undergone a formal third-party cryptographic security audit by an independent security evaluation firm. While its underlying cryptographic primitives (X25519, ChaCha20-Poly1305, BLAKE2s, Ed25519) are industry-standard, you should evaluate BitChat accordingly before relying on it in hostile or high-risk operational environments.

Verified Security Foundation

VERIFIED

Noise XX Handshake

Provides mutual peer authentication without relying on certificate authorities, public key infrastructures (PKI), or central key servers.

Pattern: Noise_XX_25519_ChaChaPoly_BLAKE2s
VERIFIED

Forward Secrecy

Ephemeral Curve25519 (X25519) keypairs are negotiated per connection. Session encryption keys reside exclusively in volatile process memory and are zeroed upon session termination.

Ephemeral X25519 • RAM-Only Keys
VERIFIED

Authenticated Encryption

Payloads are protected with 256-bit ChaCha20 authenticated with Poly1305 MACs (AEAD). Payloads modified in transit are rejected before application dispatch.

ChaCha20-Poly1305 AEAD

Noise XX Mutual Authentication Flow

How two nodes mutually prove their identity and establish symmetric encryption keys across radio or LAN without transmitting long-term keys in plaintext.

Noise XX Handshake Diagram
Mutual Authentication & Ephemeral Key Exchange via Noise_XX_25519_ChaChaPoly_BLAKE2s

Security Guarantees & Explicit Limitations

Threats Mitigated

  • Authoritative Rust Noise XX & Zeroization: Direct peer sessions execute inside Rust NativeNoiseSession with zeroize::ZeroizeOnDrop, zero eager Python session key copies, and fail-closed u32::MAX nonce exhaustion guards.
  • Strict Replay & AEAD Protection: 1,024-entry sliding replay window tracks every wire nonce including nonce 0, advancing strictly after ChaCha20-Poly1305 authentication tag verification succeeds.
  • Collision-Safe Identity & Trust Separation: NativePeerStateEngine rejects colliding keys for both modern SHA-256 peer IDs and post-auth legacy bitchat-tui peer IDs, keeping observed, authenticated, and user-confirmed verified trust strictly separate.
  • Bounded DoS Defenses & No Central Servers: Pending DM queues are capped (32 per peer / 512 global), UDP discovery is rate-limited natively via NativeIpRateLimiter, and no central servers or accounts exist.

Known Limitations & Non-Guarantees

  • RF & Network Traffic Analysis: Physical radio observers can detect BLE transmission events and MAC addresses. LAN observers can inspect UDP discovery frames and unencrypted outer routing headers.
  • Physical Device Compromise & OS Memory: Long-term identity keys in ~/.bitchat/identity.json rely on OS file permissions (0600 on POSIX, user DACL on Windows) without on-disk passphrase encryption yet; Rust zeroize scrubs owned memory on drop but cannot guarantee erasure from OS swap or kernel crash dumps.
  • Authentication vs. Real-World Identity: Completing Noise XX proves cryptographic possession of a peer's static key (authenticated), not real-world identity — out-of-band fingerprint verification (/verify) is required for verified trust.
  • Broadcast Channels & Radio DoS: Public broadcast messages (#public) are intentionally unencrypted for local mesh participants, and physical RF jamming cannot be prevented by software.

Reporting Security Vulnerabilities

We take reports of security vulnerabilities seriously and appreciate the assistance of the security research community.

Private Security Advisory Process

Please do not report security vulnerabilities through public GitHub issues, public discussion forums, or social media. Instead, use GitHub's private vulnerability reporting feature:

Open Private Security Advisory →
Maintainer Response Policy: BitChat is maintained as an open-source project. While maintainers investigate reports as promptly as possible, we do not guarantee commercial-grade 48-hour triage or 5-day resolution service level agreements (SLAs). Please allow reasonable time for investigation and patch development prior to public disclosure.