You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by mp...@apache.org on 2015/11/20 13:38:17 UTC
ambari git commit: AMBARI-13991. HTTP status code 401 on incorrect
login credentials. (mpapirkovskyy)
Repository: ambari
Updated Branches:
refs/heads/trunk 65d1b4125 -> 0d93e9314
AMBARI-13991. HTTP status code 401 on incorrect login credentials. (mpapirkovskyy)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/0d93e931
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/0d93e931
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/0d93e931
Branch: refs/heads/trunk
Commit: 0d93e93144d0e9051d49a70d3f9edbef499dde01
Parents: 65d1b41
Author: Myroslav Papirkovskyy <mp...@hortonworks.com>
Authored: Fri Nov 20 14:28:37 2015 +0200
Committer: Myroslav Papirkovskyy <mp...@hortonworks.com>
Committed: Fri Nov 20 14:37:56 2015 +0200
----------------------------------------------------------------------
.../src/main/resources/webapp/WEB-INF/spring-security.xml | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/0d93e931/ambari-server/src/main/resources/webapp/WEB-INF/spring-security.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/webapp/WEB-INF/spring-security.xml b/ambari-server/src/main/resources/webapp/WEB-INF/spring-security.xml
index 8b5bd97..3bbc785 100644
--- a/ambari-server/src/main/resources/webapp/WEB-INF/spring-security.xml
+++ b/ambari-server/src/main/resources/webapp/WEB-INF/spring-security.xml
@@ -24,15 +24,15 @@
<http use-expressions="true"
disable-url-rewriting="true" entry-point-ref="ambariEntryPoint">
- <http-basic/>
<intercept-url pattern="/**" access="isAuthenticated()"/>
+ <custom-filter ref="basicFilter" position="BASIC_AUTH_FILTER"/>
<custom-filter ref="ambariJwtAuthenticationFilter" after="BASIC_AUTH_FILTER" />
<custom-filter ref="ambariAuthorizationFilter" before="FILTER_SECURITY_INTERCEPTOR"/>
</http>
<!--<ldap-server id="ldapServer" root="dc=ambari,dc=apache,dc=org"/>-->
- <authentication-manager>
+ <authentication-manager alias="authenticationManager">
<authentication-provider user-service-ref="ambariLocalUserService">
<password-encoder ref="passwordEncoder"/>
@@ -46,4 +46,8 @@
<beans:bean id="ambariEntryPoint" class="org.apache.ambari.server.security.AmbariEntryPoint">
</beans:bean>
+
+ <beans:bean id="basicFilter" class="org.springframework.security.web.authentication.www.BasicAuthenticationFilter">
+ <beans:constructor-arg ref="authenticationManager"/>
+ </beans:bean>
</beans:beans>