【发布时间】:2015-03-21 07:37:49
【问题描述】:
我正在使用 spring security 3.2.5 和 Tomcat 7。当我尝试进入需要身份验证的页面(在远程服务器上通过 https)时,我没有重定向到默认的 spring security 登录表单。
我的 security.xml:
<security:intercept-url pattern="/**"
access="isAuthenticated()" requires-channel="https"/>
<security:port-mappings>
<!-- Default ports -->
<security:port-mapping http="8080" https="443" />
</security:port-mappings>
我得到的错误:
Google Chrome's connection attempt to X.X.XXX.42 was rejected. The website may be down, or your network may not be properly configured.ERR_CONNECTION_REFUSED
我尝试按照本教程进行操作:Link
块引用
【问题讨论】:
-
您是否在 server.xml 中启用了 https 连接器? 443端口是否在防火墙中打开?
-
是的。 https 工作重定向不
-
可以通过http访问登录页面吗?
-
不,我正在使用负载均衡器,但如果我直接尝试使用 tomcat 是的
标签: java spring spring-mvc tomcat spring-security