RIFT: Realtime Interactive Fast Transport β A next-generation transport protocol for real-time communications (VoIP, video, collaboration) designed for mobile-first, multipath-native, and censorship-resistant environments.
This repository contains the official specification for the RIFT Transport Protocol.
RIFT is designed to address the limitations of traditional transport protocols (TCP, QUIC) in real-time communication scenarios:
- β Seamless roaming across network changes (Wi-Fi β LTE) without connection drops
- β Low tail-latency for audio/video even with packet loss and jitter
- β Multipath-native with active-backup and duplication modes
- β Adaptive FEC for resilience in poor network conditions
- β Built-in QoS scheduler with programmable priority policies
- β Censorship-resistant extensions (obfuscation, relay, fallback transports)
RIFT's multipath capabilities enable seamless transitions between network interfaces (Wi-Fi β LTE) without connection drops. The protocol validates multiple paths simultaneously and performs instant failover when the active path degrades, ensuring uninterrupted real-time communication.
π RIFT-SPEC-RC1.md β Main protocol specification (RC1 Final)
- Status: Release Candidate 1 (Final) β
- Wire Format: FROZEN for v1.0
- Ready for: Independent implementation and interoperability testing
π RC1-CHANGES.md β Critical changes log
- Documents all interoperability fixes
- Verification checklist
- Confidence assessment
- Read the specification: Start with RIFT-SPEC-RC1.md
- Pay attention to critical sections: Look for CRITICAL (interop) markers
- Implement conformance: Follow all MUST/MUST NOT requirements (RFC 2119)
- Test interoperability: Verify against other implementations
Key Sections for First Implementation:
- Section 4: Packetization and Header Formats
- Section 5: Cryptographic Handshake (Noise Framework)
- Section 6: Core Frames
- Section 7: Loss Recovery and Timers
- Section 8: Congestion Control and Pacing
RIFT introduces several novel approaches:
- Mobile-first multipath: Seamless Wi-Fi/LTE handover without application-level reconnection
- Noise-first crypto: Lightweight alternative to TLS for transport-layer security
- Adaptive FEC: Dynamic forward error correction based on network conditions
- Programmable QoS: Application-controlled priority scheduling with deadlines
- β Packet Formats: Long/Short headers with Header Protection
- β Frame Types: All core frames (ACK, STREAM, DATAGRAM, PATH_CHALLENGE, etc.)
- β Cryptography: Noise IK pattern with ChaCha20-Poly1305
- β Loss Recovery: ACK-based with PTO (Probe Timeout)
- β Congestion Control: BBRv2 and Cubic support
- β Multipath: Path validation, migration, active-backup, duplication
- β QoS Scheduler: 4 priority classes (P0-P3) with deadline support
- β Forward Error Correction: XOR and Reed-Solomon FEC
RIFT's built-in QoS scheduler manages four priority classes (P0-P3) with deadline-aware packet handling. P0 (audio/signaling) receives highest priority with aggressive dropping of stale packets, while P1 (video) uses adaptive FEC. P2/P3 handle interactive and bulk data with anti-starvation guarantees, ensuring fair bandwidth allocation even under congestion.
- π Obfuscation: obfs4, TLS-mimic, ShadowSocks transforms
- π Relay Infrastructure: Single-hop and multi-hop forwarding
- π‘οΈ Stealth Mode: Port knocking, timing jitter, decoy traffic
- π Fallback Transports: TCP wrapper, WebSocket tunnel
- π TUN/TAP Integration: VPN-like functionality
- π SOCKS5 Proxy: Transparent proxying
- π― Traffic Classification: Application-aware routing
β Wire format complete and frozen β All critical ambiguities resolved β Transport Parameters and Error Codes registries added β Golden test vectors and conformance tests defined β Interoperability-ready β No known blocking issues
Two independent implementations MUST be able to:
- Complete Noise handshake (INITIAL β HANDSHAKE β 1-RTT)
- Exchange STREAM and DATAGRAM frames
- Process ACK frames correctly (PN space scoping)
- Validate paths (PATH_CHALLENGE/PATH_RESPONSE with 5-tuple binding)
- Handle packet loss and retransmission
- Perform multipath operations
- Apply Header Protection correctly
- Construct AEAD nonces correctly
RIFT uses the Noise IK pattern for its cryptographic handshake, providing 0-RTT capability with Perfect Forward Secrecy. The handshake progresses through three independent packet number spaces (INITIAL, HANDSHAKE, 1-RTT), each with its own cryptographic protection level and ACK tracking.
π¦ Rust: rokoss21/rift-rs (coming soon)
- Modular architecture (rift-wire, rift-crypto, rift-core, rift-io)
- v1.0 baseline + v2.x anti-censorship extensions
- Linux, Windows, macOS support
(Will be updated as implementations become available)
- Mobile-First: Optimized for LTE/Wi-Fi roaming and NAT traversal
- Realtime-Friendly: Low latency (P0 audio < 50ms), deadline-aware scheduling
- Resilience: Multipath, FEC, adaptive keep-alive
- Security: Noise Protocol Framework, PFS, AEAD, Header Protection
- Observability: RTT/loss/jitter metrics without decrypting payload
- Anti-Ossification: Greasing, reserved bits, extensible frame types
The diagram above illustrates the complete RIFT protocol stack, from UDP datagram handling through cryptographic protection, multipath management, QoS scheduling, and application-level streams/datagrams.
We welcome contributions to the specification! Here's how you can help:
- π Ambiguities: Found unclear text? Open an issue
- π Interop Problems: Implementation not compatible? Report it
- π Errata: Spotted a typo or technical error? Submit a fix
- Read CONTRIBUTING.md before submitting
- For v1.0, the wire format is frozen β only clarifications/errata accepted
- For v2.x+ extensions, proposals are welcome
- π¬ GitHub Discussions: Start a discussion
- π§ Email: ecsiar@gmail.com
- π Implementer's Guide: (coming soon)
- π§ͺ Test Vectors: Appendix C - Interoperability Test Vectors
- π Performance Analysis: (coming soon)
- RIFT-RS: Reference Rust implementation
- RIFT-CLI: Command-line client for testing
- RIFT-Server: Production server implementation
This specification is released under the MIT License. See LICENSE for details.
Copyright (c) 2026 Emil Rokossovskiy
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
- Complete wire specification (RC1)
- Golden test vectors (Appendix C)
- Conformance test plan (22-point checklist)
- Reference implementation (rift-rs)
- Interoperability testing
- Obfuscation layer implementation
- Relay infrastructure deployment
- Field testing in censored regions
- Performance optimization
- TUN/TAP integration
- SOCKS5 proxy support
- Traffic classification engine
- VPN-like features
Emil Rokossovskiy
- GitHub: @rokoss21
- Email: ecsiar@gmail.com
Special thanks to:
- QUIC Working Group for protocol design inspiration
- Noise Protocol Framework authors for elegant cryptographic handshake design
- obfs4 and ShadowSocks projects for censorship resistance techniques
| Type | Name | Purpose |
|---|---|---|
0x00 |
FRAME_BUNDLE | Frame bundling container |
0x01 |
ACK | Acknowledge packets |
0x10 |
PING | Liveness probe |
0x11 |
PONG | Ping response |
0x12 |
PATH_CHALLENGE | Path validation |
0x13 |
PATH_RESPONSE | Path validation response |
0x20 |
STREAM | Reliable byte stream |
0x30 |
DATAGRAM | Unreliable datagram |
0x40 |
NEW_TOKEN | 0-RTT token issuance |
0x50 |
CC_EVENT | Congestion control feedback |
0x62 |
NEW_CONNECTION_ID | CID rotation |
0x64 |
CONNECTION_CLOSE | Terminate connection |
- CID Length: [0, 20] bytes, fixed for connection lifetime
- PN Spaces: INITIAL, HANDSHAKE, 1-RTT (independent)
- ACK Scoping: Within PN space only (no cross-PN-space ACKs)
- Path Validation: Bound to 5-tuple, not PathID
If you use RIFT in academic work, please cite:
@techreport{rokossovskiy2026rift,
title={RIFT Transport Protocol Specification (RC1)},
author={Rokossovskiy, Emil},
year={2026},
institution={RIFT Protocol Project},
url={https://github.com/rokoss21/rift-spec}
}Repository: https://github.com/rokoss21/rift-spec Status: RC1 Final β Ready for Implementation π Last Updated: February 10, 2026




