You are viewing a plain text version of this content. The canonical link for it is here.
Posted to general@jakarta.apache.org by Guillermo Payet <gp...@oceangroup.com> on 2002/08/06 03:33:12 UTC

Forcing a FORM authentication

Hello,

I've been trying to figure this one out all day.  So far with not
much luck. :-(

-A user registers to our Web site (LocalHarvest.org), and this creates 
 an account in our OpenLDAP directory.
-At this point, we invite the user to login via the standard form 
 authentication mechanism.
-Since our users are farmers, and not particularly computer savvy,
 a lot of them are getting confused and not really understanding 
 that even though they just registered, they still need to *login*
 into the site.

So, I'd like to "force" a FORM authentication by somehow calling
/login/j_security_check from the "registration" page, or doing 
something equivalent, so that the session becomes authenticated
automatically after a successful registration.

We're using Tomcat 4.0.3

I found this pointer to a purported solution to our problem:

http://www.apachelabs.org/tomcat-user/200105.mbox/%3C9005C0C9C85BD31181B2006008+5DAC8B10C8EF@tuvi.andmevara.ee%3E

But it ain't working.  I've tried all kinds of variations on this,
but I cannot figure out how to make it work. It seems that once a 
request is matched against auth constraints, (which happens when the
registration page is first loaded) it will not be matched again. 
This means that any redirection of the request to j_security_check 
just returns a 404, since authenticate() is never called again and so 
it fails to intercept the request and authenticate the session.

Any ideas??  Any help is appreciated!

	thanks!

	--Guillermo Payet



-- 
Guillermo Payet
O C E A N    G R O U P
email: gpayet@oceangroup.com
web: http://www.oceangroup.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Forcing a FORM authentication

Posted by Guillermo Payet <gp...@oceangroup.com>.
oops.... my apologies... I should have posted this one to the tomcat-user
list instead.

	--G


-- 
Guillermo Payet
O C E A N    G R O U P
email: gpayet@oceangroup.com
web: http://www.oceangroup.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Forcing a FORM authentication

Posted by "Craig R. McClanahan" <cr...@apache.org>.
You would do much better posting this to the TOMCAT-USER mailing list
instead of here.

Craig McClanahan

On Mon, 5 Aug 2002, Guillermo Payet wrote:

> Date: Mon, 5 Aug 2002 18:33:12 -0700
> From: Guillermo Payet <gp...@oceangroup.com>
> Reply-To: Jakarta General List <ge...@jakarta.apache.org>
> To: general@jakarta.apache.org
> Subject: Forcing a FORM authentication
>
>
> Hello,
>
> I've been trying to figure this one out all day.  So far with not
> much luck. :-(
>
> -A user registers to our Web site (LocalHarvest.org), and this creates
>  an account in our OpenLDAP directory.
> -At this point, we invite the user to login via the standard form
>  authentication mechanism.
> -Since our users are farmers, and not particularly computer savvy,
>  a lot of them are getting confused and not really understanding
>  that even though they just registered, they still need to *login*
>  into the site.
>
> So, I'd like to "force" a FORM authentication by somehow calling
> /login/j_security_check from the "registration" page, or doing
> something equivalent, so that the session becomes authenticated
> automatically after a successful registration.
>
> We're using Tomcat 4.0.3
>
> I found this pointer to a purported solution to our problem:
>
> http://www.apachelabs.org/tomcat-user/200105.mbox/%3C9005C0C9C85BD31181B2006008+5DAC8B10C8EF@tuvi.andmevara.ee%3E
>
> But it ain't working.  I've tried all kinds of variations on this,
> but I cannot figure out how to make it work. It seems that once a
> request is matched against auth constraints, (which happens when the
> registration page is first loaded) it will not be matched again.
> This means that any redirection of the request to j_security_check
> just returns a 404, since authenticate() is never called again and so
> it fails to intercept the request and authenticate the session.
>
> Any ideas??  Any help is appreciated!
>
> 	thanks!
>
> 	--Guillermo Payet
>
>
>
> --
> Guillermo Payet
> O C E A N    G R O U P
> email: gpayet@oceangroup.com
> web: http://www.oceangroup.com
>
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>