All vulnerabilities

Servers and applications

GHSA-9xr4-r82x-p44j

Compose `use_api_socket` bypasses the Hide bind mounts for non-administrators setting

Severity
High 8.7
Published
19 Nov 2026
Last changed
19 Nov 2026
Added to UpHeron
19 Nov 2026
Fixed in
2.39.9, 2.45.4, 3.1.0
Weakness
Improper access control (CWE-284)Incorrect authorization (CWE-863)
Attack
Over the network · Needs a user account · No user action needed
Attacker can
Read data · Change data · Take it down
CVSS vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Sources
Project advisories (GitHub)

Description

Portainer lets non-administrator users deploy Docker Compose stacks to an environment, and when the per-environment setting Hide bind mounts for non-administrators is enabled, the stack validator IsValidStackFile rejects bind mounts declared in top-level volumes and each service's volumes. It never inspected a service's use_api_socket flag. When that flag is set, Docker Compose adds a bind mount of the Docker socket (/var/run/docker.sock) and a DOCKER_CONFIG carrying registry credentials to the service while bringing the stack up, after Portainer's validation has already passed. Any authenticated user with the Standard user role and stack-management access to a Docker standalone environment can exploit this.

Portainer operates a shared-responsibility security model: administrators decide how permissive each environment's security settings are, and Portainer is responsible for enforcing those settings as configured.

From portainer/portainer's security advisory. Shortened; the full text is there.

Workarounds

Administrators who cannot immediately upgrade can reduce exposure by:

  • Hide the use of Stacks for non-administrators. In each Docker environment's settings, enable Hide the use of Stacks for non-administrators. Portainer then refuses stack creation and management from non-administrator users on the server side, which blocks this vector. It removes self-service stack deployment for those users; users with the environment administrator role can still deploy stacks.
  • Limit standard-user environment access.
Workarounds as given by portainer/portainer's security advisory.

Affected software

SoftwareAffected versions
PortainerServers and applications · github:portainer/portainer
  • From 2.39.0 before 2.39.9
  • From 2.40.0 before 2.45.4
  • From 3.0.0 before 3.1.0

About Portainer

Open source software to manage Docker, docker swarm and Kubernetes

From Wikidata, CC0 1.0.
Docker Hub pulls
1,590,442,292Docker Hub, 15 Nov 2026
GitHub stars
38,831GitHub, 15 Nov 2026
Forks
2,940GitHub, 15 Nov 2026
Latest release
2.45.3GitHub, 15 Nov 2026
Released
21 Oct 2026GitHub
License
ZlibGitHub
First published on GitHub
19 May 2016GitHub

References