Re: [squid-users] 302 response

From: KT Sin <ktsin@dont-contact.us>
Date: Tue, 05 Jun 2001 11:33:49 +0800

Hi

Squid converts hostnames in URLs to lower case. See line 259-260 of
src/url.c.

RFC 2068 states that comparisons of hostnames MUST be case-insensitive.

I believe Java Webserver (at least the authentication servlet) does
case-sensitive comparison of hostnames in URLs and Host: headers. If the web
server's hostname consists of mixed cases e.g. redmesa.Microsoft.COM,
comparison will fail. The servlet will then create a redirection hoping to
get the correct hostname (with the correct case).

kt

P.S. Do you work for Sun? 8)

rawvsh wrote:
>
> Which I did and got the following request/response
> from the Java Web Server:
>
> ---
> 988057183.821 104 x.x.30.85 TCP_MISS/302 637 GET
> http://redmesa:8080/CPRTReport.csv? - DIRECT/redmesa
> text/html [Referer:
> http://redmesa:8080/infospc/pages/RepSelection.html\r\nProxy-Connection:
> Keep-Alive\r\nUser-Agent: Mozilla/4.77 %5ben%5d (X11;
> U; SunOS 5.8 sun4u)\r\nHost: redmesa:8080\r\nAccept:
> image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
> image/png, */*\r\nAccept-Encoding:
> gzip\r\nAccept-Language: en\r\nAccept-Charset:
> iso-8859-1,*,utf-8\r\nCookie:
> my_id=9TaHbFPEsWylwPKLfJ1B; my_login=iaRD9vuvZu;
> visitor_uid=3536343033323338335e30;
> jwssessionid=BTCT2DYAAAAABAMTCPFAAAA\r\n] [HTTP/1.1
> 302 Moved Temporarily\r\nServer:
> JavaWebServer/1.1.3\r\nAuth-Needed:
> Auth-Needed\r\nContent-Type: text/html\r\nLocation:
> http://redmesa:8080/CPRTReport.csv?rptName=CPRT_Manager&optionalFields=ASM_Name\r\nContent-Length:
> 228\r\nConnection: Keep-Alive\r\nDate: Mon, 23 Apr
> 2001 20:19:42 GMT\r\n\r]
>
> ---
>
> The Web Server folks use a Java Based Authentication
> Servlet that launches a login screen on a page
> request, get's user login / pwd and takes the user to
> the requested page...
>
> What next?
>
> Thanks for your help!
>
> Rawvsh.
>
> --- Henrik Nordstrom <hno@hem.passagen.se> wrote:
> > Start by enabling log_mime_hdrs.
> >
> > --
> > Henrik Nordstrom
> > Squid Hacker
> >
> > RG wrote:
> > >
> > > Hi,
> > >
> > > I am running Squid v2.3.STABLE4 on Solaris 8
> > > supporting a large number of users.
> > >
> > > Accessing one of our intranet webservers running
> > Java
> > > Webserver 1.1.3 always results in a "Document
> > > Moved..." response and this goes into a loop --
> > > "Clicking "moved here" takes the users into
> > another
> > > instance of the same URL.
> > >
> > > The webserver uses JSP at the backend and this URL
> > is
> > > supposed to launch a login screen (with a
> > different
> > > URL). Due to the "302 responses", users are not
> > even
> > > able to get to this screen.
> > >
> > > The same URL works well using a proxy running
> > Netscape
> > > proxy server v3.52.
> > >
> > > Any pointers appreciated,
> > >
> > > rawvsh.
> > >
> > > __________________________________________________
> > > Do You Yahoo!?
> > > Yahoo! Auctions - buy the things you want at great
> > prices
> > > http://auctions.yahoo.com/
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Auctions - buy the things you want at great prices
> http://auctions.yahoo.com/
Received on Mon Jun 04 2001 - 21:33:52 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 17:00:28 MST