Skip to content

proxy.golang.org: wsarecv: An existing connection was forcibly closed by the remote host from ZSCALER, INC ip. #71704

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
nitin455 opened this issue Feb 13, 2025 · 6 comments

Comments

@nitin455
Copy link

nitin455 commented Feb 13, 2025

Go version

go version go1.24.0 windows/amd64

Output of go env in your module/workspace:

set AR=ar
set CC=gcc
set CGO_CFLAGS=-O2 -g
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-O2 -g
set CGO_ENABLED=0
set CGO_FFLAGS=-O2 -g
set CGO_LDFLAGS=-O2 -g
set CXX=g++
set GCCGO=gccgo
set GO111MODULE=
set GOAMD64=v1
set GOARCH=amd64
set GOAUTH=netrc
set GOBIN=
set GOCACHE=C:\Users\xxx\AppData\Local\go-build
set GOCACHEPROG=
set GODEBUG=
set GOENV=C:\Users\xxx\AppData\Roaming\go\env
set GOEXE=.exe
set GOEXPERIMENT=
set GOFIPS140=off
set GOFLAGS=
set GOGCCFLAGS=-m64 -fno-caret-diagnostics -Qunused-arguments -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=C:\Users\xxx\AppData\Local\Temp\go-build994176254=/tmp/go-build -gno-record-gcc-switches
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GOMOD=C:\Users\xxx\go\src\xxx\go.mod
set GOMODCACHE=C:\Users\xxx\go\pkg\mod
set GONOPROXY=gitlab.com/xxx/*
set GONOSUMDB=gitlab.com/xxx/*
set GOOS=windows
set GOPATH=C:\Users\xxx\go
set GOPRIVATE=gitlab.com/xxx/*
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=C:\Program Files\Go
set GOSUMDB=sum.golang.org
set GOTELEMETRY=local
set GOTELEMETRYDIR=C:\Users\xxx\AppData\Roaming\go\telemetry
set GOTMPDIR=
set GOTOOLCHAIN=auto
set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64
set GOVCS=
set GOVERSION=go1.24.0
set GOWORK=
set PKG_CONFIG=pkg-config

What did you do?

When I am trying to run command go mod tidy or go build, i am getting below error.

PS C:\Users\xxx\go\src\xxx> go mod tidy
go: downloading golang.org/x/sys v0.18.0
go: downloading github.com/google/pprof v0.0.0-20230309165930-d61513b1440d
go: gitlab.com/xxx/xxx imports
        gopkg.in/DataDog/dd-trace-go.v1/ddtrace/tracer imports
        golang.org/x/sys/windows: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.
go: gitlab.com/xxx/xxx  imports
        gopkg.in/DataDog/dd-trace-go.v1/profiler imports
        github.com/google/pprof/profile: github.com/google/[email protected]: read "https://proxy.golang.org/github.com/google/pprof/@v/v0.0.0-20230309165930-d61513b1440d.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.
go: gitlab.com/xxx/xxx imports
        gopkg.in/DataDog/dd-trace-go.v1/ddtrace/tracer imports
        gopkg.in/DataDog/dd-trace-go.v1/internal/osinfo imports
        golang.org/x/sys/windows/registry: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.
go: gitlab.com/xxx/xxx/internal/model/account imports
        github.com/go-playground/validator/v10 imports
        golang.org/x/crypto/sha3 imports
        golang.org/x/sys/cpu: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.       
go: gitlab.com/xxx/xxx/internal/setup imports
        github.com/labstack/gommon/log imports
        github.com/mattn/go-isatty imports
        golang.org/x/sys/unix: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.

What did you see happen?

I am unable to run or build my application on my system. It always give connection closed error.

PS C:\Users\xxx\go\src\xxx> go mod tidy
go: downloading golang.org/x/sys v0.18.0
go: downloading github.com/google/pprof v0.0.0-20230309165930-d61513b1440d
go: gitlab.com/xxx/xxx imports
        gopkg.in/DataDog/dd-trace-go.v1/ddtrace/tracer imports
        golang.org/x/sys/windows: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.
go: gitlab.com/xxx/xxx  imports
        gopkg.in/DataDog/dd-trace-go.v1/profiler imports
        github.com/google/pprof/profile: github.com/google/[email protected]: read "https://proxy.golang.org/github.com/google/pprof/@v/v0.0.0-20230309165930-d61513b1440d.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.
go: gitlab.com/xxx/xxx imports
        gopkg.in/DataDog/dd-trace-go.v1/ddtrace/tracer imports
        gopkg.in/DataDog/dd-trace-go.v1/internal/osinfo imports
        golang.org/x/sys/windows/registry: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.
go: gitlab.com/xxx/xxx/internal/model/account imports
        github.com/go-playground/validator/v10 imports
        golang.org/x/crypto/sha3 imports
        golang.org/x/sys/cpu: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.       
go: gitlab.com/xxx/xxx/internal/setup imports
        github.com/labstack/gommon/log imports
        github.com/mattn/go-isatty imports
        golang.org/x/sys/unix: golang.org/x/[email protected]: read "https://proxy.golang.org/golang.org/x/sys/@v/v0.18.0.zip": read tcp 192.168.x.x:xxxx->142.250.196.177:443: wsarecv: An existing connection was forcibly closed by the remote host.

What did you expect to see?

I am expecting that my application should run normally without errors.

@Jorropo
Copy link
Member

Jorropo commented Feb 13, 2025

What is your public IP ? (for the network address, so 24 first bits)

@nitin455
Copy link
Author

What is your public IP ? (for the network address, so 24 first bits)

136.226.255

@Jorropo Jorropo changed the title golang.org/x/sys: wsarecv: An existing connection was forcibly closed by the remote host. proxy.golang.org: wsarecv: An existing connection was forcibly closed by the remote host from ZSCALER, INC ip. Feb 13, 2025
@Jorropo
Copy link
Member

Jorropo commented Feb 13, 2025

Thx, here are the networks https://bgpview.io/ip/136.226.255.0.

@Jorropo
Copy link
Member

Jorropo commented Feb 13, 2025

For completeness can you try go mod tidy with ENV GOPROXY set to direct ?
It might work, then it's very likely an issue with the proxy altho it should still be fixed even if GOPROXY=direct works.

@seankhliao
Copy link
Member

if zscaler is closing your connections, please talk to your network admin.

@seankhliao seankhliao closed this as not planned Won't fix, can't repro, duplicate, stale Feb 13, 2025
@nitin455
Copy link
Author

There was ZScaler in between and it was making problem. Issue got resolved after disabling ZScaler.

Thanks everyone for your valuable inputs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants