Package org.eclipse.net4j.util.security
Class UserManagerAuthenticator
java.lang.Object
org.eclipse.net4j.util.event.Notifier
org.eclipse.net4j.util.lifecycle.Lifecycle
org.eclipse.net4j.util.security.UserManagerAuthenticator
- All Implemented Interfaces:
INotifier,INotifier.INotifier2,IDeactivateable,ILifecycle,ILifecycle.DeferrableActivation,IAuthenticator
- Since:
- 3.3
- Author:
- Eike Stepper
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.eclipse.net4j.util.lifecycle.ILifecycle
ILifecycle.DeferrableActivationNested classes/interfaces inherited from interface org.eclipse.net4j.util.event.INotifier
INotifier.INotifier2 -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidauthenticate(String userID, char[] password) Authenticates the user with the passeduserIDby checking whether the suppliedpasswordmatches the password stored for this user.protected byte[]protected voidprotected voidintbyte[]intvoidsetEncryptionAlgorithmName(String encryptionAlgorithmName) voidsetEncryptionIterationCount(int encryptionIterationCount) voidsetEncryptionSaltBytes(byte[] encryptionSaltBytes) voidsetRandomizer(IRandomizer randomizer) voidsetTokenLength(int tokenLength) voidsetUserManager(IUserManager userManager) Methods inherited from class org.eclipse.net4j.util.lifecycle.Lifecycle
activate, checkActive, checkArg, checkArg, checkInactive, checkNull, checkState, checkState, deactivate, deferredActivate, doAfterActivate, doBeforeDeactivate, doDeactivate, dump, getLifecycleState, isActive, isDeferredActivation, toStringMethods inherited from class org.eclipse.net4j.util.event.Notifier
addListener, addUniqueListener, fireEvent, fireEvent, fireEvent, fireThrowable, firstListenerAdded, getListeners, getNotificationService, hasListener, hasListeners, lastListenerRemoved, listenerAdded, listenerRemoved, removeListenerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.eclipse.net4j.util.event.INotifier
addListener, getListeners, hasListeners, removeListener
-
Field Details
-
DEFAULT_TOKEN_LENGTH
public static final int DEFAULT_TOKEN_LENGTH- See Also:
-
-
Constructor Details
-
UserManagerAuthenticator
public UserManagerAuthenticator()
-
-
Method Details
-
getEncryptionAlgorithmName
-
setEncryptionAlgorithmName
-
getEncryptionSaltBytes
public byte[] getEncryptionSaltBytes() -
setEncryptionSaltBytes
public void setEncryptionSaltBytes(byte[] encryptionSaltBytes) -
getEncryptionIterationCount
public int getEncryptionIterationCount() -
setEncryptionIterationCount
public void setEncryptionIterationCount(int encryptionIterationCount) -
getTokenLength
public int getTokenLength() -
setTokenLength
public void setTokenLength(int tokenLength) -
getRandomizer
-
setRandomizer
-
getUserManager
-
setUserManager
-
authenticate
Description copied from interface:IAuthenticatorAuthenticates the user with the passeduserIDby checking whether the suppliedpasswordmatches the password stored for this user.The implementation is required to throw a
SecurityExceptionif the passwords do not match.- Specified by:
authenticatein interfaceIAuthenticator- Throws:
SecurityException
-
doBeforeActivate
- Overrides:
doBeforeActivatein classLifecycle- Throws:
Exception
-
doActivate
- Overrides:
doActivatein classLifecycle- Throws:
Exception
-
createRandomToken
protected byte[] createRandomToken()
-