안녕하세요.
Apache에서요.. (httpd.conf)
ServerName...
...생략...
SetEnvIFNoCase Request_URI .(asf|avi|wma)$ is_not_access
SetEnvIFNoCase Request_URI .(gif|jpg|jpeg)$ is_allow_access
############
## 사례 1 ##
############
<Directory /home/*>
AllowOverride All
Order allow,deny
Allow from all
Deny from env=is_not_access
</Directory>
...생략...
############
## 사례 2 ##
############
<VirtualHost 127.0.0.1>
ServerAdmin me@localhost.com
DocumentRoot /home/sungmin/www
ServerName domain.com
<Directory "/home/sungmin/www">
Order deny,allow
Deny from all
Allow from env=is_allow_access
</Directory>
</VirtualHost>
이런식으로 했습니다.
사례 1의 경우 is_not_access 에 정의된 영상파일을 금지하는
것이고,
사례 2의 경우 is_allow_access 에 정의된 이미지 파일은 허용하고
나머지는 거부한다는 목적으로 한 것입니다.
근데, 아무것도 거부 안되고 다 됩니다.??
/usr/local/apache/bin/httpd -t 검사해도 OK고,
재시작해도 에러없습니다.
뭐 잘못 되었는지요??
|