[prev in list] [next in list] [prev in thread] [next in thread] 

List:       struts-dev
Subject:    RE: Role-Based Actions
From:       "Deadman, Hal" <hal.deadman () tallan ! com>
Date:       2001-10-24 20:01:01
[Download RAW message or body]


> If this is added, I'm willing to modify the struts-example to use roles
and
> form-based authentication.  I figured out a trick last week (using
javascript
> and cookies) to show the user loginForm again on the form-error page and
allow
> them to login from there.  I can add this to the sample that I'll create.


Why do you need javascript and cookies to redisplay the login page on the
form-error-page? I just call the same action for both form-login-page and
form-error-page. The action forwards to a login jsp and uses a url parameter
to determine whether or not to display an error message to the user.  Maybe
I don't understand what you are doing?

<login-config>
	<auth-method>FORM</auth-method>
	<realm-name>rdbmsRealm</realm-name>
	<form-login-config>
		<form-login-page>/login.do?type=attempt</form-login-page>
		<form-error-page>/login.do?type=failed</form-error-page>
	</form-login-config>
</login-config>

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic