AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / server / 问题

问题[mod-auth](server)

Martin Hope
WackGet
Asked: 2020-03-26 20:44:08 +0800 CST

使用 Apache 在 Varnish 缓存后面保护对某些页面/目录的访问?

  • 0

我有一个公共网站,其中包含一些仅供私人/内部使用的 URL/目录。这些私人区域只能通过特定的 IP 地址或已知的用户名/密码访问。

目前我通过 .htaccess 文件实现这一点,如下所示:

AuthType     Basic
AuthName     "Protected Area"
AuthUserFile /path/to/.htpasswd

SetEnvIf Remote_Addr     1.2.3.4 trusted
SetEnvIf X-Forwarded-For 1.2.3.4 trusted
# (Note I am aware X-Forwarded-For can be spoofed)

<RequireAny>
    Require env trusted
    Require valid-user
</RequireAny>

问题是我想在我的服务器前面添加 Varnish 以提供缓存。显然,现有设置不适用于 Varnish,因为它无法以这种方式缓存受 .htaccess 文件限制的内容。

有没有办法我可以继续使用我的 .htaccess 文件来保护我的内部页面,或者我可以使用类似的方法来将安全责任放在 Varnish 本身上,它不需要每次我想要更改 Varnish 的 VCL 文件添加或修改限制?

security varnish apache-2.4 centos7 mod-auth
  • 1 个回答
  • 604 Views
Martin Hope
Matt Phillips
Asked: 2010-03-07 17:19:10 +0800 CST

Apache2 + mod_auth_kerb + 活动目录不会验证组权限

  • 1

我在 ubuntu 下设置了一个 apache2 服务器来针对 Active Directory 域控制器进行身份验证。它适用于我要保护的文件夹中的 .htaccess 文件,如

require valid-user

我的问题是我想使用组权限进行身份验证。因此,如果我在域上通过了身份验证(例如 matt)并且我尝试访问一个文件夹。我应该可以把

require group my_group@my.domain

它应该检查用户 matt 是否是 my_group 活动目录组的成员。我的想法是错的还是 mod_auth_kerb 不可能做到这一点?

apache-2.2 kerberos mod-auth
  • 1 个回答
  • 1525 Views
Martin Hope
veilig
Asked: 2010-02-25 10:06:58 +0800 CST

阿帕奇认证

  • 0

我正在尝试在我的网络上设置本地网络服务器。我希望能够从我的网络中的任何机器访问网络服务器,而无需进行身份验证。并且两个额外的域需要在没有身份验证的情况下访问它。我想在其中进行身份验证的其他所有人。到目前为止,我可以从我的网络内部访问它。并且两个额外的域可以访问我的网络服务器,但其他人只是挂起。他们没有得到认证或任何东西。

谁能告诉我我在这里做错了什么?

到目前为止,这是我的 apache 站点可用文件的一部分:

<Directory /path/to/server/>
    Options Indexes FollowSymLinks -Multiviews
    Order Deny,Allow
    Deny from All
    Allow from 192.168
    Allow from localhost
    Allow from domain1
    Allow from domain2
    AuthType Basic
    AuthName "my authentication"
    AuthUserFile /path/to/file
    Require valid-user
    Satisfy Any
    AllowOverride All
    <Files .htaccess>
        Order Allow,Deny
        Allow from All
    </Files>
</Directory>
apache-2.2 authentication mod-auth
  • 1 个回答
  • 148 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve