DockerCLI/cli/config/credentials
Tibor Vass 8d199d5bba Use golang.org/x/sys/execabs
On Windows, the os/exec.{Command,CommandContext,LookPath} functions
resolve command names that have neither path separators nor file extension
(e.g., "git") by first looking in the current working directory before
looking in the PATH environment variable.
Go maintainers intended to match cmd.exe's historical behavior.

However, this is pretty much never the intended behavior and as an abundance of precaution
this patch prevents that when executing commands.
Example of commands that docker.exe may execute: `git`, `docker-buildx` (or other cli plugin), `docker-credential-wincred`, `docker`.

Note that this was prompted by the [Go 1.15.7 security fixes](https://blog.golang.org/path-security), but unlike in `go.exe`,
the windows path lookups in docker are not in a code path allowing remote code execution, thus there is no security impact on docker.

Signed-off-by: Tibor Vass <tibor@docker.com>
2021-01-26 17:18:04 +00:00
..
credentials.go Remove docker api dependency from cli/config 2019-01-31 21:25:43 +00:00
default_store.go Use golang.org/x/sys/execabs 2021-01-26 17:18:04 +00:00
default_store_darwin.go defaultCredentialStore: make this a function 2017-09-20 11:14:27 -06:00
default_store_linux.go config/credentials: don't run 'pass' to detect it 2018-06-29 11:38:39 -07:00
default_store_unsupported.go Fix compilation of defaultCredentialStore() on unsupported platforms 2018-02-10 15:30:32 +00:00
default_store_windows.go defaultCredentialStore: make this a function 2017-09-20 11:14:27 -06:00
file_store.go Remove docker api dependency from cli/config 2019-01-31 21:25:43 +00:00
file_store_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-23 00:28:55 +01:00
native_store.go Remove docker api dependency from cli/config 2019-01-31 21:25:43 +00:00
native_store_test.go bump gotest.tools v3.0.1 for compatibility with Go 1.14 2020-02-23 00:28:55 +01:00