docker-moby 25.0.3: fix CVE-2024-36623
PATCH 1/1 docker-moby 25.0.3: fix CVE-2024-36623
Upstream Repository: https://github.com/moby/moby.git
Bug Details: https://nvd.nist.gov/vuln/detail/CVE-2024-36623
Type: Security Fix
CVE: CVE-2024-36623
Score: 8.1
Patch: https://github.com/moby/moby/commit/8e3bcf197488
Analysis:
- Moby through v25.0.3 has a race condition vulnerability in the streamformatter package. It can trigger multiple concurrent write operations resulting in data corruption. [1]
- The fix adds a mutex to prevent concurrent writes and protect against data corruption. [2]
Reference:
[1] https://nvd.nist.gov/vuln/detail/CVE-2024-36623
[2] https://github.com/moby/moby/commit/8e3bcf197488
--- recipes-containers/docker/docker-moby_git.bb | 1 + .../docker/files/CVE-2024-36623.patch | 55 +++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 recipes-containers/docker/files/CVE-2024-36623.patch
recipes-containers/docker/docker-moby_git.bb +1 -0
@@ -60,6 +60,7 @@ SRC_URI = "\ file://CVE-2024-36621.patch;patchdir=src/import \ file://CVE-2024-29018_p1.patch;patchdir=src/import \ file://CVE-2024-29018_p2.patch;patchdir=src/import \ + file://CVE-2024-36623.patch;patchdir=src/import \ " DOCKER_COMMIT = "${SRCREV_moby}"
recipes-containers/docker/files/CVE-2024-36623.patch new file +55 -0
55 lines not on this page · raw message
Signature · 1 line
2.35.6
This patch is coming through garbled:
[/home/bruc...]> git am -s ~/incoming/0003-_meta-virtualization_scarthgap_PATCH_docker-moby_25.0.3_fix_CVE-2024-3.patch Patch format detection failed.
Bruce
In message: [meta-virtualization] [scarthgap] [PATCH] docker-moby 25.0.3: fix CVE-2024-36623
Quoted 112 lines · on 17/07/2025 Sudhir Dumbhare -X (sudumbha - E INFOCHIPS PRIVATE LIMITED at…
Upstream Repository: https://github.com/moby/moby.git
Bug Details: https://nvd.nist.gov/vuln/detail/CVE-2024-36623
Type: Security Fix
CVE: CVE-2024-36623
Score: 8.1
Patch: https://github.com/moby/moby/commit/8e3bcf197488Analysis:
- Moby through v25.0.3 has a race condition vulnerability in the streamformatter package. It can trigger multiple concurrent write operations resulting in data corruption. [1]
- The fix adds a mutex to prevent concurrent writes and protect against data corruption. [2]Reference:
[1] https://nvd.nist.gov/vuln/detail/CVE-2024-36623
[2] https://github.com/moby/moby/commit/8e3bcf197488Signed-off-by Sudhir Dumbhare <[email protected]>--- recipes-containers/docker/docker-moby_git.bb | 1 + .../docker/files/CVE-2024-36623.patch | 55 +++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 recipes-containers/docker/files/CVE-2024-36623.patchrecipes-containers/docker/docker-moby_git.bb +1
-0@@ -60,6 +60,7 @@ SRC_URI = "\ file://CVE-2024-36621.patch;patchdir=src/import \ file://CVE-2024-29018_p1.patch;patchdir=src/import \ file://CVE-2024-29018_p2.patch;patchdir=src/import \ + file://CVE-2024-36623.patch;patchdir=src/import \ " DOCKER_COMMIT = "${SRCREV_moby}"recipes-containers/docker/files/CVE-2024-36623.patch new file +55
-0@@ -0,0 +1,55 @@ +From 595fb34dbb46105379b469abfb70f7f9228c9361 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Pawe=C5=82=20Gronowski?= <[email protected]> +Date: Thu, 22 Feb 2024 18:01:40 +0100 +Subject: [PATCH] pkg/streamformatter: Make `progressOutput` concurrency safe +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Sync access to the underlying `io.Writer` with a mutex. + +Upstream-Status: Backport [https://github.com/moby/moby/commit/8e3bcf197488] +CVE: CVE-2024-36623 + +Signed-off-by: Paweł Gronowski <[email protected]> +(cherry picked from commit 5689dabfb357b673abdb4391eef426f297d7d1bb) +Signed-off-by: Albin Kerouanton <[email protected]> +(cherry picked from commit 8e3bcf19748838b30e34d612832d1dc9d90363b8) +Signed-off-by: Sudhir Dumbhare <[email protected]> +--- + pkg/streamformatter/streamformatter.go | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/pkg/streamformatter/streamformatter.go b/pkg/streamformatter/streamformatter.go +index b0456e580d..098df6b523 100644 +--- a/pkg/streamformatter/streamformatter.go ++++ b/pkg/streamformatter/streamformatter.go +@@ -5,6 +5,7 @@ import ( + "encoding/json" + "fmt" + "io" ++ "sync" + + "github.com/docker/docker/pkg/jsonmessage" + "github.com/docker/docker/pkg/progress" +@@ -109,6 +110,7 @@ type progressOutput struct { + sf formatProgress + out io.Writer + newLines bool ++ mu sync.Mutex + } + + // WriteProgress formats progress information from a ProgressReader. +@@ -120,6 +122,9 @@ func (out *progressOutput) WriteProgress(prog progress.Progress) error { + jsonProgress := jsonmessage.JSONProgress{Current: prog.Current, Total: prog.Total, HideCounts: prog.HideCounts, Units: prog.Units} + formatted = out.sf.formatProgress(prog.ID, prog.Action, &jsonProgress, prog.Aux) + } ++ ++ out.mu.Lock() ++ defer out.mu.Unlock() + _, err := out.out.Write(formatted) + if err != nil { + return err +-- +2.44.1 +Signature · 11 lines
2.35.6 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#9318): https://lists.yoctoproject.org/g/meta-virtualization/message/9318 Mute This Topic: https://lists.yoctoproject.org/mt/114208293/1050810 Group Owner: [email protected] Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
PATCH 1/1 docker-moby 25.0.3: fix CVE-2024-36623
Bug Details: https://nvd.nist.gov/vuln/detail/CVE-2024-36623
Type: Security Fix
CVE: CVE-2024-36623
Score: 8.1
Patch: https://github.com/moby/moby/commit/8e3bcf197488
Analysis:
- Moby through v25.0.3 has a race condition vulnerability in the streamformatter package. It can trigger multiple concurrent write operations resulting in data corruption. [1]
- The fix adds a mutex to prevent concurrent writes and protect against data corruption. [2]
Reference:
[1] https://nvd.nist.gov/vuln/detail/CVE-2024-36623
[2] https://github.com/moby/moby/commit/8e3bcf197488
--- recipes-containers/docker/docker-moby_git.bb | 1 + .../docker/files/CVE-2024-36623.patch | 47 +++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 recipes-containers/docker/files/CVE-2024-36623.patch
recipes-containers/docker/docker-moby_git.bb +1 -0
@@ -60,6 +60,7 @@ SRC_URI = "\ file://CVE-2024-36621.patch;patchdir=src/import \ file://CVE-2024-29018_p1.patch;patchdir=src/import \ file://CVE-2024-29018_p2.patch;patchdir=src/import \ + file://CVE-2024-36623.patch;patchdir=src/import \ " DOCKER_COMMIT = "${SRCREV_moby}"
recipes-containers/docker/files/CVE-2024-36623.patch new file +47 -0
47 lines not on this page · raw message
Signature · 1 line
2.23.1
Sorry for the slow reply, I've been working on package uprevs for the M3 builds and am just getting to this now.
How are you sending this patch ? It is still failing patch detection by git am , so I can't apply it to the tree.
Bruce
Quoted 112 lines · On Mon, Jul 21, 2025 at 6:19 AM Sudhir Dumbhare -X (sudumbha - E INFOCHIPS…
Bug Details: https://nvd.nist.gov/vuln/detail/CVE-2024-36623
Type: Security Fix
CVE: CVE-2024-36623
Score: 8.1
Patch: https://github.com/moby/moby/commit/8e3bcf197488Analysis:
- Moby through v25.0.3 has a race condition vulnerability in the streamformatter package. It can trigger multiple concurrent write operations resulting in data corruption. [1]
- The fix adds a mutex to prevent concurrent writes and protect against data corruption. [2]Reference:
[1] https://nvd.nist.gov/vuln/detail/CVE-2024-36623
[2] https://github.com/moby/moby/commit/8e3bcf197488Signed-off-by Sudhir Dumbhare <[email protected]>--- recipes-containers/docker/docker-moby_git.bb | 1 + .../docker/files/CVE-2024-36623.patch | 47 +++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 recipes-containers/docker/files/CVE-2024-36623.patchrecipes-containers/docker/docker-moby_git.bb +1
-0@@ -60,6 +60,7 @@ SRC_URI = "\ file://CVE-2024-36621.patch;patchdir=src/import \ file://CVE-2024-29018_p1.patch;patchdir=src/import \ file://CVE-2024-29018_p2.patch;patchdir=src/import \ + file://CVE-2024-36623.patch;patchdir=src/import \ " DOCKER_COMMIT = "${SRCREV_moby}"recipes-containers/docker/files/CVE-2024-36623.patch new file +9
-0@@ -0,0 +1,47 @@ +commit 5becb76fa5a5cb9de135b82017dbc7da7d345614 +Author: Paweł Gronowski <[email protected]> +Date: Thu Feb 22 18:01:40 2024 +0100 + + pkg/streamformatter: Make `progressOutput` concurrency safe + + Sync access to the underlying `io.Writer` with a mutex. + + Upstream-Status: Backport [https://github.com/moby/moby/commit/8e3bcf197488]
recipes-containers/docker/files/CVE-2024-36623.patch new file +9
-0+ CVE: CVE-2024-36623 + + Signed-off-by: Paweł Gronowski <[email protected]> + (cherry picked from commit 5689dabfb357b673abdb4391eef426f297d7d1bb) + Signed-off-by: Albin Kerouanton <[email protected]> + (cherry picked from commit 8e3bcf19748838b30e34d612832d1dc9d90363b8) + Signed-off-by: Sudhir Dumbhare <[email protected]> + +diff --git a/pkg/streamformatter/streamformatter.gob/pkg/streamformatter/streamformatter.go
recipes-containers/docker/files/CVE-2024-36623.patch new file +20
-0+index b0456e580d..098df6b523 100644 +--- a/pkg/streamformatter/streamformatter.go ++++ b/pkg/streamformatter/streamformatter.go +@@ -5,6 +5,7 @@ import ( + "encoding/json" + "fmt" + "io" ++ "sync" + + "github.com/docker/docker/pkg/jsonmessage" + "github.com/docker/docker/pkg/progress" +@@ -109,6 +110,7 @@ type progressOutput struct { + sf formatProgress + out io.Writer + newLines bool ++ mu sync.Mutex + } + + // WriteProgress formats progress information from a ProgressReader. +@@ -120,6 +122,9 @@ func (out *progressOutput) WriteProgress(progprogress.Progress) error {
+ jsonProgress := jsonmessage.JSONProgress{Current:
prog.Current, Total: prog.Total, HideCounts: prog.HideCounts, Units:
prog.Units}
+ formatted = out.sf.formatProgress(prog.ID, prog.Action,
&jsonProgress, prog.Aux)recipes-containers/docker/files/CVE-2024-36623.patch new file +7
-1+ } ++ ++ out.mu.Lock() ++ defer out.mu.Unlock() + _, err := out.out.Write(formatted) + if err != nil { + return err --2.23.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#9327):
https://lists.yoctoproject.org/g/meta-virtualization/message/9327
Mute This Topic: https://lists.yoctoproject.org/mt/114208293/1050810
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end - "Use the force Harry" - Gandalf, Star Trek II
A patch is generated using the command
$git format-patch -1 HEAD
To confirm the patch applies correctly;
verify with following sequence:
-clone meta-virtualization
$git clone git://git.yoctoproject.org/meta-virtualization
-switch to the scarthgap branch
$git checkout scarthgap
-and apply the patch
$git am 0001-docker-moby-25.0.3-fix-CVE-2024-36623.patch
Finally, sending the patch via git send-email. please check the patch verified with above sequence.
Thanks & Regards,
Sudhir
________________________________
From: Bruce Ashfield <[email protected]>
Sent: 31 July 2025 23:11
To: Sudhir Dumbhare -X (sudumbha - E INFOCHIPS PRIVATE LIMITED at Cisco) <[email protected]>
Cc: [email protected] <[email protected]>; xe-linux-external(mailer list) <[email protected]>; Viral Chavda (vchavda) <[email protected]>
Subject: Re: [meta-virtualization] [scarthgap] [PATCH] docker-moby 25.0.3: fix CVE-2024-36623
Sorry for the slow reply, I've been working on package uprevs for the M3 builds and am just getting to this now.
How are you sending this patch ? It is still failing patch detection by git am , so I can't apply it to the tree.
Bruce
On Mon, Jul 21, 2025 at 6:19 AM Sudhir Dumbhare -X (sudumbha - E INFOCHIPS PRIVATE LIMITED at Cisco) via lists.yoctoproject.org<http://lists.yoctoproject.org> <[email protected]<mailto:[email protected]>> wrote:
Bug Details: https://nvd.nist.gov/vuln/detail/CVE-2024-36623
Type: Security Fix
CVE: CVE-2024-36623
Score: 8.1
Patch: https://github.com/moby/moby/commit/8e3bcf197488
Analysis:
- Moby through v25.0.3 has a race condition vulnerability in the streamformatter package. It can trigger multiple concurrent write operations resulting in data corruption. [1]
- The fix adds a mutex to prevent concurrent writes and protect against data corruption. [2]
Reference:
[1] https://nvd.nist.gov/vuln/detail/CVE-2024-36623
[2] https://github.com/moby/moby/commit/8e3bcf197488
--- recipes-containers/docker/docker-moby_git.bb<http://docker-moby_git.bb> | 1 + .../docker/files/CVE-2024-36623.patch | 47 +++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 recipes-containers/docker/files/CVE-2024-36623.patch
recipes-containers/docker/docker-moby_git.bb<http://docker-moby_git.bb> +1 -0
@@ -60,6 +60,7 @@ SRC_URI = "\ file://CVE-2024-36621.patch;patchdir=src/import \ file://CVE-2024-29018_p1.patch;patchdir=src/import \ file://CVE-2024-29018_p2.patch;patchdir=src/import \ + file://CVE-2024-36623.patch;patchdir=src/import \ " DOCKER_COMMIT = "${SRCREV_moby}"
recipes-containers/docker/files/CVE-2024-36623.patch new file +47 -0
47 lines not on this page · raw message
--
2.23.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9327): https://lists.yoctoproject.org/g/meta-virtualization/message/9327
Mute This Topic: https://lists.yoctoproject.org/mt/114208293/1050810
Group Owner: [email protected]<mailto:meta-virtualization%[email protected]>
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [[email protected]<mailto:[email protected]>]
-=-=-=-=-=-=-=-=-=-=-=-
--
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end
- "Use the force Harry" - Gandalf, Star Trek II
Quoted 12 lines · On Thu, Jul 31, 2025 at 3:43 PM Sudhir Dumbhare -X (sudumbha - E INFOCHIPS…
A patch is generated using the command
$git format-patch -1 HEADTo confirm the patch applies correctly;
verify with following sequence:(quoted diff) +0
-3-clone meta-virtualization $git clone git://git.yoctoproject.org/meta-virtualization -switch to the scarthgap branch $git checkout scarthgap -and apply the patch $git am 0001-docker-moby-25.0.3-fix-CVE-2024-36623.patch
Quoted 3 lines
Finally, sending the patch via git send-email. please check the patch verified with above sequence.
I assure you that everything you sent isn't applying, and I've been doing this for several decades now :)
Something in your send path is rewriting the patches, in particular the From field. Which makes it an invalid patch. When I edited
From: it is valid.
I've sent it before, but I can't track it down now .. there's an OpenEmbedded wiki entry on how to fix the From field when sending mail. I suggest searching that up.
But your patch also doesn't apply to the top of scarthgap (this is after I edited it).
ruce-XPS-8940 [/home/bruc...ualization]> git am -s ~/incoming/0002-_meta-virtualization_scarthgap_PATCH_docker-moby_25.0.3_fix_CVE-2024-3.patch
Applying: docker-moby 25.0.3: fix CVE-2024-36623
.git/rebase-apply/patch:47: space before tab in indent.
"encoding/json"
.git/rebase-apply/patch:48: space before tab in indent.
"fmt"
.git/rebase-apply/patch:49: space before tab in indent.
"io".git/rebase-apply/patch:51: trailing whitespace.
.git/rebase-apply/patch:52: space before tab in indent.
"github.com/docker/docker/pkg/jsonmessage"
error: patch failed: recipes-containers/docker/docker-moby_git.bb:60
error: recipes-containers/docker/docker-moby_git.bb: patch does not apply Patch failed at 0001 docker-moby 25.0.3: fix CVE-2024-36623
hint: Use 'git am --show-current-patch=diff' to see the failed patch When you have resolved this problem, run "git am --continue". If you prefer to skip this patch, run "git am --skip" instead. To restore the original branch and stop patching, run "git am --abort".
Bruce
Quoted 147 lines
Thanks & Regards,
Sudhir------------------------------
*From:* Bruce Ashfield <[email protected]>
*Sent:* 31 July 2025 23:11
*To:* Sudhir Dumbhare -X (sudumbha - E INFOCHIPS PRIVATE LIMITED at Cisco) <[email protected]>
*Cc:* [email protected] < [email protected]>; xe-linux-external(mailer list) <[email protected]>; Viral Chavda (vchavda) < [email protected]>
*Subject:* Re: [meta-virtualization] [scarthgap] [PATCH] docker-moby 25.0.3: fix CVE-2024-36623Sorry for the slow reply, I've been working on package uprevs for the M3 builds and am just getting to this now.
How are you sending this patch ? It is still failing patch detection by git am , so I can't apply it to the tree.
Bruce
On Mon, Jul 21, 2025 at 6:19 AM Sudhir Dumbhare -X (sudumbha - E INFOCHIPS PRIVATE LIMITED at Cisco) via lists.yoctoproject.org <sudumbha= [email protected]> wrote:
Bug Details: https://nvd.nist.gov/vuln/detail/CVE-2024-36623
Type: Security Fix
CVE: CVE-2024-36623
Score: 8.1
Patch: https://github.com/moby/moby/commit/8e3bcf197488Analysis:
- Moby through v25.0.3 has a race condition vulnerability in the streamformatter package. It can trigger multiple concurrent write operations resulting in data corruption. [1]
- The fix adds a mutex to prevent concurrent writes and protect against data corruption. [2]Reference:
[1] https://nvd.nist.gov/vuln/detail/CVE-2024-36623
[2] https://github.com/moby/moby/commit/8e3bcf197488Signed-off-by Sudhir Dumbhare <[email protected]>--- recipes-containers/docker/docker-moby_git.bb | 1 + .../docker/files/CVE-2024-36623.patch | 47 +++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 recipes-containers/docker/files/CVE-2024-36623.patch(quoted diff) +0
-0b/recipes-containers/docker/docker-moby_git.bbindex
aa239f68..d40e3e17100644recipes-containers/docker/docker-moby_git.bb +1
-0@@ -60,6 +60,7 @@ SRC_URI = "\ file://CVE-2024-36621.patch;patchdir=src/import \ file://CVE-2024-29018_p1.patch;patchdir=src/import \ file://CVE-2024-29018_p2.patch;patchdir=src/import \ + file://CVE-2024-36623.patch;patchdir=src/import \ " DOCKER_COMMIT = "${SRCREV_moby}"recipes-containers/docker/files/CVE-2024-36623.patch new file +9
-0@@ -0,0 +1,47 @@ +commit 5becb76fa5a5cb9de135b82017dbc7da7d345614 +Author: Paweł Gronowski <[email protected]> +Date: Thu Feb 22 18:01:40 2024 +0100 + + pkg/streamformatter: Make `progressOutput` concurrency safe + + Sync access to the underlying `io.Writer` with a mutex. + + Upstream-Status: Backport [https://github.com/moby/moby/commit/8e3bcf197488]
recipes-containers/docker/files/CVE-2024-36623.patch new file +9
-0+ CVE: CVE-2024-36623 + + Signed-off-by: Paweł Gronowski <[email protected]> + (cherry picked from commit 5689dabfb357b673abdb4391eef426f297d7d1bb) + Signed-off-by: Albin Kerouanton <[email protected]> + (cherry picked from commit 8e3bcf19748838b30e34d612832d1dc9d90363b8) + Signed-off-by: Sudhir Dumbhare <[email protected]> + +diff --git a/pkg/streamformatter/streamformatter.gob/pkg/streamformatter/streamformatter.go
recipes-containers/docker/files/CVE-2024-36623.patch new file +20
-0+index b0456e580d..098df6b523 100644 +--- a/pkg/streamformatter/streamformatter.go ++++ b/pkg/streamformatter/streamformatter.go +@@ -5,6 +5,7 @@ import ( + "encoding/json" + "fmt" + "io" ++ "sync" + + "github.com/docker/docker/pkg/jsonmessage" + "github.com/docker/docker/pkg/progress" +@@ -109,6 +110,7 @@ type progressOutput struct { + sf formatProgress + out io.Writer + newLines bool ++ mu sync.Mutex + } + + // WriteProgress formats progress information from a ProgressReader. +@@ -120,6 +122,9 @@ func (out *progressOutput) WriteProgress(progprogress.Progress) error {
+ jsonProgress := jsonmessage.JSONProgress{Current:
prog.Current, Total: prog.Total, HideCounts: prog.HideCounts, Units:
prog.Units}
+ formatted = out.sf.formatProgress(prog.ID, prog.Action,
&jsonProgress, prog.Aux)recipes-containers/docker/files/CVE-2024-36623.patch new file +7
-1+ } ++ ++ out.mu.Lock() ++ defer out.mu.Unlock() + _, err := out.out.Write(formatted) + if err != nil { + return err --2.23.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#9327):
https://lists.yoctoproject.org/g/meta-virtualization/message/9327
Mute This Topic: https://lists.yoctoproject.org/mt/114208293/1050810
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=---
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end
- "Use the force Harry" - Gandalf, Star Trek II
Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end - "Use the force Harry" - Gandalf, Star Trek II