cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oliver Wulff (Confluence)" <conflue...@apache.org>
Subject [CONF] Apache CXF > Fediz IDP 1.1
Date Tue, 05 Nov 2013 14:39:00 GMT
<html>
<head>
    <base href="https://cwiki.apache.org/confluence">
            <link rel="stylesheet" href="/confluence/s/en/2176/1/15/_/styles/combined.css?spaceKey=CXF&amp;forWysiwyg=true"
type="text/css">
    </head>
<body style="background: white;" bgcolor="white" class="email-body">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
    <h2><a href="https://cwiki.apache.org/confluence/display/CXF/Fediz+IDP+1.1">Fediz
IDP 1.1</a></h2>
    <h4>Page <b>edited</b> by             <a href="https://cwiki.apache.org/confluence/display/~owulff@apache.org">Oliver
Wulff</a>
    </h4>
        <br/>
                         <h4>Changes (5)</h4>
                                 
    
<div id="page-diffs">
                    <table class="diff" cellpadding="0" cellspacing="0">
    
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >| TED\\ | DET\\ | <br> <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">The
Fediz IDP doesn&#39;t support several realms within one WAR which requires to build a
Fediz IDP WAR for Realm A (default, shipped with Fediz Distribution) and Realm B. See below
how to build a Fediz IDP WAR for a specific realm. <br> <br></td></tr>
            <tr><td class="diff-unchanged" >h3. Installation <br> <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >h5. Build the IDP WAR <br> <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">Fediz
1.1 distribution ships a Fediz IDP WAR built for Realm-A. <br>{code} <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">The
Fediz 1.1 distribution ships one Fediz IDP WAR built for Realm-A by default. The distribution
also contains the IDP and STS sources with two Maven Profiles _realm-a_ and _realm-b_. More
information is provided in the {{README.txt} [here|http://svn.apache.org/viewvc/cxf/fediz/tags/fediz-1.1.0/services/idp/README.txt?view=co]
<br></td></tr>
            <tr><td class="diff-unchanged" > <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">{code}
<br> <br></td></tr>
            <tr><td class="diff-unchanged" >Once you deploy the IDP WAR files
to your Tomcat installation (&lt;catalina.home&gt;/webapps), you should be able to
see the Fediz STS from a browser at [http://localhost:9080/fediz-idp-sts/STSService?wsdl]
, assuming you&#39;re using port 9080 as listed above. <br> <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >h5. User and password <br> <br></td></tr>
            <tr><td class="diff-changed-lines" >The users and passwords are configured
in a Spring configuration file in {{webapps/fediz-idp-sts/WEB-INF/passwords.xml}}. The following
users are already configured <span class="diff-added-words"style="background-color: #dfd;">for
the _Realm A_</span> and can easily be extended. <br></td></tr>
            <tr><td class="diff-unchanged" >{code:xml} <br>    &lt;util:map
id=&quot;passwords&quot;&gt; <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
    
            </table>
    </div>                            <h4>Full Content</h4>
                    <div class="notificationGreySide">
        <h1><a name="FedizIDP1.1-FedizIDP"></a>Fediz IDP</h1>

<p>The Release 1.1 introduces the following new feature:</p>

<ul>
	<li>Federation Metadata<br/>
The IDP supports publishing the WS-Federation Metadata document which allows to more easily
integrate the IDP into platforms which support referencing a Metadata document. Metadata consists
of the signing certificate, the provided claims, etc.</li>
</ul>


<ul>
	<li>Spring Web Flow support<br/>
The IDP has been refactored to use Spring Web Flow to manage the federation flow. This provides
flexibility to be able to customize the IDP to company's specific requirements. The IDP is
secured by Spring Security to get the benefits and flexibility of Spring Security.</li>
</ul>


<ul>
	<li>Resource IDP and Home Realm Discovery<br/>
This is the major new feature. The IDP is able to figure out from which security domain/realm
the browser request is coming from to redirect the sign-in request to the requestor IDP which
does the authentication and issues a token which is sent to the Resource IDP. The Resource
IDP will then either map the principal from one security domain to the target security domain
and get claims information of the mapped principal or transform the claims information and
finally issue a new token for the relying party (application).</li>
</ul>



<p>The Fediz Identity Provider (IDP) consists of two WAR files. One is the Security
Token Service (STS) component, fediz-idp-sts.war, which is responsible for validating credentials,
getting the requested claims data and issuing a SAML token. There is no easy way for Web browsers
to issue SOAP requests to the STS directly, necessitating the second component, an IDP WAR
(fediz-idp.war) which allows browser-based applications to interact with the STS. The communication
between the browser and the IDP must be performed within the confines of the base HTTP 1.1
functionality and conform as closely as possible to the WS-Trust protocols semantic.</p>

<p>The Fediz STS is based on a customized CXF STS configured to support standard Federation
use cases demonstrated by the examples. The Fediz STS has been enhanced to support two realms
&#42;Realm-A&#42; and &#42;Realm-B&#42; with the following set of users:</p>
<div class='table-wrap'>
<table class='confluenceTable'><tbody>
<tr>
<th class='confluenceTh'> User </th>
<th class='confluenceTh'> Password<br class="atl-forced-newline" /> </th>
</tr>
<tr>
<td class='confluenceTd'> <em>Realm A</em><br class="atl-forced-newline"
/> </td>
<td class='confluenceTd'>&nbsp;</td>
</tr>
<tr>
<td class='confluenceTd'> alice<br class="atl-forced-newline" /> </td>
<td class='confluenceTd'> ecila<br class="atl-forced-newline" /> </td>
</tr>
<tr>
<td class='confluenceTd'> bob<br class="atl-forced-newline" /> </td>
<td class='confluenceTd'> bob<br class="atl-forced-newline" /> </td>
</tr>
<tr>
<td class='confluenceTd'> ted<br class="atl-forced-newline" /> </td>
<td class='confluenceTd'> det<br class="atl-forced-newline" /> </td>
</tr>
<tr>
<td class='confluenceTd'> <em>Realm B</em><br class="atl-forced-newline"
/> </td>
<td class='confluenceTd'>&nbsp;</td>
</tr>
<tr>
<td class='confluenceTd'> ALICE<br class="atl-forced-newline" /> </td>
<td class='confluenceTd'> ECILA<br class="atl-forced-newline" /> </td>
</tr>
<tr>
<td class='confluenceTd'> BOB<br class="atl-forced-newline" /> </td>
<td class='confluenceTd'> BOB<br class="atl-forced-newline" /> </td>
</tr>
<tr>
<td class='confluenceTd'> TED<br class="atl-forced-newline" /> </td>
<td class='confluenceTd'> DET<br class="atl-forced-newline" /> </td>
</tr>
</tbody></table>
</div>


<p>The Fediz IDP doesn't support several realms within one WAR which requires to build
a Fediz IDP WAR for Realm A (default, shipped with Fediz Distribution) and Realm B. See below
how to build a Fediz IDP WAR for a specific realm.</p>

<h3><a name="FedizIDP1.1-Installation"></a>Installation</h3>

<p>The Fediz IDP has been tested with Tomcat 6 and 7 but should be able to work with
any commercial JEE application server.</p>

<p>It's recommended to set up a dedicated (separate) Tomcat instance for the IDP compared
to the one hosting the RP (relying party) applications.   Using one deployment of Tomcat with
multiple CATALINA_BASE instances, as described <a href="http://www.shaunabram.com/multiple-tomcat-instances/"
class="external-link" rel="nofollow">here</a> is one option but note any libs in
$CATALINA_HOME/lib folder will be shared throughout each of the activated CATALINA_BASE instances.
 Another probably simpler alternative is to copy your Tomcat folder into a second location
and edit its conf/server.xml file and <a href="http://viralpatel.net/blogs/2009/08/running-multiple-instance-apache-tomcat-single-server.html"
class="external-link" rel="nofollow">change port values</a> (discussed below) so
they don't conflict with the original Tomcat installation.</p>

<p>To start and stop this second Tomcat instance, it is perhaps easiest to create small
startup.sh and shutdown.sh scripts that temporarily redefine $CATALINA_HOME from the first
to the second instance, for example:</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: java; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
CATALINA_HOME=/path/to/second/tomcat
$CATALINA_HOME/bin/startup.sh
</pre>
</div></div>

<p>and</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: java; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
CATALINA_HOME=/path/to/second/tomcat
$CATALINA_HOME/bin/shutdown.sh
</pre>
</div></div>

<p>If you're using the one Tomcat with multiple instance option, it's $CATALINA_BASE
instead that will need to be redefined above.</p>

<h5><a name="FedizIDP1.1-Tomcatserver.xmlconfiguration"></a>Tomcat server.xml
configuration</h5>

<p>The Fediz examples use the following Tomcat port values for the IDP/STS, defined
in the conf/server.xml file.  We use ports different from the Tomcat defaults so as not to
conflict with the Tomcat instance running the RP applications.</p>

<ul>
	<li>HTTP port: 9080 (used for Maven deployment, mvn tomcat:redeploy)</li>
	<li>HTTPS port: 9443 (where IDP and STS are accessed)</li>
	<li>Server port: 9005 (for shutdown and other commands)</li>
</ul>


<p>Here is a sample snippet for showing the configuration of the above three values:</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: xml; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
&lt;Server port="9005" shutdown="SHUTDOWN"&gt;
...

   &lt;!-- http configuration --&gt;
   &lt;Connector port="9080" protocol="HTTP/1.1"
        connectionTimeout="20000"
        redirectPort="9443" /&gt;

   ...

   &lt;!-- https configuration --&gt;
   &lt;Connector port="9443" protocol="HTTP/1.1" SSLEnabled="true"
        maxThreads="150" scheme="https" secure="true"
        keystoreFile="idp-ssl-server.jks"
        keystorePass="tompass" sslProtocol="TLS" /&gt;
   ...

   &lt;Connector port="9009" protocol="AJP/1.3" redirectPort="9443" /&gt;

...
&lt;/Server&gt;
</pre>
</div></div>

<p>The keystoreFile is relative to $CATALINA_BASE. See <a href="http://tomcat.apache.org/tomcat-7.0-doc/ssl-howto.html"
class="external-link" rel="nofollow">here</a> for the Tomcat 7 configuration reference.
This page also describes how to create certificates.  Sample Tomcat keystores (not for production
use, but useful for demoing Fediz and running the sample applications) are provided in the
examples/samplekeys folder of the Fediz distribution.</p>

<p>To establish trust, there are significant keystore/truststore requirements between
the Tomcat instances and the various web applications (IDP, STS, Relying party applications,
third party web services, etc.)  See <a href="http://svn.apache.org/viewvc/cxf/fediz/tags/fediz-1.1.0/examples/samplekeys/HowToGenerateKeysREADME.html?revision=1538770&amp;view=co"
class="external-link" rel="nofollow">this page</a> for more details, it lists the
trust requirements as well as sample scripts for creating your own (self-signed) keys.</p>

<p><b>Warning:  All sample keystores provided with Fediz (including in the WAR
files for its services and examples) are for development/prototyping use only.  They'll need
to be replaced for production use, at a minimum with your own self-signed keys but strongly
recommended to use third-party signed keys.</b></p>

<h5><a name="FedizIDP1.1-BuildtheIDPWAR"></a>Build the IDP WAR</h5>

<p>The Fediz 1.1 distribution ships one Fediz IDP WAR built for Realm-A by default.
The distribution also contains the IDP and STS sources with two Maven Profiles <em>realm-a</em>
and <em>realm-b</em>. More information is provided in the {{README.txt} <a
href="http://svn.apache.org/viewvc/cxf/fediz/tags/fediz-1.1.0/services/idp/README.txt?view=co"
class="external-link" rel="nofollow">here</a></p>

<p>Once you deploy the IDP WAR files to your Tomcat installation (&lt;catalina.home&gt;/webapps),
you should be able to see the Fediz STS from a browser at <a href="http://localhost:9080/fediz-idp-sts/STSService?wsdl"
class="external-link" rel="nofollow">http://localhost:9080/fediz-idp-sts/STSService?wsdl</a>
, assuming you're using port 9080 as listed above.</p>


<h3><a name="FedizIDP1.1-Configuration"></a>Configuration</h3>

<p>You can manage the users, their claims and the claims per application in the IDP.</p>

<h5><a name="FedizIDP1.1-Userandpassword"></a>User and password</h5>

<p>The users and passwords are configured in a Spring configuration file in <tt>webapps/fediz-idp-sts/WEB-INF/passwords.xml</tt>.
The following users are already configured for the <em>Realm A</em> and can easily
be extended.</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: xml; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
    &lt;util:map id="passwords"&gt;
        &lt;entry key="alice"
            value="ecila" /&gt;
        &lt;entry key="bob"
            value="bob" /&gt;
        &lt;entry key="ted"
            value="det" /&gt;
    &lt;/util:map&gt;
</pre>
</div></div>

<h5><a name="FedizIDP1.1-UserClaims"></a>User Claims</h5>

<p>The claims of each user are configured in a spring configuration file <tt>webapps/fediz-idp-sts/WEB-INF/userClaims.xml</tt>.
The following claims are already configured:</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: xml; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
  &lt;util:map id="userClaimsREALMA"&gt;
    &lt;entry key="alice"
      value-ref="REALMA_aliceClaims" /&gt;
    &lt;entry key="bob"
      value-ref="REALMA_bobClaims" /&gt;
    &lt;entry key="ted"
      value-ref="REALMA_tedClaims" /&gt;
  &lt;/util:map&gt;

  &lt;util:map id="REALMA_aliceClaims"&gt;
    &lt;entry key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname"
      value="Alice" /&gt;
    &lt;entry key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname"
      value="Smith" /&gt;
    &lt;entry key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress"
      value="alice@realma.org" /&gt;
    &lt;entry key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/role"
      value="User" /&gt;
  &lt;/util:map&gt;
</pre>
</div></div>

<p>The claim id's are configured according to Section 7.5 in the specification <a
href="http://docs.oasis-open.org/imi/identity/v1.0/identity.html" class="external-link" rel="nofollow">Identity
Metasystem Interoperability</a>. The mapping of claims to a SAML attribute statement
are described in Section 7.2.</p>

<h5><a name="FedizIDP1.1-Applicationclaims"></a>Application claims</h5>

<p><em>Note: The configuration file</em> <tt><em>RPClaims.xml</em></tt>
<em>has been replaced</em></p>

<p>The required claims per relying party are configured in the new IDP configuration
file <tt>idp-config-&lt;realm&gt;.xml</tt> which has been enhanced to
support other configuration parameters as well:</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: xml; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
    &lt;bean id="srv-fedizhelloworld" class="org.apache.cxf.fediz.service.idp.model.ServiceConfig"&gt;
        &lt;property name="realm" value="urn:org:apache:cxf:fediz:fedizhelloworld" /&gt;
        &lt;property name="protocol" value="http://docs.oasis-open.org/wsfed/federation/200706"
/&gt;
        &lt;property name="serviceDisplayName" value="Fedizhelloworld" /&gt;
        &lt;property name="serviceDescription" value="Web Application to illustrate WS-Federation"
/&gt;
        &lt;property name="role" value="ApplicationServiceType" /&gt;
        &lt;property name="tokenType" value="http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV2.0"
/&gt;
        &lt;property name="lifeTime" value="3600" /&gt;
        &lt;property name="requestedClaims"&gt;
            &lt;util:list&gt;
                &lt;bean class="org.apache.cxf.fediz.service.idp.model.RequestClaim"&gt;
                    &lt;property name="claimType" value="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname"
/&gt;
                    &lt;property name="optional" value="false" /&gt;
                &lt;/bean&gt;
                &lt;bean class="org.apache.cxf.fediz.service.idp.model.RequestClaim"&gt;
                    &lt;property name="claimType" value="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname"
/&gt;
                    &lt;property name="optional" value="false" /&gt;
                &lt;/bean&gt;
                &lt;bean class="org.apache.cxf.fediz.service.idp.model.RequestClaim"&gt;
                    &lt;property name="claimType" value="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress"
/&gt;
                    &lt;property name="optional" value="false" /&gt;
                &lt;/bean&gt;
                &lt;bean class="org.apache.cxf.fediz.service.idp.model.RequestClaim"&gt;
                    &lt;property name="claimType" value="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/role"
/&gt;
                    &lt;property name="optional" value="true" /&gt;
                &lt;/bean&gt;
            &lt;/util:list&gt;
        &lt;/property&gt;
    &lt;/bean&gt;
</pre>
</div></div>


<h3><a name="FedizIDP1.1-ConfigureLDAPdirectory"></a>Configure LDAP directory</h3>

<p>The Fediz IDP can be configured to attach an LDAP directory to authenticate users
and to retrieve claims information of users.</p>

<h5><a name="FedizIDP1.1-Usernameandpasswordauthentication"></a>Username
and password authentication</h5>

<p>WSS4J supports username/password authentication using JAAS. The JDK provides a JAAS
LoginModule for LDAP which can be configured as illustrated here in a sample jaas configuration
(jaas.config):</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: java; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
myldap {
 com.sun.security.auth.module.LdapLoginModule REQUIRED
 userProvider=ldap://ldap.mycompany.org:389/OU=Users,DC=mycompany,DC=org"
 authIdentity="cn={USERNAME},OU=Users,DC=mycompany,DC=org"
 useSSL=false
 debug=true;
};
</pre>
</div></div>

<p>You can get more information about this LoginModule <a href="http://download.oracle.com/javase/6/docs/jre/api/security/jaas/spec/com/sun/security/auth/module/LdapLoginModule.html"
class="external-link" rel="nofollow">here</a>.</p>

<p>In this example, all the users are stored in the organization unit Users within mycompany.org.
The configuration filename can be chosen, e.g. <tt>jaas.config</tt>. The filename
must be configured as a JVM argument. JVM related configurations for Tomcat can be done in
the file <tt>setenv.sh/bat</tt> located in directory <tt>tomcat/bin</tt>.
This script is called implicitly by <tt>catalina.bat/sh</tt> and might look like
this for UNIX:</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: java; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
#!/bin/sh
JAVA_OPTS="-Djava.security.auth.login.config=/opt/tomcat/conf/jaas.config"
export JAVA_OPTS
</pre>
</div></div>

<p>Next, the STS endpoint has to be configured to use the JAAS LoginModule which is
accomplished by the <tt>JAASUsernameTokenValidator</tt>.</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: xml; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
&lt;bean
  class="org.apache.ws.security.validate.JAASUsernameTokenValidator"
      id="jaasUTValidator"&gt;
   &lt;property name="contextName" value="myldap"/&gt;
&lt;/bean&gt;

&lt;jaxws:endpoint id="transportSTSUT"
  endpointName="ns1:TransportUT_Port"
  serviceName="ns1:SecurityTokenService"
  xmlns:ns1=http://docs.oasis-open.org/ws-sx/ws-trust/200512/
  wsdlLocation="/WEB-INF/wsdl/ws-trust-1.4-service.wsdl"
  address="/STSServiceTransportUT"
  implementor="#transportSTSProviderBean"&gt;

  &lt;jaxws:properties&gt;
    &lt;entry key="ws-security.ut.validator"
         value-ref="jaasUTValidator"/&gt;
  &lt;/jaxws:properties&gt;
&lt;/jaxws:endpoint&gt;
</pre>
</div></div>

<p>The property <tt>contextName</tt> must match the context name defined
in the JAAS configuration file which is <tt>myldap</tt> in this example.</p>

<h5><a name="FedizIDP1.1-Claimsmanagement"></a>Claims management</h5>

<p>When a STS client (IDP) requests a claim, the ClaimsManager in the STS checks every
registered ClaimsHandler who can provide the data of the requested claim.  The CXF STS provides
<tt>org.apache.cxf.sts.claims.LdapClaimsHandler</tt> which is a claims handler
implementation to get claims from user attributes in a LDAP directory.</p>

<p>You configure which claim URI maps to which LDAP user attribute. The implementation
uses the Spring Ldap Module (LdapTemplate).</p>

<p>The following example illustrate the changes to be made in <tt>webapps/fediz-idp-sts/WEB-INF/cxf-transport.xml</tt>:</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="theme: Default; brush: xml; gutter: false" style="font-size:12px; font-family:
ConfluenceInstalledFont,monospace;">
&lt;util:list id="claimHandlerList"&gt;
  &lt;ref bean="ldapClaimsHandler" /&gt;
&lt;/util:list&gt;

&lt;bean id="contextSource"
   class="org.springframework.ldap.core.support.LdapContextSource"&gt;
  &lt;property name="url" value="ldap://ldap.mycompany.org:389" /&gt;
  &lt;property name="userDn"
    value="CN=techUser,OU=Users,DC=mycompany,DC=org" /&gt;
  &lt;property name="password" value="mypassword" /&gt;
&lt;/bean&gt;

&lt;bean id="ldapTemplate"
   class="org.springframework.ldap.core.LdapTemplate"&gt;
  &lt;constructor-arg ref="contextSource" /&gt;
&lt;/bean&gt;

&lt;util:map id="claimsToLdapAttributeMapping"&gt;
  &lt;entry
key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname"
value="givenName" /&gt;
  &lt;entry key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname"
value="sn" /&gt;
  &lt;entry
key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress"
value="mail" /&gt;
  &lt;entry key="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/country"
value="c" /&gt;
&lt;/util:map&gt;

&lt;bean id="ldapClaimsHandler"
    class="org.apache.cxf.sts.claims.LdapClaimsHandler"&gt;
  &lt;property name="ldapTemplate" ref="ldapTemplate" /&gt;
  &lt;property name="claimsLdapAttributeMapping"
            ref="claimsToLdapAttributeMapping" /&gt;
  &lt;property name="userBaseDN"
      value="OU=Users,DC=mycompany,DC=org" /&gt;
&lt;/bean&gt;
</pre>
</div></div>

<p>You must deploy the library for the spring ldap module and its dependencies. The
POM of the spring ldap module is available <a href="http://repo1.maven.org/maven2/org/springframework/ldap/spring-ldap/1.2/spring-ldap-1.2.pom"
class="external-link" rel="nofollow">here</a>.</p>

<p>You can add the dependency to spring ldap module to the Fediz STS POM, add the above
configuration and rebuild the STS component or do the configuration in the deployed STS directly
and add the following JAR files:</p>

<ul>
	<li>lang-2.1.0.jar</li>
	<li>ldapbp-1.0.jar</li>
	<li>spring-ldap-1.2.jar</li>
</ul>

    </div>
        <div id="commentsSection" class="wiki-content pageSection">
        <div style="float: right;" class="grey">
                        <a href="https://cwiki.apache.org/confluence/users/removespacenotification.action?spaceKey=CXF">Stop
watching space</a>
            <span style="padding: 0px 5px;">|</span>
                <a href="https://cwiki.apache.org/confluence/users/editmyemailsettings.action">Change
email notification preferences</a>
</div>
        <a href="https://cwiki.apache.org/confluence/display/CXF/Fediz+IDP+1.1">View
Online</a>
        |
        <a href="https://cwiki.apache.org/confluence/pages/diffpagesbyversion.action?pageId=34838916&revisedVersion=2&originalVersion=1">View
Changes</a>
            </div>
</div>
</div>
</div>
</div>
</body>
</html>

Mime
View raw message