Hi,
I try to implement an application which get more information from login page to get the
roles from authentificated user.
The login page looks like that:
<form action="j_security_check" method="POST">
| Username: <input type="text" name="j_username" />
| Password: <input type="password" name="j_password" />
| Organisation: <input type="text" name="j_organisation"
/><br />
| <input type="submit" value="Login" />
| </form>
The loginmodul works fine if i try to get only the username and password from the
callbackhandle.
If i try to get the 'TextInputCallback' an UnsupportedCallbackException occur.
sourcecode (loginmodule - during method login()):
| ...
| Callback[] theCallbacks = new Callback[] {
| new NameCallback("Username: "),
| new PasswordCallback("Password: ", false),
| new TextInputCallback("Organisation: ") };
| ...
| try {
| callbackHandler.handle(theCallbacks);
| username = ((NameCallback)callbacks[0]).getName();
| char[] tmpPassword = ((PasswordCallback)callbacks[1]).getPassword();
| strOrganisationId = ((TextInputCallback)callbacks[2]).getText(); // here is the
problem...
| ...
| }catch (....)
| {
| } ...
|
I think this must be often use. Has anybody an idea or a method of solution.
Thx J.M.Jacob
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4019433#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...