cuibobo

yum -y install httpd

vim /etc/httpd/conf/httpd.conf

ServerName  www.baidu.com

<Directory "/var/www/html">
authtype "basic"                                    #开启
authname "haha"            #定义别名
authuserfile "/var/www/html/pass.txt"    #指定网页根目录
require user 用户名              #指定用户
</Directory>

service  httpd  restart

#htpasswd  -c   /var/www/html/pass.txt   用户名

 注释:http访问规则:order,allow,deny(没有定义默认是最后一个单词)  order是有顺序的
        allow from IP地址
        deny from  IP地址

分类:

技术点:

相关文章:

  • 2021-10-23
  • 2021-06-21
  • 2021-12-23
  • 2021-07-06
  • 2021-11-01
  • 2022-01-02
  • 2022-01-02
  • 2021-09-21
猜你喜欢
  • 2021-05-29
  • 2021-06-28
  • 2021-12-23
  • 2021-06-25
  • 2021-11-05
  • 2021-12-23
  • 2021-12-23
相关资源
相似解决方案