-
Wander Lairson Costa authored
If the caller set ups a Credential in os/exec.Command, os/exec.Command.Start will end up calling setgroups(2), even if no supplementary groups were given. Only root can call setgroups(2) on BSD kernels, which causes Start to fail for non-root users when they try to set uid and gid for the new process. We fix by introducing a new field to syscall.Credential named NoSetGroups, and setgroups(2) is only called if it is false. We make this field with inverted logic to preserve backward compatibility. RELNOTES=yes Change-Id: I3cff1f21c117a1430834f640ef21fd4e87e06804 Reviewed-on: https://go-review.googlesource.com/36697Reviewed-by: Ian Lance Taylor <iant@golang.org>
79f6a5c7
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
example_test.go | ||
exec.go | ||
exec_posix.go | ||
exec_posix_test.go | ||
exec_test.go | ||
internal_test.go | ||
lp_plan9.go | ||
lp_test.go | ||
lp_unix.go | ||
lp_unix_test.go | ||
lp_windows.go | ||
lp_windows_test.go |