From: Junio C Hamano <gitster@pobox.com>
To: Jeff King <peff@peff.net>
Cc: Antoine Pelisse <apelisse@gmail.com>, git <git@vger.kernel.org>,
Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: contrib/credential/netrc/git-credential-netrc: Use of uninitialized value in string
Date: Mon, 26 Aug 2013 20:56:23 -0700 [thread overview]
Message-ID: <xmqqr4dfhjmg.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <CALWbr2ynAvevTxFd3duAfFzgv0DCGTDxFUaniW-8hM+eoLiOEw@mail.gmail.com> (Antoine Pelisse's message of "Sat, 24 Aug 2013 16:55:32 +0200")
Antoine Pelisse <apelisse@gmail.com> writes:
> I've tried to use the netrc credential with git-send-email
> (v1.8.4-rc2), and I've had the following log (running with -d -v):
Peff what do you think? From credential layer's point of view, I
think we make it totally up to the helper to decide if a request
matches what it supports, and if a particular helper wants to make
sure it is asked for a specific protocol, that is an OK thing to do,
but it feels unnecessarily unfriendly and treating missing proto
specification as a wildcard to talk to the specified host over any
protocol may not hurt, I would think.
> We were given search token protocol and value smtp
> We were given search token host and value smtp.gmail.com:587
> We were given search token username and value apelisse@gmail.com
> Searching for host = smtp.gmail.com:587
> Searching for password = (any value)
> Searching for path = (any value)
> Searching for protocol = smtp
> Searching for username = apelisse@gmail.com
> Using GPG to open /home/antoine/.authinfo.gpg: [gpg --decrypt
> /home/antoine/.authinfo.gpg]
>
> You need a passphrase to unlock the secret key for
> user: "Antoine Pelisse <apelisse@gmail.com>"
> 2048-bit RSA key, ID DE2A8792, created 2010-12-31 (main key ID A066A853)
>
> gpg: encrypted with 2048-bit RSA key, ID DE2A8792, created 2010-12-31
> "Antoine Pelisse <apelisse@gmail.com>"
> compare host [smtp.gmail.com:587] to [smtp.gmail.com:587] (entry:
> password=secret, username=apelisse@gmail.com, host=smtp.gmail.com:587)
> OK: any value satisfies check password
> OK: any value satisfies check path
> Use of uninitialized value $_[2] in printf at
> /home/antoine/code/git/contrib/credential/netrc/git-credential-netrc
> line 419.
> compare protocol [] to [smtp] (entry: password=secret,
> username=apelisse@gmail.com, host=smtp.gmail.com:587)
> Use of uninitialized value in string eq at
> /home/antoine/code/git/contrib/credential/netrc/git-credential-netrc
> line 378.
>
> I can fix the problem by adding a "protocol smtp" to the matching
> line, but I wonder why this would be necessary ? After all, if host
> smtp.gmail.com:587 matches, do we need to match the protocol ?
>
> Cheers,
> Antoine
next prev parent reply other threads:[~2013-08-27 3:56 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-24 14:55 contrib/credential/netrc/git-credential-netrc: Use of uninitialized value in string Antoine Pelisse
2013-08-27 3:56 ` Junio C Hamano [this message]
2013-08-27 20:05 ` Jeff King
2013-09-03 15:23 ` Ted Zlatanov
2013-09-03 17:35 ` Jeff King
2013-10-08 14:34 ` Ted Zlatanov
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqr4dfhjmg.fsf@gitster.dls.corp.google.com \
--to=gitster@pobox.com \
--cc=apelisse@gmail.com \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
--cc=tzz@lifelogs.com \
/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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.