public class DefaultLoginPanel extends java.lang.Object implements Authenticator
Modifier and Type | Field and Description |
---|---|
private ThinClient |
client
Client interface.
|
private static int |
EDIT_FID
Edit frame ID.
|
private ScreenBuffer |
editsb
The screen buffer for the editing frame.
|
private ScreenDefinition |
editsd
Edit frame definition.
|
private static java.lang.String |
INVALID_PASSWORD
Invalid password status message.
|
private static java.lang.String |
INVALID_USER
Invalid user status message.
|
private java.lang.String |
lastid
The userid typed last time this was used.
|
private java.lang.String |
lastpw
The password typed last time this was used.
|
private static int |
PASSWORD_ID
Password field ID.
|
private static java.lang.String |
STD_MSG
Standard login status message.
|
private static int |
USER_ID
User ID field ID.
|
AUTH_ACTION_ABORT, AUTH_ACTION_CONTINUE, AUTH_ACTION_DONE, AUTH_ACTION_RETRY, AUTH_MODE_CUSTOM, AUTH_MODE_HIGHEST, AUTH_MODE_IDPW, AUTH_MODE_LOWEST, AUTH_MODE_NONE, AUTH_MODE_X509, AUTH_MODE_X509_IDPW, AUTH_REQ_PROCESS, AUTH_REQ_PROGRAM, AUTH_REQ_USER, AUTH_RESULT_INSUFFICIENT_RIGHTS, AUTH_RESULT_INVALID_PASSWORD, AUTH_RESULT_INVALID_USERID, AUTH_RESULT_NONE, AUTH_RESULT_SKIP_TO_NEXT, AUTH_RESULT_SUCCESS, AUTH_RESULT_UNSPECIFIED_FAILURE, PKT_SIZE_SKIP_TO_NEXT
Constructor and Description |
---|
DefaultLoginPanel()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
private void |
addSkip(ScreenDefinition sd,
int lines,
int id)
Add specified number of empty lines
|
byte[] |
clientAuthHook(java.util.Map<java.lang.String,java.lang.Object> parameters,
int code)
Implements client side custom authentication logic.
|
void |
clientFinalize()
Finalizes any resources allocated during authentication by the client.
|
void |
configure(java.lang.String option)
Configures the Authenticator by setting the "option" parameter from directory.xml.
|
java.util.Set<java.lang.String> |
getAuthenticationEntities()
Returns a set of entities that this class handles.
|
SessionListener |
getSessionListener()
Not used for the client side, always returns
null . |
AuthenticationResponse |
serverAuthHook(byte[] auth,
java.lang.String entity)
Not used for the client side.
|
private ThinClient client
private ScreenDefinition editsd
private static final int EDIT_FID
private static final int USER_ID
private static final int PASSWORD_ID
private static final java.lang.String STD_MSG
private static final java.lang.String INVALID_PASSWORD
private static final java.lang.String INVALID_USER
private ScreenBuffer editsb
private java.lang.String lastid
private java.lang.String lastpw
public byte[] clientAuthHook(java.util.Map<java.lang.String,java.lang.Object> parameters, int code)
clientAuthHook
in interface Authenticator
parameters
- Additional configuration parameters. This plugin uses
"option" parameter which is taken from the directory.code
- The result of the most recent attempt to authenticate or
AUTH_RESULT_NONE
if this is the first attempt.public void clientFinalize()
clientFinalize
in interface Authenticator
public AuthenticationResponse serverAuthHook(byte[] auth, java.lang.String entity)
serverAuthHook
in interface Authenticator
auth
- The authorization input from the client.entity
- The entity to be authenticated.null
.public SessionListener getSessionListener()
null
.getSessionListener
in interface Authenticator
null
.public java.util.Set<java.lang.String> getAuthenticationEntities()
getAuthenticationEntities
in interface Authenticator
null
.public void configure(java.lang.String option)
configure
in interface Authenticator
option
- The value of "option" entry for the auth plugin.private void addSkip(ScreenDefinition sd, int lines, int id)
sd
- The frame to which to add a skip.lines
- Lines to skip.id
- Widget ID to be used for this skip widget.