Skip to content

Instantly share code, notes, and snippets.

@xlcommunity
Last active June 13, 2018 15:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xlcommunity/d20933e1a26bdcb8feff to your computer and use it in GitHub Desktop.
Save xlcommunity/d20933e1a26bdcb8feff to your computer and use it in GitHub Desktop.
Integrate Crowd and Deployit 3.7.x
<?xml version="1.0" encoding="UTF-8"?>
<!-- NOTE: THIS CODE IS DEPRECATED
Please refer to this documentation, to leverage OIDC authentication for Crowd integration
CrowdId: https://confluence.atlassian.com/crowd/1-2-what-is-crowdid-58656152.html
Setting up OpenId authentication: https://docs.xebialabs.com/xl-release/concept/xl-release-oidc-authentication.html
-->
<!--
THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS
FOR A PARTICULAR PURPOSE. THIS CODE AND INFORMATION ARE NOT SUPPORTED BY XEBIALABS.
-->
<!--
Copyright (c) 2008-2010 XebiaLabs B.V. All rights reserved.
Your use of XebiaLabs Software and Documentation is subject to the Personal
License Agreement.
http://www.xebialabs.com/deployit-personal-edition-license-agreement
You are granted a personal license (i) to use the Software for your own
personal purposes which may be used in a production environment and/or (ii)
to use the Documentation to develop your own plugins to the Software.
"Documentation" means the how to's and instructions (instruction videos)
provided with the Software and/or available on the XebiaLabs website or other
websites as well as the provided API documentation, tutorial and access to
the source code of the XebiaLabs plugins. You agree not to (i) lease, rent
or sublicense the Software or Documentation to any third party, or otherwise
use it except as permitted in this agreement; (ii) reverse engineer,
decompile, disassemble, or otherwise attempt to determine source code or
protocols from the Software, and/or to (iii) copy the Software or
Documentation (which includes the source code of the XebiaLabs plugins). You
shall not create or attempt to create any derivative works from the Software
except and only to the extent permitted by law. You will preserve XebiaLabs'
copyright and legal notices on the Software and Documentation. XebiaLabs
retains all rights not expressly granted to You in the Personal License
Agreement.
-->
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:security="http://www.springframework.org/schema/security"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.1.xsd
">
<!-- crowd context -->
<import resource="applicationContext-CrowdClient.xml"/>
<bean id="rememberMeAuthenticationProvider" class="com.xebialabs.deployit.security.authentication.RememberMeAuthenticationProvider"/>
<bean id="jcrAuthenticationProvider" class="com.xebialabs.deployit.security.authentication.JcrAuthenticationProvider"/>
<security:authentication-manager alias="authenticationManager">
<security:authentication-provider ref="rememberMeAuthenticationProvider" />
<security:authentication-provider ref="crowdAuthenticationProvider"/>
<security:authentication-provider ref="jcrAuthenticationProvider"/>
</security:authentication-manager>
<bean id="crowdUserDetailsService" class="com.atlassian.crowd.integration.springsecurity.user.CrowdUserDetailsServiceImpl">
<property name="authenticationManager" ref="crowdAuthenticationManager" />
<property name="groupMembershipManager" ref="crowdGroupMembershipManager" />
<property name="userManager" ref="crowdUserManager" />
<property name="authorityPrefix" value=""/>
<!-- sample value
<property name="authorityPrefix" value="ROLE_"/>
-->
</bean>
<bean id="crowdAuthenticationProvider" class="com.atlassian.crowd.integration.springsecurity.RemoteCrowdAuthenticationProvider">
<constructor-arg ref="crowdAuthenticationManager" />
<constructor-arg ref="httpAuthenticator" />
<constructor-arg ref="crowdUserDetailsService" />
</bean>
</beans>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment