Skip to content
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

net: TestDialListenerAddr triggers interactive Windows Firewall prompt #59497

Closed
bcmills opened this issue Apr 8, 2023 · 2 comments
Closed
Assignees
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done. Testing An issue that has been verified to require only test changes, not just a test failure.
Milestone

Comments

@bcmills
Copy link
Contributor

bcmills commented Apr 8, 2023

What version of Go are you using (go version)?

C:\Users\bryan\src\go\src>go version
go version devel go1.21-66cac9e1e4 Fri Apr 7 23:34:21 2023 +0000 windows/amd64

What operating system and processor architecture are you using (go env)?

go env Output
C:\Users\bryan\src\go\src>go env
set GO111MODULE=
set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\bryan\AppData\Local\go-build
set GOENV=C:\Users\bryan\AppData\Roaming\go\env
set GOEXE=.exe
set GOEXPERIMENT=
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GOMODCACHE=C:\Users\bryan\go\pkg\mod
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPATH=C:\Users\bryan\go
set GOPRIVATE=
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=C:\Users\bryan\src\go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=C:\Users\bryan\src\go\pkg\tool\windows_amd64
set GOVCS=
set GOVERSION=devel go1.21-66cac9e1e4 Fri Apr 7 23:34:21 2023 +0000
set GCCGO=gccgo
set GOAMD64=v1
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set GOMOD=C:\Users\bryan\src\go\src\go.mod
set GOWORK=
set CGO_CFLAGS=-O2 -g
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-O2 -g
set CGO_FFLAGS=-O2 -g
set CGO_LDFLAGS=-O2 -g
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -mthreads -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=C:\Users\bryan\AppData\Local\Temp\go-build4136781064=/tmp/go-build -gno-record-gcc-switches

What did you do?

go test std cmd -timeout=1h

What did you expect to see?

All tests passing without interactive prompts for anything.

What did you see instead?

A Windows Firewall dialog for net.test.exe.

I used the -run flag to narrow it down to the TestDialListenerAddr test case in particular (the regression test for #18806). I'm not sure why that particular test case triggers the Windows firewall prompt, but it does every time I run it.

The test passes even if I deny the firewall permission.

(attn @golang/windows; CC @bradfitz @ianlancetaylor @neild)

@bcmills bcmills added Testing An issue that has been verified to require only test changes, not just a test failure. OS-Windows NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Apr 8, 2023
@bcmills bcmills added this to the Backlog milestone Apr 8, 2023
@bcmills bcmills added Testing An issue that has been verified to require only test changes, not just a test failure. NeedsFix The path to resolution is known, but the work has not been done. and removed Testing An issue that has been verified to require only test changes, not just a test failure. OS-Windows labels Apr 8, 2023
@bcmills bcmills self-assigned this Apr 10, 2023
@bcmills bcmills modified the milestones: Backlog, Go1.21 Apr 10, 2023
@gopherbot gopherbot removed the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Apr 10, 2023
@gopherbot
Copy link

Change https://go.dev/cl/482163 mentions this issue: net: avoid opening an external port in TestDialListenerAddr

@gopherbot
Copy link

Change https://go.dev/cl/483696 mentions this issue: net: allow TestDialListenerAddr without an external network

gopherbot pushed a commit that referenced this issue Apr 11, 2023
As of CL 482163, this test now works when only a loopback network is
available.

Updates #59497.

Change-Id: I32be4b74bbc663eb109763ea19d79f22c63f50ae
Reviewed-on: https://go-review.googlesource.com/c/go/+/483696
Run-TryBot: Bryan Mills <bcmills@google.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
TryBot-Bypass: Bryan Mills <bcmills@google.com>
Auto-Submit: Bryan Mills <bcmills@google.com>
@golang golang locked and limited conversation to collaborators Apr 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done. Testing An issue that has been verified to require only test changes, not just a test failure.
Projects
None yet
Development

No branches or pull requests

2 participants