AI COOKED A modern, serverless, peer-to-peer (P2P) messaging and media application designed for 42 school students and local networks (LAN).
ft_msg is built with a strict Zero-Trust philosophy, ensuring high security and privacy without relying on any central server.
- Language: Go (Golang) - Compiled as a single portable binary.
- Discovery: mDNS (Multicast DNS) for automatic LAN peer discovery.
- Transport: QUIC (UDP-based) for connection resilience (IP roaming), native multiplexing, and built-in TLS 1.3.
- Media: WebRTC (
pion/webrtc) for end-to-end encrypted Voice and Video calls with dynamic ICE port negotiation. - Cryptography:
- Identity & Auth: Ed25519
- Key Exchange: X25519 (ECDH)
- Session Encryption: ChaCha20-Poly1305 (Double encrypted over QUIC)
- Storage: Pure Go SQLite (
modernc.org/sqlite) to prevent JSON corruption during asynchronous operations.
This application operates under the assumption that the local network is hostile.
- Anti-RCE (Remote Code Execution) & Injection:
- No dynamic execution: Network payloads MUST NOT contain executable code, scripts, or shell commands.
- Protobuf Serialization: All network communication uses strictly typed Protocol Buffers. If an incoming byte stream does not perfectly match the compiled schema, it is dropped immediately. JSON is avoided for network payloads to prevent deep-nesting memory bombs.
- Sanitization: All text inputs are treated as raw text. The GUI/CLI must strictly escape characters when rendering to prevent XSS or terminal injection.
- Anti-DDoS & Resource Exhaustion:
- Strict Sizing: All incoming streams have hard limits (e.g., max 1MB for a text payload). Buffer overflow attempts will cause an immediate connection drop.
- Timeouts: All connection attempts and reads have strict 5-second deadlines to prevent Slowloris or stalling attacks.
- Fast-Drop: Peers must authenticate with a valid Ed25519 signature within 3 seconds of connecting, or they are dropped.
- No Sudo/Root: The application runs entirely in user-space.
(Instructions will be added as the CLI/GUI modules are developed).