Liferay 7.0-ce-m3

com.liferay.portal.security.ldap
Class DefaultPortalLDAP

java.lang.Object
  extended by com.liferay.portal.security.ldap.DefaultPortalLDAP
All Implemented Interfaces:
PortalLDAP

public class DefaultPortalLDAP
extends Object
implements PortalLDAP


Constructor Summary
DefaultPortalLDAP()
           
 
Method Summary
 LdapContext getContext(long ldapServerId, long companyId)
           
 LdapContext getContext(long companyId, String providerURL, String principal, String credentials)
           
 Binding getGroup(long ldapServerId, long companyId, String groupName)
           
 Attributes getGroupAttributes(long ldapServerId, long companyId, LdapContext ldapContext, String fullDistinguishedName)
           
 Attributes getGroupAttributes(long ldapServerId, long companyId, LdapContext ldapContext, String fullDistinguishedName, boolean includeReferenceAttributes)
           
 byte[] getGroups(long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, String baseDN, String groupFilter, List<SearchResult> searchResults)
           
 byte[] getGroups(long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, String baseDN, String groupFilter, String[] attributeIds, List<SearchResult> searchResults)
           
 byte[] getGroups(long ldapServerId, long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, List<SearchResult> searchResults)
           
 byte[] getGroups(long ldapServerId, long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, String[] attributeIds, List<SearchResult> searchResults)
           
 String getGroupsDN(long ldapServerId, long companyId)
           
 long getLdapServerId(long companyId, String screenName, String emailAddress)
           
 Attribute getMultivaluedAttribute(long companyId, LdapContext ldapContext, String baseDN, String filter, Attribute attribute)
           
 String getNameInNamespace(long ldapServerId, long companyId, Binding binding)
           
 Binding getUser(long ldapServerId, long companyId, String screenName, String emailAddress)
           
 Binding getUser(long ldapServerId, long companyId, String screenName, String emailAddress, boolean checkOriginalEmail)
           
 Attributes getUserAttributes(long ldapServerId, long companyId, LdapContext ldapContext, String fullDistinguishedName)
           
 byte[] getUsers(long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, String baseDN, String userFilter, List<SearchResult> searchResults)
           
 byte[] getUsers(long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, String baseDN, String userFilter, String[] attributeIds, List<SearchResult> searchResults)
           
 byte[] getUsers(long ldapServerId, long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, List<SearchResult> searchResults)
           
 byte[] getUsers(long ldapServerId, long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, String[] attributeIds, List<SearchResult> searchResults)
           
 String getUsersDN(long ldapServerId, long companyId)
           
 boolean hasUser(long ldapServerId, long companyId, String screenName, String emailAddress)
           
 boolean isGroupMember(long ldapServerId, long companyId, String groupDN, String userDN)
           
 boolean isUserGroupMember(long ldapServerId, long companyId, String groupDN, String userDN)
           
 byte[] searchLDAP(long companyId, LdapContext ldapContext, byte[] cookie, int maxResults, String baseDN, String filter, String[] attributeIds, List<SearchResult> searchResults)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultPortalLDAP

public DefaultPortalLDAP()
Method Detail

getContext

public LdapContext getContext(long ldapServerId,
                              long companyId)
                       throws Exception
Specified by:
getContext in interface PortalLDAP
Throws:
Exception

getContext

public LdapContext getContext(long companyId,
                              String providerURL,
                              String principal,
                              String credentials)
                       throws Exception
Specified by:
getContext in interface PortalLDAP
Throws:
Exception

getGroup

public Binding getGroup(long ldapServerId,
                        long companyId,
                        String groupName)
                 throws Exception
Specified by:
getGroup in interface PortalLDAP
Throws:
Exception

getGroupAttributes

public Attributes getGroupAttributes(long ldapServerId,
                                     long companyId,
                                     LdapContext ldapContext,
                                     String fullDistinguishedName)
                              throws Exception
Specified by:
getGroupAttributes in interface PortalLDAP
Throws:
Exception

getGroupAttributes

public Attributes getGroupAttributes(long ldapServerId,
                                     long companyId,
                                     LdapContext ldapContext,
                                     String fullDistinguishedName,
                                     boolean includeReferenceAttributes)
                              throws Exception
Specified by:
getGroupAttributes in interface PortalLDAP
Throws:
Exception

getGroups

public byte[] getGroups(long companyId,
                        LdapContext ldapContext,
                        byte[] cookie,
                        int maxResults,
                        String baseDN,
                        String groupFilter,
                        List<SearchResult> searchResults)
                 throws Exception
Specified by:
getGroups in interface PortalLDAP
Throws:
Exception

getGroups

public byte[] getGroups(long companyId,
                        LdapContext ldapContext,
                        byte[] cookie,
                        int maxResults,
                        String baseDN,
                        String groupFilter,
                        String[] attributeIds,
                        List<SearchResult> searchResults)
                 throws Exception
Specified by:
getGroups in interface PortalLDAP
Throws:
Exception

getGroups

public byte[] getGroups(long ldapServerId,
                        long companyId,
                        LdapContext ldapContext,
                        byte[] cookie,
                        int maxResults,
                        List<SearchResult> searchResults)
                 throws Exception
Specified by:
getGroups in interface PortalLDAP
Throws:
Exception

getGroups

public byte[] getGroups(long ldapServerId,
                        long companyId,
                        LdapContext ldapContext,
                        byte[] cookie,
                        int maxResults,
                        String[] attributeIds,
                        List<SearchResult> searchResults)
                 throws Exception
Specified by:
getGroups in interface PortalLDAP
Throws:
Exception

getGroupsDN

public String getGroupsDN(long ldapServerId,
                          long companyId)
                   throws Exception
Specified by:
getGroupsDN in interface PortalLDAP
Throws:
Exception

getLdapServerId

public long getLdapServerId(long companyId,
                            String screenName,
                            String emailAddress)
                     throws Exception
Specified by:
getLdapServerId in interface PortalLDAP
Throws:
Exception

getMultivaluedAttribute

public Attribute getMultivaluedAttribute(long companyId,
                                         LdapContext ldapContext,
                                         String baseDN,
                                         String filter,
                                         Attribute attribute)
                                  throws Exception
Specified by:
getMultivaluedAttribute in interface PortalLDAP
Throws:
Exception

getNameInNamespace

public String getNameInNamespace(long ldapServerId,
                                 long companyId,
                                 Binding binding)
                          throws Exception
Specified by:
getNameInNamespace in interface PortalLDAP
Throws:
Exception

getUser

public Binding getUser(long ldapServerId,
                       long companyId,
                       String screenName,
                       String emailAddress)
                throws Exception
Specified by:
getUser in interface PortalLDAP
Throws:
Exception

getUser

public Binding getUser(long ldapServerId,
                       long companyId,
                       String screenName,
                       String emailAddress,
                       boolean checkOriginalEmail)
                throws Exception
Specified by:
getUser in interface PortalLDAP
Throws:
Exception

getUserAttributes

public Attributes getUserAttributes(long ldapServerId,
                                    long companyId,
                                    LdapContext ldapContext,
                                    String fullDistinguishedName)
                             throws Exception
Specified by:
getUserAttributes in interface PortalLDAP
Throws:
Exception

getUsers

public byte[] getUsers(long companyId,
                       LdapContext ldapContext,
                       byte[] cookie,
                       int maxResults,
                       String baseDN,
                       String userFilter,
                       List<SearchResult> searchResults)
                throws Exception
Specified by:
getUsers in interface PortalLDAP
Throws:
Exception

getUsers

public byte[] getUsers(long companyId,
                       LdapContext ldapContext,
                       byte[] cookie,
                       int maxResults,
                       String baseDN,
                       String userFilter,
                       String[] attributeIds,
                       List<SearchResult> searchResults)
                throws Exception
Specified by:
getUsers in interface PortalLDAP
Throws:
Exception

getUsers

public byte[] getUsers(long ldapServerId,
                       long companyId,
                       LdapContext ldapContext,
                       byte[] cookie,
                       int maxResults,
                       List<SearchResult> searchResults)
                throws Exception
Specified by:
getUsers in interface PortalLDAP
Throws:
Exception

getUsers

public byte[] getUsers(long ldapServerId,
                       long companyId,
                       LdapContext ldapContext,
                       byte[] cookie,
                       int maxResults,
                       String[] attributeIds,
                       List<SearchResult> searchResults)
                throws Exception
Specified by:
getUsers in interface PortalLDAP
Throws:
Exception

getUsersDN

public String getUsersDN(long ldapServerId,
                         long companyId)
                  throws Exception
Specified by:
getUsersDN in interface PortalLDAP
Throws:
Exception

hasUser

public boolean hasUser(long ldapServerId,
                       long companyId,
                       String screenName,
                       String emailAddress)
                throws Exception
Specified by:
hasUser in interface PortalLDAP
Throws:
Exception

isGroupMember

public boolean isGroupMember(long ldapServerId,
                             long companyId,
                             String groupDN,
                             String userDN)
                      throws Exception
Specified by:
isGroupMember in interface PortalLDAP
Throws:
Exception

isUserGroupMember

public boolean isUserGroupMember(long ldapServerId,
                                 long companyId,
                                 String groupDN,
                                 String userDN)
                          throws Exception
Specified by:
isUserGroupMember in interface PortalLDAP
Throws:
Exception

searchLDAP

public byte[] searchLDAP(long companyId,
                         LdapContext ldapContext,
                         byte[] cookie,
                         int maxResults,
                         String baseDN,
                         String filter,
                         String[] attributeIds,
                         List<SearchResult> searchResults)
                  throws Exception
Specified by:
searchLDAP in interface PortalLDAP
Throws:
Exception

Liferay 7.0-ce-m3