CVE-2021-47837CWE-79

Markdownify 1.2.0 - Persistent Cross-Site Scripting

Medium · published January 16, 2026

CVSS v4.0
5.1
EPSS
0%
Percentile
37.6
In the wild
Unconfirmed
What it is

⚠️ A crafty markdown file could become a ticking time bomb! Markdownify 1.2.0 is vulnerable to persistent cross-site scripting, allowing attackers to stash malicious scripts that execute when opened. 💣 Think of it like a hidden note tucked inside a book in a library. When an unsuspecting reader opens that book, the note springs to life with an unwanted surprise – all while the librarian is none the wiser! If an attacker successfully uploads a crafted markdown file, they can execute scripts that might lead to remote code execution. This means they could manipulate sensitive data, hijack user sessions, or even take over the entire system if left unchecked. Yikes!

Put simply

Think of it like a hidden note tucked inside a book in a library. When an unsuspecting reader opens that book, the note springs to life with an unwanted surprise – all while the librarian is none the wiser! This vulnerability allows attackers to upload markdown files with embedded scripts, which execute when the file is accessed by users. It’s a classic case of cross-site scripting gone persistent, allowing the payload to linger and execute under the right conditions.

What to do

If an attacker successfully uploads a crafted markdown file, they can execute scripts that might lead to remote code execution. This means they could manipulate sensitive data, hijack user sessions, or even take over the entire system if left unchecked. Yikes! To protect yourself, update Markdownify to version 1.2.1 or later immediately. Additionally, implement file validation to ensure only safe markdown files can be uploaded. Regular audits of file contents can also help catch any sneaky scripts before they execute! You've got this! Follow these steps, and you’ll be a security hero in no time! 🦸‍♂️

The record
Technical detail
CVSS v4.0
5.1 · MEDIUM
Vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N
EPSS
0.00444 · 37.6th percentile
Weakness
CWE-79 · Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Published
2026-01-16T19:09Z
EPSS history
Timeline
  • 16 JAN 19:09Z
    Markdownify 1.2.0 - Persistent Cross-Site Scripting
    cvelistv5