You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Ashish Kulkarni <ku...@yahoo.com> on 2005/01/20 20:49:02 UTC

basic or form based authentication not working

Hi
i am using tomcat5.0.28 and trying to setup basic or
form based authentication, and it is just not working,

following is the information in web.xml
<security-constraint>
 <web-resource-collection>
  <web-resource-name>secure download maps software 
  </web-resource-name>
    <url-pattern>/pages/download/*</url-pattern>
    <url-pattern>/download/*</url-pattern>
    <http-method>GET</http-method>
    <http-method>POST</http-method>
  </web-resource-collection>
 <auth-constraint>
	<role-name>admin</role-name>
 </auth-constraint>
 <user-data-constraint>
    <transport-guarantee>NONE</transport-guarantee>
 </user-data-constraint>
</security-constraint>

<login-config>
 <auth-method>FORM</auth-method>
 <realm-name>Form-Based Authentication  
Area</realm-name>
 <form-login-config>
  <form-login-page>/login.jsp</form-login-page>
  <form-error-page>/error.jsp</form-error-page>
 </form-login-config>
</login-config>
<security-role>
<description>
 Only download role allowed to download
</description>
 <role-name>admin</role-name>
</security-role>

What may be the error

Ashish


		
__________________________________ 
Do you Yahoo!? 
Take Yahoo! Mail with you! Get it on your mobile phone. 
http://mobile.yahoo.com/maildemo 

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: basic or form based authentication not working

Posted by Ashish Kulkarni <ku...@yahoo.com>.
Hi
I was able to get it working, in <context> i had not
set privileged="true", i added this line and it works
fine now

Ashish

--- Omar Adobati <om...@gmail.com> wrote:

> can you show haow you set up the <context> for this
> webapp?
> 
> 
> On Thu, 20 Jan 2005 11:49:02 -0800 (PST), Ashish
> Kulkarni
> <ku...@yahoo.com> wrote:
> > Hi
> > i am using tomcat5.0.28 and trying to setup basic
> or
> > form based authentication, and it is just not
> working,
> > 
> > following is the information in web.xml
> > <security-constraint>
> > <web-resource-collection>
> >  <web-resource-name>secure download maps software
> >  </web-resource-name>
> >    <url-pattern>/pages/download/*</url-pattern>
> >    <url-pattern>/download/*</url-pattern>
> >    <http-method>GET</http-method>
> >    <http-method>POST</http-method>
> >  </web-resource-collection>
> > <auth-constraint>
> >        <role-name>admin</role-name>
> > </auth-constraint>
> > <user-data-constraint>
> >    <transport-guarantee>NONE</transport-guarantee>
> > </user-data-constraint>
> > </security-constraint>
> > 
> > <login-config>
> > <auth-method>FORM</auth-method>
> > <realm-name>Form-Based Authentication
> > Area</realm-name>
> > <form-login-config>
> >  <form-login-page>/login.jsp</form-login-page>
> >  <form-error-page>/error.jsp</form-error-page>
> > </form-login-config>
> > </login-config>
> > <security-role>
> > <description>
> > Only download role allowed to download
> > </description>
> > <role-name>admin</role-name>
> > </security-role>
> > 
> > What may be the error
> > 
> > Ashish
> > 
> > __________________________________
> > Do you Yahoo!?
> > Take Yahoo! Mail with you! Get it on your mobile
> phone.
> > http://mobile.yahoo.com/maildemo
> > 
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail:
> tomcat-user-help@jakarta.apache.org
> > 
> > 
> 
> 
> -- 
> Adobati Omar
> omar.adobati@gmail.it
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail:
> tomcat-user-help@jakarta.apache.org
> 
> 



		
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - 250MB free storage. Do more. Manage less. 
http://info.mail.yahoo.com/mail_250

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: basic or form based authentication not working

Posted by Omar Adobati <om...@gmail.com>.
can you show haow you set up the <context> for this webapp?


On Thu, 20 Jan 2005 11:49:02 -0800 (PST), Ashish Kulkarni
<ku...@yahoo.com> wrote:
> Hi
> i am using tomcat5.0.28 and trying to setup basic or
> form based authentication, and it is just not working,
> 
> following is the information in web.xml
> <security-constraint>
> <web-resource-collection>
>  <web-resource-name>secure download maps software
>  </web-resource-name>
>    <url-pattern>/pages/download/*</url-pattern>
>    <url-pattern>/download/*</url-pattern>
>    <http-method>GET</http-method>
>    <http-method>POST</http-method>
>  </web-resource-collection>
> <auth-constraint>
>        <role-name>admin</role-name>
> </auth-constraint>
> <user-data-constraint>
>    <transport-guarantee>NONE</transport-guarantee>
> </user-data-constraint>
> </security-constraint>
> 
> <login-config>
> <auth-method>FORM</auth-method>
> <realm-name>Form-Based Authentication
> Area</realm-name>
> <form-login-config>
>  <form-login-page>/login.jsp</form-login-page>
>  <form-error-page>/error.jsp</form-error-page>
> </form-login-config>
> </login-config>
> <security-role>
> <description>
> Only download role allowed to download
> </description>
> <role-name>admin</role-name>
> </security-role>
> 
> What may be the error
> 
> Ashish
> 
> __________________________________
> Do you Yahoo!?
> Take Yahoo! Mail with you! Get it on your mobile phone.
> http://mobile.yahoo.com/maildemo
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> 


-- 
Adobati Omar
omar.adobati@gmail.it

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org