Files
zerogravity/Cargo.toml
Louie 7455f76351 feat: match Go TLS fingerprint for MITM upstream (#11)
* feat: match Go TLS fingerprint for MITM upstream connections

Replace rustls with boring2 (BoringSSL) for all MITM→Google upstream
connections, configured with Go crypto/tls exact defaults:

- Cipher suites: TLS_AES_128_GCM_SHA256 + 14 others in Go order
- Curves: X25519, P-256, P-384
- Signature algorithms: ECDSA+SHA256, RSA-PSS+SHA256, etc.
- HTTP/2 SETTINGS: 4MB stream window, 1GB connection window, 10MB
  header list, no adaptive windowing

Local TLS (LS→MITM) still uses rustls for CA cert presentation.
boring2/tokio-boring2 were already compiled as transitive deps from
wreq — no new build time added.

* chore: fmt + update README TLS description
2026-02-18 16:15:08 -06:00

61 lines
1.4 KiB
TOML

[package]
name = "zerogravity"
version = "1.0.1"
edition = "2021"
license = "MIT"
description = "OpenAI-compatible proxy for Google Antigravity"
repository = "https://github.com/NikkeTryHard/zerogravity"
authors = ["NikkeTryHard"]
[[bin]]
name = "zerogravity"
path = "src/main.rs"
[[bin]]
name = "zg"
path = "src/bin/zg.rs"
[dependencies]
axum = { version = "0.8", features = ["json"] }
tokio = { version = "1", features = ["full"] }
wreq = { version = "6.0.0-rc.28", features = ["json"] }
wreq-util = "3.0.0-rc.10"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
uuid = { version = "1", features = ["v4"] }
regex = "1"
async-stream = "0.3"
tower-http = { version = "0.6", features = ["cors"] }
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
clap = { version = "4", features = ["derive"] }
rand = "0.8"
flate2 = "1"
brotli = "7"
chrono = "0.4"
# MITM proxy dependencies
rcgen = "0.13"
rustls = { version = "0.23", features = ["ring"] }
tokio-rustls = "0.26"
rustls-native-certs = "0.8"
rustls-pemfile = "2"
boring2 = "5.0.0-alpha.12"
tokio-boring2 = "5.0.0-alpha.12"
time = "0.3"
base64 = "0.22"
httparse = "1"
# HTTP/2 + gRPC interception
hyper = { version = "1", features = ["http2", "client", "server"] }
hyper-util = { version = "0.1", features = ["tokio"] }
http-body-util = "0.1"
http = "1"
bytes = "1"
tokio-stream = "0.1"
[profile.release]
opt-level = "z"
lto = true
strip = true