How do I restrict web access to parent folders of the main website directory. For example if I have the following directories/files:
/
├── home
│ └── user
│ │ ├── img.png
│ │ ├── script.js
│ │ └── page.html
└── var
└── www
└── index.html
and www.example.com points to /var/www/
, I don't /var/www/index.html
to be able to access any files outside, in this case, img.png
, script.js
, page.html
.
A few extra notes: