| java.lang.Object org.apache.derby.impl.jdbc.authentication.JNDIAuthenticationSchemeBase org.apache.derby.impl.jdbc.authentication.LDAPAuthenticationSchemeImpl
LDAPAuthenticationSchemeImpl | final public class LDAPAuthenticationSchemeImpl extends JNDIAuthenticationSchemeBase (Code) | | This is the Cloudscape LDAP authentication scheme implementation.
JNDI system/environment properties can be set at the database
level as database properties. They will be picked-up and set in
the JNDI initial context if any are found.
We do connect first to the LDAP server in order to retrieve the
user's distinguished name (DN) and then we reconnect and try to
authenticate with the user's DN and passed-in password.
In 2.0 release, we first connect to do a search (user full DN lookup).
This initial lookup can be done through anonymous bind or using special
LDAP search credentials that the user may have configured on the
LDAP settings for the database or the system.
It is a typical operation with LDAP servers where sometimes it is
hard to tell/guess in advance a users' full DN's.
NOTE: In a future release, we will cache/maintain the user DN within
the the cloudscape database or system to avoid the initial lookup.
Also note that LDAP search/retrieval operations are usually very fast.
The default LDAP url is ldap:/// (ldap://localhost:389/)
See Also: org.apache.derby.authentication.UserAuthenticator See Also: |
authenticateUser | public boolean authenticateUser(String userName, String userPassword, String databaseName, Properties info) throws java.sql.SQLException(Code) | | Authenticate the passed-in user's credentials.
We authenticate against a LDAP Server.
Parameters: userName - The user's name used to connect to JBMS system Parameters: userPassword - The user's password used to connect to JBMS system Parameters: databaseName - The database which the user wants to connect to. Parameters: info - Additional jdbc connection info. |
setJNDIProviderProperties | protected void setJNDIProviderProperties()(Code) | | This method basically tests and sets default/expected JNDI properties
for the JNDI provider scheme (here it is LDAP).
|
|
|