This authentication service supports Derby NATIVE authentication.
To activate this service, set the derby.authentication.provider database or system property to a value beginning with the token "NATIVE:".
This service instantiates and calls the basic User authentication scheme at runtime.
User credentials are defined in the SYSUSERS table.
| Modifier and Type | Field and Description |
|---|---|
| private boolean | |
| private String | |
| private boolean | |
| private String | |
| private double | |
| private long |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| private boolean | authenticateLocally(String
The user's name used to connect to JBMS system userName, String The user's password used to connect to JBMS system userPassword, String The database which the user wants to connect to. databaseName)Authenticate the passed-in credentials against the local database. |
| private boolean | authenticateRemotely(String
The user's name used to connect to JBMS system userName, String The user's password used to connect to JBMS system userPassword, String The database which the user wants to connect to. databaseName)Authenticate the passed-in credentials against another Derby database. |
| public boolean | authenticateUser(String
The user's name used to connect to JBMS system userName, String The user's password used to connect to JBMS system userPassword, String The database which the user wants to connect to. databaseName, Properties Additional jdbc connection info. info)Implements org. Authenticate the passed-in user's credentials. |
| private boolean | authenticatingInThisDatabase(String userVisibleDatabaseName)
Return true if we are authenticating in this database. |
| private boolean | authenticatingInThisService(String canonicalDatabaseName)
Return true if we are authenticating in this service. |
| public void | boot(boolean
True if the database should be created create, Properties Configuration properties properties)Overrides org. Implements org. Start this module. |
| public boolean | canSupport(Properties properties)
Implements org. Check if we should activate this authentication service. |
| private String | |
| private String | |
| private static ModuleFactory | |
| private static String | getServiceName(final Object serviceModule)
Hides org. Must be private so that user code can't call this entry point. |
| public String | getSystemCredentialsDatabaseName()
Overrides org. Implements org. Override behavior in superclass |
| private boolean | isCredentialsService(String canonicalDatabaseName)
Return true if the passed in service is the credentials database. |
| private void | |
| private boolean | |
| private StandardException |
| _authenticateDatabaseOperationsLocally | back to summary |
|---|---|
| private boolean _authenticateDatabaseOperationsLocally | |
| _badlyFormattedPasswordProperty | back to summary |
|---|---|
| private String _badlyFormattedPasswordProperty | |
| _creatingCredentialsDB | back to summary |
|---|---|
| private boolean _creatingCredentialsDB | |
| _credentialsDB | back to summary |
|---|---|
| private String _credentialsDB | |
| _passwordExpirationThreshold | back to summary |
|---|---|
| private double _passwordExpirationThreshold | |
| _passwordLifetimeMillis | back to summary |
|---|---|
| private long _passwordLifetimeMillis | |
| NativeAuthenticationServiceImpl | back to summary |
|---|---|
| public NativeAuthenticationServiceImpl() | |
| authenticateLocally | back to summary |
|---|---|
| private boolean authenticateLocally(String userName, String userPassword, String databaseName) throws StandardException, SQLException Authenticate the passed-in credentials against the local database. | |
| authenticateRemotely | back to summary |
|---|---|
| private boolean authenticateRemotely(String userName, String userPassword, String databaseName) throws StandardException, SQLWarning Authenticate the passed-in credentials against another Derby database. This is done by getting a connection to the credentials database using the supplied username and password. If the connection attempts succeeds, then authentication succeeds. | |
| authenticateUser | back to summary |
|---|---|
| public boolean authenticateUser(String userName, String userPassword, String databaseName, Properties info) throws SQLException Implements org. Authenticate the passed-in user's credentials.
| |
| authenticatingInThisDatabase | back to summary |
|---|---|
| private boolean authenticatingInThisDatabase(String userVisibleDatabaseName) throws StandardException Return true if we are authenticating in this database. | |
| authenticatingInThisService | back to summary |
|---|---|
| private boolean authenticatingInThisService(String canonicalDatabaseName) throws StandardException Return true if we are authenticating in this service. | |
| boot | back to summary |
|---|---|
| public void boot(boolean create, Properties properties) throws StandardException Overrides org. Implements org. Doc from org. Start this module. In this case, nothing needs to be done.
| |
| canSupport | back to summary |
|---|---|
| public boolean canSupport(Properties properties) Implements org. Check if we should activate this authentication service.
| |
| getCanonicalServiceName | back to summary |
|---|---|
| private String getCanonicalServiceName() throws StandardException Get the canonical name of the current database service | |
| getCanonicalServiceName | back to summary |
|---|---|
| private String getCanonicalServiceName(String rawName) throws StandardException Turn a service name into its normalized, standard form | |
| getMonitor | back to summary |
|---|---|
| private static ModuleFactory getMonitor() Must be private so that user code can't call this entry point. | |
| getServiceName | back to summary |
|---|---|
| private static String getServiceName(final Object serviceModule) Hides org. Must be private so that user code can't call this entry point. | |
| getSystemCredentialsDatabaseName | back to summary |
|---|---|
| public String getSystemCredentialsDatabaseName() Overrides org. Implements org. Override behavior in superclass
| |
| isCredentialsService | back to summary |
|---|---|
| private boolean isCredentialsService(String canonicalDatabaseName) throws StandardException Return true if the passed in service is the credentials database. | |
| parseNativeSpecification | back to summary |
|---|---|
| private void parseNativeSpecification(Properties properties) Parse the specification of NATIVE authentication. It can take 3 forms:
| |
| validAuthenticationProvider | back to summary |
|---|---|
| private boolean validAuthenticationProvider() throws StandardException Return true if AUTHENTICATION_PROVIDER_PARAMETER was well formatted. The property must have designated some database as the authentication authority. | |
| wrap | back to summary |
|---|---|
| private StandardException wrap(Throwable t) | |