Skip to main content

CKAN CVE-2025-54384

MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2025-10-29 security-advisories@github.com
6.3
CVSS 3.1 · Vendor: github
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Authenticate as content-editing user
  2. Delivery
    Inject malicious markdown in resource/dataset description
  3. Exploit
    Victim loads affected portal page
  4. Execution
    Payload executes in victim browser
  5. Impact
    Steal session or act as victim

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires an authenticated CKAN user with permission to create or edit content rendered through markdown_extract() - specifically dataset, resource, organization, or group descriptions (the advisory cites resource description as the stored-XSS sink), or any extension page reusing that helper. The attacker stores a malicious markdown payload, and a second user must then view the affected page (UI:R), so it is not driveby/unauthenticated against a default config. Exploitation is limited to CKAN versions < 2.10.9 and 2.11.0 through 2.11.3; patched 2.10.9/2.11.4 instances, and portals that disallow untrusted account registration or content submission, are not realistically exposed.

Impact

This is a stored cross-site scripting (CWE-79) flaw in CKAN's helpers.markdown_extract(), rated medium (CVSS 6.3) by the vendor via GitHub Security Advisory GHSA-2r4h-8jxv-w2j8. The CVSS 3.1 vector (AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:L/A:N) indicates a network-reachable, low-complexity attack that nonetheless requires some privileges (PR:L - an account able to submit dataset/resource/org/group content) and victim interaction (UI:R - a user must load the affected page). No EPSS score, CISA KEV listing, or SSVC decision data was provided, and no public exploit was supplied; therefore this is 'no public exploit identified at time of analysis.' There is no evidence of active exploitation. The two signals that do exist (medium CVSS, confirmed vendor patch) point to a genuine-but-not-urgent issue: it is a real authenticated stored-XSS vector worth patching on exposed/multi-tenant portals, but the PR:L and UI:R requirements materially cap mass-exploitation potential. Note a modeling tension: the vendor scored C:H with S:U, yet stored XSS typically executes in the victim's browser context (arguably a scope change with lower direct confidentiality impact) - treat the C:H as the vendor's conservative choice rather than confirmed evidence of full data disclosure.

Exploit ScenarioDerived

An attacker who can register or already holds a content-contributor account on a CKAN portal embeds a malicious markdown/HTML payload in a field rendered via markdown_extract() - such as a resource or dataset description. When another user (including an administrator) browses that dataset, resource, organization, or group page, the unsanitized payload executes in their browser, enabling session/cookie theft or actions on their behalf. No public proof-of-concept was provided, but the patch diff (replacing a regex tag-strip with bleach_clean and adding <script> test cases) confirms the injection path.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Oct 19, 2026

Stored cross-site scripting in CKAN's markdown rendering helper allows an authenticated user who can create or edit dataset, resource, organization or group descriptions to plant a markdown payload that executes in the browser of any user who later views the affected page. CKAN releases before 2.10.9, and 2.11.0 through 2.11.3, are affected because helpers.markdown_extract() regex-stripped HTML tags instead of sanitizing the converted markdown, then handed the result to the template layer as a trusted HTML literal; the vendor rates this medium (CVSS 6.3), and our review re-scores it with scope changed (stored payload can act in the victim's session context). No public exploit identified at time of analysis, and no CISA KEV listing.

RemediationAI

Vendor-released patch: upgrade to CKAN 2.10.9 or 2.11.4 (advisory GHSA-2r4h-8jxv-w2j8; commits 6d0065f2fc7e2682196d125275af34b93e9e554e and 112affffa74b14fc97c54abcf18315df97114917), which swaps the bypassable RE_MD_HTML_TAGS regex in helpers.markdown_extract() and render_markdown() for bleach_clean(..., strip=True). If an immediate upgrade is not possible, the most effective compensating control is to remove the attack precondition: restrict dataset, resource, organization and group create/edit permissions so only trusted accounts can submit descriptions, and disable open user self-registration while unpatched - the trade-off is reduced portal openness and manual onboarding of contributors. Deploying a Content-Security-Policy that disallows inline script and restricts script-src to same-origin assets reduces payload execution even if stored markup is served, at the cost of auditing existing inline scripts and third-party embeds. Site operators who cannot patch CKAN itself can override helpers.markdown_extract() in a small local extension that routes output through the same bleach_clean(strip=True) call, though this depends on the extension shadowing the core helper and must be re-verified on every upgrade. Review existing dataset, resource, organization and group descriptions for injected markup and re-save or clean any suspicious entries after patching, since stored payloads persist in the database.

Affected Packages

pypi ckan fix: 2.10.9, 2.11.4

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

CKAN is a Python/Flask data portal application that renders user-supplied descriptions through its Jinja2 template layer. The vulnerable code path is ckan/lib/helpers.py: helpers.markdown_extract() converted text with the markdown library and then removed tags using a naive regular expression (RE_MD_HTML_TAGS = re.compile('<[^><]*>')) before the result was wrapped in a markup literal so Jinja autoescaping would not touch it. Tag-stripping regexes are not a parser and are trivially bypassed, so markup that survived the regex reached the browser as raw HTML - the classic CWE-79 pattern of neutralization performed at the wrong layer with an insufficient technique. The same regex was also used in render_markdown(), and the upstream fix (commit 6d0065f2, companion 112affff) replaces the regex with bleach_clean(markdown(text), strip=True) from CKAN's existing bleach dependency and deletes the RE_MD_HTML_TAGS definition entirely. The accompanying test changes are instructive: test fixtures that previously expected '<h1>moo</h1>' to pass through now use '<script>moo</script>' and expect either literal escaping ('<script>moo</script>') or stripping to plain 'moo', and anchor tags with non-ASCII quote characters are now emitted as properly escaped <a href="..."> elements. The sink named in advisory GHSA-2r4h-8jxv-w2j8 is the stored resource description, but any dataset, organization, group or extension-provided page that calls the helper inherits the same exposure.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (github) PRIMARY 6.3 MEDIUM
AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:L/A:N
vuln.today AI 5.4 MEDIUM

Authenticated content submitter (PR:L) stores markdown that runs in a victim's browser after they load the page (UI:R), crossing into the browser's context (S:C) with limited confidentiality/integrity impact typical of stored XSS.

3.1 AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
4.0 AV:N/AC:L/AT:N/PR:L/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

Primary rating from Vendor (github).

CVSS VectorVendor: github

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
Low
Availability
None

DescriptionCVE.org

CKAN is an open-source DMS (data management system) for powering data hubs and data portals. Prior to 2.10.9 and 2.11.4, the helpers.markdown_extract() function did not perform sufficient sanitization of input data before wrapping in an HTML literal element. This helper is used to render user-provided data on dataset, resource, organization or group pages (plus any page provided by an extension that used that helper function), leading to a potential XSS vector. This vulnerability has been fixed in CKAN 2.10.9 and 2.11.4.

Threat Intelligence Overview

EPSS Score
0.2%
Top 88% exploitable
Prevalence
Medium
open-source data portal common on government and open-data sites, not ubiquitous
Data Quality
3 sources
Confidence: Low

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

32
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +32
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy