qemu/Fix-the-missing-hmp_nbd_server_start-change-in-CVE-2.patch
2025-01-08 11:19:59 +08:00

27 lines
817 B
Diff

From 8d0a13959c6dde9c73dd85add4a95a33d57b8d9a Mon Sep 17 00:00:00 2001
From: xiao-yuliang <xiaoyuliang@kylinos.cn>
Date: Wed, 16 Oct 2024 10:50:44 +0800
Subject: [PATCH] Fix the missing hmp_nbd_server_start change in CVE-2024-7409
---
monitor/hmp-cmds.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
index bf468fe8eb..c1ffaba0ce 100644
--- a/monitor/hmp-cmds.c
+++ b/monitor/hmp-cmds.c
@@ -2365,7 +2365,8 @@ void hmp_nbd_server_start(Monitor *mon, const QDict *qdict)
goto exit;
}
- nbd_server_start(addr, NULL, NULL, 0, &local_err);
+ nbd_server_start(addr, NULL, NULL, NBD_DEFAULT_MAX_CONNECTIONS,
+ &local_err);
qapi_free_SocketAddress(addr);
if (local_err != NULL) {
goto exit;
--
2.28.0.windows.1