LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 02-02-2006, 03:55 AM   #1
bigtl
Member
 
Registered: Aug 2001
Location: Worksop England
Distribution: debian, fedora core
Posts: 35

Rep: Reputation: 15
confused by file permission


Hi

my webserver is running as user www-data

i have the following file:

-rwxr--r-- 1 root root 4800 2006-02-02 09:47 misc.class.php

yet my php scripts run through the webserver can delete this file. How?

surely if this is owned by root, only root can delete it.


thanks in advance.
tony
 
Old 02-02-2006, 04:50 AM   #2
marozsas
Senior Member
 
Registered: Dec 2005
Location: Campinas/SP - Brazil
Distribution: SuSE, RHEL, Fedora, Ubuntu
Posts: 1,508
Blog Entries: 2

Rep: Reputation: 68
Deleting a file (or changing it's name) is an operation on the directory not on the file itself !
So, you have to pay attention to directory permissions.
 
Old 02-02-2006, 05:56 AM   #3
bigtl
Member
 
Registered: Aug 2001
Location: Worksop England
Distribution: debian, fedora core
Posts: 35

Original Poster
Rep: Reputation: 15
now it all becomes clear, thanks
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Very confused about 2GB file size limit! nkendrick Linux - General 6 09-29-2005 07:14 PM
File Permission gardenair Linux - Newbie 5 04-28-2005 10:35 PM
Confused about partitions and file structure frankie_DJ Linux - Newbie 2 09-17-2004 06:25 PM
BASH scripting: confused about redirection & file descriptors funkymunky Programming 1 06-07-2004 07:47 AM
Pretty confused about using numbers for file permissions Squall Linux - General 3 04-21-2004 09:17 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 08:14 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration