Java Mailing List Archive

http://www.junlu.com/

Google
Google
Mailing List
Home
Forum Home
JBoss - Java Application Server
Struts - A MVC web framework
Tomcat - JSP/Servlet container
iText - An open source PDF Java Library
JDOM - JDOM XML Parser
J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition
J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog
Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology
JSP - A mailing list about Java Server Pages specification and reference
Struts & Hibernate
Subjects
JSP editor plugin for eclipse ?
org apache jasper JasperException: Unable to compile class for JSP
Tomcat: Connection reset by peer: socket write error
Cannot retrieve definition for form bean null
Struts Tiles Tutorial (free Struts training)
Where do I download Tomcat 4 0 6?
Data Access Object (DAO) pattern, example DAO 's
Where to download Tomcat v 4 1 24 from?
Tomcat 5 0 16 Requested resource not available
Oracle Connection Pooling in 3 2 2
Servlet : Session invalidate
Servlet action is currently unavailable
Tomcat/Struts Unicode Encoding/Decoding problems
Tomcat and webapplication specific java library path
Running a Simple JMS Example
Mapping in workers2 properties
org apache jasper JasperException
Cannot find message resources under key org apache struts action
   MESSAGE
problem with html:text bean throwing exception
Cannot find message resources under key org apache struts action MESSAGE
invalid direct reference problem with solution
Tool for jsp debug Try Sysdeo Eclipse Plugin
Tomcat 5 Cannot load JDBC driver class 'null ' SQL state: null
weblogic ejbc
java properties file
Jboss 3 2 3 Coyote Can 't re
Tomcat 5, Apache2 and mod jk2 integration problem
JBoss example problem new to J2EE
url string for connecting jboss to oracle
Value attribute of <html:checkbox
javax servlet ServletException: BeanUtils populate
HTTP Status 404 The requested resource is not available
5 0 18: Windows XP Pro vs Windows 2000
 
restrictedUserAgents parameter

restrictedUserAgents parameter

2004-01-24       - By Lukas �sterreicher

 Back
Reply:     1     2  

Hello

I was recently tipped to try the restrictedUserAgents parameter in the server
.xml file.
This parameter however is not correctly implemented in tomcat 5.0.16.
So now I found a (alpha?) compile of tomcat 5.0.18 and I think they have
done work on it because at least the server reacts differently now if I turn it
on.

I have added restrictedUserAgents="Winamp" to force http 1.0 replies for
requests of winamp because it apparantly cannot deal with chunked encoding
(at least for ogg).

Without the parameter it would send in http 1.1 and chunked encoding (because
I do not know the content length). With the parameter it would just close the
connection.

This is all because for ogg winamp requests in http 1.1.

For mp3 data it requests in http 1.0 and the reply is a continuous datastream
with unknown length.

The strange thing is that in both cases it will send Connection: close, but in
case of mp3
it will send a datastream afterwards, in case of ogg it will not.

I had hoped and thought that when I use the restrictedUserAgents parameter it
will
force replies to http 1.0 and thus reply like it does with mp3: send an un
-cunked audio stream.
Why doesn't it?

Is this option not properly implemented still?

See some http headers for details:

MP3 Request:
GET /yarf/hdm.mp3;jsessionid=893513CC03654D83936718AAB1EEEA8F?trackid=82&file
=hdm.mp3 HTTP/1.0..Host: yarf.sytes.net..User-Agent: WinampMPEG/2.8..Accept: */*
..Icy-
MetaData:1..-- ---- --: -- --....

MP3 Response:
HTTP/1.1 200 OK..Content-Location: hdm_56k.mp3..Content-Type: audio/x-mpeg.
.Date: Sat, 24 Jan 2004 22:55:03 GMT..Server: Apache-Coyote/1.1..Connection:
close....? ?....?.....4?
?.LAME3.92


OGG Request:
GET /yarf/hdm.ogg;jsessionid=893513CC03654D83936718AAB1EEEA8F?trackid=82&file
=hdm.ogg HTTP/1.1..Host:yarf.sytes.net..User-Agent:Winamp..Accept:*/*....

Ogg Response:
HTTP/1.1 200 OK..Content-Location: hdm_28k.ogg..Content-Type: application/ogg.
.Date: Sat, 24 Jan 2004 22:59:57 GMT..Server: Apache-Coyote/1.1..Connection:
close....


Note:
The MP3 Response contains also the first few bytes of the real datastream

So my question:
How can I force tomcat reply ogg like it would for mp3?
Theoretically, would it reply like I want to if for ogg it sent a HTTP 1.0
request?
Why does it send Connection: close but send mp3 data afterwards?

Thanx in Advance,
Lukas





-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------
To unsubscribe, e-mail: tomcat-user-unsubscribe@(protected)
For additional commands, e-mail: tomcat-user-help@(protected)




©2008 junlu.com - Jax Systems, LLC, U.S.A.