docker: Ignore SIGURG on Linux

fix #IA9T8K

(cherry picked from commit c24648a4d416f366d23ee7ae58736c7794595d15)
This commit is contained in:
chenjiankun 2024-07-15 17:18:22 +08:00 committed by openeuler-sync-bot
parent caec49267e
commit 6d238abf6b
5 changed files with 52 additions and 3 deletions

View File

@ -1 +1 @@
18.09.0.336
18.09.0.338

View File

@ -1,6 +1,6 @@
Name: docker-engine
Version: 18.09.0
Release: 337
Release: 338
Epoch: 2
Summary: The open-source application container engine
Group: Tools/Docker
@ -227,6 +227,12 @@ fi
%endif
%changelog
* Mon Jul 15 2024 chenjiankun<chenjiankun1@huawei.com> - 18.09.0-338
- Type:bugfix
- CVE:NA
- SUG:NA
- DESC:Ignore SIGURG on Linux
* Fri Jun 07 2024 suoxiaocong <suoxiaocong@kylinos.cn> - 18.09.0-337
- Type:BUG
- CVE:NA

View File

@ -1 +1 @@
33f6ee35033ba46754532d87ae6800eca565cb26
a08d4cca7068a32e0d0af533c6e01aacc3f525ff

View File

@ -0,0 +1,42 @@
From 96b2c9ecfbd1ebaae8353c1131e6ed8a0c3de65b Mon Sep 17 00:00:00 2001
From: chenjiankun <chenjiankun1@huawei.com>
Date: Fri, 21 Jun 2024 16:39:55 +0800
Subject: [PATCH] docker: Ignore SIGURG on Linux
In go1.14+, SIGURG is used by the runtime to handle preemtable system
calls.
In practice this signal caught *frequently*.
For reference:
https://go.googlesource.com/proposal/+/master/design/24543-non-cooperative-preemption.md
golang/go#37942
https://github.com/docker/cli/commit/fff164c22e8dc904291fecb62307312fd4ca153e
---
components/cli/cli/command/container/tty.go | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/components/cli/cli/command/container/tty.go b/components/cli/cli/command/container/tty.go
index cb49ded8e..5a914b109 100644
--- a/components/cli/cli/command/container/tty.go
+++ b/components/cli/cli/command/container/tty.go
@@ -13,6 +13,7 @@ import (
"github.com/docker/docker/client"
"github.com/docker/docker/pkg/signal"
"github.com/sirupsen/logrus"
+ "golang.org/x/sys/unix"
)
// resizeTtyTo resizes tty to specific height and width
@@ -79,7 +80,7 @@ func ForwardAllSignals(ctx context.Context, cli command.Cli, cid string) chan os
signal.CatchAll(sigc)
go func() {
for s := range sigc {
- if s == signal.SIGCHLD || s == signal.SIGPIPE {
+ if s == signal.SIGCHLD || s == signal.SIGPIPE || s == unix.SIGURG {
continue
}
var sig string
--
2.33.0

View File

@ -273,4 +273,5 @@ patch/0272-Fixes-41871-Update-daemon-daemon.go-resume-healthche.patch
patch/0273-backport-fix-CVE-2024-24557.patch
patch/0274-docker-fix-CVE-2024-29018.patch
patch/0275-backport-fix-CVE-2024-32473.patch
patch/0276-docker-Ignore-SIGURG-on-Linux.patch
#end