Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

En esta breve guía encontrarás los pasos a seguir para poder configurar correctamente el acceso Multi-Dominio en Thuban.

...

  1. Dirigirse a la carpeta Context de la instalación de Thuban, ubicar y abrir en un editor de texto el archivo “user-application-context.xml

  2. Agregar los siguientes beans al mismo:

...

  1. Dirigirse a la carpeta Context de la instalación de Thuban, ubicar y abrir en un editor de texto el archivo “user-application-context.xml

  2. Agregar los siguientes beans al mismo:

...

Code Block
languagexml
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xmlns:aop="http://www.springframework.org/schema/aop"
     xmlns:tx="http://www.springframework.org/schema/tx"
     xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
     http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd
     http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd">

	<bean id="domains" class="org.apache.commons.collections.map.LinkedMap">
  		<constructor-arg>
    		<map>
     			<entry>
       				<key><value>CORP1</value></key>
       				<ref bean="corp1Domain"/>
     			</entry>
     			<entry>
       				<key><value>Corp2</value></key>
       				<ref bean="corp2Domain "/>
     			</entry>
   			</map>
 		</constructor-arg>
	</bean>

	<bean id="corp1Domain" class="com.latintech.thuban.services.login.ldap.LdapDefinition">
  		<property name="ldapHost" value="ldap://corp1.example.org:389"/>
  		<property name="ldapBase" value="dc=corp1,dc=example,dc=org"/>
  		<property name="ldapName" value="Corp1"/>
  		<property name="ldapUserAttributeId" value="sAMAccountName"/>
  		<property name="ldapUserAttributeName" value="name"/>
  		<property name="ldapUserAttributeDistinguishedName" value="distinguishedName"/>
  		<property name="ldapUserAttributeMemberOf" value="memberOf"/>
  		<property name="ldapUserAttributeMail" value="mail"/>
  		<property name="ldapUserAttributeArea" value="dept"/>
  		<property name="ldapUserAttributePhone" value="phone"/>
	</bean>

	<bean id="corp2Domain" class="com.latintech.thuban.services.login.ldap.LdapDefinition">
  		<property name="ldapHost" value="ldap://corp2.example.org:389"/>
  		<property name="ldapBase" value="dc=corp2,dc=example,dc=org"/>
  		<property name="ldapName" value="Corp2"/>
  		<property name="ldapUserAttributeId" value="sAMAccountName"/>
  		<property name="ldapUserAttributeName" value="name"/>
  		<property name="ldapUserAttributeDistinguishedName" value="distinguishedName"/>
  		<property name="ldapUserAttributeMemberOf" value="memberOf"/>
  		<property name="ldapUserAttributeMail" value="mail"/>
  		<property name="ldapUserAttributeArea" value="dept"/>
  		<property name="ldapUserAttributePhone" value="phone"/>
	</bean>
</beans>
Note

ATENCION!

Verificar bien al configurar el atributo: ldapBase

Si están copiando la configuración de un dominio en el context.properties y lo están pasando al XML, verificar que no les queden las \ o \\ antecediendo los = en el ldapBase ya que eso hará que el sistema fallé.

En el XML el ldapBase debe ser → <property name="ldapBase" value="dc=corp2,dc=example,dc=org"/>

Y no → <property name="ldapBase" value="dc\=corp2,dc\=example,dc\=org"/>

Artículos Relacionados

Filter by label (Content by label)
showLabelsfalse
showSpacefalse
cqllabel in ( "ldap" , "how-to" ) and title !~ "\"¿Cómo configurar el Multi-Dominio en Thuban?\"" and space = currentSpace ( )

...