hi, i'm using linux. there are some domains there, such as the follow:
/home/wwwroot/aaa.com
/home/wwwroot/bbb.com
/home/wwwroot/ccc.com
FILE1: /home/wwwroot/aaa.com/get.php
FILE2:/home/wwwroot/bbb.com/config.php
in FILE1, I wrote:
<?php
$data = file_get_contents('/home/wwwroot/bbb.com/config.php');
echo $data; //i can get the data.
?>
I think is unsafe. could you please tell me how to config with nignx config that the domain only allow to acces its directory.?
/home/wwwroot/aaa.com
/home/wwwroot/bbb.com
/home/wwwroot/ccc.com
FILE1: /home/wwwroot/aaa.com/get.php
FILE2:/home/wwwroot/bbb.com/config.php
in FILE1, I wrote:
<?php
$data = file_get_contents('/home/wwwroot/bbb.com/config.php');
echo $data; //i can get the data.
?>
I think is unsafe. could you please tell me how to config with nignx config that the domain only allow to acces its directory.?