From nobody Sat Nov 23 08:22:43 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1730368509986809.117662797122; Thu, 31 Oct 2024 02:55:09 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 96BBD139A; Thu, 31 Oct 2024 05:55:08 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id 8AEAC1372; Thu, 31 Oct 2024 05:54:48 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 72DC31372; Thu, 31 Oct 2024 05:54:45 -0400 (EDT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id D65621314 for ; Thu, 31 Oct 2024 05:54:44 -0400 (EDT) Received: from mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-207-qOB13Y2CN52DOu0tng6FWw-1; Thu, 31 Oct 2024 05:54:42 -0400 Received: from mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.15]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id DA0B51956088 for ; Thu, 31 Oct 2024 09:54:41 +0000 (UTC) Received: from orkuz (unknown [10.43.3.115]) by mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 691501956086 for ; Thu, 31 Oct 2024 09:54:41 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1730368484; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qZU5xk4uO2yQZ++uBPgSAyK2MkvASVFF9CdvBwY+qyU=; b=hKS3bguFuN6aX5bUFmXJtn5L4Taj6wro07yOropYGXJ0CNZNYHwgcUvysVXgaDqYAe+esm 72RIRhSyd2R7q9j6YWFA4A4ELw0DdOpgndSzTde10SYRepNupUzhjCCe/BrfuCxHYwm93+ /6M7j5br+CTQINvv5tP6YNnl821M7GE= X-MC-Unique: qOB13Y2CN52DOu0tng6FWw-1 From: Jiri Denemark To: devel@lists.libvirt.org Subject: [PATCH] spec: Fix attributes for ghosts directories in %{_rundir} Date: Thu, 31 Oct 2024 10:54:37 +0100 Message-ID: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Message-ID-Hash: ALAEEQMW3IQJGJJU3U5LM7BBIBRNDSSP X-Message-ID-Hash: ALAEEQMW3IQJGJJU3U5LM7BBIBRNDSSP X-MailFrom: jdenemar@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1730368512267116600 Content-Type: text/plain; charset="utf-8" Directories which we dynamically create in %{_rundir} with non-default attributes (i.e., the owner differs from root:root and/or mode is not 755) fail RPM verification. We should properly declare the expected ownership and mode in the specfile. Signed-off-by: Jiri Denemark Reviewed-by: J=C3=A1n Tomko --- libvirt.spec.in | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/libvirt.spec.in b/libvirt.spec.in index d54d2a1e3e..69693f4851 100644 --- a/libvirt.spec.in +++ b/libvirt.spec.in @@ -2038,7 +2038,7 @@ exit 0 %config(noreplace) %{_sysconfdir}/sasl2/libvirt.conf %dir %{_datadir}/libvirt/ %ghost %dir %{_rundir}/libvirt/ -%ghost %dir %{_rundir}/libvirt/common/ +%ghost %dir %attr(0700, root, root) %{_rundir}/libvirt/common/ %dir %attr(0755, root, root) %{_localstatedir}/lib/libvirt/ %dir %attr(0711, root, root) %{_localstatedir}/lib/libvirt/images/ %dir %attr(0711, root, root) %{_localstatedir}/lib/libvirt/filesystems/ @@ -2124,7 +2124,7 @@ exit 0 %{_unitdir}/virtinterfaced-ro.socket %{_unitdir}/virtinterfaced-admin.socket %attr(0755, root, root) %{_sbindir}/virtinterfaced -%ghost %dir %{_rundir}/libvirt/interface/ +%ghost %dir %attr(0700, root, root) %{_rundir}/libvirt/interface/ %{_libdir}/libvirt/connection-driver/libvirt_driver_interface.so %{_mandir}/man8/virtinterfaced.8* =20 @@ -2166,7 +2166,7 @@ exit 0 %{_unitdir}/virtnodedevd-ro.socket %{_unitdir}/virtnodedevd-admin.socket %attr(0755, root, root) %{_sbindir}/virtnodedevd -%ghost %dir %{_rundir}/libvirt/nodedev/ +%ghost %dir %attr(0700, root, root) %{_rundir}/libvirt/nodedev/ %{_libdir}/libvirt/connection-driver/libvirt_driver_nodedev.so %{_mandir}/man8/virtnodedevd.8* =20 @@ -2181,8 +2181,8 @@ exit 0 %attr(0755, root, root) %{_sbindir}/virtnwfilterd %dir %attr(0700, root, root) %{_sysconfdir}/libvirt/nwfilter/ %ghost %dir %{_rundir}/libvirt/network/ -%ghost %dir %{_rundir}/libvirt/nwfilter-binding/ -%ghost %dir %{_rundir}/libvirt/nwfilter/ +%ghost %dir %attr(0700, root, root) %{_rundir}/libvirt/nwfilter-binding/ +%ghost %dir %attr(0700, root, root) %{_rundir}/libvirt/nwfilter/ %{_libdir}/libvirt/connection-driver/libvirt_driver_nwfilter.so %{_mandir}/man8/virtnwfilterd.8* =20 @@ -2196,7 +2196,7 @@ exit 0 %{_unitdir}/virtsecretd-admin.socket %attr(0755, root, root) %{_sbindir}/virtsecretd %dir %attr(0700, root, root) %{_sysconfdir}/libvirt/secrets/ -%ghost %dir %{_rundir}/libvirt/secrets/ +%ghost %dir %attr(0700, root, root) %{_rundir}/libvirt/secrets/ %{_libdir}/libvirt/connection-driver/libvirt_driver_secret.so %{_mandir}/man8/virtsecretd.8* =20 @@ -2275,11 +2275,11 @@ exit 0 %config(noreplace) %{_sysconfdir}/libvirt/qemu.conf %config(noreplace) %{_sysconfdir}/libvirt/qemu-lockd.conf %config(noreplace) %{_sysconfdir}/logrotate.d/libvirtd.qemu -%ghost %dir %{_rundir}/libvirt/qemu/ -%ghost %dir %{_rundir}/libvirt/qemu/dbus/ -%ghost %dir %{_rundir}/libvirt/qemu/passt/ -%ghost %dir %{_rundir}/libvirt/qemu/slirp/ -%ghost %dir %{_rundir}/libvirt/qemu/swtpm/ +%ghost %dir %attr(0770, %{qemu_user}, %{qemu_group}) %{_rundir}/libvirt/qe= mu/ +%ghost %dir %attr(0770, %{qemu_user}, %{qemu_group}) %{_rundir}/libvirt/qe= mu/dbus/ +%ghost %dir %attr(0770, %{qemu_user}, %{qemu_group}) %{_rundir}/libvirt/qe= mu/passt/ +%ghost %dir %attr(0770, %{qemu_user}, %{qemu_group}) %{_rundir}/libvirt/qe= mu/slirp/ +%ghost %dir %attr(0770, %{qemu_user}, %{qemu_group}) %{_rundir}/libvirt/qe= mu/swtpm/ %dir %attr(0751, %{qemu_user}, %{qemu_group}) %{_localstatedir}/lib/libvir= t/qemu/ %dir %attr(0751, %{qemu_user}, %{qemu_group}) %{_localstatedir}/lib/libvir= t/qemu/checkpoint/ %dir %attr(0751, %{qemu_user}, %{qemu_group}) %{_localstatedir}/lib/libvir= t/qemu/dump/ --=20 2.47.0