Projet Socle ENT
Pages enfant
  • CAS (Central Authentication Service) (esup 4)

Comparaison des versions

Légende

  • Ces lignes ont été ajoutées. Ce mot a été ajouté.
  • Ces lignes ont été supprimées. Ce mot a été supprimé.
  • La mise en forme a été modifiée.
Commentaire: Modification des beans

...

  1. Ajout dans le fichier pom.xml du cas bundle :

    Bloc de code
    titleuportal-portlets-overlay/cas/pom.xml
    firstline160
    linenumberstrue
    <dependency>
        <groupId>org.jasig.cas</groupId>
        <artifactId>cas-server-support-ldap</artifactId>
        <version>${cas-server.version}</version>
        <scope>compile</scope>
        <exclusions>
            <exclusion>
                <groupId>org.inspektr</groupId>
                <artifactId>inspektr-core</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
  2. Ajouts dans le fichier deployerConfigContext.xml du cas bundle :

    Bloc de code
    titleuportal-portlets-overlay/cas/src/main/webapp/WEB-INF/deployerConfigContext.xml
    firstline120
    <property name="authenticationHandlers">
            <list>
            ...
            <bean class="org.jasig.cas.adaptors.ldap.FastBindLdapAuthenticationHandler" >
                <property name="filter" value="${environment.build.ldap.uidAttr}=%u,${environment.build.ldap.baseDn}" />
                <property name="contextSource" ref="contextSource" />
            </bean>
        </list>
    </property>
    Bloc de code
    titleuportal-portlets-overlay/cas/src/main/webapp/WEB-INF/deployerConfigContext.xml
    firstline222
    linenumberstrue
    </beans>
        ...
        <bean id="contextSource" class="org.springframework.ldap.core.support.LdapContextSource">
            <property name="urls">
                <list>
                    <value>${environment.build.ldap.url}</value>
                </list>
            </property>
        </bean>
        ...
    </beans>

 

Connecter un CAS Externe et LDAP

...

  1. Ajout dans le fichier pom.xml du cas :

    Bloc de code
    titlecas-server-3.5.1/cas-server-webapp/pom.xml
    firstline160
    <dependency>
         <groupId>org.jasig.cas</groupId>
         <artifactId>cas-server-support-ldap</artifactId>
         <version>${cas.version}</version>
    </dependency>
    Remarque

    Le paramètre ${cas.version} est à remplacer par la version de CAS.

     

    Ajouts dans le fichier deployerConfigContext.xml du cas :

    Bloc de code
    titlecas-server-webapp/src/main/webapp/WEB-INF/deployerConfigContext.xml
    firstline120
    <property name="authenticationHandlers">
        <list>
            ...
            <bean class="org.jasig.cas.adaptors.ldap.FastBindLdapAuthenticationHandler" >
                <property name="filter" value="${environment.build.ldap.uidAttr}=%u,${environment.build.ldap.baseDn}" />
                <property name="contextSource" ref="contextSource" />
            </bean>
        </list>
    </property>
    Bloc de code
    titlecas-server-webapp/src/main/webapp/WEB-INF/deployerConfigContext.xml
    firstline222
    <beans>
        ...
        <bean id="contextSource" class="org.springframework.ldap.core.support.LdapContextSource">
            <property name="urls">
                <list>
                    <value>${environment.build.ldap.url}</value>
                </list>
            </property>
        </bean>
        ...
    </beans>
    Remarque

    Les paramètres suivants sont à remplacer :

    ${environment.build.ldap.uidAttr}
    ${environment.build.ldap.baseDn}
    ${environment.build.ldap.url}

    Ces paramètres sont explicités sur la page de configuration LDAP.

...