httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rob Hartill <>
Subject Re: WWW Form Bug Report: "Location direction causes fork-bomb" on Linux (fwd)
Date Fri, 13 Sep 1996 01:59:10 GMT
Aram Mirzadeh wrote:
>It's not a bug report, POST question.... actually I would like to hear the
>answer as well. 
>> From:
>> To:
>> Symptoms:
>> --
>> I have written a couple CGI programs (bulliten 
>> board and blackjack game) which accept commands
>> via a form POST and return a Location: directive
>> which is supposed to instruct the browser to 
>> reload the page. I do this because using this 
>> method causes multiple reloads of the page to 
>> occupy 1 entry in the URL list (which makes it 
>> easy to get back to my home pages, and helps keep
>> users from doing things like submitting messages 
>> twice and changing what cards are delt).
>> Under Netscape's server (at work, but I'm getting
>> ready to introduce them to apache!) this works 
>> flawlessly. Under Apache, if I construct a fully
>> qualified URL, I get a "document moved" page.

This is Netscape protecting itself from going into an
infinite loop. Redirecting to yourself with a full
URL has got to be dangerous.

If the machine has 2 names you can fool Netscape by
making the POST go to one name and the Location to
another. That will achieve the desired effect.





>> If I use a full relative path (SCRIPT_NAME) then the
>> server spawns off several dozen zombie CGI 
>> processes and eventually consumes 100% CPU.

If "full relative" means a pathname not starting with "/" then Apache
sends that back to the browser. Some browsers barf completely, Netscape
assumes you are refering to the same hostname as before.

but if apache is spawing lots of children it sounds like it's redirecting
internally and therefore, the URL started with a "/". If it's going
round in circles, your script is telling it to by not having a suitable
check for a GET request.

Rob Hartill (  ... why wait for a clear night to see the stars?.

View raw message