CVE-2025-36366 Overview
IBM Db2 for Linux, UNIX and Windows (includes Db2 Connect Server) contains a denial of service vulnerability that allows an authenticated user to cause abnormal server termination. The vulnerability is triggered when executing a query that invokes the JSON_Object scalar function, which may trigger an unhandled exception leading to service disruption.
Critical Impact
Authenticated attackers can crash the IBM Db2 database server by executing specially crafted queries using the JSON_Object function, potentially causing significant service disruption and data availability issues.
Affected Products
- IBM Db2 for Linux
- IBM Db2 for UNIX
- IBM Db2 for Windows (includes Db2 Connect Server)
Discovery Timeline
- 2026-01-30 - CVE CVE-2025-36366 published to NVD
- 2026-02-05 - Last updated in NVD database
Technical Details for CVE-2025-36366
Vulnerability Analysis
This vulnerability falls under CWE-943 (Improper Neutralization of Special Elements in Data Query Logic), indicating that the IBM Db2 database engine fails to properly handle certain input conditions when processing the JSON_Object scalar function. The flaw exists in the query processing logic where malformed or unexpected parameters passed to the JSON function are not adequately validated, leading to an unhandled exception condition.
The attack can be executed remotely over the network and requires low privileges to exploit. While no user interaction is required, the attacker must have valid credentials to connect to the database. The vulnerability exclusively impacts availability without affecting data confidentiality or integrity.
Root Cause
The root cause of this vulnerability stems from improper exception handling within the JSON_Object scalar function implementation in IBM Db2. When specific query patterns or malformed input data are processed by this function, the database engine encounters an unexpected state that is not properly caught by error handling routines. This unhandled exception propagates through the database engine, causing the server process to terminate abnormally.
Attack Vector
The attack vector is network-based, requiring an authenticated user with database access. An attacker with low-level privileges can craft and execute SQL queries that invoke the JSON_Object scalar function with specific parameters designed to trigger the unhandled exception. The attack does not require any user interaction and can be performed remotely against any accessible Db2 instance.
The vulnerability allows an attacker to repeatedly crash the database server, potentially leading to prolonged service outages if automated restart mechanisms are not in place or if the attack is sustained.
Detection Methods for CVE-2025-36366
Indicators of Compromise
- Unexpected IBM Db2 server process terminations or crashes
- Abnormal increase in database restart events in system logs
- Query logs showing unusual or malformed JSON_Object function calls
- Error logs indicating unhandled exceptions in JSON processing routines
Detection Strategies
- Monitor database audit logs for queries containing JSON_Object function calls with unusual parameters
- Implement alerting on sudden Db2 service terminations or repeated restart cycles
- Deploy database activity monitoring (DAM) solutions to track and analyze SQL query patterns
- Review authentication logs for suspicious user accounts executing JSON-related queries
Monitoring Recommendations
- Enable verbose logging for SQL query execution on IBM Db2 instances
- Configure automated alerts for database service state changes and unexpected terminations
- Implement baseline monitoring for normal JSON_Object function usage patterns
- Set up real-time correlation rules in SIEM solutions to detect potential exploitation attempts
How to Mitigate CVE-2025-36366
Immediate Actions Required
- Apply the security patch from IBM as documented in the IBM Support Document
- Review and restrict database user privileges to minimize the number of accounts that can execute JSON functions
- Implement query filtering or application-level controls to validate JSON function usage
- Enable enhanced logging and monitoring on all production Db2 instances
Patch Information
IBM has released a security update to address this vulnerability. Organizations running affected versions of IBM Db2 for Linux, UNIX, and Windows should apply the patch immediately. Detailed patch information and download links are available in the IBM Support Document.
Workarounds
- Restrict access to the JSON_Object function through database permissions if the function is not required for business operations
- Implement application-layer input validation to sanitize queries before they reach the database
- Deploy network segmentation to limit database access to trusted application servers only
- Consider temporarily disabling or restricting JSON function usage until patches can be applied
# Example: Review current user permissions for JSON function access
db2 "SELECT * FROM SYSCAT.ROUTINEAUTH WHERE ROUTINENAME LIKE 'JSON%'"
# Example: Monitor for Db2 service restarts
journalctl -u db2fmcd.service --since "24 hours ago" | grep -i "restart\|start\|stop"
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

