Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9b89cba6 authored by Bryan Huntsman's avatar Bryan Huntsman Committed by Stepan Moskovchenko
Browse files

scripts: checkpatch.pl: warn on invalid credentials



@quicinc.com identities are not allowed.  Check the "From:" field in the
patch, equivalent to the author in the git commit, and the Signed-off-by
field.

Signed-off-by: default avatarBryan Huntsman <bryanh@codeaurora.org>
(cherry picked from commit 374146d3656f815f45145861396df4ee35f60cec)
Signed-off-by: default avatarStepan Moskovchenko <stepanm@codeaurora.org>
parent e720f36f
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -2021,6 +2021,10 @@ sub process {
					     "email address '$email' might be better as '$suggested_email$comment'\n" . $herecurr);
				}
			}
			if ($line =~ /^\s*signed-off-by:.*(quicinc|qualcomm)\.com/i) {
				WARN("BAD_SIGN_OFF",
				     "invalid Signed-off-by identity\n" . $line );
			}			

# Check for duplicate signatures
			my $sig_nospace = $line;
@@ -2034,6 +2038,11 @@ sub process {
			}
		}

#check the patch for invalid author credentials
		if ($line =~ /^From:.*(quicinc|qualcomm)\.com/) {
			WARN("BAD_AUTHOR", "invalid author identity\n" . $line );
		}

# Check for wrappage within a valid hunk of the file
		if ($realcnt != 0 && $line !~ m{^(?:\+|-| |\\ No newline|$)}) {
			ERROR("CORRUPTED_PATCH",