2013年1月24日木曜日

ApacheでBasic認証とIP制限を組み合わせる

.htaccess で以下の感じで。
AuthType Basic
AuthName "Input your ID and Password"
AuthUserFile /var/www/.htpasswd
require valid-user
Satisfy any
Order Deny,Allow
Allow From 192.168
Deny From All
Satisfy any を使って書けばいい。

0 件のコメント:

コメントを投稿