Skip to content
Memory corruption Advisory Intermediate CVE-2025-52461

The Biosig Project libbiosig Nex parsing out-of-bounds read vulnerability

An out-of-bounds read vulnerability exists in libbiosig's Nex file parsing because an attacker-controlled offset is used without bounds checking. A crafted .nex file can cause an information leak or denial of service.

Mark Bereza Follow

Originally disclosed on Cisco Talos

High 8.2 View original

An out-of-bounds read vulnerability exists in the Nex parsing functionality of The Biosig Project libbiosig 3.9.0 and Master Branch (35a819fa). A specially crafted .nex file can lead to an information leak.

Mark Bereza and Lilith >_>, on Cisco Talos

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

The code uses an attacker-controlled offset from the file to compute a pointer into a heap buffer without validating that the offset stays within the buffer's bounds.

Impact

An attacker could leak information from memory or cause a denial of service (crash) by providing a malicious .nex file.

What the attacker needed

Victim opens a malicious .nex file

The fix

The vulnerability was fixed in a vendor patch release.

How it was found

  1. Craft a .nex file with a large offset value in the per-channel header.
  2. Open the file with libbiosig, which triggers the Nex parsing code.
  3. The parser reads the offset and sets hc->bufptr to an address outside the buffer.
  4. When populating the event table, the code dereferences hc->bufptr, causing an out-of-bounds read.

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 library that reads medical signal files. When the library processes a file, it trusts a number stored in the file to decide where to read data from memory. If that number is too large, the library reads from outside the intended memory area, which can crash the program or leak data.

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.

More by Mark Bereza

View all

12 more disclosed reports, best first.

More from Cisco Talos

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.