[Zope-dev] apache reverse proxy zope 2.7a1 bug?

Bernd Dorn zope-mailinglist@mopa.at
Fri, 11 Jul 2003 13:48:15 +0200


Bernd Dorn wrote:

> Dieter Maurer wrote:
> 
>> Bernd Dorn wrote at 2003-7-10 07:24 +0200:
>>  > i currently installed the zope 2.7 alpha 1 release on my linux 
>> (rh9)  > server and on my win2k developement machine
>>  >  > when the zope instance is directly accessed everything works 
>> fine, also  > the proxy access on the linux box works. but when i try 
>> to proxy zope  > through apache on my windoze box i get a 502 http error:
>>  > excerpt from the apache errror logs::
>>  >  > [Wed Jul 09 13:44:01 2003] [warn] proxy: bad HTTP/1.1 header 
>> returned by  > ... (GET)
>>  >  > it seems that zope 2.7 sends some corrupted http headers on windoze
>>
>> I would use a TCPLogger (I would use Shane's "tcpwatch")
>> to analyse the communication between browser and Zope.
>> I expect Zope sends the same header whether the browser or Apache
>> sends the request.
>> If this were not true, I would put the TCPLogger between Apache
>> and Zope.
>>
>>
>> Dieter
> 
> 
> 
> thanks for your answer
> 
> i think i found the problem by the use of tcpwatch
> 
> the linux installation returns this header::
> 
>  [00:00.030 - server connected]
>  HTTP/1.1 200 OK
>  Server: Zope/(unreleased version, python 2.2.2, linux2) ZServer/1.1
>  Date: Fri, 11 Jul 2003 11:15:12 GMT
>  Content-Length: 3053
>  Etag:
>  Content-Type: text/html
> 
> which seems to be ok
> 
> but the windoze returns this::
> 
>  [00:00.020 - server connected]
>  HTTP/1.1 200 OK
>  Server: Zope/(Zope 2.7.0-a1
>  , python 2.2.3, win32) ZServer/1.1
>  Date: Fri, 11 Jul 2003 11:12:14 GMT
>  Content-Length: 3053
>  Etag:
>  Content-Type: text/html
> 
> which imho is not ok, because the server field has linebreaks in it
> probably a unix/dos linebreak issue?
> 
> hm, i will try to change the server signature somewhere as a temporary 
> solution
> 
> but i think this should be fixed
> 
> though, my mozilla does not complain about it ..
> 
> 
> tia, bernd
> 
> 
> 
> _______________________________________________
> Zope-Dev maillist  -  Zope-Dev@zope.org
> http://mail.zope.org/mailman/listinfo/zope-dev
> **  No cross posts or HTML encoding!  **
> (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
> http://mail.zope.org/mailman/listinfo/zope )

just for the records ...

the problem is in lib/python/version.txt

which has a newline at the end of the file and therefore returns a 
newline, when i remove this newline it works


i hope some bugfixer reads this ...

App/version_txt.py should remove any linebreaks or just read the first line

much better:
the publisher should take care to handle linebreaks in header fields, 
additional lines just have to start with a space character

cheers, bernd