[FFmpeg-cvslog] avfilter/vf_minterpolate: Check pts before division

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: master | Michael Niedermayer  | Sat 
Dec 30 02:51:32 2023 +0100| [68146f06f852078866b3ef1564556e3a272920c7] | 
committer: Michael Niedermayer

avfilter/vf_minterpolate: Check pts before division

Fixes: FPE
Fixes: tickets/10758/poc20ffmpeg

Discovered by Zeng Yunxiang

Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=68146f06f852078866b3ef1564556e3a272920c7
---

 libavfilter/vf_minterpolate.c | 9 +++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/libavfilter/vf_minterpolate.c b/libavfilter/vf_minterpolate.c
index 9920210ece..b2242a15ee 100644
--- a/libavfilter/vf_minterpolate.c
+++ b/libavfilter/vf_minterpolate.c
@@ -1075,8 +1075,13 @@ static void interpolate(AVFilterLink *inlink, AVFrame 
*avf_out)
 pts = av_rescale(avf_out->pts, (int64_t) ALPHA_MAX * 
outlink->time_base.num * inlink->time_base.den,
(int64_t) 
outlink->time_base.den * inlink->time_base.num);
 
-alpha = (pts - mi_ctx->frames[1].avf->pts * ALPHA_MAX) / 
(mi_ctx->frames[2].avf->pts - mi_ctx->frames[1].avf->pts);
-alpha = av_clip(alpha, 0, ALPHA_MAX);
+if (mi_ctx->frames[2].avf->pts > mi_ctx->frames[1].avf->pts) {
+alpha = (pts - mi_ctx->frames[1].avf->pts * ALPHA_MAX) / 
(mi_ctx->frames[2].avf->pts - mi_ctx->frames[1].avf->pts);
+alpha = av_clip(alpha, 0, ALPHA_MAX);
+} else {
+av_log(ctx, AV_LOG_DEBUG, "duplicate input PTS detected\n");
+alpha = 0;
+}
 
 if (alpha == 0 || alpha == ALPHA_MAX) {
 av_frame_copy(avf_out, alpha ? mi_ctx->frames[2].avf : 
mi_ctx->frames[1].avf);

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] avcodec/mpegvideo_enc: Dont copy beyond the image

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: master | Michael Niedermayer  | Sat 
Dec 30 03:06:39 2023 +0100| [a066b8a809fa6d8b31398d41787822803f8762f2] | 
committer: Michael Niedermayer

avcodec/mpegvideo_enc: Dont copy beyond the image

Fixes: out of array access
Fixes: tickets/10754/poc17ffmpeg

Discovered by Zeng Yunxiang.

Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a066b8a809fa6d8b31398d41787822803f8762f2
---

 libavcodec/mpegvideo_enc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index dcbf4c0429..b369c3c735 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -1212,7 +1212,7 @@ static int load_input_picture(MpegEncContext *s, const 
AVFrame *pic_arg)
 dst += INPLACE_OFFSET;
 
 if (src_stride == dst_stride)
-memcpy(dst, src, src_stride * h);
+memcpy(dst, src, src_stride * h - src_stride + w);
 else {
 int h2 = h;
 uint8_t *dst2 = dst;

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] avfilter/avf_showwaves: Check history_nb_samples

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: master | Michael Niedermayer  | Sat 
Dec 30 02:39:58 2023 +0100| [08bd2cbfeb34717d60ec62bcbaeb7996206df906] | 
committer: Michael Niedermayer

avfilter/avf_showwaves: Check history_nb_samples

Fixes: out of array access
Fixes: tickets/10756/poc18ffmpeg

Discovered by Zeng Yunxiang
Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=08bd2cbfeb34717d60ec62bcbaeb7996206df906
---

 libavfilter/avf_showwaves.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavfilter/avf_showwaves.c b/libavfilter/avf_showwaves.c
index 329753c8c8..e19b93a207 100644
--- a/libavfilter/avf_showwaves.c
+++ b/libavfilter/avf_showwaves.c
@@ -440,6 +440,8 @@ static int config_output(AVFilterLink *outlink)
 
 showwaves->history_nb_samples = av_rescale(showwaves->w * nb_channels * 2,
showwaves->n.num, 
showwaves->n.den);
+if (showwaves->history_nb_samples <= 0)
+return AVERROR(EINVAL);
 showwaves->history = av_calloc(showwaves->history_nb_samples,
sizeof(*showwaves->history));
 if (!showwaves->history)

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] avcodec/mpegvideo_enc: Use ptrdiff_t for stride

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: master | Michael Niedermayer  | Sat 
Dec 30 03:09:52 2023 +0100| [e063c1d079086150580ed7a9ad076da122e27f76] | 
committer: Michael Niedermayer

avcodec/mpegvideo_enc: Use ptrdiff_t for stride

Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e063c1d079086150580ed7a9ad076da122e27f76
---

 libavcodec/mpegvideo_enc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index b369c3c735..c192be6ca4 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -1193,8 +1193,8 @@ static int load_input_picture(MpegEncContext *s, const 
AVFrame *pic_arg)
 }
 
 for (int i = 0; i < 3; i++) {
-int src_stride = pic_arg->linesize[i];
-int dst_stride = i ? s->uvlinesize : s->linesize;
+ptrdiff_t src_stride = pic_arg->linesize[i];
+ptrdiff_t dst_stride = i ? s->uvlinesize : s->linesize;
 int h_shift = i ? s->chroma_x_shift : 0;
 int v_shift = i ? s->chroma_y_shift : 0;
 int w = s->width  >> h_shift;

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] avfilter/vf_minterpolate: Check pts before division

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: release/6.1 | Michael Niedermayer  | 
Sat Dec 30 02:51:32 2023 +0100| [c9e6162554cc7d04a56e2edd1f6f1479c6f8b62f] | 
committer: Michael Niedermayer

avfilter/vf_minterpolate: Check pts before division

Fixes: FPE
Fixes: tickets/10758/poc20ffmpeg

Discovered by Zeng Yunxiang

Signed-off-by: Michael Niedermayer 
(cherry picked from commit 68146f06f852078866b3ef1564556e3a272920c7)
Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c9e6162554cc7d04a56e2edd1f6f1479c6f8b62f
---

 libavfilter/vf_minterpolate.c | 9 +++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/libavfilter/vf_minterpolate.c b/libavfilter/vf_minterpolate.c
index 9920210ece..b2242a15ee 100644
--- a/libavfilter/vf_minterpolate.c
+++ b/libavfilter/vf_minterpolate.c
@@ -1075,8 +1075,13 @@ static void interpolate(AVFilterLink *inlink, AVFrame 
*avf_out)
 pts = av_rescale(avf_out->pts, (int64_t) ALPHA_MAX * 
outlink->time_base.num * inlink->time_base.den,
(int64_t) 
outlink->time_base.den * inlink->time_base.num);
 
-alpha = (pts - mi_ctx->frames[1].avf->pts * ALPHA_MAX) / 
(mi_ctx->frames[2].avf->pts - mi_ctx->frames[1].avf->pts);
-alpha = av_clip(alpha, 0, ALPHA_MAX);
+if (mi_ctx->frames[2].avf->pts > mi_ctx->frames[1].avf->pts) {
+alpha = (pts - mi_ctx->frames[1].avf->pts * ALPHA_MAX) / 
(mi_ctx->frames[2].avf->pts - mi_ctx->frames[1].avf->pts);
+alpha = av_clip(alpha, 0, ALPHA_MAX);
+} else {
+av_log(ctx, AV_LOG_DEBUG, "duplicate input PTS detected\n");
+alpha = 0;
+}
 
 if (alpha == 0 || alpha == ALPHA_MAX) {
 av_frame_copy(avf_out, alpha ? mi_ctx->frames[2].avf : 
mi_ctx->frames[1].avf);

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] avcodec/mpegvideo_enc: Dont copy beyond the image

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: release/6.1 | Michael Niedermayer  | 
Sat Dec 30 03:06:39 2023 +0100| [e1c2fa6b9addeacfa8b9e24acf9d4699ecdaa764] | 
committer: Michael Niedermayer

avcodec/mpegvideo_enc: Dont copy beyond the image

Fixes: out of array access
Fixes: tickets/10754/poc17ffmpeg

Discovered by Zeng Yunxiang.

Signed-off-by: Michael Niedermayer 
(cherry picked from commit a066b8a809fa6d8b31398d41787822803f8762f2)
Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e1c2fa6b9addeacfa8b9e24acf9d4699ecdaa764
---

 libavcodec/mpegvideo_enc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index 6d2d417454..e460ca407c 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -1213,7 +1213,7 @@ static int load_input_picture(MpegEncContext *s, const 
AVFrame *pic_arg)
 dst += INPLACE_OFFSET;
 
 if (src_stride == dst_stride)
-memcpy(dst, src, src_stride * h);
+memcpy(dst, src, src_stride * h - src_stride + w);
 else {
 int h2 = h;
 uint8_t *dst2 = dst;

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] Changelog: update

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: release/6.1 | Michael Niedermayer  | 
Sat Dec 30 22:19:58 2023 +0100| [e38092ef9395d7049f871ef4d5411eb410e283e0] | 
committer: Michael Niedermayer

Changelog: update

Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e38092ef9395d7049f871ef4d5411eb410e283e0
---

 Changelog | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/Changelog b/Changelog
index f0ea8700cd..2dca1d96c7 100644
--- a/Changelog
+++ b/Changelog
@@ -2,6 +2,9 @@ Entries are sorted chronologically from oldest to youngest 
within each release,
 releases are sorted from youngest to oldest.
 
 version 6.1.1
+- avcodec/mpegvideo_enc: Dont copy beyond the image
+- avfilter/vf_minterpolate: Check pts before division
+- avfilter/avf_showwaves: Check history_nb_samples
 - avformat/flacdec: Avoid double AVERRORS
 - avfilter/vf_vidstabdetect: Avoid double AVERRORS
 - avcodec/vaapi_encode: Avoid double AVERRORS

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] avfilter/avf_showwaves: Check history_nb_samples

2023-12-30 Thread Michael Niedermayer
ffmpeg | branch: release/6.1 | Michael Niedermayer  | 
Sat Dec 30 02:39:58 2023 +0100| [ea276a511a3aa3d8fdab352e96f13ca1ffd7ae2b] | 
committer: Michael Niedermayer

avfilter/avf_showwaves: Check history_nb_samples

Fixes: out of array access
Fixes: tickets/10756/poc18ffmpeg

Discovered by Zeng Yunxiang
Signed-off-by: Michael Niedermayer 
(cherry picked from commit 08bd2cbfeb34717d60ec62bcbaeb7996206df906)
Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ea276a511a3aa3d8fdab352e96f13ca1ffd7ae2b
---

 libavfilter/avf_showwaves.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavfilter/avf_showwaves.c b/libavfilter/avf_showwaves.c
index 329753c8c8..e19b93a207 100644
--- a/libavfilter/avf_showwaves.c
+++ b/libavfilter/avf_showwaves.c
@@ -440,6 +440,8 @@ static int config_output(AVFilterLink *outlink)
 
 showwaves->history_nb_samples = av_rescale(showwaves->w * nb_channels * 2,
showwaves->n.num, 
showwaves->n.den);
+if (showwaves->history_nb_samples <= 0)
+return AVERROR(EINVAL);
 showwaves->history = av_calloc(showwaves->history_nb_samples,
sizeof(*showwaves->history));
 if (!showwaves->history)

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] Tag n6.1.1 : FFmpeg 6.1.1 release

2023-12-30 Thread git
[ffmpeg] [branch: refs/tags/n6.1.1]
Tag:6f4048827982a8f48f71f551a6e1ed2362816eec
> http://git.videolan.org/gitweb.cgi/ffmpeg.git?a=tag;h=6f4048827982a8f48f71f551a6e1ed2362816eec

Tagger: Michael Niedermayer 
Date:   Sun Dec 31 01:05:42 2023 +0100

FFmpeg 6.1.1 release
___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-cvslog] [ffmpeg-web] branch master updated. 6d2f499 web/download: Add FFmpeg 6.1.1

2023-12-30 Thread ffmpeg-git
The branch, master has been updated
   via  6d2f499dade4e9254b68df10633db5f22c2e0757 (commit)
   via  5c31763a04daa359f868fa08a56c63a146287af4 (commit)
  from  9cbe3927f1e85ce9cc7c60b82a9cf6e49430b30b (commit)


- Log -
commit 6d2f499dade4e9254b68df10633db5f22c2e0757
Author: Michael Niedermayer 
AuthorDate: Sun Dec 31 02:31:05 2023 +0100
Commit: Michael Niedermayer 
CommitDate: Sun Dec 31 02:31:05 2023 +0100

web/download: Add FFmpeg 6.1.1

Signed-off-by: Michael Niedermayer 

diff --git a/src/download b/src/download
index 62a3ea6..0e6fa7e 100644
--- a/src/download
+++ b/src/download
@@ -1,10 +1,10 @@
 
 
   
-https://ffmpeg.org/releases/ffmpeg-6.1.tar.xz"; class="btn 
btn-success">
+https://ffmpeg.org/releases/ffmpeg-6.1.1.tar.xz"; class="btn 
btn-success">
   
   Download Source Code
-  ffmpeg-6.1.tar.xz
+  ffmpeg-6.1.1.tar.xz
 
 
 More releases
@@ -303,10 +303,10 @@ gpg: Good signature from "FFmpeg release signing key 
Changelog
+  https://git.ffmpeg.org/gitweb/ffmpeg.git/shortlog/n6.1.1";>Changelog
   https://git.ffmpeg.org/gitweb/ffmpeg.git/blob/refs/heads/release/6.1:/RELEASE_NOTES";>Release
 Notes
  


commit 5c31763a04daa359f868fa08a56c63a146287af4
Author: Michael Niedermayer 
AuthorDate: Sat Nov 11 22:47:37 2023 +0100
Commit: Michael Niedermayer 
CommitDate: Sun Dec 17 02:49:37 2023 +0100

web/security: Add CVE-2023-47343

Signed-off-by: Michael Niedermayer 

diff --git a/src/security b/src/security
index fa2c372..b862459 100644
--- a/src/security
+++ b/src/security
@@ -118,6 +118,7 @@ CVE-2021-33815, 26d3c81bc5ef2f8c3f09d45eaeacfb4b1139a777
 CVE-2021-38114, 7150f9575671f898382c370acae35f9087a30ba1
 CVE-2021-38171, 9ffa49496d1aae4cbbb387aac28a9e061a6ab0a6
 CVE-2021-38291, e01d306c647b5827102260b885faa223b646d2d1 ticket/9312,
+CVE-2023-47343, 0f6a3405e8987ad761a2d9139fdc95bbb6a61118
 
 
 FFmpeg 4.4

---

Summary of changes:
 src/download | 22 +++---
 src/security |  1 +
 2 files changed, 12 insertions(+), 11 deletions(-)


hooks/post-receive
-- 

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".