Configurazione LDAP

cancel
Showing results for 
Search instead for 
Did you mean: 
d_brugo
Member II

Configurazione LDAP

Buongiorno sono un nuovo iscritto al forum in Italiano di Alfresco.
Ho un probelma devo configurare ldap per alfresco per cui ho modificato il seguenti file xml:
    ldap-authentication-context.xml
    commentato il segunete codice per abilitare solo ldap
    <!– DAO that rejects changes - LDAP is read only at the moment. It does allow users to be deleted with out warnings from the UI. –>
       
        <!– <bean name="authenticationDao" class="org.alfresco.repo.security.authentication.DefaultMutableAuthenticationDao" >
            <property name="allowDeleteUser">
                <value>true</value>
            </property>
        </bean>    –>
    ldap-authentication.properties
    Editato le voci in grassetto
    ldap.authentication.userNameFormat=CN=%s,DC=provincia,DC=sassari,DC=loc

    # The LDAP context factory to use
    ldap.authentication.java.naming.factory.initial=com.sun.jndi.ldap.LdapCtxFactory

    # The URL to connect to the LDAP server
    ldap.authentication.java.naming.provider.url=ldap://172.16.0.170:389

    # The authentication mechanism to use
    ldap.authentication.java.naming.security.authentication=SIMPLE

    # The default principal to use (only used for LDAP sync)
    ldap.authentication.java.naming.security.principal=user@mioDomino

    # The password for the default principal (only used for LDAP sync)
    ldap.authentication.java.naming.security.credentials=passMioDominio

    # Escape commas entered by the user at bind time
    # Useful when using simple authentication and the CN is part of the DN and contains commas
    ldap.authentication.escapeCommasInBind=false

    altro file
    ldap-synchronisation.properties
    # The query to find the people to import
    ldap.synchronisation.personQuery=(objectclass=inetOrgPerson)

    # The search base of the query to find people to import
    ldap.synchronisation.personSearchBase=DC=provincia,DC=sassari,DC=loc

    # The attribute name on people objects found in LDAP to use as the uid in Alfresco
    ldap.synchronisation.userIdAttributeName=uid

    # The attribute on person objects in LDAP to map to the first name property in Alfresco
    ldap.synchronisation.userFirstNameAttributeName=givenName

    # The attribute on person objects in LDAP to map to the last name property in Alfresco
    ldap.synchronisation.userLastNameAttributeName=sn

    # The attribute on person objects in LDAP to map to the email property in Alfresco
    ldap.synchronisation.userEmailAttributeName=mail

    # The attribute on person objects in LDAP to map to the organizational id  property in Alfresco
    ldap.synchronisation.userOrganizationalIdAttributeName=o

    # The default home folder provider to use for people created via LDAP import
    ldap.synchronisation.defaultHomeFolderProvider=personalHomeFolderProvider

    # The query to find group objects
    ldap.synchronisation.groupQuery=(objectclass=groupOfNames)

    # The search base to use to find group objects
    ldap.synchronisation.groupSearchBase=DC=provincia,DC=sassari,DC=loc

    # The attribute on LDAP group objects to map to the gid property in Alfrecso
    ldap.synchronisation.groupIdAttributeName=CN


    infine editato il file file-servers-custom.xml
    aggiungendo il seguente codice
    <config evaluator="string-compare" condition="CIFS Server" 
        replace="true">
            <serverEnable enabled="false"/>
          <host name="172.16.0.2" domain="provincia"/>
          <comment>Alfresco CIFS Server</comment>
          <!– Set to the broadcast mask for the subnet –>
          <broadcast>255.255.252.0</broadcast>
          <!– Use Java socket based NetBIOS over TCP/IP and
               native SMB
          on linux –>
          <tcpipSMB platforms="linux,solaris,macosx"/>
          <netBIOSSMB platforms="linux,solaris,macosx"/>
             <!– Can be mapped to non-privileged ports,
                   then use firewall
           rules to forward requests from the standard ports –>
            <!–        
          <tcpipSMB port="1445" platforms="linux,solaris,macosx"/>
          <netBIOSSMB sessionPort="1139" namePort="1137"
          datagramPort="1138" platforms="linux,solaris,macosx"/>
            –>

      
          <hostAnnounce interval="5"/>
          <!– Use Win32 NetBIOS interface on Windows –>
          <Win32NetBIOS/>
          <Win32Announce interval="5"/>
          <!– CIFS authentication –>
          <authenticator type=" passthru ">
           <LocalDomain/>
          </authenticator>

      
          <!–
          <WINS>
             <primary>1.2.3.4</primary>

    <secondary>5.6.7.8</secondary>
          </WINS>
           –>
          <sessionDebug flags="Negotiate,Socket"/>
       </config>

      
      <config evaluator="string-compare" condition="FTP Server"
       replace="true">
            <serverEnable enabled="false"/> 
            <!– Run on a non-privileged port –>
            <!–
            <port>1121</port>
            –>
          <!– FTP authentication –>
          <authenticator type="alfresco"/>        
              <!–      <debug
              flags="File,Search,Error,Directory,Info,DataPort"/> –>
       </config>

      
    <config evaluator="string-compare" condition="Filesystem Security" 
    replace="true">
        <authenticator type=" passthru ">
          <!– the name of your ldap server  – >    
          <Server> 172.16.0.170</Server>
          </authenticator>
       </config>

    Per Concludere ho fatto diverse prove, arrivo alla pagina di login ma non accedo ad Alfresco.
    Sembrerebbe un problema di sincronizzazione.
1 Reply
openpj
Moderator
Moderator

Re: Configurazione LDAP

Una prova che puoi fare subito è quella di cambiare questa property per lo userId:

ldap.synchronisation.userIdAttributeName=cn