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

cmd/go: TestACL fails on Windows when set was not done in English #26658

Closed
iwdgo opened this issue Jul 28, 2018 · 1 comment
Closed

cmd/go: TestACL fails on Windows when set was not done in English #26658

iwdgo opened this issue Jul 28, 2018 · 1 comment

Comments

@iwdgo
Copy link
Contributor

iwdgo commented Jul 28, 2018

Please answer these questions before submitting your issue. Thanks!

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

Go 1.11beta2 as bootstrap and
go version devel +0090c13c91 Sat Jul 28 01:15:16 2018 +0000 windows/amd64

Does this issue reproduce with the latest release?

Yes

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

set GOARCH=amd64
set GOBIN=
set GOCACHE=C:\Users\()\AppData\Local\go-build
set GOEXE=.exe
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOOS=windows
set GOPATH=C:\Users\()\Documents\Google\
set GOPROXY=
set GORACE=
set GOROOT=C:\Go
set GOTMPDIR=
set GOTOOLDIR=C:\Go\pkg\tool\windows_amd64
set GCCGO=gccgo
set CC=gcc
set CXX=g++
set CGO_ENABLED=0
set GOMOD=
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\()\AppData\Local\Temp\go-build944532010=/tmp/go-build -gno-record-gcc-switches

What did you do?

>all.bat

If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.

What did you expect to see?

ok cmd/go

What did you see instead?

--- FAIL: TestACL (0.24s)
    go_windows_test.go:99: icacls failed: exit status 1332
        guest: No mapping between account names and security IDs was done.
        Successfully processed 0 files; Failed processing 1 files

The cause is the usage of the "guest" account. This account may not exist if Windows was initially configured in another language. The proposed fix is to use the "Guests" group which keeps the test valid and will always succeed whatever version of Windows as stated by
https://docs.microsoft.com/en-us/windows/security/identity-protection/access-control/local-accounts
and https://support.microsoft.com/en-us/help/243330/well-known-security-identifiers-in-windows-operating-systems

To avoid language issues and to keep the test simple, the SID of the account should be used.

@gopherbot
Copy link

Change https://golang.org/cl/126598 mentions this issue: cmd/go: uses SID of group Guests to test ACL

@golang golang locked and limited conversation to collaborators Jul 28, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants