From patchwork Sun May 16 03:03:55 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Li Qiang X-Patchwork-Id: 12260129 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 73BEEC433ED for ; Sun, 16 May 2021 03:05:58 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E398461221 for ; Sun, 16 May 2021 03:05:57 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E398461221 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=163.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:55470 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1li76K-0003Rx-TN for qemu-devel@archiver.kernel.org; Sat, 15 May 2021 23:05:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:45700) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1li74o-0000on-Eg for qemu-devel@nongnu.org; Sat, 15 May 2021 23:04:22 -0400 Received: from m12-13.163.com ([220.181.12.13]:51768) by eggs.gnu.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1li74i-0002Z9-Se for qemu-devel@nongnu.org; Sat, 15 May 2021 23:04:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id:MIME-Version; bh=F4PVu Ro4JXFNwNqf/c0Ww7fXKmCAGKqsBaVViBtNCxE=; b=grt0klvsk1XrjxsF+U0jU Jw5x81VvtIotpQPbY4pfApcix9XaAuXpN6icno+uDhqoQZtpZNcypUvIpaBillv0 xUPKI15yOcgIjw92N6vF60kp9tCwOBwMy+BGKSEOoqdNIX9Ug2PSGXOZgfXVkRlb o69PF07AGTTwVFfL7adFUw= Received: from ubuntu.localdomain (unknown [115.200.200.157]) by smtp9 (Coremail) with SMTP id DcCowAC3evili6Bg85SBAw--.61303S4; Sun, 16 May 2021 11:04:07 +0800 (CST) From: Li Qiang To: marcandre.lureau@redhat.com, kraxel@redhat.com, philmd@redhat.com, ppandit@redhat.com, mcascell@redhat.com, qemu-devel@nongnu.org Subject: [PATCH v2 0/8] vhost-user-gpu: fix several security issues Date: Sat, 15 May 2021 20:03:55 -0700 Message-Id: <20210516030403.107723-1-liq3ea@163.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-CM-TRANSID: DcCowAC3evili6Bg85SBAw--.61303S4 X-Coremail-Antispam: 1Uf129KBjvJXoW7WF48Jr1fJFyUur1furWxJFb_yoW8Gr4UpF WxWF13Kr4xArs3ArWfJF4DWFyrZF1xWF1UCFy7C3Wfur4UW34jv3s8Cw4Yka1UGF9YqFW7 tF15Ar18Gr1qqaUanT9S1TB71UUUUUUqnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x07UuKZAUUUUU= X-Originating-IP: [115.200.200.157] X-CM-SenderInfo: 5oltjvrd6rljoofrz/1tbitAeUbVSIlhIIrQAAs3 Received-SPF: pass client-ip=220.181.12.13; envelope-from=liq3ea@163.com; helo=m12-13.163.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Li Qiang , liq3ea@gmail.com Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" These security issue is low severity and is similar with the virtio-vga/virtio-gpu device. All of them can be triggered by the guest user. Change since v1: Add the CVE information: Several memory leak issues is combined assigned CVE-2021-3544. Information disclosure is assigned CVE-2021-3545. OOB memory write access is assigned CVE-2021-3545. Abstract 'vg_cleanup_mapping_iov' to make code more clearly. Li Qiang (8): vhost-user-gpu: fix memory disclosure in virgl_cmd_get_capset_info (CVE-2021-3545) vhost-user-gpu: fix resource leak in 'vg_resource_create_2d' (CVE-2021-3544) vhost-user-gpu: fix memory leak in vg_resource_attach_backing (CVE-2021-3544) vhost-user-gpu: fix memory leak while calling 'vg_resource_unref' (CVE-2021-3544) vhost-user-gpu: fix memory leak in 'virgl_cmd_resource_unref' (CVE-2021-3544) vhost-user-gpu: fix memory leak in 'virgl_resource_attach_backing' (CVE-2021-3544) vhost-user-gpu: fix OOB write in 'virgl_cmd_get_capset' (CVE-2021-3546) vhost-user-gpu: abstract vg_cleanup_mapping_iov contrib/vhost-user-gpu/vhost-user-gpu.c | 29 ++++++++++++++++++++++--- contrib/vhost-user-gpu/virgl.c | 20 +++++++++++++++-- contrib/vhost-user-gpu/vugpu.h | 2 +- 3 files changed, 45 insertions(+), 6 deletions(-) Reviewed-by: Marc-André Lureau