This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit d47bcf08173990256126fc027e3a92d429772207 Author: Michael Niedermayer <[email protected]> AuthorDate: Thu Oct 15 03:33:38 2026 +0200 Commit: michaelni <[email protected]> CommitDate: Tue Oct 20 20:41:50 2026 +0000 avcodec/dvbsubenc: reject rects wider or higher than 65535 Region width and height are 16 bit fields (ETSI EN 300 743, 7.2.3); Fixes: tOTDK93gpiC1 Fixes: out of array write Fixes: signed integer overflow Out of array write Replicated through API with ASAN Signed integer overflow Replicated through API with UBSAN Region width truncated to 16 bits Replicated through API with plain output check Found during the review of https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/24913 --- libavcodec/dvbsubenc.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libavcodec/dvbsubenc.c b/libavcodec/dvbsubenc.c index b6e31ab933..062f93412b 100644 --- a/libavcodec/dvbsubenc.c +++ b/libavcodec/dvbsubenc.c @@ -302,6 +302,10 @@ static int dvbsub_encode(AVCodecContext *avctx, uint8_t *outbuf, int buf_size, if (h->num_rects >= 256) return AVERROR(EINVAL); + for (i = 0; i < h->num_rects; i++) + if (h->rects[i]->w > 0xFFFF || h->rects[i]->h > 0xFFFF) + return AVERROR(EINVAL); + if (avctx->width > 0 && avctx->height > 0) { if (buf_size < 11) return AVERROR_BUFFER_TOO_SMALL; -- To stop receiving notification emails like this one, please contact [email protected]. _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
