Heap-buffer-overflow in pcapplusplus: SomeIpSdEntry::SomeIpSdEntry
Summary
OSV-2023-1154: Heap-buffer-overflow in pcpp::SomeIpSdEntry::SomeIpSdEntry. Affects pcapplusplus versions >= 6a67cab6914074841ed81116ac72219ca070a44d, < 6a5cb61eba4f082f7dcd4e87031520102e1babdf. Fixed in 6a5cb61eba4f082f7dcd4e87031520102e1babdf. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
pcapplusplus is an open-source library that provides a high-level interface for capturing, parsing, and analyzing network packets. It is commonly used in network monitoring and analysis tools. The SomeIpSdEntry class in pcapplusplus is responsible for handling Service Discovery (SD) entries in the SomeIP protocol. SD entries contain information about available services on a network. Unfortunately, a heap-buffer-overflow vulnerability has been discovered in the SomeIpSdEntry constructor, which could lead to a crash or potentially allow an attacker to execute arbitrary code.
Vulnerability Detail
The vulnerability occurs due to a heap-buffer-overflow in the SomeIpSdEntry constructor. When parsing a packet, the SomeIpSdLayer calls the getEntries function, which in turn invokes the SomeIpSdEntry constructor. By crafting a malicious packet, an attacker can trigger a heap-buffer-overflow, leading to a crash or potential code execution. The vulnerability has been assigned a medium severity rating.
How To Fix
Minimum fixed version
6a5cb61eba4f082f7dcd4e87031520102e1babdf
This is the first release that contains the fix.
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
No workaround has been provided for this vulnerability. It is recommended to apply the fix as soon as possible.
Conclusion
In conclusion, pcapplusplus is vulnerable to a heap-buffer-overflow in the SomeIpSdEntry constructor. This vulnerability can result in a crash or potential code execution. To mitigate the risk, it is crucial to update the pcapplusplus library to the fixed version. For further assistance or support in vulnerability remediation, please contact DevNack.com.
See every vulnerability recorded for pcapplusplus →
FAQ
pcapplusplus is an open-source library for capturing, parsing, and analyzing network packets.
The SomeIpSdEntry class in pcapplusplus handles Service Discovery (SD) entries in the SomeIP protocol.
A heap-buffer-overflow is a type of memory corruption vulnerability where data is written beyond the bounds of a heap-allocated buffer.
The vulnerability could lead to a crash of the affected application or potentially allow an attacker to execute arbitrary code.
The vulnerability has been assigned a medium severity rating.
References
Related vulnerabilities
Recent vulnerabilities recorded for pcapplusplus.