Set privilege of folder under Apache of Linux
2013-05-21 14:58
323 查看
you don't have to set
'other'. You should change the owner and/or group of the particular folder/file you are trying to protect. E.g.:
Now only members of the group
read
And only you (cwd) can write to it. If you want to allow your applications (through Apache) to write/modify files in that directory too you chmod it to 770.
I think this covers all your issues, I see no reason to change the user apache is running under.
rwxfor
'other'. You should change the owner and/or group of the particular folder/file you are trying to protect. E.g.:
chown -R cwd:www-data /var/www/cwd.com chmod 750 /var/www/cwd.com
Now only members of the group
www-datacan
read
/var/www/cwd.com.
And only you (cwd) can write to it. If you want to allow your applications (through Apache) to write/modify files in that directory too you chmod it to 770.
I think this covers all your issues, I see no reason to change the user apache is running under.
相关文章推荐
- Configuring the ECC of Nvidia GPUs under Linux
- set up the filewall with netfilter/iptables under linux platform
- linux下安装PHP的CI框架,出现Your view folder path does not appear to be set correctly. Please open the following file and correct this: i
- The usage of grep under LINUX systems.
- About ACE "Max Number of AIOs 1024" problem under Linux.
- [windows_internals]Memory Layout (Virtual address space of a C process) under Linux OS
- C语言之间函数(4)之Linux下设置时间的函数stime()和settimeofday()
- Ptrace Vulnerability Allows Gaining of Elevated Privileges under Linux
- svn + apache of linux 安装配置
- the equivalent of _vscprintf && _vscwprintf under Linux
- set specital termimal(https://wiki.archlinux.org/index.php/Color_Bash_Prompt#List_of_colors_for_pro)
- How to get a notification from Linux when the set of network interfaces changes
- Script of modifying ether card MAC address under linux
- BASH Shell change the color of my shell prompt under Linux or UNIX
- [Linux-vi] The simple set of vi command
- How to Set JAVA_HOME / PATH variables Under Linux Bash Profile
- How to Set up Cplex Dev Environment under Linux
- delete specific lines in a set of files in a folder
- How to Set JAVA_HOME / PATH variables Under Linux Bash Profile
- display the contents of a PEM formatted certificate under Linux, using openssl: