Skip to content

[Decode] Validate JPEG quantization table selectors - #2080

Open
XinfengZhang wants to merge 1 commit into
intel:masterfrom
XinfengZhang:fix-jpeg-quant-selector
Open

XinfengZhang wants to merge 1 commit into
intel:masterfrom
XinfengZhang:fix-jpeg-quant-selector

Conversation

@XinfengZhang

Copy link
Copy Markdown
Contributor

JPEG quantization table selectors outside the four available tables could index past the matrix arrays on the Gen11 decode path.

Validate all component selectors before storing picture parameters in both VA decode entry points. Add the missing Gen11 bounds check and reject invalid selectors in the shared MFX quantization command builder before accessing either array.

Validation:

  • ASan/UBSan: 5,126 checks using automatically extracted source blocks, covering all uint8 selectors, each component position, excessive component counts, and rotated/unrotated matrix commands.
  • git diff --check passed.
  • Full driver build and GPU execution have not been performed.

Reject out-of-range JPEG quantization table selectors before storing
picture parameters or accessing the quantization matrices. Add the
missing Gen11 check and protect the shared MFX command builder.

Validate all selectors at both VA decode entry points before changing
picture state, so invalid later components cannot leave partial updates.
@XinfengZhang
XinfengZhang marked this pull request as ready for review November 25, 2026 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant