discord-proxy 0.1.0

Windows-first Discord process-local proxy launcher
Documentation

Discord Proxy

Windows-first launcher for starting Discord with a process-local proxy. The first MVP avoids DLL injection and system proxy changes.

References

This project references the Discord proxy approach from:

https://github.com/aiqinxuancai/discord-proxy/

Usage

Inspect the detected Discord installation:

cargo run -- doctor

Start Discord with a plain HTTP proxy:

cargo run -- launch --proxy http://127.0.0.1:1080

Start Discord with a SOCKS5 or authenticated proxy:

cargo run -- launch --proxy socks5://user:pass@127.0.0.1:1080

For SOCKS5 or authenticated upstream proxies, the tool starts a local HTTP CONNECT bridge on 127.0.0.1 and keeps running. Keep the terminal open while Discord uses the proxy.

Preview the launch command without starting Discord:

cargo run -- launch --proxy socks5://127.0.0.1:1080 --dry-run

Config File

By default, the launcher reads discord-proxy.toml from the current directory when present.

proxy = "socks5://127.0.0.1:1080"
channel = "stable"
# discord_dir = "C:\\Users\\you\\AppData\\Local\\Discord"

Supported channels: stable, canary, ptb, development.

Current Scope

  • Supports Windows Discord discovery through explicit paths, uninstall registry keys, %LOCALAPPDATA%\Discord*, and protocol-handler registry keys.
  • Normalizes candidates passed as install roots, Update.exe, Discord.exe, or app-* directories.
  • Selects the newest launchable app-* directory and skips empty or partial update directories.
  • Launches through Update.exe --processStart ... --a=--proxy-server=....
  • Falls back to direct Discord.exe --proxy-server=... launch when Update.exe is not available.
  • Sets process-local HTTP_PROXY, HTTPS_PROXY, and lowercase variants.
  • Bridges authenticated HTTP and SOCKS5 upstream proxies to a local unauthenticated HTTP proxy.

Limitations

  • The bridge currently focuses on HTTP CONNECT. SOCKS5 upstream mode rejects non-CONNECT HTTP proxy requests.
  • This does not guarantee Discord voice/WebRTC UDP proxying.
  • DLL side-loading compatibility mode is intentionally not implemented in the MVP.