{"id":"CVE-2026-94565","aliases":["CVE-2026-94565","GHSA-662q-v5rm-78gm"],"related":[],"kind":"vulnerability","state":"published","title":"NukeViet CMS: Unauthenticated Stored XSS in the Contact module","summary":"NukeViet CMS is a multi Content Management System. From the 3.x release line until 4.6.01, an unauthenticated visitor can submit a Contact module message containing an event-handler attribute prefixed by a slash. NukeViet\\Core\\Request::filterTags() tokenizes attributes using only ASCII spaces, so it sees /onerror and misses the ^on denylist, while the browser treats the slash as a separator and activates onerror. The message is stored and rendered without output encoding in the administration panel, which lacks a Content Security Policy, allowing same-origin JavaScript execution when an administrator opens the message. This issue is fixed in version 4.6.01.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"NukeViet CMS is a multi Content Management System. From the 3.x release line until 4.6.01, an unauthenticated visitor can submit a Contact module message containing an event-handler attribute prefixed by a slash. NukeViet\\Core\\Request::filterTags() tokenizes attributes using only ASCII spaces, so it sees /onerror and misses the ^on denylist, while the browser treats the slash as a separator and activates onerror. The message is stored and rendered without output encoding in the administration panel, which lacks a Content Security Policy, allowing same-origin JavaScript execution when an administrator opens the message. This issue is fixed in version 4.6.01.","source":"cvelist"},{"lang":"en","text":"### Summary\nA stored-XSS vulnerability in the Contact module allows any unauthenticated user to inject malicious Javascript.\n\n### Details\nNukeViet's central input filter (`NukeViet\\Core\\Request::filterTags`), applied to virtually all `POST` data, is a denylist HTML sanitizer. Its most important rule strips any attribute whose name matches `/^on/i` (event handlers). This rule is bypassable through an **HTML parser differential**: the filter tokenizes a tag's attributes by splitting on ASCII space (`0x20`) only, whereas browsers also separate attributes on `/`. By inserting a `/` immediately before an event-handler name, the attacker makes the filter read the attribute name as `/onerror` — which does **not** start with `on`, so the denylist misses it — while the browser parses it as `onerror` and fires it.\n\nThe payload survives the entire filter chain unmodified and is stored and served **raw** (no output encoding) into the administration panel, which sends **no Content-Security-Policy**:\n\n```\nINPUT  : <img src=x /onerror=alert(document.domain)>\nSTORED : <img src=\"x\" /onerror=\"alert(document.domain)\" />\nADMIN  : <td colspan=\"2\"><img src=\"x\" /onerror=\"alert(document.domain)\" /></td>\n```\n\nBecause the handler executes in the **same origin** as the admin panel, an unauthenticated attacker who submits a crafted contact message obtains arbitrary JavaScript execution in the session of any administrator who opens it — enabling administrator **account takeover**.\n\n### PoC\n#### Minimal payload\n\n```html\n<img src=x /onerror=alert(document.domain)>\n```\n\n`alert(document.domain)` displays the site's real origin (e.g. the target host), proving **same-origin** execution.\n\n#### Manual reproduction (fresh 4.6.00 install, default config)\n\n1. As an anonymous visitor open `/contact/`; set the **message** field to the payload above.\n2. Solve the CAPTCHA and submit (form returns `status: ok`).\n3. Log in to the admin panel; open **Admin → Contact** and view the message\n   (`admin/index.php?nv=contact&op=view&id=<id>`).\n4. `onerror` fires on view; `alert()` shows the panel's own origin.\n\n### Impact\nAn unauthenticated attacker achieves arbitrary JavaScript execution in the **same origin** as the NukeViet admin panel, running in the session of any administrator who views the malicious contact message. Possible attacks:\n1. Super admin account persistence\n2. RCE via admin functions\n\n### Mitigation\n1. **Tokenize attributes the way the HTML spec does.** In `filterTags()`, treat `/` (and all HTML    whitespace: tab, LF, FF, CR, space) as attribute separators, so `/onerror` is parsed as the token `onerror` and caught by the existing denylist. Equivalently, strip leading `/` and other non-name characters from the attribute name before the `^on` test.\n2. **Do not preserve non-conforming attribute names.** Reject/normalize any attribute whose name is not `[A-Za-z][A-Za-z0-9-]*` after normalization, rather than emitting `/onerror` verbatim.\n3. **Prefer an allowlist of attributes** over the `^on` denylist; drop anything not explicitly permitted for the element.","format":"markdown","source":"ghsa"}],"published":"2026-11-20T18:46:11.473Z","modified":"2026-11-30T20:45:09.965Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N","score":9.3,"rating":"CRITICAL"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N","score":9.3,"rating":"CRITICAL"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N","score":9.3,"rating":"CRITICAL"}],"cwes":["CWE-79"],"affected":[{"ranges":[{"version":">= 3.0.0, < 4.6.01","status":"affected"}],"vendor":"nukeviet","product":"nukeviet","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"3.0.0","status":"affected","fixed":"4.6.01"}],"ecosystem":"Packagist","package":"nukeviet/nukeviet","purl":"pkg:composer/nukeviet/nukeviet","source":"ghsa"}],"references":[{"url":"https://github.com/nukeviet/nukeviet/security/advisories/GHSA-662q-v5rm-78gm","tags":["exploit","web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/nukeviet/nukeviet/commit/ef90780e50d54384019a36aa2bcf9fd58776f698","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/nukeviet/nukeviet/releases/tag/4.6.01","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nukeviet.vn/vi/news/Tin-tuc/thong-bao-phat-hanh-nukeviet-4-6-01-857.html","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-94565","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/nukeviet/nukeviet","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"no","technicalImpact":"total","date":"2026-11-20T19:14:05.249Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-94565","url":"https://www.cve.org/CVERecord?id=CVE-2026-94565","licence":"CVE Terms of Use","modified":"2026-11-20T19:14:26.271Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-662q-v5rm-78gm","url":"https://github.com/advisories/GHSA-662q-v5rm-78gm","licence":"CC-BY-4.0","modified":"2026-11-30T20:45:09.965Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-94565","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-94565","licence":"Public domain","modified":"2026-11-20T20:17:50.583Z"}],"updatedAt":"2026-11-30T20:57:24.864Z","epss":{"score":0.00819,"percentile":0.5425,"date":"2026-11-30T12:00:22.000Z"}}