RC RANDOM CHAOS

AI-built fuzzer surfaces divide-by-zero crash in FFmpeg's VPK demuxer

· via Hacker News

Original source

We found a division by zero bug in FFmpeg with a vibecoded fuzzer

Hacker News →

Researcher Darío Clavijo used a fuzzer he assembled largely with AI assistance — a ‘vibecoded’ tool — to find an integer divide-by-zero in FFmpeg’s VPK demuxer (libavformat/vpk.c), the parser for Sony PS2 audio. The fuzzer minimized a crash down to a 21-byte file carrying the VPK magic header and a zero in the channel-count field. When vpk_read_packet divides last_block_size by nb_channels, that zero triggers a SIGFPE and hard-crashes any application built on FFmpeg that ingests the file.

The root cause is a validation gap: the header parser checks the channel count, but the packet-reading path does not, so the two code paths disagree about whether the value is safe to divide by. The impact is a denial-of-service — no code execution, medium severity — but it reliably kills media pipelines that process untrusted input. The proposed fix is a one-line guard in vpk_read_packet returning AVERROR_INVALIDDATA when the channel count is zero. The issue remains open; maintainer Jun Zhao tied it to an earlier mailing-list thread, and no patch has landed.

The wider hook is that an AI-assisted fuzzer still turned up a genuine bug in a mature C codebase that is already among the most heavily fuzzed in open source (via OSS-Fuzz). It’s a small crash, not a marquee CVE, but it signals that low-effort, LLM-scaffolded tooling can meaningfully extend fuzzing coverage into rarely-exercised demuxers. Fittingly, the report itself sits behind FFmpeg’s Anubis proof-of-work wall — a defense erected against the same wave of aggressive AI scraping.

Read the full article

Continue reading at Hacker News →

This is an AI-generated summary. Read the original for the full story.