GitHub Advisoryadvisory · PyPI

GHSA-rqj7-6wrp-6g2g Open WebUI: POST /api/v1/images/edit bypasses the global image-edit switch and the per-user image-generation permission

MEDIUM Published 2026-07-24 Modified 2026-07-24 Official page ↗
Aliases
CVE-2026-59227
Ecosystem
PyPI
Packages
open-webui
Severity
Moderate
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L
Weaknesses
CWE-862, CWE-863
Reviewed
2026-07-24

Affected packages

• PyPI open-webui: >= 0.8.11, < 0.10.0 → fixed in 0.10.0

Description

Summary `POST /api/v1/images/edit` performed no authorization beyond requiring a verified account. Every other image-editing surface in Open WebUI enforces the global image-edit switch and the per-user image-generation permission — the `/api/v1/images/generations` route, the built-in `edit_image` tool, and the chat image-edit middleware — but the direct edit route enforced neither. A verified non-admin user could therefore invoke server-side image editing, reaching the configured image-edit provider with the administrator's credentials, even when the administrator had globally disabled image editing (`ENABLE_IMAGE_EDIT=False`) or denied that user image-generation permission. The image-editing UI is surfaced only to administrators (Playground), so the route additionally exposed an admin-only capability to any verified user. Impact An authenticated, non-admin user can: • bypass the global `ENABLE_IMAGE_EDIT=False` administrator control; • bypass a denied per-user/group `features.image_generation` permission; • cause the server to send billable image-edit requests to the configured provider (OpenAI-compatible, Gemini, or ComfyUI) using administrator-configured credentials (`IMAGES_EDIT_OPENAI_API_KEY` for the OpenAI engine). No cross-user data is exposed and the provider credentials are never returned to the caller; the impact is the control/permission bypass and the associated billable resource consumption. Affected Versions `>= 0.8.11, Content-Type: application/json {"image":"data:image/png;base64,","prompt":"edit","model":"gpt-image-1"} ``` The request reaches the configured image-edit provider and returns an edited image despite the disabled control/permission. Patch The direct route is split from its shared implementation (mirroring `generate_images`/`image_generations`): a thin `/edit` route now enforces `ENABLE_IMAGE_EDIT` and the per-user `features.image_generation` permission before delegating to the shared `image_edits()` implementation. The internal callers (the `edit_image` tool and the chat middleware) call the implementation directly and already gate themselves, so they are unaffected.

Related

Alias · CVE (1)

  • CVE-2026-59227 Open WebUI is an extensible, feature-rich, and user-friendly self-hosted AI platform. vulnerability

Weakness · CWE (2)

  • CWE-862 Missing Authorization weakness
  • CWE-863 Incorrect Authorization weakness

References