httpd-docs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Slive <jos...@slive.ca>
Subject Re: Please add a solution to the FAQ
Date Thu, 08 Dec 2005 15:23:45 GMT


Michel Hendriks wrote:
>> -----Oorspronkelijk bericht-----
>> Van: Joshua Slive [mailto:joshua@slive.ca] 
>> Verzonden: donderdag 8 december 2005 15:26
>> Aan: docs@httpd.apache.org
>> Onderwerp: Re: Please add a solution to the FAQ
>>
>> Michel Hendriks wrote:
>>> Apache 1.3 apparently also outputs the "Premature end of headers" 
>>> warning if the script or its directories are not owned by 
>> the correct user.
>>> So all I needed to do was change the ownership of 
>> directoies and the 
>>> script to the user I was trying to run it under and all of 
>> a sudden it 
>>> worked!
>>>  
>>> Maybe you could save someone else the same agony by adding 
>> this to the 
>>> answers?
>> Actually, I'm pretty sure that your problem is either your 
>> script crashing because of bad permissions on files it uses, 
>> which is document: 
>> "Even if the CGI runs fine from the command line, remember 
>> that the environment and permissions may be different when 
>> running under the web server. The CGI can only access 
>> resources allowed for the User and Group
>>   specified in your Apache configuration."
>>
>> Joshua.
> 
> Well....Not entirely what I am seeing here. My script was owned by root and
> had
> 0755 permissions. That should give anyone enough permissions to run this
> script 
> and indeed it does. However, some kind of check exists in Apache which
> rejects 
> running of the script as it is not owned by the user itself.
> 
> The script was located in donkey/public_html/cgi-bin/start.cgi. All dir's
> and files
> From the public_html/ and deeper were owned by root.
> I did not change a thing, except do a `chown -R donkey:donkey public_html/`
> and
> After that the script worked!
> 
> Michel
> 
> B.t.w I'm using Mandrake 8.2 and Apache 1.3.23

Almost certainly it was not httpd with the problem but suexec.  I have 
long argued against distributions which install suexec by default for 
reasons like this.

Joshua.

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


Mime
View raw message