Re: Cannot clone the git repository shared over http with authorization.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Apr 02, 2012 at 04:31:15AM -0400, Jeff King wrote:
> On Sun, Apr 01, 2012 at 09:45:36PM +0200, Clemens Buchacher wrote:
> 
> > So far I figured out that setting 'git config http.maxRequests 1' fixes
> > the problem as well. Looking at the output with GIT_CURL_VERBOSE=1 set,
> > it seems that some GET requests use the credentials, while others do
> > not. My guess is that the CURLOPT_USERPWD option does not apply to all
> > threads.
> 
> Yes, that is exactly it. Furthermore, the multi-fetch code paths used by
> the http walker do not have the magic "notice a 401 and retry". I think
> something like this should fix it (it passes your tests),
> which is basically just double-checking that we set CURLOPT_USERPWD
> whenever we get a slot (I wish there was some way of asking "does this
> curl handle have USERPWD already set?", but I couldn't fine one).

I think this is the way to go. I am sending the updated patch for the test
(much of my changes were unnecessary), and your fix on top.

[PATCH 1/2] http auth fails with multiple curl handles
[PATCH 2/2] fix http auth with multiple curl handles

Clemens
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]