|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.derby.impl.jdbc.authentication.AuthenticationServiceBase
org.apache.derby.impl.jdbc.authentication.BasicAuthenticationServiceImpl
public final class BasicAuthenticationServiceImpl
This authentication service is the basic Derby user authentication level support. It is activated upon setting derby.authentication.provider database or system property to 'BUILTIN'.
It instantiates & calls the basic User authentication scheme at runtime.
In 2.0, users can now be defined as database properties. If derby.database.propertiesOnly is set to true, then in this case, only users defined as database properties for the current database will be considered.
Field Summary |
---|
Fields inherited from class org.apache.derby.impl.jdbc.authentication.AuthenticationServiceBase |
---|
authenticationScheme, AuthenticationTrace, ID_PATTERN_CONFIGURABLE_HASH_SCHEME, ID_PATTERN_SHA1_SCHEME, SECMEC_USRSSBPWD, SEPARATOR_CHAR |
Fields inherited from interface org.apache.derby.iapi.jdbc.AuthenticationService |
---|
MODULE |
Constructor Summary | |
---|---|
BasicAuthenticationServiceImpl()
|
Method Summary | |
---|---|
boolean |
authenticateUser(java.lang.String userName,
java.lang.String userPassword,
java.lang.String databaseName,
java.util.Properties info)
Authenticate the passed-in user's credentials. |
void |
boot(boolean create,
java.util.Properties properties)
Start this module. |
boolean |
canSupport(java.util.Properties properties)
Check if we should activate this authentication service. |
private java.lang.String |
encryptPasswordUsingStoredAlgorithm(java.lang.String user,
java.lang.String password,
java.lang.String storedPassword)
Encrypt a password using the same algorithm as we used to generate the stored password token. |
Methods inherited from class org.apache.derby.impl.jdbc.authentication.AuthenticationServiceBase |
---|
apply, authenticate, encryptPasswordConfigurableScheme, encryptPasswordSHA1Scheme, getDatabaseProperty, getProperty, getSystemProperty, init, map, requireAuthentication, setAuthenticationService, stop, substitutePassword, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BasicAuthenticationServiceImpl()
Method Detail |
---|
public boolean canSupport(java.util.Properties properties)
canSupport
in interface ModuleSupportable
public void boot(boolean create, java.util.Properties properties) throws StandardException
AuthenticationServiceBase
boot
in interface ModuleControl
boot
in class AuthenticationServiceBase
StandardException
- upon failure to load/boot the expected
authentication service.ModuleControl.boot(boolean, java.util.Properties)
public boolean authenticateUser(java.lang.String userName, java.lang.String userPassword, java.lang.String databaseName, java.util.Properties info) throws java.sql.SQLException
authenticateUser
in interface UserAuthenticator
userName
- The user's name used to connect to JBMS systemuserPassword
- The user's password used to connect to JBMS systemdatabaseName
- The database which the user wants to connect to.info
- Additional jdbc connection info.
java.sql.SQLException
- An exception processing the request,
connection request will be denied. The SQL exception will
be returned to the connection attempt.private java.lang.String encryptPasswordUsingStoredAlgorithm(java.lang.String user, java.lang.String password, java.lang.String storedPassword) throws StandardException
user
- the user whose password to encryptpassword
- the plaintext passwordstoredPassword
- the password token that's stored in the database
StandardException
- if the password cannot be encrypted with the
requested algorithm
|
Built on Thu 2010-12-23 20:49:13+0000, from revision ??? | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |