문제

I am trying to simulate shared hosting on my local server by blocking off the root directory.

I've tried:

<Directory "C:/xampp/htdocs/root">
Options -Indexes
</Directory>

in httpd.conf (restarted Apache)

and

Options -Indexes

in the .htaccess of htdocs.

What do I need to do to restrict opendir from accessing beyond this folder?

도움이 되었습니까?

해결책

You need to use open_basedir in the config file

open_basedir - how to set for specific directory

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top