Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Re^2: CGI parse and edit file

by ikkon (Monk)
on Feb 29, 2008 at 04:46 UTC ( #671091=note: print w/replies, xml ) Need Help??

in reply to Re: CGI parse and edit file
in thread CGI parse and edit file

[Thu Feb 28 20:23:55 2008] cgiTest.cgi: Can't open Entrance.css : Permission denied at /hosted/MysticAbyss/site/Entrance/cgiTest.cgi line 57.
thats the error I recieve I am not sure why I am getting a permission error I set the permission to 755 and initial it seems to open just fine until the writing acures then it bombs.

Replies are listed 'Best First'.
Re^3: CGI parse and edit file
by moritz (Cardinal) on Feb 29, 2008 at 08:05 UTC
    You don't have a selinux enabled operating system, by chance, or one with some other additional security services?

    Update: much easier explanation: the files are stored as belonging to your user, not the web server's user id.

Re^3: CGI parse and edit file
by proceng (Scribe) on Feb 29, 2008 at 13:13 UTC
    Setting the permission to 755 without changing the owner does not confer write privileges to anyone else.
    Allowing write privileges to anyone else is DANGEROUS to the health of your web server.
    If you must allow a web hosted procedure to modify a CSS file, create and edit a user file (ie: a CSS file stored in the user's directory) and design the application to override the appication defaults with this.
    Many browsers will allow this to be done locally, research the target browser(s).
    Again, do not allow users to modify system files, especially as part of a web application (I usually set permissions to 0555 and then override only as necessary).

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://671091]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (5)
As of 2017-11-24 21:22 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (353 votes). Check out past polls.