mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-02-03 21:23:48 +00:00
[PR #2028] [CLOSED] Fix GXF VBI out-of-bounds panic in userdata.rs #2832
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?
📋 Pull Request Information
Original PR: https://github.com/CCExtractor/ccextractor/pull/2028
Author: @THE-Amrit-mahto-05
Created: 1/17/2026
Status: ❌ Closed
Base:
master← Head:fix/rust-gxf-vbi-oob📝 Commits (1)
2c77126Fix GXF VBI out-of-bounds panic in userdata.rs📊 Changes
1 file changed (+1 additions, -0 deletions)
View changed files
📝
src/rust/src/es/userdata.rs(+1 -0)📄 Description
In raising this pull request, I confirm the following (please check boxes):
My familiarity with the project is as follows (check one):
Desciption
critical out-of-bounds panic when processing malformed GXF VBI data.
Previously, the code attempted to slice exactly 720 bytes from the stream, even if fewer bytes were available:
This caused the program to panic if the GXF packet was truncated, corrupted, or attacker-crafted. The check for udatalen < 720 only logged a message but did not prevent execution.
Fix
We could consider returning a specific error variant instead of Ok(1) to indicate that the packet is malformed. This would allow higher level code to handle malformed packets explicitly (e.g., loging, skipping, or applying custom processing). The current approach is safe and ensures decoder stability.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.