NVIDIA nvdisasm symbol table parsing improper array index validation vulnerability
An improper array index validation in nvdisasm's symbol table parsing allows a crafted ELF file to cause an out-of-bounds write. An attacker could potentially achieve code execution by writing a pointer beyond an allocated buffer.
Originally disclosed on Cisco Talos
An improper array index validation vulnerability exists in the symbol table parsing functionality of NVIDIA nvdisasm 12.8.90. A specially crafted ELF file can lead to an out-of-bounds write.
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 code fails to properly validate an array index derived from the symbol's st_value, allowing it to exceed the allocated buffer size.
Impact
An attacker could write a pointer to attacker-controlled data 8 bytes beyond an allocated buffer, which could lead to code execution.
What the attacker needed
Victim opens a malicious ELF file
How it was found
- Craft an ELF file with a malicious .symtab entry.
- Run nvdisasm on the crafted file.
- The tool parses the symbol table and computes an out-of-bounds index.
- An out-of-bounds read and write occur, leading to a crash.
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 a tool called nvdisasm that reads special files (ELF files). When the tool processes a file with a manipulated symbol table, it calculates an index that goes past the end of a memory buffer, causing it to write data outside the buffer. This can crash the program or, in worse cases, let an attacker run their own code.
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.