CVE-2023-5256

7.5 HIGH

📋 TL;DR

Drupal's JSON:API module can expose sensitive error backtraces that may be cached and accessible to anonymous users. This information disclosure vulnerability could lead to privilege escalation by revealing system details. Only sites with the JSON:API module enabled are affected.

💻 Affected Systems

Products:
  • Drupal
Versions: Drupal core versions with JSON:API module enabled
Operating Systems: All
Default Config Vulnerable: ✅ No
Notes: Only affects sites with JSON:API module enabled. Core REST and contributed GraphQL modules are not affected.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Anonymous users obtain sensitive system information from cached error backtraces, enabling privilege escalation attacks that could lead to full site compromise.

🟠

Likely Case

Anonymous users access cached error information containing system paths, configuration details, or other sensitive data that could aid further attacks.

🟢

If Mitigated

With proper caching controls and error handling, only generic error messages are exposed, limiting information disclosure.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Exploitation requires triggering error conditions in JSON:API endpoints and accessing cached error responses.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Apply Drupal security update for CVE-2023-5256

Vendor Advisory: https://www.drupal.org/sa-core-2023-006

Restart Required: No

Instructions:

1. Update Drupal core to the latest secure version. 2. Apply the security patch for CVE-2023-5256. 3. Clear all caches after patching.

🔧 Temporary Workarounds

Disable JSON:API Module

all

Uninstall the JSON:API module to completely mitigate the vulnerability

drush pm-uninstall jsonapi

Configure Error Handling

all

Configure Drupal to not display error backtraces to users

Set $config['system.logging']['error_level'] = 'hide' in settings.php

🧯 If You Can't Patch

  • Disable the JSON:API module immediately
  • Implement strict caching controls to prevent caching of error responses

🔍 How to Verify

Check if Vulnerable:

Check if JSON:API module is enabled and review error handling configuration

Check Version:

drush status | grep 'Drupal version'

Verify Fix Applied:

Verify Drupal core is updated to patched version and test JSON:API error responses

📡 Detection & Monitoring

Log Indicators:

  • Multiple error responses from JSON:API endpoints
  • Anonymous users accessing cached error pages

Network Indicators:

  • Unusual requests to JSON:API endpoints designed to trigger errors

SIEM Query:

source="drupal" AND (uri="*jsonapi*" AND status>=500)

🔗 References

📤 Share & Export