Click here to Skip to main content
15,890,438 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all,

Here is my virtual host file, but when added the deny all, i am unable to see the site online. Just struggling to set up the virutal host with deny all for a particular sub directory within my application.

How to make this secure..any suggestions are highly appreciated.

What I have tried:

<VirtualHost *:80>
ServerName www.xxx.com
ServerAlias xxx.com
ServerAlias https://www.xxx.com
ServerAdmin xxx@gmail.com
php_flag log_errors on
    php_flag display_errors off
    php_value error_reporting 2147483647
ErrorLog "logs/abc.com-error.log"
CustomLog "logs/abc.com-access.log" common

	DocumentRoot "c:/xampp/htdocs/abc"
	<Directory "c:/xampp/htdocs/abc">
	
	 Options FollowSymLinks Indexes
    AllowOverride All
    Order deny,allow
    Allow from 127.0.0.1
    Deny from all
    Require all granted
	
		
	</Directory>
</VirtualHost>
Posted
Updated 16-Jun-19 2:59am
v2

1 solution

You could try to change the order:
Order allow,deny
and check if it fits your needs.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900