Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] Appropriate permissions for cron job PHP script



Hi Dave,

> I realized this morning that it if someone knew the exact URL, they
> could activate it and if they hammered it enough, I suppose they could
> cause some slow down on the site.

Why not move the php script out of the web tree? That way it won't be
possible to be activated by a random visitor.

> I was wondering what the appropriate permission setting would be to
> make it so that it can only be activated by the local system, not by
> visitors to the site.

Assuming that the user activating the cron is root, you could simply
'chown root:root myScript.php; chmod 600 myScript.php' that should
make it so that only root as the read/write rights and no one
(including the webserver) can do anything else.... assuming your
webserver is not running as root, which is highly unlikely.

Cheers,
Sach


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links