From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [IPv6:2a0f:8001:1:32::40]) by lore.proxmox.com (Postfix) with ESMTPS id C19811FF0AF for ; Fri, 20 Nov 2026 13:03:53 +0100 (CET) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id 07C2321733; Fri, 20 Nov 2026 13:03:47 +0100 (CET) From: Thomas Lamprecht To: pve-devel@lists.proxmox.com, Fiona Ebner Subject: applied: [PATCH qemu-server] fix #8355: qga response: properly handle left-overs from other clients Date: Fri, 20 Nov 2026 13:00:00 +0100 Message-ID: <179517598320.39194.14397669434116210765.b4-ty@b4> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20261119140355.137355-1-f.ebner@proxmox.com> References: <20261119140355.137355-1-f.ebner@proxmox.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1795176221694 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.148 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: 2JCZLWWFXMJKFITB7I7AIIQT73PBDEOA X-Message-ID-Hash: 2JCZLWWFXMJKFITB7I7AIIQT73PBDEOA X-MailFrom: t.lamprecht@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Thu, 19 Nov 2026 15:02:49 +0100, Fiona Ebner wrote: > The QGA response buffer may contain left-overs from other clients if > they didn't read the response. The check that was in place only > compared the expected command ID and the one from the response > numerically, which does not work if the left-over originated from a > client with a different PID. > > To be able to parse and compare the PID from a sequence number, the > format has to be adapted first, because the mapping ($pid,$seq) -> > int("${pid}0${seq}") is not injective. For example, 50501 can arise > from ($pid=5,$seq=501) or ($pid=505,$seq=1). Convert the sequence > number to octal first and use '8' as a, now uniquely identifiable, > separator to get a bijective mapping. > > [...] Applied, thanks! [1/1] fix #8355: qga response: properly handle left-overs from other clients https://git.proxmox.com/?p=qemu-server.git;a=commitdiff;h=ca9efd7cd04c456182a43ee6524d21aff97dce6a