mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-02-03 21:23:48 +00:00
Heap buffer overflow when handling Teletext data in copy_capbuf_demux_data #869
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @THE-Amrit-mahto-05 on GitHub (Dec 29, 2025).
Summary
There is a heap buffer overflow vulnerability in the Teletext demux path
in
src/lib_ccx/ts_functions.c, functioncopy_capbuf_demux_data.Details
When processing Teletext data (
CCX_CODEC_TELETEXT), the code copiescinfo->capbufintoptr->bufferwithout verifying that there is enoughspace remaining in the destination buffer (
BUFSIZE):If capbuflen exceeds the remaining buffer space, this results in a write
past the end of the heap buffer
The generic PES/DVB path in the same function performs a bounds check,
but the Teletext path was missing this validation.
Impact
Proposed Fix
Add a bounds check before copying Teletext data, similar to the generic path:
I have prepared a PR that adds this check.
Environment
Affected file: src/lib_ccx/ts_functions.c
Function: copy_capbuf_demux_data