最終更新:2013-09-25 (水) 21:32:25 (3857d)  

httpd.conf
Top / httpd.conf

Linux/etc/httpd/conf/httpd.conf

IP制限

  • 89.149.244.21からのアクセスがひどいので拒否。
Order allow,deny 
Allow from all
Deny from 89.149.192.0/18

アクセスコントロール

Apache 2.2 configuration:

  • Order allow,deny
    Allow from all

Apache 2.4 configuration:

ディレクティブ

<Directory /path/to>

  • 指定のファイルシステムのディレクトリとサブディレクトリとのみに 適用されるディレクティブを囲む
  • AllowOverrideはDirectoryのみ
  • 頭の/がなかったらDocumentRoot?からの相対パス。

<Location /uri>

  • 囲んだディレクティブをマッチする URL のみに適用
  • <Location> ディレクティブは ファイルシステム外のコンテンツにディレクティブを適用するときに 使用してください。ファイルシステムに存在するコンテンツに対しては、 <Directory> と <Files> を使ってください。 例外は、<Location /> で、これはサーバ全体に対して 設定を適用する簡単な方法です。
      • Server-Status
      • ProxyPass?

<LocationMatch? /regexp>

Include

CentOS 5

Include conf.d/*.conf

Ubuntu

関連

参考