Security mailing lists by PureSourceCode

CVE-2026-53427

LOW 2.3CVSS 4.0

Cross-site scripting in MDEx via unescaped highlight_lines_class code-fence attribute

Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') vulnerability in leandrocp MDEx allows stored or reflected cross-site scripting via attacker-controlled Markdown.

When syntax highlighting and full info-string forwarding (render: [full_info_string: true]) are enabled, the Lumis adapter copies the value of a code fence's highlight_lines_class info-string attribute, unescaped, into the class attribute of every rendered line. comrak_nif::lumis_adapter::LumisAdapter::parse_custom_attributes in native/comrak_nif/src/lumis_adapter.rs shlex-parses the info string and stores each key=value pair verbatim, highlight_lines_config pulls highlight_lines_class into the per-line class value, and write_highlighted interpolates that value directly into the class attribute of the per-line <div>. A single-quoted shell token preserves an inner double quote through shlex parsing, so a value such as '"><script>alert(1)</script>' terminates the class attribute early and the markup that follows is emitted as live HTML.

An attacker who can submit Markdown (through comments, posts, wiki pages, documentation, or any user-generated content) can inject arbitrary HTML and JavaScript that runs in the browser of every user who views the rendered output, enabling session theft, account takeover, and other client-side attacks. No authentication or special privileges are required.

The vulnerable native code originally shipped inside mdex (in native/comrak_nif/src/autumnus_adapter.rs, later renamed to native/comrak_nif/src/lumis_adapter.rs) and was later extracted into the separate mdex_native package (native/mdex_native_nif/src/lumis_adapter.rs).

This issue affects mdex: from 0.8.0 before 0.12.3; mdex_native: from 0.1.0 before 0.2.3.

Published
29 Jun 2026
Last modified
2 Dec 2026
Assigned by
6b3ad84c-e1a6-4bf7-a703-f496b71e49db
NVD status
Deferred
Weakness
CWE-79
Also known as
EEF-CVE-2026-53427GHSA-v664-pmxr-mxxx
Sources
NVDJSONCVE ListJSONOSV EEF-CVE-2026-53427JSON

Scores

SourceScored byVersionScoreVector / decision
NVD 6b3ad84c-e1a6-4bf7-a703-f496b71e49db (Secondary) CVSS 4.0 LOW 2.3 CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
CVE List EEF CVSS 4.0 LOW 2.3 CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
CVE List CISA-ADP SSVC Exploitation: none; Automatable: no; Technical Impact: partial

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
CVE List https://repo.hex.pm mdex
cpe:2.3:a:leandrocp:mdex:*:*:*:*:*:*:*:*
>= 0.8.0, < 0.12.3 0.12.3
CVE List https://github.com leandrocp/mdex
cpe:2.3:a:leandrocp:mdex:*:*:*:*:*:*:*:*
>= 0107e1d55b7679677a82745911b4139c96307264, < 6ed94d905f97af188323f042698ae841c02293b4 6ed94d905f97af188323f042698ae841c02293b4
CVE List https://repo.hex.pm mdex_native
cpe:2.3:a:leandrocp:mdex_native:*:*:*:*:*:*:*:*
>= 0.1.0, < 0.2.3 0.2.3
CVE List https://github.com leandrocp/mdex_native
cpe:2.3:a:leandrocp:mdex_native:*:*:*:*:*:*:*:*
>= 956528c5e31746253347029e810a969ab916fd27, < 7738ff428a54058ea0a3293eb2e17b5f4c953e2d 7738ff428a54058ea0a3293eb2e17b5f4c953e2d
OSV Hex mdex >= 0.8.0, < 0.12.3 0.12.3
OSV Hex mdex_native >= 0.1.0, < 0.2.3 0.2.3

References

History

  • 2 Dec 2026 13:48 UTC · NVD: updated (other details)
  • 2 Dec 2026 13:48 UTC · OSV: updated (other details)
  • 2 Dec 2026 12:48 UTC · CVE List: updated (other details)
  • 25 Nov 2026 20:32 UTC · CVE List: first stored (published 29 Jun 2026)
  • 25 Nov 2026 20:15 UTC · OSV: first stored (published 29 Jun 2026)
  • 25 Nov 2026 20:10 UTC · NVD: first stored (published 29 Jun 2026)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.