CVE-2025-54384

6.3 MEDIUM

📋 TL;DR

This vulnerability is a cross-site scripting (XSS) flaw in CKAN's helpers.markdown_extract() function, which fails to properly sanitize user input before rendering it in HTML. It allows attackers to inject malicious scripts into dataset, resource, organization, or group pages, potentially compromising user sessions or stealing data. Affected users include anyone running CKAN versions prior to 2.10.9 or 2.11.4, especially those with public-facing data portals.

💻 Affected Systems

Products:
  • CKAN
Versions: All versions prior to 2.10.9 and 2.11.4
Operating Systems: Any OS running CKAN
Default Config Vulnerable: ⚠️ Yes
Notes: The vulnerability affects any CKAN instance using the helpers.markdown_extract() function, which is common in default configurations for rendering user data on various pages.

⚠️ Manual Verification Required

This CVE does not have specific version information in our database, so automatic vulnerability detection cannot determine if your system is affected.

Why? The CVE database entry doesn't specify which versions are vulnerable (no version ranges provided by the vendor/NVD).

🔒 Custom verification scripts are available for registered users. Sign up free to download automated test scripts.

Recommended Actions:
  1. Review the CVE details at NVD
  2. Check vendor security advisories for your specific version
  3. Test if the vulnerability is exploitable in your environment
  4. Consider updating to the latest version as a precaution

⚠️ Risk & Real-World Impact

🔴

Worst Case

An attacker could execute arbitrary JavaScript in victims' browsers, leading to session hijacking, data theft, or defacement of CKAN pages, potentially affecting all users accessing the vulnerable pages.

🟠

Likely Case

Limited XSS attacks targeting specific users, such as stealing cookies or redirecting to malicious sites, with impact confined to individual sessions or minor data exposure.

🟢

If Mitigated

If input validation or output encoding is implemented, the risk is reduced to minimal or no impact, as malicious scripts would be neutralized before execution.

🌐 Internet-Facing: HIGH, as CKAN is often deployed as a public data portal, making it accessible to attackers who can exploit the XSS via user-provided content.
🏢 Internal Only: MEDIUM, as internal users could still be targeted, but the attack surface is smaller compared to internet-facing deployments.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: MEDIUM

Exploitation requires an attacker to inject malicious input into user-provided data fields, but no public proof-of-concept has been released as of the advisory.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: CKAN 2.10.9 and 2.11.4

Vendor Advisory: https://github.com/ckan/ckan/security/advisories/GHSA-2r4h-8jxv-w2j8

Restart Required: No

Instructions:

1. Backup your CKAN instance and database. 2. Update CKAN to version 2.10.9 or 2.11.4 using your package manager or source. 3. Verify the update by checking the version and testing the affected pages.

🔧 Temporary Workarounds

Input Sanitization Workaround

all

Implement custom input validation or output encoding for user-provided data in CKAN templates to strip or escape HTML/JavaScript content before rendering.

Modify CKAN templates to use safe filters, e.g., in Jinja2: {{ user_input|safe }} should be avoided; use {{ user_input|e }} for escaping.

🧯 If You Can't Patch

  • Disable or restrict user input fields that use the helpers.markdown_extract() function to reduce attack surface.
  • Deploy a web application firewall (WAF) with XSS protection rules to block malicious payloads.

🔍 How to Verify

Check if Vulnerable:

Check your CKAN version; if it is below 2.10.9 or 2.11.4, you are vulnerable. Review code for use of helpers.markdown_extract() in templates.

Check Version:

Run: ckan --version or check the CKAN configuration file for version details.

Verify Fix Applied:

After patching, confirm the version is 2.10.9 or 2.11.4 and test by attempting to inject simple XSS payloads into user data fields to ensure they are sanitized.

📡 Detection & Monitoring

Log Indicators:

  • Look for unusual or repeated POST/GET requests to CKAN pages with JavaScript or HTML payloads in user input fields.

Network Indicators:

  • Monitor for outbound connections to suspicious domains triggered by CKAN page loads, which may indicate successful XSS exploitation.

SIEM Query:

Example: 'source="ckan" AND (payload CONTAINS "<script>" OR payload CONTAINS "javascript:")'

🔗 References

📤 Share & Export