lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20250114-b4-get_maintainer-v1-2-ecf40f0d032d@suse.cz>
Date: Tue, 14 Jan 2025 09:57:55 +0100
From: Vlastimil Babka <vbabka@...e.cz>
To: Joe Perches <joe@...ches.com>
Cc: workflows@...r.kernel.org, Theodore Ts'o <tytso@....edu>, 
 Bryan O'Donoghue <bryan.odonoghue@...aro.org>, 
 Thorsten Leemhuis <linux@...mhuis.info>, Kees Cook <kees@...nel.org>, 
 linux-kernel@...r.kernel.org, Vlastimil Babka <vbabka@...e.cz>
Subject: [PATCH 2/2] get_maintainer: print subsystem status also for
 reviewers and lists

When reporting maintainers, the subsystem information includes its
status (S: entry from MAINTAINERS) whenever it's not the most common one
(Maintained). However this status information is missing for reviewers
and especially for mailing lists, which may be often the only kind of
e-mail address reported for subsystems that are of Orphan status.

For completeness, include the status information also for reviewers and
lists in the same way as for maintainers. Implementation-wise, factor
out obtaining the subsystem status from get_maintainer_role to a new
function get_subsystem_status.

For the catch-all LKML L: entry defined in "THE REST" section, the
"subsystem" is kept ommitted and thus also its status "Buried alive in
reporters" is not reported.

Signed-off-by: Vlastimil Babka <vbabka@...e.cz>
---
 scripts/get_maintainer.pl | 61 ++++++++++++++++++++++++++++-------------------
 1 file changed, 37 insertions(+), 24 deletions(-)

diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index 82a0032f4d4c7dad876afeb601b5f1957d1a838f..c9373a21da2537181f5c9eb09bb901d1981cb0dc 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -1263,6 +1263,28 @@ sub find_ending_index {
     return $index;
 }
 
+sub get_subsystem_status {
+    my ($index) = @_;
+
+    my $i;
+    my $start = find_starting_index($index);
+    my $end = find_ending_index($index);
+
+    my $status = "unknown";
+    for ($i = $start + 1; $i < $end; $i++) {
+	my $tv = $typevalue[$i];
+	if ($tv =~ m/^([A-Z]):\s*(.*)/) {
+	    my $ptype = $1;
+	    my $pvalue = $2;
+	    if ($ptype eq "S") {
+		$status = $pvalue;
+	    }
+	}
+    }
+
+    return lc($status);
+}
+
 sub get_subsystem_name {
     my ($index) = @_;
 
@@ -1280,44 +1302,31 @@ sub get_subsystem_name {
 sub get_maintainer_role {
     my ($index) = @_;
 
-    my $i;
-    my $start = find_starting_index($index);
-    my $end = find_ending_index($index);
-
-    my $role = "unknown";
+    my $role = "maintainer";
     my $subsystem = get_subsystem_name($index);
-    my $substatus = "";
-
-    for ($i = $start + 1; $i < $end; $i++) {
-	my $tv = $typevalue[$i];
-	if ($tv =~ m/^([A-Z]):\s*(.*)/) {
-	    my $ptype = $1;
-	    my $pvalue = $2;
-	    if ($ptype eq "S") {
-		$role = $pvalue;
-	    }
-	}
-    }
+    my $status = get_subsystem_status($index);
 
-    $role = lc($role);
-    if ($role eq "maintained") {
-	$role = "maintainer";
-    } elsif ($role eq "buried alive in reporters") {
+    if ($status eq "maintained") {
+	$status = "";
+    } elsif ($status eq "buried alive in reporters") {
+	$status = "";
 	$role = "chief penguin";
     } else {
-	$substatus = " [" . $role . "]";
-	$role = "maintainer";
+	$status = " [" . $status . "]";
     }
-    return $role . ":" . $subsystem . $substatus;
+    return $role . ":" . $subsystem . $status;
 }
 
 sub get_list_role {
     my ($index) = @_;
 
     my $subsystem = get_subsystem_name($index);
+    my $status = get_subsystem_status($index);
 
     if ($subsystem eq "THE REST") {
 	$subsystem = "";
+    } elsif ($status ne "maintained") {
+	$subsystem .= " [" . $status . "]";
     }
 
     return $subsystem;
@@ -1382,6 +1391,10 @@ sub add_categories {
 	    } elsif ($ptype eq "R") {
 		if ($email_reviewer) {
 		    my $subsystem = get_subsystem_name($i);
+		    my $status = get_subsystem_status($i);
+		    if ($status ne "maintained") {
+			$subsystem .= " [" . $status . "]";
+		    }
 		    push_email_addresses($pvalue, "reviewer:$subsystem" . $suffix);
 		}
 	    } elsif ($ptype eq "T") {

-- 
2.47.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ