[Zope] Using urllib2 to access Zope URLs

Dylan Reinhardt zope@dylanreinhardt.com
20 May 2003 19:19:10 -0700


Sorry... I thought you were saying you had found a way to *circumvent*
the authentication.  Good to hear that wasn't what you meant.

I'm not sure why it doesn't work for urllib2... I've only used that for
making POST requests, I've never used it with HTTP authentication. 
Perhaps someone on comp.lang.python would know if nobody here speaks
up... it's more of a general Python question.

Dylan


On Tue, 2003-05-20 at 13:25, Damon Butler wrote:
> On Tue, 2003-05-20 at 15:31, Dylan Reinhardt wrote:
> > On Tue, 2003-05-20 at 12:53, Damon Butler wrote:
> > > Tests with the wget utility show that it is
> > > possible to get past the authorization
> > 
> > Oh?  Has anyone else seen this?
> 
> Whaddya mean? The following command returns the proper HTML:
> 
> wget --http-user=username --http-passwd=password
> http://localhost:8080/manage_main
> 
> This tells me that it is possible to supply the username and password
> programatically from outside the Zope framework and (presumably) get
> some real work done. But the authorization doesn't carry through under
> python.urllib2. Why is that?
> 
> --Damon
>