UseridPasswordFileTestState
Introduction and overview
This AuthState should not be used in production. Its sole purpose is to test and demonstrate functionality.
This AuthState is a very simple user registry for user ID/password logins for testing.
Description
The following table describes the characteristics of the AuthState.
Topic | Description |
---|---|
Class | ch.nevis.esauth.auth.states.standard.UseridPasswordFileTestState |
Logging | StdStates |
Auditing | none |
Marker | file:username/password |
Properties | UseridPasswordFile (string)This property should point to a Java property file, containing the user accounts. The file must be readable for the process owner of the nevisAuth instance. |
Methods | authenticate |
Input | isiwebuserid (user, required): login ID (and at the same time the user ID) of the user to authenticate |
isiwebpasswd (user, required): password | |
Transitions | ok: User was authenticated. |
default: User not found or pass-phrase not valid. | |
Output | none |
Errors | 1: unknown user; invalid password |
Notes | none |
Example
<AuthState name="SimpleLogin" class="ch.nevis.esauth.auth.states.standard.UseridPasswordFileTestState">
<ResultCond name="ok" next="AuthDone"/>
<Response value="AUTH_CONTINUE">
<Gui name="AuthUidPwDialog" label="login.uidpw.label">
<GuiElem name="lasterror" type="error" label="${notes:lasterrorinfo}" value="${notes:lasterror}"/>
<GuiElem name="info" type="info" label="login.uidpw.text"/>
<GuiElem name="isiwebuserid" type="text" label="userid.label" value="${request:loginId}"/>
<GuiElem name="isiwebpasswd" type="pw-text" label="password.label"/>
<GuiElem name="submit" type="button" label="submit.button.label" value="Login"/>
</Gui>
</Response>
<property name="UseridPasswordFile" value="conf/passwd.properties"/>
</AuthState>
For testing, you can also use the ch.nevis.esauth.auth.engine.UidPwLoginTest AuthState (see default configuration for details). This AuthState allows a login with any login ID and a password with the same value.