All vulnerabilities
CVE-2026-57231GHSA-4hq8-gpf5-8p68GO-2026-6594

github.com/containers/podman/v5: Podman: Malformed Image can trick podman run into leaking host environment variables into the container

podman-container-tools github.com/containers/podman/v5goLibraries & packages
CVSS
7.5High
ExploitationNo known exploitationNot in CISA KEV, which does not prove it is unexploitedCISA KEV
Exploit odds (EPSS)0.44%Chance of exploitation activity in the next 30 days, higher than 36% of CVEs. Scored 23 Oct 2026FIRST EPSS
Fixed in5.8.4Also 6.0.0GitHub
Published26 Jun 2026Updated 1 Oct 2026CVE List

What fixes it

  • 5.8.4github.com/containers/podman/v5, goGitHubgo get github.com/containers/podman/v5@v5.8.4
  • 6.0.0go.podman.io/podman/v6, goGitHubgo get go.podman.io/podman/v6@v6.0.0
  • 5.8.4github.com/containers/podman/v5, GoOSVgo get github.com/containers/podman/v5@v5.8.4
  • 6.0.0go.podman.io/podman/v6, GoOSVgo get go.podman.io/podman/v6@v6.0.0

A fixed version on one release line is not the upgrade target for every line. Check your exact version and any vendor backports.

Description

Summary

An 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.

Details

podman run allows --env VAR1 or --env VAR* which will read the variable values from the current environment and then passes them into the container. However because the same parsing logic was reused for the image config env section that means that an image variable could also gain access to that.

Patch

That image spec requires the env variables to be in the form of key=value, so to address this invalid formatted variables get rejected and the container will not run.

Fixed in https://github.com/podman-container-tools/podman/commit/6c431b73dbf8e4b20b778644d7a80caebdb75050

Workaround

Do not run untrusted images. Before running an image consider inspecting the config with podman image inspect --format '{{.Config.Env}}' <image> and check for any variables that do not have a value assigned.

Text from GitHub Advisory Database

Affected versions 13

  • github.com/containers/podman/v5, go< 5.8.4GitHub
  • go.podman.io/podman/v6, go< 6.0.0GitHub
  • github.com/containers/podman/v4, go<= 4.9.5GitHub
  • github.com/containers/podman/v3, go<= 3.4.7GitHub
  • github.com/containers/podman/v2, go<= 2.2.1GitHub
  • github.com/containers/podman, go>= 1.8.1, < 5.8.4GitHub
  • podmanaffected: >= 1.8.1, < 5.8.4CVE List
  • github.com/containers/podman/v5, Gofrom first release, fixed in 5.8.4OSV
  • go.podman.io/podman/v6, Gofrom first release, fixed in 6.0.0OSV
  • github.com/containers/podman/v4, Gofrom first release, through 4.9.5OSV
  • github.com/containers/podman/v3, Gofrom first release, through 3.4.7OSV
  • github.com/containers/podman/v2, Gofrom first release, through 2.2.1OSV
  • github.com/containers/podman, Gofrom 1.8.1OSV

References 6