Repository navigation
feat: tunnel-node service + CodeFull.gs (1/3) - #93
Merged
Merged
Conversation
Standalone Rust HTTP server that bridges HTTP tunnel requests to real TCP connections. Apps Script can only make HTTP requests (UrlFetchApp), not raw TCP — the tunnel node holds persistent TCP sockets and translates between HTTP (from Apps Script) and raw TCP (to destinations). - tunnel-node/: axum-based HTTP server with connect/data/close/batch protocol, session management, background reader per session, idle reaping, Docker-ready for Cloud Run or any VPS - assets/apps_script/CodeFull.gs: extends Code.gs with tunnel forwarding (single + batch ops) alongside existing HTTP relay - config.full.example.json: example config for full mode Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
This was referenced Apr 23, 2026
Closed
therealaleph
added a commit
that referenced
this pull request
Apr 23, 2026
+ #93) - Android DEFAULT_SNI_POOL: mirror the Rust-side fix from #92 — accounts.googl.com replaced by accounts.google.com. Same cert-SAN mismatch that was failing every Nth rotation in the Rust client affected the Android user's sniHosts population; both pools need to stay in sync by design. - Release rolls up PR #92 (cert fix) and PR #93 (tunnel-node + CodeFull.gs scaffolding). PR #93 adds a standalone binary under tunnel-node/ plus an Apps Script companion; no main-crate changes, so this is a zero-risk merge. Users who want to deploy a tunnel node can start today. The dispatch that activates `mode: full` is still in review in PR #94.
|
Interesting architecture using Apps Script + Cloud Run tunnel-node. Has anyone tested PR #93 tunnel-node mode in real conditions? Curious whether it provides measurable throughput/latency gains for destinations outside Google (X, Telegram, CDNs, random websites), or if the main benefit is better censorship bypass, stability, and reliability. |
therealaleph
pushed a commit
that referenced
this pull request
Apr 24, 2026
Adds a new `mode: full` that tunnels ALL traffic end-to-end through Apps Script → a remote tunnel node. Browser does TLS directly with the destination. No MITM, no CA installation needed on the client device. Ships as part of the 3-PR series: #93 (tunnel-node service + CodeFull.gs, merged) + this (Rust-side Mode::Full + batch tunnel client) + #95 (Android UI dropdown, now rolled into this PR post-rebase). ### Architecture - Client → mhrv-rs → script.google.com (Apps Script fetch) → tunnel-node on user's VPS → real destination - Apps Script is the transport to reach the VPS; works even when the ISP blocks direct VPS IPs - Batch multiplexer collects data from all active sessions and ships one Apps Script request per tick ### Safety properties of this merge - AppsScript + GoogleOnly dispatch paths are **unchanged**; Full mode is an additive branch at the top of `dispatch_tunnel`. - `tunnel_client.rs` is a new isolated module (387 LOC). - `tunnel_request()` is a new method on `DomainFronter`, no change to `relay()` / `relay_parallel_range()`. - Config: additive `Mode::Full` variant + validation tests (2 new); existing validation rules untouched. - Local build: clean compile. `cargo test --quiet`: 75 passed (73 → 75 with 2 new config tests). ### Closes Unblocks the feature requested in #61, #69, #100, #105, #110, #111, #113, #116. ### Testing vahidlazio has iterated on prior review feedback. End-to-end testing with a real tunnel-node deployment will follow post-merge from @Feiabyte (volunteered in #61). Post-merge CI will exercise compile + full test matrix across all targets; any regression caught there gets a fast-follow fix.
therealaleph
pushed a commit
that referenced
this pull request
Apr 25, 2026
Standalone Rust/axum HTTP server + Apps Script-side CodeFull.gs for users who want to deploy a remote tunnel node. All new files; no changes to the main Rust crate. This is part 1 of 3 of the full-tunnel feature — it adds scaffolding that users can opt into once the Rust-side Mode::Full lands in #94.
therealaleph
added a commit
that referenced
this pull request
Apr 25, 2026
+ #93) - Android DEFAULT_SNI_POOL: mirror the Rust-side fix from #92 — accounts.googl.com replaced by accounts.google.com. Same cert-SAN mismatch that was failing every Nth rotation in the Rust client affected the Android user's sniHosts population; both pools need to stay in sync by design. - Release rolls up PR #92 (cert fix) and PR #93 (tunnel-node + CodeFull.gs scaffolding). PR #93 adds a standalone binary under tunnel-node/ plus an Apps Script companion; no main-crate changes, so this is a zero-risk merge. Users who want to deploy a tunnel node can start today. The dispatch that activates `mode: full` is still in review in PR #94.
therealaleph
pushed a commit
that referenced
this pull request
Apr 25, 2026
Adds a new `mode: full` that tunnels ALL traffic end-to-end through Apps Script → a remote tunnel node. Browser does TLS directly with the destination. No MITM, no CA installation needed on the client device. Ships as part of the 3-PR series: #93 (tunnel-node service + CodeFull.gs, merged) + this (Rust-side Mode::Full + batch tunnel client) + #95 (Android UI dropdown, now rolled into this PR post-rebase). ### Architecture - Client → mhrv-rs → script.google.com (Apps Script fetch) → tunnel-node on user's VPS → real destination - Apps Script is the transport to reach the VPS; works even when the ISP blocks direct VPS IPs - Batch multiplexer collects data from all active sessions and ships one Apps Script request per tick ### Safety properties of this merge - AppsScript + GoogleOnly dispatch paths are **unchanged**; Full mode is an additive branch at the top of `dispatch_tunnel`. - `tunnel_client.rs` is a new isolated module (387 LOC). - `tunnel_request()` is a new method on `DomainFronter`, no change to `relay()` / `relay_parallel_range()`. - Config: additive `Mode::Full` variant + validation tests (2 new); existing validation rules untouched. - Local build: clean compile. `cargo test --quiet`: 75 passed (73 → 75 with 2 new config tests). ### Closes Unblocks the feature requested in #61, #69, #100, #105, #110, #111, #113, #116. ### Testing vahidlazio has iterated on prior review feedback. End-to-end testing with a real tunnel-node deployment will follow post-merge from @Feiabyte (volunteered in #61). Post-merge CI will exercise compile + full test matrix across all targets; any regression caught there gets a fast-follow fix.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part 1 of 3: Full Tunnel Mode
Standalone tunnel node server + Apps Script. No changes to the main Rust crate.
What
tunnel-node/: Rust HTTP server (axum) that bridges HTTP tunnel requests to real TCP connections. Session-based protocol: connect, data, close, batch. Docker-ready for Cloud Run or any VPS.assets/apps_script/CodeFull.gs: Extends Code.gs with tunnel forwarding (single + batch) alongside existing HTTP relay.config.full.example.json: Example config for full mode.Why a separate tunnel node?
Apps Script can only make HTTP requests (
UrlFetchApp.fetch()). It cannot open raw TCP sockets. The tunnel node holds persistent TCP connections and translates between HTTP (from Apps Script) and raw TCP (to destinations).Recommended: deploy on Google Cloud Run — same Google network as Apps Script, minimal UrlFetchApp hop latency.
Deployment
See
tunnel-node/README.mdfor Docker and direct binary options.Files
tunnel-node/Cargo.toml,tunnel-node/src/main.rs,tunnel-node/Dockerfile,tunnel-node/README.md,tunnel-node/.gitignoreassets/apps_script/CodeFull.gsconfig.full.example.json🤖 Generated with Claude Code