サーバセキュリティ

apacheユーザの変更

apache2デフォルトユーザwww-dataの変更

$ sudo pico /etc/apache2/envvars
.....
# Since there is no sane way to get the parsed apache2 config in scripts, some
# settings are defined via environment variables and then used in apache2ctl,
# /etc/init.d/apache2, /etc/logrotate.d/apache2, etc.
export APACHE_RUN_USER=apache_user
export APACHE_RUN_GROUP=apache_user
....
$ sudo chown -R apache_user:apache_user /var/www/html
$ sudo chmod -R 7XX /var/www/html

www-dataによるawstats等関連サービスのアクセス権も変更すること。