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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMuHMdV29UV6qrN8RhSJqh+yYevsOD0UERvYqHBhh8rRn8CXsA@mail.gmail.com>
Date:   Tue, 10 Jul 2018 17:50:30 +0200
From:   Geert Uytterhoeven <geert@...ux-m68k.org>
To:     Joe Perches <joe@...ches.com>
Cc:     Geert Uytterhoeven <geert+renesas@...der.be>,
        Andy Whitcroft <apw@...onical.com>, jgg@...lanox.com,
        Stephen Rothwell <sfr@...b.auug.org.au>,
        Linus Walleij <linus.walleij@...aro.org>,
        Yoshihiro Shimoda <yoshihiro.shimoda.uh@...esas.com>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] checkpatch: Require author Signed-off-by

Hi Joe,

On Tue, Jul 10, 2018 at 5:28 PM Joe Perches <joe@...ches.com> wrote:
> On Tue, 2018-07-10 at 17:07 +0200, Geert Uytterhoeven wrote:
> > On Tue, Jul 10, 2018 at 4:34 PM Joe Perches <joe@...ches.com> wrote:
> > > On Tue, 2018-07-10 at 14:10 +0200, Geert Uytterhoeven wrote:
> > > > Print an error if none of the Signed-off-by lines cover the patch
> > > > author.
> > >
> > > []
> > > > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> > >
> > > []
> > > > @@ -13,6 +13,7 @@ use POSIX;
> > > >  use File::Basename;
> > > >  use Cwd 'abs_path';
> > > >  use Term::ANSIColor qw(:constants);
> > > > +use MIME::Words 'decode_mimewords';
> > >
> > > Is this a typically installed perl module?
> > > If so, what perl version installed it by default?
> >
> > I don't know. At least my Ubuntu 16.04LTS and 18.04LTS systems had it
> > installed.
> > It does not seem to be part of the core modules, cfr.
> > https://perldoc.perl.org/index-modules-M.html
> >
> > I've tried using MIME::QuotedPrint instead, but then we need to parse
> > =?UTF-8?q? ourselves, as decode_qp() only transforms the actual
> > quoted printable bits in side the encoded From: address.
>
> I'd looked too and couldn't find it from 5.10 forward,
> so I'd prefer not requiring that module.

"that module" = MIME::Words?
So I can use MIME::QuotedPrint?

> Also, the From: line is also an email header and I don't
> believe it should be used author information in the
> same way as a patch From: line.
>
> So likely the
>
> +# Check the patch for a From:
> +               if ($line =~ /^\s*From: (.*)/i) {
>
> should be "if ($in_commit_log && $line =~ /^\s*From: (.*)/) {

That doesn't work. The "From:" line in the email body is only added by
git-send-email when it detects the "From:" line in the patch differs from
user.email in git-config.
It is not present in patches generated by git-format-patch.

So to work for both the sending ("From:" in email header only) and
receiving ("From:" in email header, to be overridden by "From:" in email
body) side, the $in_commit_log check must not be present.

> with some regex or function to remove the MIME encoded word.

I guess I can do that.

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ