From nobody Mon Feb 9 13:37:29 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) client-ip=170.10.129.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.124 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=1676994490; cv=none; d=zohomail.com; s=zohoarc; b=MwlBdUZDSGG5eeft0ok+Z48FwSIViL7BKj5d9Y41a2joszmVX2flcC/2efzQobH7UkEMeF0u7QALY4C9/l46HEMLJOmCpuclW0PgBpfzemOuFjF51t2uTueAkqP6nfxs82cT8rJHRhNOpyxJX9CfcZ8HDtMRZPSOJOqLBcYoPvU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1676994490; h=Content-Type:Content-Transfer-Encoding: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=6Cpx6+CfmAlvLiOXZQy3xm1vfsCFn/ImIG+CwP8ol7s=; b=GW1Tdlsd5R6MU3Wboqf4rjfTMZkxvtUsYXTYXhfPg0BU3wkXHygEV6hsp4XM5ZIHagmIbesdC39niET0Sfdk4BahwQHI0QHc6pzmAhpTPIjCS7PEuTkAAysSFUJobQSQpgh04I1PchlBnWzukNg91nJ6itdw8NT3LHh/cNJeNjg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.zohomail.com with SMTPS id 1676994490069985.0499721931134; Tue, 21 Feb 2023 07:48:10 -0800 (PST) Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-473-12vOjYbYMjOGIKUvrBMXZg-1; Tue, 21 Feb 2023 10:48:07 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 77E7280557B; Tue, 21 Feb 2023 15:47:58 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (unknown [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5D733440D9; Tue, 21 Feb 2023 15:47:58 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 0DDE0194037B; Tue, 21 Feb 2023 15:47:48 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 228F81949751 for ; Tue, 21 Feb 2023 15:47:44 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id EA7CB492B01; Tue, 21 Feb 2023 15:47:43 +0000 (UTC) Received: from speedmetal.redhat.com (unknown [10.45.242.16]) by smtp.corp.redhat.com (Postfix) with ESMTP id 748E2492B00 for ; Tue, 21 Feb 2023 15:47:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1676994489; h=from:from:sender:sender: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: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=6Cpx6+CfmAlvLiOXZQy3xm1vfsCFn/ImIG+CwP8ol7s=; b=htoQ6BmeQZYh3DKi3wNnP4Jm4iIQRZE3nNvyQZ/++IaufmoZw9BE15dabFckn9if8WCDNg UDtXN/jF/45O4HyN4cNSaULnjEmC32ah9vC20WQI3pQpwGhix/a9owbRi/IBguIuEXYHFb SgDHq9dcoVTSRoUh/JsaXa1ujWJWkrE= X-MC-Unique: 12vOjYbYMjOGIKUvrBMXZg-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 6/6] gendispatch: Drop 'aclapi' mode Date: Tue, 21 Feb 2023 16:47:37 +0100 Message-Id: <3f4d21bc75027d2536442ebba55a72b9f2c91d8e.1676994420.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1676994491215100001 Content-Type: text/plain; charset="utf-8" The separate API perms XML is no longer used. Remove the support for generating it. Signed-off-by: Peter Krempa --- src/rpc/gendispatch.pl | 64 ++---------------------------------------- 1 file changed, 3 insertions(+), 61 deletions(-) diff --git a/src/rpc/gendispatch.pl b/src/rpc/gendispatch.pl index 4a50ac27e0..b186849606 100755 --- a/src/rpc/gendispatch.pl +++ b/src/rpc/gendispatch.pl @@ -42,8 +42,8 @@ my $res =3D GetOptions("mode=3Ds" =3D> \$mode); die "cannot parse command line options" unless $res; die "unknown mode '$mode', expecting 'client', 'server', " . - "'aclheader', 'aclbody', 'aclsym', 'aclapi' or 'debug'" - unless $mode =3D~ /^(client|server|aclheader|aclbody|aclsym|aclapi|deb= ug)$/; + "'aclheader', 'aclbody', 'aclsym', or 'debug'" + unless $mode =3D~ /^(client|server|aclheader|aclbody|aclsym|debug)$/; my $structprefix =3D shift or die "missing struct prefix argument"; my $procprefix =3D shift or die "missing procedure prefix argument"; @@ -452,14 +452,6 @@ if ($mode eq "aclsym") { # Automatically generated from $protocol by gendispatch.pl. # Do not edit this file. Any changes you make will be lost. __EOF__ -} elsif ($mode eq "aclapi") { - print <<__EOF__; - - -__EOF__ } else { print <<__EOF__; /* Automatically generated from $protocol by gendispatch.pl. @@ -2020,8 +2012,7 @@ elsif ($mode eq "client") { } } elsif ($mode eq "aclheader" || $mode eq "aclbody" || - $mode eq "aclsym" || - $mode eq "aclapi") { + $mode eq "aclsym") { my %generate =3D map { $_ =3D> 1 } @autogen; my @keys =3D keys %calls; @@ -2059,8 +2050,6 @@ elsif ($mode eq "client") { print "\n"; print "#define VIR_FROM_THIS VIR_FROM_ACCESS\n"; print "\n"; - } elsif ($mode eq "aclapi") { - print "\n"; } else { print "\n"; } @@ -2085,8 +2074,6 @@ elsif ($mode eq "client") { print $apiname . "CheckACL;\n"; } print $apiname . "EnsureACL;\n"; - } elsif ($mode eq "aclapi") { - &generate_aclapi($call); } else { &generate_acl($call, $call->{acl}, "Ensure"); if (defined $call->{aclfilter}) { @@ -2247,50 +2234,5 @@ elsif ($mode eq "client") { print "}\n\n"; } } - - sub generate_aclapi { - my $call =3D shift; - - my $apiname =3D $prefix . $call->{ProcName}; - if ($structprefix eq "qemu") { - $apiname =3D~ s/(vir(Connect)?Domain)/${1}Qemu/; - } elsif ($structprefix eq "lxc") { - $apiname =3D~ s/virDomain/virDomainLxc/; - } - - print " \n"; - - my $acl =3D $call->{acl}; - foreach (@{$acl}) { - my @bits =3D split /:/; - my $objname =3D $bits[0]; - $objname =3D~ s/_/-/g; - my $perm =3D $bits[1]; - $perm =3D~ s/_/-/g; - print " \n"; - } - - my $aclfilter =3D $call->{aclfilter}; - foreach (@{$aclfilter}) { - my @bits =3D split /:/; - my $objname =3D $bits[0]; - $objname =3D~ s/_/-/g; - my $perm =3D $bits[1]; - $perm =3D~ s/_/-/g; - - print " \n"; - } - - print " \n"; - } - - } - - if ($mode eq "aclapi") { - print "\n"; } } --=20 2.39.2