[Twisted-Python] double slash '//' problem in url - authentication with guard.HTTPAuthSessionWrapper
exarkun at twistedmatrix.com
exarkun at twistedmatrix.com
Fri Feb 26 08:40:58 MST 2010
On 11:45 am, ravikant.4784 at gmail.com wrote:
>Hi,
>
>I am trying to understand how basic authentication can be used with
>twisted.web. twistedmatrix provides an example on the same which is
>reproduced at
>>>*http://pastebin.com/hE5TFpZT
>*
>when I use this example code to login, it works fine but returns with
>double
>slash '//' in url before index file or rather for any file accessed.
>like:
>>>http://localhost:8889//index.html
>
>it will work for all files with double slash
>>>http://localhost:8889//vision.html
>
>but will return index page for any request with single slash
>>>http://localhost:8889/anything.html/ will always return index page.
>
>Please help me figuring out what is the problem and what can be
>possible fix
>to it.
With current trunk I can't reproduce this behavior. If I request
//index.html or /index.html/, the response is a 404. If I request
/index.html or /clients.html, the response is the expected page.
Jean-Paul
More information about the Twisted-Python
mailing list