想了解带有基本authentication的Apache反向代理的新动态吗?本文将为您提供详细的信息,我们还将为您解答关于apache反向代理的相关问题,此外,我们还将为您介绍关于.net–IAuth
想了解带有基本authentication的Apache反向代理的新动态吗?本文将为您提供详细的信息,我们还将为您解答关于apache 反向代理的相关问题,此外,我们还将为您介绍关于.net – IAuthenticationFilter.OnAuthenticationChallenge()的目的是什么、Apache 2.4“..authentication失败..:密码不匹配”、Apacheauthentication规则转换为nginx服务器、Apacheconfiguration – 从authentication中排除位置的新知识。
本文目录一览:- 带有基本authentication的Apache反向代理(apache 反向代理)
- .net – IAuthenticationFilter.OnAuthenticationChallenge()的目的是什么
- Apache 2.4“..authentication失败..:密码不匹配”
- Apacheauthentication规则转换为nginx服务器
- Apacheconfiguration – 从authentication中排除位置
带有基本authentication的Apache反向代理(apache 反向代理)
在将stream量转发到我的后端服务器之前,尝试使用基本身份validationconfiguration我的反向代理。 任何人都可以给我一个解决scheme。
示例:
用户(互联网) – >反向代理/虚拟主机服务器(需要在这里添加基本authentication) – >后端服务器(未authentication)
如何在Heroku上以REST API后端优化服务静态文件
使用Nginx将端口80转发到8080
如何configurationNginx充当代理负载均衡器?
在apache中build立一个基本的web代理
neo4j web界面背后的Nginx反向代理
Nginx转发代理 – 失败(24:打开的文件太多),
如何在linux中安全地使用http_proxyvariables
为什么Nginx不caching我的内容?
通过configurationapache的.conf文件将httpredirect到https
在Web应用程序中使用Nginx服务器转到Web服务器
您可以按照此处的说明进行操作: 身份验证,授权和访问控制 。 你的反向代理的主要区别在于你要把auth的东西放在一个Location块中,即使这个文档说他们只允许在目录块中:
<Location /> AuthType Basic ... </Location>
在Location块之外,你可以放置你的代理命令,比如:
ProxyPass / http://localhost:8080/
这是我用来通过https完成对数据库的基本认证的配置。 我的后端服务器运行Tomcat,并使用AJP连接到它。 有趣的端口号(4443)是因为标准端口(443)已被使用,我不想在同一个端口上配置多个https服务。
<Ifmodulee mod_ssl.c> NameVirtualHost *:4443 <VirtualHost *:4443> serverAdmin webmaster@localhost serverName ws.myserver.se serverAlias ws.myserveralias.se ErrorLog /var/log/apache2/ajpProxy.error.log # Possible values include: debug,info,notice,warn,error,crit,# alert,emerg. LogLevel info CustomLog /var/log/apache2/ajpProxy.log combined DBDriver MysqL DBDParams "host=127.0.0.1 port=3306 user=proxyAuthUser pass=yourDbPasswordHere dbname=yourdbname" DBDMin 4 DBDKeep 8 DBDMax 20 DBDExptime 300 <Proxy *> # core authentication and mod_auth_basic configuration # for mod_authn_dbd AuthType Basic AuthName "Backend auth name" AuthBasicProvider dbd # core authorization configuration Require valid-user # mod_authn_dbd sql query to authenticate a user AuthDBDUserPWQuery "SELECT password FROM user WHERE emailAddress = %s" AddDefaultCharset Off Order deny,allow Allow from all </Proxy> ProxyPass / ajp://localhost:8009/ ProxyPassReverse / ajp://localhost:8009/ # SSL Engine Switch: # Enable/disable SSL for this virtual host. SSLEngine on # A self-signed (snakeoil) certificate can be created by installing # the ssl-cert package. See # /usr/share/doc/apache2.2-common/README.Debian.gz for more info. # If both key and certificate are stored in the same file,only the # SSLCertificateFile directive is needed. SSLCertificateFile /etc/apache2/ssl/yourCertificateFile.crt SSLCertificateKeyFile /etc/apache2/ssl/yourPrivateKeyFile.key <FilesMatch ".(cgi|shtml|phtml|PHP)$"> SSLOptions +StdEnvVars </FilesMatch> <Directory /usr/lib/cgi-bin> SSLOptions +StdEnvVars </Directory> browserMatch "MSIE [2-6]" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0 # MSIE 7 and newer should be able to use keepalive browserMatch "MSIE [17-9]" ssl-unclean-shutdown </VirtualHost> </Ifmodulee>
首先,检查你的apache2是否有utils包
sudo apt-get install apache2-utils
然后,设置用户名和密码。
sudo htpasswd -c /etc/apache2/.htpasswd <username>
之后,编辑您的反向代理以使用身份验证
<VirtualHost *:80> ProxyPreserveHost On ProxyPass / http://someaddress:1234/ ProxyPassReverse / http://someaddress:1234/ Timeout 5400 ProxyTimeout 5400 serverName dev.mydomain.com serverAlias *.dev.mydomain.com <Proxy *> Order deny,allow Allow from all Authtype Basic Authname "Password required" AuthUserFile /etc/apache2/.htpasswd Require valid-user </Proxy> </virtualhost>
至少,更新你的Apache
sudo service apache2 reload
总结
以上是小编为你收集整理的带有基本authentication的Apache反向代理全部内容。
如果觉得小编网站内容还不错,欢迎将小编网站推荐给好友。
.net – IAuthenticationFilter.OnAuthenticationChallenge()的目的是什么
> IAuthenticationFilter.OnAuthentication
>授权(如果有的话)
>控制器动作
> IAuthenticationFilter.OnAuthenticationChallenge
为什么在控制器动作之后会发生?从this blog post开始,我读到了
The key thing to remember is that
OnAuthenticationChallenge
does not
necessarily run before every other Action Filter. It can run at
varIoUs stages.
如果我们无法判断它究竟何时被调用,它怎么有用呢?
解决方法
“只要请求失败了操作方法的身份验证或授权策略,MVC框架就会调用OnAuthenticationChallange方法.OnAuthenticationChallenge方法传递一个AuthenticationChallengeContext对象,该对象派生自ControllerContext类”
所以,一个实际的例子是:
1 – 您设置自定义授权过滤器
2 – 用户在授权方法上失败
调用3 – OnAuthenticationChallenge方法.
Apache 2.4“..authentication失败..:密码不匹配”
我在Windows Server 2008 R2中运行Apache 2.4。 我正在尝试密码保护一个子目录,并成功地在Apache 2.0中这样做。 升级后,我采取了Apache的build议,并试图把authenticationconfiguration在httpd.config。 我允许读取密码文件和一切似乎是为了,但是当我testing它时,我得到以下错误:
[Mon Apr 01 19:58:36.438476 2013] [auth_basic:error] [pid 3984:tid 788] [client xxx.yyy.254.2:49253] AH01617:user master:“/restricted/file.zip”的authentication失败:密码不匹配
但是,我知道我正在发送正确的密码。 看下面我的configuration,任何意见是有帮助的。
<Directory "C:/www/mydir/restricted"> #AllowOverride AuthConfig #Order allow,deny #Allow from all AuthType Basic AuthName Restricted AuthUserFile "C:/www/mydir/passwords/pass" Require valid-user </Directory> <Directory "C:/www/mydir"> Require all granted </Directory> <VirtualHost *:80> ServerAdmin admin@.com DocumentRoot "C:/www/mydir" ServerName "fakeurl.com" ErrorLog "C:/www/mydir/logs/error.log" CustomLog "C:/www/mydir/logs/accesslog/access.log" common </VirtualHost> <VirtualHost *:80> ServerAdmin admin@.com DocumentRoot "C:/www/mydir" ServerName "www.fakeurl.com" ErrorLog "C:/www/mydir/logs/error.log" CustomLog "C:/www/mydir/logs/accesslog/access.log" common </VirtualHost>
我将如何在.htaccess文件中编写if – elseif – elseif条件块?
混合内容/不安全内容SSL
.htaccess不能只与Internet Explorer一起工作
redirect到https和www在Apache中的单一redirect
Nginx – Magento多个网站
如何使用.htaccess检查文件是否存在于caching中,如果没有则加载正常脚本
PHP / Apache:使用.htaccess重写规则
使用.htaccess在多个条件下的URL重写/redirect/限制
在Apache中使用Access-Control-Allow-Origin标头处理多个域
重写dynamicurl
我刚刚遇到了同样的问题,在最后一个小时里把我逼疯了。 我可以确认,史蒂夫的建议在命令行中输入密码的作品 – 所以在我的情况下“htpasswd -b密码文件用户密码”伎俩。
这是Apache的相关错误报告。
你用''htpasswd''创建你的密码了吗?
httpd-2.4.4中的htpasswd坏了( https://issues.apache.org/bugzilla/show_bug.cgi?id=54735 )。
据我了解,问题是特定于httpd-2.4.4中的htpasswd,只有当您手动输入密码才会发生,所以您可以通过执行以下操作之一来解决该问题:
在命令行提供密码(例如“htpasswd -b .htpasswd用户密码”);
使用httpd-2.4.3中的htpasswd版本;
使用摘要式身份验证而不是基本身份验证(htdigest不受影响);
等到httpd-2.4.5发布;
在bug报告(这似乎工作)应用修补程序,并从源重建htpasswd。
总结
以上是小编为你收集整理的Apache 2.4“..authentication失败..:密码不匹配”全部内容。
如果觉得小编网站内容还不错,欢迎将小编网站推荐给好友。
Apacheauthentication规则转换为nginx服务器
请帮助我将这些.httacces规则从apache转换为Nginx规则
RewriteCond %{HTTP:Authorization} ^(.*) RewriteRule ^(.*) - [E=HTTP_AUTHORIZATION:%1] SetEnvIf Authorization "(.*)" HTTP_AUTHORIZATION=$1
谢谢。
为什么laravel家园没有运行Apache
密码保护Flask应用程序中的一个网页
htaccess重写QueryString在Apache 2.2中消失,但在2.4中工作
Url重写mod_rewrite
如何阻止POST请求的IP,但不是GET?
总结
以上是小编为你收集整理的Apacheauthentication规则转换为nginx服务器全部内容。
如果觉得小编网站内容还不错,欢迎将小编网站推荐给好友。
Apacheconfiguration – 从authentication中排除位置
我有一个受Shibbolethauthentication模块保护的Web应用程序。 我目前的configuration如下
<Location /MyApp> AuthType shibboleth ShibUseHeaders On ShibRequestSetting requireSession 1 require shibboleth </Location>
shibboleth是一个提供SSOfunction的身份validation模块,当前的stream程将用户引导到身份提供者以供用户inputlogin凭证。 我希望能够打开一个特定的URL,以便URL被authentication模块绕过。 我试了下面,但它似乎并没有工作,我得到一个空白页面加载URL
方法1
<Location /MyApp/Login.html> Satisfy Any Allow from all AuthType None Require all granted </Location>
方法2
位置重写为多个域
在Nginx中嵌套位置
得到被点击的图片框的位置
我应该在哪里放第三方库?
带有多个位置的Nginx proxypass
<Location /MyApp/Login.html> AuthType shibboleth ShibRequestSetting requireSession 0 require shibboleth </Location>
我做了一些额外的debugging,似乎问题是与其他文件的Login.html加载 – 如CSS,JS等。什么是正确的方式来configuration这个在Apache中,这样的Login.html可以绕过authentication
谢谢
如何将python中的.place()方法转换为java?
如何防止出现新的连接的networking位置对话框(家庭,工作,公共)?
C# – 如何访问WLAN信号强度和其他?
不能用Nginx隐藏位置的端口
获取文件的扇区位置
我对最后关于排除Login.html加载的其他文件的评论最终是正确的。 我使用下面的格式来排除HTML文件正在加载的文件
<Location ~ "/MyApp/(Login.html|SessionTimeout.html|accessDenied.html|/badRequest.html|status|css/*|login/*|images/*|style/*|js/*|javascript/*|)"> Satisfy Any Allow from all AuthType None Require all granted </Location>
总结
以上是小编为你收集整理的Apacheconfiguration – 从authentication中排除位置全部内容。
如果觉得小编网站内容还不错,欢迎将小编网站推荐给好友。
关于带有基本authentication的Apache反向代理和apache 反向代理的问题就给大家分享到这里,感谢你花时间阅读本站内容,更多关于.net – IAuthenticationFilter.OnAuthenticationChallenge()的目的是什么、Apache 2.4“..authentication失败..:密码不匹配”、Apacheauthentication规则转换为nginx服务器、Apacheconfiguration – 从authentication中排除位置等相关知识的信息别忘了在本站进行查找喔。
本文标签: