All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nelson Benitez Leon <nelsonjesus.benitez@seap.minhap.es>
To: Jeff King <peff@peff.net>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 2/6] http: handle proxy proactive authentication
Date: Fri, 04 May 2012 15:55:47 +0200	[thread overview]
Message-ID: <4FA3DFE3.5050702@seap.minhap.es> (raw)
In-Reply-To: <20120504071632.GB21895@sigill.intra.peff.net>

On 05/04/2012 09:16 AM, Jeff King wrote:
> On Thu, May 03, 2012 at 06:39:54PM +0200, Nelson Benitez Leon wrote:
> 
>> If http_proactive_auth flag is set and there is a username
>> but no password in the proxy url, then interactively ask for
>> the password.
>>
>> This makes possible to not have the password written down in
>> http_proxy env var or in http.proxy config option.
>>
>> Also take care that CURLOPT_PROXY don't include username or
>> password, as we now set them in the new set_proxy_auth() function
>> where we use their specific cURL options.
> 
> Do we actually need to do that? If we set CURLOPT_PROXYUSERNAME, will
> curl ignore it in favor of what's in the URL? 

I explicitly remove username/pass from CURLOPT_PROXY to not having to worry
about that question, to not provide cURL with two different sets of proxy auth
info, common sense dictates cURL specific proxy options should take precedence
over embedded in url by I haven't seen that mentioned by any cURL docs so we 
should look at the source to know the truth but even then that could change in
the future so I think is safer to only provide one path for auth info.

Having username/password on the CURLOPT_PROXY option gives us no special gain at
the cost of not permitting usernames with reserved characters like '@' or ':' which
are not unusual at all. So I'm inclined to preserve current set_proxy_auth() 
function and re-introduce the code that sets CURLOPT_PROXY with only $prot://$host.

Are you ok with this? or do you prefer I change set_proxy_auth() to a set_curl_proxy()
function where I embedded user/pass in CURLOPT_PROXY ? that is the remaining thing I need
to know to send a new re-roll.

  parent reply	other threads:[~2012-05-04 12:59 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-03 16:39 [PATCH 2/6] http: handle proxy proactive authentication Nelson Benitez Leon
2012-05-04  7:16 ` Jeff King
2012-05-04 11:10   ` Nelson Benitez Leon
2012-05-04 10:51     ` Jeff King
2012-05-04 13:55   ` Nelson Benitez Leon [this message]
2012-05-04 13:55     ` Jeff 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=4FA3DFE3.5050702@seap.minhap.es \
    --to=nelsonjesus.benitez@seap.minhap.es \
    --cc=git@vger.kernel.org \
    --cc=peff@peff.net \
    /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.