com.ibm.commerce.security.commands
Class VerifyCredentialsCmdImpl
- java.lang.Object
-
- com.ibm.websphere.command.TargetableCommandImpl
-
- com.ibm.websphere.command.CacheableCommandImpl
-
- com.ibm.commerce.command.MeasuredCacheableCommandImpl
-
- com.ibm.commerce.command.AbstractECTargetableCommand
-
- com.ibm.commerce.command.TaskCommandImpl
-
- com.ibm.commerce.security.commands.VerifyCredentialsCmdImpl
-
- All Implemented Interfaces:
- com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, VerifyCredentialsCmd, com.ibm.websphere.cache.Sizeable, com.ibm.websphere.command.CacheableCommand, com.ibm.websphere.command.Command, com.ibm.websphere.command.CommandCaller, com.ibm.websphere.command.TargetableCommand, java.io.Serializable
public class VerifyCredentialsCmdImpl extends TaskCommandImpl implements VerifyCredentialsCmd
This command takes the input credentials and updates them in either the database, the LDAP server, or third-party system. Credentials are updated depending on how the WebSphere Commerce server is configured.
Before executing this task command, the methods listed below must be invoked.
- setLogonId
- setPassword
Error View Task: VerifyCredentialsErrorView
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field and Description static java.lang.String
ERRTASK_NAME
Error task name.-
Fields inherited from interface com.ibm.commerce.security.commands.VerifyCredentialsCmd
defaultCommandClassName, NAME
-
-
Constructor Summary
Constructors Constructor and Description VerifyCredentialsCmdImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.lang.String
getAuthenticateUserId()
This method retrieves the user ID of the logged in user.java.lang.String
getLogonId()
This method retrieves the logon ID under which the current user wishes to logon.boolean
isValidCredentials()
After the this command task is executed, a boolean result flag will be set to indicate if the authentication was successful.void
performExecute()
This method executes the command through updating the credentials in either LDAP, the database, or a third-party authentication repository.void
setLogonId(java.lang.String strLogonId)
This method sets the logon ID.void
setPassword(java.lang.String strPassword)
This method sets the password.void
validateParameters()
This method validates the parameters through ensuring that the logon ID and password parameters are non-zero length strings.-
Methods inherited from class com.ibm.commerce.command.AbstractECTargetableCommand
accessControlCheck, checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, execute, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getObjectSize, getPostInvokeParameters, getPreInvokeParameters, getResources, getStoreId, getUser, getUserId, isReadyToCallExecute, reset, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties
-
Methods inherited from class com.ibm.websphere.command.CacheableCommandImpl
executeFromCache, getCaller, getEntryInfo, getId, getSharingPolicy, postExecute, preExecute, setCaller, setObjectSize, unionDependencies, updateCache
-
Methods inherited from class com.ibm.websphere.command.TargetableCommandImpl
getCommandTarget, getCommandTargetName, getTargetPolicy, hasOutputProperties, setCommandTarget, setCommandTargetName, setHasOutputProperties, setOutputProperties, setTargetPolicy
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.ibm.websphere.command.CacheableCommand
executeFromCache, getCaller, getEntryInfo, getId, getSharingPolicy, postExecute, preExecute, setCaller, updateCache
-
Methods inherited from interface com.ibm.websphere.command.TargetableCommand
getCommandTarget, getCommandTargetName, hasOutputProperties, setCommandTarget, setCommandTargetName, setOutputProperties
-
Methods inherited from interface com.ibm.commerce.command.ECCommand
checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getExceptionInvokeParameters, getPostInvokeParameters, getPreInvokeParameters, getResources, getStoreId, getUser, getUserId, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties
-
-
-
-
Field Detail
-
ERRTASK_NAME
public static final java.lang.String ERRTASK_NAME
Error task name.- See Also:
- Constant Field Values
-
-
Method Detail
-
getAuthenticateUserId
public java.lang.String getAuthenticateUserId()
This method retrieves the user ID of the logged in user.- Specified by:
getAuthenticateUserId
in interfaceVerifyCredentialsCmd
- Returns:
- The userId.
-
getLogonId
public java.lang.String getLogonId()
This method retrieves the logon ID under which the current user wishes to logon.- Specified by:
getLogonId
in interfaceVerifyCredentialsCmd
- Returns:
- The logon ID.
-
isValidCredentials
public boolean isValidCredentials()
After the this command task is executed, a boolean result flag will be set to indicate if the authentication was successful. This method returns this result flag to indicate if the authentication was successful.- Specified by:
isValidCredentials
in interfaceVerifyCredentialsCmd
- Returns:
- True if authentication was successful.
-
performExecute
public void performExecute() throws ECException
This method executes the command through updating the credentials in either LDAP, the database, or a third-party authentication repository. Credentials are updated depending on the configuration of the WebSphere Commerce server.- Specified by:
performExecute
in interfaceECCommand
- Specified by:
performExecute
in interfacecom.ibm.websphere.command.TargetableCommand
- Overrides:
performExecute
in classAbstractECTargetableCommand
- Throws:
ECException
-
setLogonId
public void setLogonId(java.lang.String strLogonId)
This method sets the logon ID.- Specified by:
setLogonId
in interfaceVerifyCredentialsCmd
- Parameters:
strLogonId
- The new value for the logonID parameter.
-
setPassword
public void setPassword(java.lang.String strPassword)
This method sets the password.- Specified by:
setPassword
in interfaceVerifyCredentialsCmd
- Parameters:
strPassword
- The new value for the password parameter.
-
validateParameters
public void validateParameters() throws ECException
This method validates the parameters through ensuring that the logon ID and password parameters are non-zero length strings.- Specified by:
validateParameters
in interfaceECCommand
- Overrides:
validateParameters
in classAbstractECTargetableCommand
- Throws:
ECException
-
-