使用htpasswd的Apache中同时使子文件夹无限制 [英] making subfolder unrestricted while using .htpasswd in apache

查看:90
本文介绍了使用htpasswd的Apache中同时使子文件夹无限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的Linux服务器上运行多个应用程序。

I have multiple applications running in my linux server.

主域名使用htpasswd的文件是安全的。

The main domain is secure using .htpasswd file.

不过,我需要的安全子域中被删除。

But I need the security to be removed in the subdomain.

我怎么能做到这一点。

问候

尼扎姆

推荐答案

将下面的子文件夹内的.htaccess文件:

Put the following in a .htaccess file inside the subfolder:

Order deny,allow
Allow from All
Satisfy any

订单拒绝,允许引起允许来覆盖任何拒绝指令。
从所有允许访问所有主机允许。
满足任何将导致密码验证被绕过,因为基于主机的规则是通过(从所有允许)。

Order deny,allow causes Allow to override any Deny directives.
Allow from All grants access to all hosts.
Satisfy any causes the password authentication to be bypassed because a host-based rule (Allow from All) was passed.

链接到Apache手册:

Links to the Apache manual:

  • <一个href="http://httpd.apache.org/docs/current/mod/mod_authz_host.html#order">http://httpd.apache.org/docs/current/mod/mod_authz_host.html#order
  • <一个href="http://httpd.apache.org/docs/current/mod/mod_authz_host.html#allow">http://httpd.apache.org/docs/current/mod/mod_authz_host.html#allow
  • <一个href="http://httpd.apache.org/docs/current/mod/core.html#satisfy">http://httpd.apache.org/docs/current/mod/core.html#satisfy
  • http://httpd.apache.org/docs/current/mod/mod_authz_host.html#order
  • http://httpd.apache.org/docs/current/mod/mod_authz_host.html#allow
  • http://httpd.apache.org/docs/current/mod/core.html#satisfy

这篇关于使用htpasswd的Apache中同时使子文件夹无限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆