Package edu.vt.middleware.ldap.auth
Class AuthenticatorCli
- java.lang.Object
-
- edu.vt.middleware.ldap.AbstractCli
-
- edu.vt.middleware.ldap.auth.AuthenticatorCli
-
public class AuthenticatorCli extends AbstractCli
Command line interface for authenticator operations.- Version:
- $Revision: 1330 $
- Author:
- Middleware Services
-
-
Field Summary
-
Fields inherited from class edu.vt.middleware.ldap.AbstractCli
logger, OPT_DSMLV1, OPT_DSMLV2, OPT_HELP, OPT_TRACE, OPT_USE_PROPERTIES, options, opts, outputDsmlv1, outputDsmlv2
-
-
Constructor Summary
Constructors Constructor Description AuthenticatorCli()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidauthenticate(AuthenticatorConfig config, java.lang.String[] attrs)Executes the authenticate operation.protected voiddispatch(org.apache.commons.cli.CommandLine line)Dispatch command line data to the handler that can perform the operation requested on the command line.protected java.lang.StringgetCommandName()Gets the name of the command for which this class provides a CLI interface.protected AuthenticatorConfiginitAuthenticatorConfig(org.apache.commons.cli.CommandLine line)Initialize an AuthenticatorConfig with command line options.protected voidinitOptions()Initialize CLI options.static voidmain(java.lang.String[] args)CLI entry point method.-
Methods inherited from class edu.vt.middleware.ldap.AbstractCli
getArgs, initLdapProperties, initOptions, performAction, printExamples, printHelp
-
-
-
-
Method Detail
-
main
public static void main(java.lang.String[] args)
CLI entry point method.- Parameters:
args- Command line arguments.
-
initOptions
protected void initOptions()
Initialize CLI options.- Specified by:
initOptionsin classAbstractCli
-
initAuthenticatorConfig
protected AuthenticatorConfig initAuthenticatorConfig(org.apache.commons.cli.CommandLine line) throws java.lang.Exception
Initialize an AuthenticatorConfig with command line options.- Parameters:
line- Parsed command line arguments container.- Returns:
AuthenticatorConfigthat has been initialized- Throws:
java.lang.Exception- On errors thrown by handler.
-
dispatch
protected void dispatch(org.apache.commons.cli.CommandLine line) throws java.lang.ExceptionDispatch command line data to the handler that can perform the operation requested on the command line.- Specified by:
dispatchin classAbstractCli- Parameters:
line- Parsed command line arguments container.- Throws:
java.lang.Exception- On errors thrown by handler.
-
authenticate
protected void authenticate(AuthenticatorConfig config, java.lang.String[] attrs) throws java.lang.Exception
Executes the authenticate operation.- Parameters:
config- Authenticator configuration.attrs- Ldap attributes to return- Throws:
java.lang.Exception- On errors.
-
getCommandName
protected java.lang.String getCommandName()
Gets the name of the command for which this class provides a CLI interface.- Specified by:
getCommandNamein classAbstractCli- Returns:
- Name of CLI command.
-
-