CVE-2025-66469

NiceGUI Reflected XSS in ui.add_css, ui.add_scss, and ui.add_sass via Style Injection

Published Dec 8, 2025 CVSS 3.1 · 6.1 Medium EPSS < 1% KEV · Not listed
Description
NiceGUI is a Python-based UI framework. Versions 3.3.1 and below are vulnerable to Reflected XSS through its ui.add_css, ui.add_scss, and ui.add_sass functions. The functions lack proper sanitization or encoding for the JavaScript context they generate. An attacker can break out of the intended <style> or <script> tags by injecting closing tags (e.g., </style> or </script>), allowing for the execution of arbitrary JavaScript. This issue is fixed in version 3.4.0.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-72qc-wxch-74mg NiceGUI Reflected XSS in ui.add_css, ui.add_scss, and ui.add_sass via Style Injection
History
Type Values Removed Values Added
First Time appeared Zauberzeug
Zauberzeug nicegui
CPEs cpe:2.3:a:zauberzeug:nicegui:*:*:*:*:*:*:*:*
Vendors & Products Zauberzeug
Zauberzeug nicegui
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Nicegui
Nicegui nicegui
Vendors & Products Nicegui
Nicegui nicegui
Type Values Removed Values Added
Description NiceGUI is a Python-based UI framework. Versions 3.3.1 and below are vulnerable to Reflected XSS through its ui.add_css, ui.add_scss, and ui.add_sass functions. The functions lack proper sanitization or encoding for the JavaScript context they generate. An attacker can break out of the intended <style> or <script> tags by injecting closing tags (e.g., </style> or </script>), allowing for the execution of arbitrary JavaScript. This issue is fixed in version 3.4.0.
Title NiceGUI Reflected XSS in ui.add_css, ui.add_scss, and ui.add_sass via Style Injection
Weaknesses CWE-79
References
Metrics cvssV3_1

{'score': 6.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Dec 9, 2025, 4:03 PM
Reserved
Dec 2, 2025, 3:43 PM
Status
Analyzed
Published
Dec 9, 2025, 12:15 AM
Modified
Oct 19, 2026, 7:10 PM