问题
I know that 777 gives more write - rights, but can people who visit your site change your file when is has the 777 instead of 755?
Sometimes it's enough when my file has the rights of 755, but I do sometimes 777, is that bad?
People don't recommend it, but why? Can people access it when it is on 777? Or are there more things that I don't know?
回答1:
A 777 permission on the directory means that everyone has access to read/write/execute (execute on a directory means that you can do a ls of the directory).
755 means read and execute access for everyone and also write access for the owner of the file. When you perform chmod 755 filename command you allow everyone to read and execute the file, owner is allowed to write to the file as well.
回答2:
check this picture and it is easy to understand .
source: Linuxeo
来源:https://stackoverflow.com/questions/18932536/ftp-rights-755-vs-777