CVE-2022-41716
Assigner: Go
Published: 2022-11-02T15:28:19.574Z
State: PUBLISHED
title: Unsanitized NUL in environment variables on Windows in syscall and os/exec
descriptions: value: Due to unsanitized NUL values, attackers may be able to maliciously set environment variables on Windows. In syscall.StartProcess and os/exec.Cmd, invalid environment variable values containing NUL values are not properly checked for. A malicious environment variable value can exploit this behavior to set a value for a different environment variable. For example, the environment variable string "A=B\x00C=D" sets the variables "A=B" and "C=D".
affected: vendor: Go standard library
product: syscall
collectionURL: https://pkg.go.dev
packageName: syscall
versions: version: 0
lessThan: 1.18.8
status: affected
versionType: semver
version: 1.19.0-0
lessThan: 1.19.3
status: affected
versionType: semver
platforms: windows
programRoutines: StartProcess
defaultStatus: unaffected
vendor: Go standard library
product: os/exec
collectionURL: https://pkg.go.dev
packageName: os/exec
versions: version: 0
lessThan: 1.18.8
status: affected
versionType: semver
version: 1.19.0-0
lessThan: 1.19.3
status: affected
versionType: semver
platforms: windows
programRoutines: Cmd.environ
dedupEnv
dedupEnvCase
Cmd.CombinedOutput
Cmd.Environ
Cmd.Output
Cmd.Run
Cmd.Start
defaultStatus: unaffected
problemTypes: descriptions: description: CWE-158: Improper Neutralization of Null Byte or NUL Character
credits: value: RyotaK (https://twitter.com/ryotkak)