From nobody Sun Feb 8 20:34:42 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1570551985; cv=none; d=zoho.com; s=zohoarc; b=Cu16eKOeTzNMOCeU0ODwKvf5Odvd/xQnBXWzejUoncf2IpP/IvOZQEVUG3AnBDRr8UCnSGPZbFGte3+XqDY+1Stj4sF7cNrrJNwnksQrgT9uqLp919B9uhcv7Kpo61i4TzRLxl3e/Z+tOxITg0yGUVi7z9Sj9F1v88bLCFAMDLU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1570551985; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=SPh5kmuPYrLbhMbCpubN+/KX8K/c5iWg8s9PphmwWQk=; b=OOAd3a9KymB7t0nFhw6B76MaidUs4ZqJJ60A+RYJq5GijecwTpRnxrkaT2VY+34UCtXVsMvx6MmFgU0J184Pp6A2TIJhhxLJ2nZLUVEzB6sEfOMFYdD+PKc9j9LD2lxLgKx6CRJPBVxe8S2aEi167WGqBNZP0elsHfshGCIHz3E= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1570551985231207.1599508355754; Tue, 8 Oct 2019 09:26:25 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id A3A4D30609AF; Tue, 8 Oct 2019 16:26:23 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 764BD60606; Tue, 8 Oct 2019 16:26:23 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 324C54EE71; Tue, 8 Oct 2019 16:26:23 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id x98GM2Mw008696 for ; Tue, 8 Oct 2019 12:22:02 -0400 Received: by smtp.corp.redhat.com (Postfix) id 26B0160606; Tue, 8 Oct 2019 16:22:02 +0000 (UTC) Received: from worklaptop.bos.redhat.com (dhcp-17-175.bos.redhat.com [10.18.17.175]) by smtp.corp.redhat.com (Postfix) with ESMTP id B1B9960605; Tue, 8 Oct 2019 16:22:01 +0000 (UTC) From: Cole Robinson To: libvirt-list@redhat.com Date: Tue, 8 Oct 2019 12:22:26 -0400 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com Cc: christian.ehrhardt@canonical.com Subject: [libvirt] [PATCH 6/7] security: apparmor: Use only virStorageSource for disk paths X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.40]); Tue, 08 Oct 2019 16:26:24 +0000 (UTC) Content-Type: text/plain; charset="utf-8" This is closer to what security_selinux.c does, and will help add support for qcow2 external data_files Signed-off-by: Cole Robinson --- src/security/virt-aa-helper.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/security/virt-aa-helper.c b/src/security/virt-aa-helper.c index 20281c38b7..b675572144 100644 --- a/src/security/virt-aa-helper.c +++ b/src/security/virt-aa-helper.c @@ -938,13 +938,13 @@ add_file_path(virStorageSourcePtr src, =20 =20 static int -disk_add_files(virDomainDiskDefPtr disk, - virBufferPtr buf) +storage_source_add_files(virStorageSourcePtr src, + virBufferPtr buf) { size_t depth =3D 0; virStorageSourcePtr tmp; =20 - for (tmp =3D disk->src; virStorageSourceIsBacking(tmp); tmp =3D tmp->b= ackingStore) { + for (tmp =3D src; virStorageSourceIsBacking(tmp); tmp =3D tmp->backing= Store) { if (add_file_path(tmp, depth, buf) < 0) return -1; =20 @@ -994,7 +994,7 @@ get_files(vahControl * ctl) =20 /* XXX should handle open errors more careful than just ignoring = them. */ - if (disk_add_files(disk, &buf) < 0) + if (storage_source_add_files(disk->src, &buf) < 0) goto cleanup; } =20 --=20 2.23.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list