git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Hans Jerry Illikainen <hji@dyntopia.com>,
	"brian m. carlson" <sandals@crustytoothpaste.net>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	Git List Mailing <git@vger.kernel.org>
Subject: Re: Signed commit regression?
Date: Fri, 28 Feb 2020 10:24:33 -0800	[thread overview]
Message-ID: <xmqqlfomefj2.fsf@gitster-ct.c.googlers.com> (raw)
In-Reply-To: <xmqqpndyeim1.fsf@gitster-ct.c.googlers.com> (Junio C. Hamano's message of "Fri, 28 Feb 2020 09:17:58 -0800")

Junio C Hamano <gitster@pobox.com> writes:

> Linus Torvalds <torvalds@linux-foundation.org> writes:
>
>> On Fri, Feb 28, 2020 at 8:44 AM Linus Torvalds
>> <torvalds@linux-foundation.org> wrote:
>>>
>>> I suspect it's due to this commit:
>>>
>>>   72b006f4bf ("gpg-interface: prefer check_signature() for GPG verification")
>>>
>>> but as mentioned I don't have the ability to really dig deeper right now.
>>
>> Never mind - I did a mindless "just revert that and test", and it
>> indeed is that commit.
>>
>> Please revert it in upstream git. The "No signature" message really is
>> horribly wrong. It's both technically entirely wrong, but it's wrong
>> from a UI standpoint too since you really need to show what the
>> missing key was.
>
> True---the messages that told you the missing piece of information
> with the original code came directly from gnupg, and the problematic
> change stopped showing that and replaced it with the generic (and
> wrong) "We tried to verify signature and it failed---it must be that
> the input did not have signature" message.
>
> It is in v2.25 already, so we'd need to revert it out of 'maint'; it
> seems to have a minimum fallout on a topic in flight, but it looks
> manageable.

I've prepared a topic to revert that commit and it is now in the
middle of 'pu'; it will get merged down to 'next', 'master' and
'maint' in due course as other topics.

Brian's SHA-256 (1/4) topic had a couple of changes that depended on
the GPG interface API from 72b006f4 ("gpg-interface: prefer
check_signature() for GPG verification", 2019-11-27), so I ejected
them out of the topic for now:

    - tag: store SHA-256 signatures in a header
    - gpg-interface: improve interface for parsing tags

In the longer term, however, we do want an updated GPG interface
layer that lets us achieve 72b006f4 wanted to, namely

 - have a single entry point into GPG interface API, so that the
   changes in the future can be centralized;

 - not to depend _too_ heavily on the GnuPG's behaviour.  The pieces
   of information that was lost from our output and made Linus upset
   was given to the end-user by us parrotting what gpg said without
   the code really understanding what is being said, and we should
   instead make our code aware of _why_ verify_signed_buffer() or
   check_signature() have failed, and make sure we report that to
   the callers.

I'd expect that there may be another round of attempt to update the
GPG interface.  Let's make sure we won't lose info given to the
end-users while doing so.

Thanks.

  reply	other threads:[~2020-02-28 18:24 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-28 16:44 Signed commit regression? Linus Torvalds
2020-02-28 16:47 ` Linus Torvalds
2020-02-28 17:17   ` Junio C Hamano
2020-02-28 18:24     ` Junio C Hamano [this message]
2020-02-28 22:27       ` brian m. carlson
2020-03-04 11:33       ` Hans Jerry Illikainen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqlfomefj2.fsf@gitster-ct.c.googlers.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=hji@dyntopia.com \
    --cc=sandals@crustytoothpaste.net \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).