1、 vim /usr/local/openresty/nginx/conf/conf.d/cloudlab.conf
##修改 location ~ ^/(.user.ini|.htaccess|.git|.project|LICENSE|README.md|web.config)
{
return 404;
}

2、重启服务生效:systemctl restart openresty
禁用nginx访问和下载文件(web.config和\.htaccess)

或者是在vim /etc/nginx/nginx.conf 中修改
验证访问不到了 systemctl restart nginx

禁用nginx访问和下载文件(web.config和\.htaccess)

相关文章:

  • 2021-11-15
  • 2022-12-23
  • 2021-07-11
  • 2021-07-16
  • 2021-09-08
  • 2022-12-23
  • 2021-10-05
猜你喜欢
  • 2022-12-23
  • 2021-06-25
  • 2022-12-23
  • 2021-09-29
  • 2021-12-18
  • 2022-12-23
相关资源
相似解决方案