Epee Levin Packet Deserialization Code Execution Vulnerability
A logic flaw in the Levin deserialization of the epee library allows a specially crafted network packet to cause a memcpy into a boost::recursive_variant object, leading to a crash and potentially code execution. An attacker can send a packet to trigger this vulnerability.
An exploitable code execution vulnerability exists in the Levin deserialization functionality of the epee library. A specially crafted network packet can cause a logic flaw, resulting in code execution.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the deserialization code treats a boost::recursive_variant object as a plain-old-data type and performs a raw memcpy into it, corrupting internal pointers.
Impact
An attacker could potentially execute arbitrary code on a Monero node by sending a crafted packet, though the report only demonstrates a crash.
What the attacker needed
Network access to a Monero node
The fix
The vendor released a patch, but the report does not describe the fix details.
How it was found
- Craft a Levin packet with a section entry of type array containing an array_entry object.
- Send the packet to a Monero node using the Levin protocol.
- The deserialization code reads the array_entry and performs a memcpy into a boost::recursive_variant object.
- This causes a crash (SIGSEGV) and may allow control of execution flow.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
This report describes a bug in how a cryptocurrency network library (epee) reads data from the network. When it reads a certain type of data, it mistakenly copies bytes directly into a complex C++ object, which can crash the program or let an attacker run their own code. The attacker only needs to send a specially crafted network packet.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.