0

I have a folder /video which should only be accessible for users who are logged in. For Authentication I use sessions. If sessions are set correctly, I use chmod('/video', 0755) to make the folder accessible. My problem: everybody has access to that folder now. How can i make folders session-based accessible?

1 Answers1

1

At the moment you give read and execute rights to everyone because of the 0755:

  • 7: Users have read, write, and execute rights
  • 5: The declared user group has read and execute rights
  • 5: Others have read and execute rights

You could try chmod('/video', 0750)

For more info read this Wikipedia article.

mkrnr
  • 842
  • 8
  • 17