Data the peer already sent stays unread in the stream and keeps occupying the connection level receive window of the quic session. When the local app aborts a download, that data is never consumed, so the credit is only returned when the read side of the stream is cancelled. Without the cancellation the window drains. The initial stream window is 512 KB and the initial connection window is 768 KB, so a few aborted downloads are enough to exhaust it. Once that happens the peer cannot send data on any stream of the session: new requests still reach the server, the server still acknowledges, there is no idle timeout and no error in the log, and the client waits forever for a response. Only a new session clears it. The test aborts three downloads of a body that is much larger than the flow control window, and then checks that the tunnel still forwards. The client reads very slowly, so the data piles up in the connection that carries it. Verified against go-gost/x#135: with the fix reverted the test fails with a timeout on the request that follows the aborted downloads, which is the reported symptom.
GO Simple Tunnel
A simple security tunnel written in golang
Features
- Listening on multiple ports
- Multi-level forwarding chain
- Rich protocol
- TCP/UDP port forwarding
- Reverse Proxy and Tunnel
- TCP/UDP transparent proxy
- DNS resolver and proxy
- TUN/TAP device and TUN2SOCKS
- Load balancing
- Routing control
- Admission control
- Bandwidth/Rate Limiter
- Plugin System
- Prometheus metrics
- Dynamic configuration
- Web API
- GUI/WebUI
Overview
There are three main ways to use GOST as a tunnel.
Proxy
As a proxy service to access the network, multiple protocols can be used in combination to form a forwarding chain for traffic forwarding.
Port Forwarding
Mapping the port of one service to the port of another service, you can also use a combination of multiple protocols to form a forwarding chain for traffic forwarding.
Reverse Proxy
Use tunnel and intranet penetration to expose local services behind NAT or firewall to public network for access.
Installation
Binary files
https://github.com/go-gost/gost/releases
Packages (DEB/RPM)
Download the package for your architecture from the releases page (amd64, amd64v3, arm64):
# Debian/Ubuntu
sudo apt install ./gost_<version>_linux_amd64.deb
# RHEL/Fedora
sudo dnf install ./gost_<version>_linux_amd64.rpm
The amd64v3 package requires an AVX2-capable CPU (x86-64-v3); use amd64 otherwise.
The packages ship a systemd service, but it is not enabled automatically: create /etc/gost/gost.yml first (see /usr/share/doc/gost/examples/gost.yml), then run sudo systemctl enable --now gost. Without a config file the service is skipped rather than failing.
install script
# install latest from [https://github.com/go-gost/gost/releases](https://github.com/go-gost/gost/releases)
bash <(curl -fsSL https://github.com/go-gost/gost/raw/master/install.sh) --install
# select version for install
bash <(curl -fsSL https://github.com/go-gost/gost/raw/master/install.sh)
From source
git clone https://github.com/go-gost/gost.git
cd gost/cmd/gost
go build
Docker
docker run --rm gogost/gost -V
Tools
GUI
WebUI
Shadowsocks Android
hamid-nazari/ShadowsocksGostPlugin
Support
Wiki: https://gost.run
YouTube: https://www.youtube.com/@gost-tunnel
Telegram: https://t.me/gogost
Google group: https://groups.google.com/d/forum/go-gost
Legacy version: v2.gost.run



