標籤:bsp sddc rip oca name tor use cgi _id
CentOS7 安裝最新版本號碼 awstats ,在httpd.conf 中增加了alias,能夠直接訪問網址就進入 瀏覽。十分不安全。
給訪問加上password的方法:
[[email protected] wwwroot]# htpasswd -bc /home/awstats/wwwroot/.htpasswd aaa 123456[[email protected] wwwroot]# nano /etc/httpd/conf/httpd.conf #改動 Apache 設定檔。給awstats 加上限制:Alias /awstatscss "/home/awstats/wwwroot/css/"Alias /awstatsicons "/home/awstats/wwwroot/icon/"ScriptAlias /awstats/ "/home/awstats/wwwroot/cgi-bin/"## This is to permit URL access to scripts/files in AWStats directory.#<Directory "/home/awstats/wwwroot"> Options None AllowOverride None AuthName "Members Only" AuthType basic AuthUserFile /home/awstats/wwwroot/.htpasswd require valid-user #Require all granted</Directory>
在又一次訪問 http://www.zbphp.com/awstats/awstats.pl 會出現須要輸入password的提示(by default7#zbphp.com):
Linux Apache 給 awstats 建立 訪問password