From 201d817e9dba579b85d70d993725e586a38949f8 Mon Sep 17 00:00:00 2001 From: Ilia Ross Date: Thu, 24 Apr 2025 11:25:03 +0300 Subject: [PATCH] Fix to preserve ACL even for modules with `noacl` flag MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit What matters now is that the module gets removed from ACLs, and the new module config page (that didn't exist before) stops working. So the simplest and best solution is to keep the module visible normally, but skip editable ACLs—since the plugin is meant to be controlled by Virtualmin permissions, and access to its config should always be allowed. https://github.com/webmin/webmin/pull/2426/files#r1972474077 --- acl/edit_user.cgi | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/acl/edit_user.cgi b/acl/edit_user.cgi index 0236aa143..d1264e00f 100755 --- a/acl/edit_user.cgi +++ b/acl/edit_user.cgi @@ -396,7 +396,6 @@ foreach my $c (sort { $b cmp $a } @cats) { my @grid = ( ); my $sw = 0; foreach my $m (@cmlist) { - next if ($m->{'noacl'}); my $md = $m->{'dir'}; my $fromgroup = $memg && &indexof($md, @{$memg->{'modules'}}) >= 0; @@ -409,7 +408,7 @@ foreach my $c (sort { $b cmp $a } @cats) { elsif ($mcan{$md}) { my $label; if ($access{'acl'} && $in{'user'} && !$safe && - &can_module_acl($m)) { + &can_module_acl($m) && !$m->{'noacl'}) { # Show link for editing ACL $label = ui_link("edit_acl.cgi?" . "mod=" . urlize($m->{'dir'}) .