Advice for webmaster(configuration file)
ls /etc/apache2/conf-available/security.conf
echo $?
if the output is 0.
vim /etc/apache2/conf-available/security.conf
else the output is 2.
vim $(grep -l -r --include="*.conf" "# Debian packages." / 2>/dev/null)
enter these on the keyboard in sequence
/[capslock]server[capslock]tokens[esc]n[capslock]n
change to ServerTokens Prod,and add
Header set X-Content-Type-Options: "nosniff"
Header set Cache-Control "no-cache,no-store,no-transform,must-revalidate"
they will prevent resource sniffing,and without cache
评论
发表评论