Just note for squid server
這裡是實做 macport 安裝的 squid
sudo port install squid
若要有基本的 login 機制要實做,如下:
編輯 /opt/local/etc/squid/squid.conf 檔.
1. 將下列此行的註解拿掉
acl password proxy_auth REQUIRED
2. 在這一行後,
# auth_param basic program /opt/local/libexec/ncsa_auth /opt/local/etc/passwd
加
auth_param basic program /opt/local/libexec/squid/ncsa_auth /opt/local/etc/passwd
3. 在這行
http_access deny all
之前,加上
http_access allow password
然後用 htpasswd 新增帳號,即可。
htpasswd -c /opt/local/etc/passwd <your account>
Orignal From: Squid server with basic auth on Mac OSX