Skip to content

gemtek-infinity/cfd-rs

 
 

Repository files navigation

cloudflared (Rust rewrite)

This repository contains the Rust rewrite of Cloudflare's tunnel client, cloudflared.

The rewrite targets behavioral parity with the frozen Go baseline release 2026.2.0. The frozen Go source lives in baseline-2026.2.0/ and is the primary behavior reference.

Current state

This is a real but partial implementation. It is not yet production-alpha ready.

What exists now:

  • config discovery, credentials decoding, and ingress matching
  • QUIC tunnel shell with quiche + BoringSSL
  • Pingora proxy seam with limited origin dispatch
  • registration and stream type boundaries
  • parity ledgers and source routing across CLI, CDC, and HIS
  • debtmap-enabled MCP routing surface

Largest remaining gaps:

  • Cap'n Proto registration RPC and stream framing parity
  • full stream round-trip through origin services
  • management service, log streaming, and Cloudflare REST API client
  • broad CLI parity beyond the current alpha surface
  • Linux service install/uninstall and systemd integration
  • local HTTP endpoints, config reload, and file watcher
  • logging compatibility across local sinks, journald/systemd, and upstream management flows
  • final performance-optimization architectural overhaul

Active lane

  • Linux only (x86_64-unknown-linux-gnu)
  • quiche + BoringSSL
  • 0-RTT required
  • Pingora in the production-alpha critical path
  • shipped artifacts: x86-64-v2 and x86-64-v4

Where truth lives

Workspace structure

Crate Purpose
crates/cfdrs-bin binary entrypoint and composition owner
crates/cfdrs-cli CLI command surface
crates/cfdrs-cdc Cloudflare-facing contracts
crates/cfdrs-his host interaction services
crates/cfdrs-shared narrowly admitted shared types

Building And Validation

Normal entry:

just validate-pr

Useful focused recipes:

just doctor
just fmt
just validate-governance
just validate-app
just validate-tools

Contributing

See CONTRIBUTING.md for workflow, parity-evidence, and CI guidance.

Useful entrypoints:

About

Attempt to rewrite Cloudflare Tunnel client to Rust

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Go 55.5%
  • Rust 36.3%
  • Python 6.1%
  • Shell 0.6%
  • Makefile 0.3%
  • Just 0.3%
  • Other 0.9%