Docker Model Runner (DMR) is software used to manage, run, and deploy AI models using Docker. Prior to version 1.1.25, Docker Model Runner contains an SSRF vulnerability in its OCI registry token exchange flow. When pulling a model, Model Runner follows the realm URL from the registry's WWW-Authenticate header without validating the scheme, hostname, or IP range. A malicious OCI registry can set the realm to an internal URL (e.g., http://127.0.0.1:3000/), causing Model Runner running on the host to make arbitrary GET requests to internal services and reflect the full response body back to the caller. Additionally, the token exchange mechanism can relay data from internal services back to the attacker-controlled registry via the Authorization: Bearer header. This issue has been patched in version 1.1.25. For Docker Desktop users, enabling Enhanced Container Isolation (ECI) blocks container access to Model Runner, preventing exploitation. However, if the Docker Model Runner is exposed to localhost over TCP in specific configurations, the vulnerability is still exploitable.
Docker Model Runner versions prior to 1.0.16 expose an unauthenticated POST endpoint that allows attackers with network access to inject arbitrary runtime flags to the underlying inference server. This can be exploited to overwrite arbitrary files accessible to the Model Runner process, including critical Docker Desktop VM disk files, potentially destroying containers, images, volumes, and build history. The vulnerability is fixed in Docker Model Runner 1.0.16 and Docker Desktop 4.61.0. A workaround involves enabling Enhanced Container Isolation to block container access to Model Runner, though certain configurations exposing Model Runner over localhost TCP remain vulnerable.