Kamailio SIP Server Heap-Based Buffer Overflow Vulnerability in Configuration File Handler

Vulnerability

A heap-based buffer overflow vulnerability has been identified in Kamailio SIP Server version 5.5. The issue arises in the Configuration File Handler, specifically within the 'rve_destroy' function of 'src/core/rvalue.c'. This vulnerability is triggered during the parsing and cleanup of module function parameters, where malformed or specially crafted configuration can lead to inconsistent 'rval_expr' structures. The 'rve_destroy' function then reads past the allocated memory, causing a heap-buffer-overflow. This vulnerability requires local access to exploit and has been publicly disclosed, with an available exploit.

Impact

Exploitation of this vulnerability causes a denial-of-service condition by crashing the Kamailio process during configuration parsing, before the daemon can fully start. Additionally, the heap-based memory corruption introduced by this vulnerability could potentially be exploited for more serious consequences, such as remote code execution, depending on the attacker's control and the environment.

Reproduction

To reproduce this vulnerability, replace the default 'kamailio-basic.cfg' with a crafted configuration file that triggers the heap-buffer-overflow. Then, start Kamailio with the AddressSanitizer enabled, using the modified configuration file. The AddressSanitizer will report the heap-buffer-overflow error, indicating that the vulnerability has been successfully exploited.

Added: Oct 27, 2025, 3:23 AM
Updated: Oct 27, 2025, 3:23 AM

Vulnerability Rating

Custom Algorithm
spread
5.2
impact
2.5
exploitability
5.4
remediation
0.0
relevance
0.8
threat
6.4
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.