 |
Как можно управлять Apache? Директивы .htaccess Web-?????? Apache ????????? ??????????? ????????? ??? ?????????? ??????????,
??? ????? ?????????? ?????????? ? ??? ???? .htaccess, ? ???? ?????
????????????? ??????????? ?????????. ????????????? ???????
??????????? ????????? ?????????, ?.?. ??? ????? ??????? ? ??? ????
?????????????. ????????????? ?????????? ????????? ? ????? httpd.conf.
???? ? ????? ???????? ???? .htaccess, ?? ? ??? ??????????? ?? ?????????, ???
?????????????? ? ???. ?????? ????????? ????????? ?? ??? ?????????????, ????
?? ??????????? ?????????? ? ?????? ?????? .htaccess.
DirectoryIndex mystart.php5 – ????????? ?????????????? ????????? ????
??? ??????????. ????????????? ??????????? ?????, ??????? ??????????????? ???
?????????, ?.?. ??????????? ?? ?????????, ?? ???? ?? ?????? ????????????
???? ????????? ????, ???????? mystart.php5, ?? ????????? ?????? ?????????.
???? ???????????? ?????? ????? ?? ?????, ??? ????? ????????????? ????
.htaccess ? ?????? ??????????, ?? ?????????? ???? mystart.php5. ?????
??????????? ????????? ?????? ????????? ?? ????? ??????, ????????? ???
????????, ??? ??????? ?????????? ??????, ????? ????? ??????, ???????????
????. ??? ?? ????? ????????? ?????????? ??????, ?????? ??????? ?? ????????.
ErrorDocument 404 /index.html – ?????? ????????? ????????? ?? ????,
??????? ?????? ?????? ? ??????, ????????????? ?????? ? ????????? ???????,
???? ? ????? ??????????? ?? ???????? ?????????? ?????. ?????? ??????
??????: 404 - ???? ?? ??????; 500 - ?????? ???????; 403 - ?????? ????????.
????????????: ErrorDocument ?????_?????? ????_?_?????.
CharsetRecodeMultipartForms Off - ????????? ????????????? ????????????
?? ?????? ??????. ???????????? ? ???????, ????? ?????? ?????????? ????????
?? ?????? ?????-???? ??????, ???????? ????????.
deny – ????????? ????????????? ??????? ? ??????????, ?
??????? .htaccess. ????????, ???? ?? ?????? ????????? ?????? ?? ????
??????, ???????? deny from all. ????????????, ???????????? ? ??????
??????????, ?????? ?? ??????, ?? ???????, ?????????? ?? ??????? ???????,
????? ????? ????? ? ?????? ? ??? ????? ?????? ?? ????, ???????????? ??
?????????? ?????. ???? ?? ?????? ??????? ?????? ?????? ??? ????????????? ip
??????, ?? ?????????
Order Allow,Deny
deny from all
allow from 192.168.6.254
???? ????? ?????????? ? IP 192.168.6.254 ?????? ????????.
????? ????? ??????? ?????? ip ????????? ?????
Order Deny,Allow
Deny from all
Allow from .test.com
Redirect / http://www.novosti.ru - ???????? (???????????????)
??????????? ?? ???? www.novosti.ru
??? ??????????????? ??????????? ??? ??????? ???????????? ???????,
????????? ? .htaccess:
redirect /scripts http://www.nov.com
redirect /_vti_bin http://www.nov.com
redirect /MSADC http://www.nov.com
redirect /_mem_bin http://www.nov.com
redirect /msadc http://www.nov.com
RedirectMatch (.*)cmd.exe$ http://www.nov.com$1
????? ?????? ? ??????? /_vti_bin ??? /scripts ????? ?????????????
???????????????? ?? ???? nov.com.
???????? ??????????? ? ??????????? ?? ??????? (???????? ?????? ??????
??????????):
RewriteCond %{HTTP_REFERER} http://www.novosti.ru
RewriteRule ^/stat.html$ /nov.html [L]
? ?????? ?????? ??? ? ????? /www.novosti.ru ?????? ????? stat.html
??????? ?????? nov.html
Options –Indexes - ????????????? ?????? ?? ???????? ???????????
??????????, ??? ?????????? ? ??? ?????????? ?????. ??? ??????????
????????? - Options +Indexes.
AddType application/x-httpd-php .ext1 .php3 - ????????? ????? ?
???????????? .extl ? .php3 ?????????? ??????????????? PHP (?.?. ??? ?
????? .php).
|
|