git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Daniel Stenberg <daniel@haxx.se>
Cc: Mike Gaffney <mr.gaffo@gmail.com>, git@vger.kernel.org
Subject: Re: [PATCH][v2] http authentication via prompts (with correct line lengths)
Date: Tue, 10 Mar 2009 01:35:04 -0700	[thread overview]
Message-ID: <7v1vt5bwsn.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <alpine.DEB.1.10.0903100905050.14797@yvahk2.pbagnpgbe.fr> (Daniel Stenberg's message of "Tue, 10 Mar 2009 09:08:58 +0100 (CET)")

Daniel Stenberg <daniel@haxx.se> writes:

> On Mon, 9 Mar 2009, Junio C Hamano wrote:
>
>> The version of libcurl on my box is 7.18.something, and it does not
>> seem to ask for password when the URL has only username but not
>> colon-password. I also expected it to ask for password when
>> $HOME/.netrc has login but not password for a given machine, but
>> that does not seem to happen either. Perhaps the version is too old.
>
> No, that's entirely expected. libcurl has no "prompt the user if no
> password was given" logic but instead delegates that work to the
> application.
>
> There was once functionality for this (removed in October 2003) but it
> was broken and violated internal guidelines so we cut out and threw
> that code away.
>
> More recently there have been people interested in re-implementing
> this "the right way" but so far it hasn't been made and thus the
> application is left to perform this task.

It's always nice to find _the_ area expert around ;-)

I somehow misread the description on CURLOPT_NETRC that appears in
http://curl.haxx.se/libcurl/c/curl_easy_setopt.html:

	libcurl uses a user name (and supplied or prompted password)
	supplied with CURLOPT_USERPWD in preference to any of the options
	controlled by this parameter.

especially the "or prompted password" part to mean that unless supplied to
the library by the caller the library would prompt the user and obtain the
password.

Thanks for clarification.

  reply	other threads:[~2009-03-10  8:36 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-10  0:08 [PATCH][v2] http authentication via prompts (with correct line lengths) Mike Gaffney
2009-03-10  0:37 ` Junio C Hamano
2009-03-10  0:45   ` Johannes Schindelin
2009-03-10  3:25     ` Mike Gaffney
2009-03-10 10:43       ` Johannes Schindelin
2009-03-10 15:33         ` Mike Gaffney
2009-03-10  4:46   ` Mike Gaffney
2009-03-10  6:34     ` Junio C Hamano
2009-03-10  8:08       ` Daniel Stenberg
2009-03-10  8:35         ` Junio C Hamano [this message]
2009-03-12  8:53       ` Mike Ralphson
2009-03-12  8:59         ` Daniel Stenberg
2009-03-12  9:12           ` Mike Ralphson
2009-03-12  9:24             ` Daniel Stenberg
2009-03-13  5:53         ` Junio C Hamano
2009-03-13  7:58           ` Daniel Stenberg
2009-03-13 10:53           ` Mike Ralphson
2009-03-14  5:55             ` Junio C Hamano
2009-03-13 12:47           ` Mike Gaffney
2009-03-14  6:43             ` Junio C Hamano
  -- strict thread matches above, loose matches on Subject: below --
2009-03-17  5:15 Amos King
2009-03-17  6:27 ` Junio C Hamano
2009-03-17  6:47   ` Junio C Hamano
2009-03-17 16:24   ` Daniel Barkalow
2009-03-18 22:41     ` Amos King

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=7v1vt5bwsn.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=daniel@haxx.se \
    --cc=git@vger.kernel.org \
    --cc=mr.gaffo@gmail.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 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 NNTP newsgroup(s).