httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zvi Har'El" ...@math.technion.ac.il>
Subject Re: overflow in mod_autoindex suspected - solaris - httpd 2.2.*
Date Thu, 18 Jan 2007 21:08:07 GMT
I Tried the two settings, independently:

1) changes the line "ForceType text/html"  to "ForceType tex/plain" in 
my .htaccess.

2) put a line "EnableSendFile off" in my .htaccess

(.htaccess is located at the parent directory of the directory which
contains the 256 bytes header file).


In the first case, I got in all the four accesses the correct response
(omitting the HTTP headers)


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
 <head>
  <title>Index of /test_mod_auto_index/256</title>
 </head>
 <body>
<pre>
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
</pre>
<pre><img src="/icons/blank.gif" alt="Icon " width="20" height="22"> <a
href="?C=N;O=D">Name</a>                    <a href="?C=M;O=A">Last
modified</a>      <a href="?C=S;O=A">Size</a>  <a
href="?C=D;O=A">Description</a><hr><img src="/icons/back.gif"
alt="[DIR]" width="20" height="22"> <a
href="/test_mod_auto_index/">Parent
Directory</a>                             -  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="1">1</a>                       14-Jan-2007 14:11    0  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="2">2</a>                       14-Jan-2007 14:11    0  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="3">3</a>                       14-Jan-2007 14:11    0  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="KUKU">KUKU</a>                    14-Jan-2007 14:20  256  
<hr></pre>
<address>Apache/2.2.4 (Unix) mod_ssl/2.2.4 OpenSSL/0.9.8d PHP/4.4.4
Server at <a
href="mailto:webmaster@math.technion.ac.il">www.math.technion.ac.il</a>
Port 80</address>
</body></html>


In the second case, I got all the four accesses the correct response
(omitting the HTTP headers)


XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
<pre><img src="/icons/blank.gif" alt="Icon " width="20" height="22"> <a
href="?C=N;O=D">Name</a>                    <a href="?C=M;O=A">Last
modified</a>      <a href="?C=S;O=A">Size</a>  <a
href="?C=D;O=A">Description</a><hr><img src="/icons/back.gif"
alt="[DIR]" width="20" height="22"> <a
href="/test_mod_auto_index/">Parent
Directory</a>                             -  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="1">1</a>                       14-Jan-2007 14:11    0  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="2">2</a>                       14-Jan-2007 14:11    0  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="3">3</a>                       14-Jan-2007 14:11    0  
<img src="/icons/text.gif" alt="[TXT]" width="20" height="22"> <a
href="KUKU">KUKU</a>                    14-Jan-2007 14:20  256  
<hr></pre>
<address>Apache/2.2.4 (Unix) mod_ssl/2.2.4 OpenSSL/0.9.8d PHP/4.4.4
Server at <a
href="mailto:webmaster@math.technion.ac.il">www.math.technion.ac.il</a>
Port 443</address>
</body></html>


The diffrence between the two responses comes from the fact  that I have
the setting "IndexOptions SuppressHTMLPreamble",  which explains the
extra lines before the X's if the Header is of type text/plain, lines
which are suppressed if the Header is of type text/html.


Since I need to use HeaderFile of mime type text/html (I use normally
the .html extension and add the necessary HTML code), it seems the
solution to the problem is to use in Solaris system the directive
"EnableSendFile off" . Note that my document root is *not* network
mounted. So, I suggest to add SOLARIS to the list of systems where
sendfile should be disabled for files over 256 bytes! It is surprising
that this problem is not exhibited in httpd 2.0.59, although this
directive was introduced already in 2.0.44 according to the manual. In
any case, thank you for pointing this directive to me.

|
Thanks,

Zvi.
|

 

Ruediger Pluem wrote, On 18/01/07 21:55:

> On 01/18/2007 01:28 PM, Zvi Har'El wrote:
>   
>> I believe this is really a problem of the HTTP client protocol level. in
>> HTTP/1.1 we get a failure, and HTTP/1.0  or HTTPS (1.1 or 1.0) success,
>> for example:
>>     
>
> Could you please do the following tests independently:
>
> 1. Change the ForceType in your .htaccess to text/plain
> 2. Add EnableSendFile off to your httpd.conf
>
> Please retest afterwards with all four accesses
>
> HTTP/1.0, HTTP/1.1, ssl and non ssl.
>
> Regards
>
> RĂ¼diger
>   

-- 
Dr. Zvi Har'El      mailto:rl@math.technion.ac.il    Department of Mathematics
tel:+972-54-4227607 icq:179294841    Technion - Israel Institute of Technology
fax:+972-4-8293388  http://www.math.technion.ac.il/~rl/    Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)


Mime
View raw message