SOCKS5 Proxy hosted on GitHub Codespaces.
Proof of concept Chisel's SOCKS5 Proxy running on GitHub Codespaces.
flowchart LR
subgraph Client [Client]
Browser --> |SOCKS5| ChiselClient[Chisel Client]
end
ChiselClient --> |WebSocket| PortForwarding[HTTP Port Forwarding]
subgraph Codespaces [GitHub Codespaces]
PortForwarding --> |WebSocket| ChiselServer[Chisel Server]
subgraph ChiselServerInternals [Chisel Server]
ChiselServer --> SOCKS5[SOCKS5 Proxy]
end
end
SOCKS5 --> Internet
flowchart LR
subgraph Client [Client]
Browser --> |SOCKS5| ChiselClient[Chisel Client]
end
ChiselClient --> |WebSocket| Cloudflare[Cloudflare Edge]
Cloudflare <--> |Cloudflare Tunnel| cloudflared[Cloudflare Tunnel client]
subgraph Codespaces [GitHub Codespaces]
cloudflared --> |WebSocket| ChiselServer[Chisel Server]
subgraph ChiselServerInternals [Chisel Server]
ChiselServer --> SOCKS5[SOCKS5 Proxy]
end
end
SOCKS5 --> Internet
You need Chisel installed since GitHub Codespaces only allows forwarding of HTTP protocol, and WebSocket can be used to tunnel SOCKS5 over HTTP.
- Create a repository on GitHub using this template by clicking "Use this template" and then click "Create a new repository".
- On your own repository, click Code, and click Codespaces tab.
- Click "Create codespace on main".
- Wait for the codespace to build.
- After the codespace is built, a terminal will appear, don't do anything, wait for Chisel to run automatically.
- When the text
server: Listening on http://0.0.0.0:8080
appeared, Chisel is now running. - Go to ports tab.
- Right click port 8080, select "Port Visibility", then select "Public".
- Copy the Local Address of port 8080.
- On your computer, connect to your Chisel websocket by running
chisel client <your local address> socks
. - Connect your browser to Chisel's SOCKS5 proxy by setting proxy settings to
localhost:1080
.
This method is shown to be faster in speed test than using GitHub Codespaces HTTP port forwarding.
- Click the meatballs menu.
- Click "New with options...".
- Under the Dev container configuration dropbox, select "SOCKS5 Proxy Codespaces via cloudflared".
- Wait for the codespace to build.
- After the codespace is built, a terminal will appear, don't do anything, wait for Chisel and cloudflared to run automatically.
- When the text
Your quick Tunnel has been created! Visit it at (it may take some time to be reachable):
appeared, Chisel and cloudflared is now running. - Under that text, there is an address like
https://<randomly-generated>.trycloudflare.com
, this is your address. - On your computer, connect to your Chisel websocket by running
chisel client <your address> socks
. - Connect your browser to Chisel's SOCKS5 proxy by setting proxy settings to
localhost:1080
.
Don't forget to gracefully shut down the proxy by pressing Ctrl+C and to delete the codespace after usage.
You can change your IP address geolocation by selecting a region on the dropbox when using "New with options...".