Skip to content

Security: stored XSS via language name in admin panel#8607

Merged
AngelFQC merged 1 commit into
masterfrom
security/auto-fix-GHSA-j9jg-h6cw-jj7v
Jun 17, 2026
Merged

Security: stored XSS via language name in admin panel#8607
AngelFQC merged 1 commit into
masterfrom
security/auto-fix-GHSA-j9jg-h6cw-jj7v

Conversation

@AngelFQC

Copy link
Copy Markdown
Member

Problem

The admin language management list rendered the stored original_name of a language directly inside an HTML value="..." attribute (and also in a <label> and a table cell) without HTML-attribute encoding. A language name containing a double quote could break out of the attribute and inject an event handler, executing arbitrary JavaScript in the browser of any other administrator who opened the language list/edit form — an admin-to-admin stored XSS.

Fix

Encode original_name with htmlspecialchars($value, ENT_QUOTES, 'UTF-8') at every point where it is rendered (the text input value, the platform-language label, and the read-only table cell). ENT_QUOTES neutralizes the double-quote attribute breakout.

Invariant now enforced

The stored language name is always emitted as inert, attribute-safe text; it can no longer terminate the value attribute or inject markup/handlers.

OWASP control

A03:2021 – Injection (Stored Cross-Site Scripting).

Refs GHSA-j9jg-h6cw-jj7v

🤖 Generated with Claude Code

The admin language list rendered the stored original_name directly inside an
input value attribute (and a label / table cell) without HTML-attribute
encoding, so a name containing a double quote could break out of the value
attribute and inject an event handler that runs in another admin's browser.

Encode the value with htmlspecialchars(..., ENT_QUOTES, 'UTF-8') at every
render point of original_name.

Refs GHSA-j9jg-h6cw-jj7v

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@AngelFQC AngelFQC merged commit 8ba2020 into master Jun 17, 2026
2 of 12 checks passed
@AngelFQC AngelFQC deleted the security/auto-fix-GHSA-j9jg-h6cw-jj7v branch June 18, 2026 22:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant