bitVakt

Kernel Kit / Infix / v26.10.0latest

CVE-2026-57231

7.5high

podman4.9.5 · 4.5.0in 4 of 4 releases

Reach podman · 4 builds in 4 of 4 releases

full reviewcross-check✓ a member decided

v25.03.14.5.0
v26.01.04.9.5
v26.09.04.9.5
v26.10.0latest4.9.5
aarch64_minimal
x86_64
aarch64_minimal–
x86_64AUsed when enabled · auto
aarch64_minimal–
x86_64AUsed when enabled · auto
aarch64_minimal–
x86_64AUsed when enabled · auto
aarch64_minimal–
x86_64AUsed when enabled

Description · NVD

Podman is a tool for managing OCI containers and pods. From 1.8.1 until 5.8.4, a container image that contains a environment variable with just a key and no value can trick podman into passing that variable from the host into the container. This is made worse by the fact that using an asterisk (*) will cause podman to pass all host variables into the container. So essentially a malicious image can exfiltrate all podman environment variables that are set in the session from where the container is launched. This vulnerability is fixed in 5.8.4 and 6.0.0.

Published 2026-06-26NVD

CVSS 3.1Network · no privileges · no user interaction

How it is reached

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None

What it costs

Confidentiality
High
Integrity
None
Availability
None
Scope
Unchanged

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

References 2
Review Av26.10.0x86_64Used when enabled✓ accepted by a member, 2026-11-12 · settles 4 of 4

Fable 5.1 · high confidence · 2026-11-05

podman 4.9.5 in this tree carries the vulnerable code: pkg/specgen/generate/container.go passes the image's Config.Env through envLib.ParseSlice, whose parseEnv (pkg/env/env.go) resolves key-only entries from the host environment and expands a trailing '*' to all host variables; neither of the two Infix patches touches this path and no backport of upstream 6c431b7 is present.

Podman is selected (BR2_PACKAGE_PODMAN=y) and confd is built with --enable-containers, but no container is defined in the factory-default configuration and no finit service starts podman by default.

An operator can enable the path through the infix-containers YANG model (containers/container/image, which makes /usr/sbin/container run 'podman pull' + 'podman create') or the CLI 'container load' command; images are pulled from network registries/URLs with an insecureAcceptAnything policy, so a malicious image from the network reaches the parser once an operator configures a container.

What leaks is the environment of the root-run container helper script, not an interactive user session.

Evidence 12
  1. Key-only env entries are looked up via os.LookupEnv, and a trailing '*' copies all matching host variables - the vulnerable logic described by the CVE.

    output/build/podman-4.9.5/pkg/env/env.go:96-122 (parseEnv)

  2. ParseSlice calls parseEnv for every entry, so image env goes through the host-lookup code.

    output/build/podman-4.9.5/pkg/env/env_unix.go:8-16 (ParseSlice)

  3. envs, err = envLib.ParseSlice(inspectData.Config.Env) - image-supplied env is parsed with the host-resolving parser; upstream fix 6c431b7 replaces this with a parser that does not consult the host.

    output/build/podman-4.9.5/pkg/specgen/generate/container.go:124

  4. Only 0001-Disable-pull-retry.patch and 0002-Add-log-driver-for-syslog.patch are applied; neither modifies pkg/env or specgen env handling.

    output/build/podman-4.9.5/.applied_patches_list

  5. BR2_PACKAGE_PODMAN=y - podman is built into the target image.

    output/.config:5248

  6. When podman is selected confd is configured with --enable-containers and installs /usr/sbin/container plus finit available/container@.conf.

    package/confd/confd.mk:22-23,134-136

  7. Only mstpd, netconf and rauc are enabled; no container/podman service runs in the factory default.

    board/common/rootfs/etc/finit.d/enabled/

  8. Generated factory config contains no 'containers' section (grep -i container returns nothing).

    src/confd/bin/gen-config

  9. YANG node containers/container{name,enabled,image} lets an operator configure a container image via NETCONF/RESTCONF/CLI.

    src/confd/yang/confd/infix-containers@2026-04-20.yang:165-185

  10. Helper script runs 'podman pull' and 'podman create' for the configured image, which triggers the vulnerable env parsing.

    package/confd/container:277,483

  11. CLI 'container load <url>' command fetches OCI images from a filename or URL.

    src/klish-plugin-infix/xml/containers.xml:37,70

  12. Default policy is insecureAcceptAnything - no signature verification on pulled images.

    package/podman/containers-policy.json

Version and patches

Advisory GHSA-4hq8-gpf5-8p68: affected >=1.8.1 <5.8.4, fixed in 5.8.4 / 6.0.0. This tree has 4.9.5 (package/podman/podman.mk:7) with vulnerable parseEnv/ParseSlice intact; no backport of commit 6c431b73dbf8e4b20b778644d7a80caebdb75050. Applied patches (0001-Disable-pull-retry, 0002-Add-log-driver-for-syslog) are unrelated.

Recommendation

Backport upstream commit 6c431b7 (separate image-env parser that does not resolve host variables) as a patch under patches/podman/4.9.5/, or upgrade podman. Until then, document that operators should only run container images from trusted sources. Impact is limited to the environment of the finit/confd-launched container helper (root), not a user session.

Open questions

Exact set of environment variables present in the container helper's process environment at 'podman create' time (what would actually leak) was not enumerated; it is inherited from finit/confd, not from a user shell.

Members of Kernel Kit decide. Sign in if you are one.