|
I hope
I can help you guys
I tried this one on my win 2000 and it is
working good .
in your web.xml document you should add a
<security-constraint> entry , define the url pattern that you want
to protect ( e.g 'myServlet' )
add
the http methods that you want the security will work on (e.g: GET, POST ...
)
after
this you should determine who should log in with the <login-config>
tag (e.g Admin)
the
<realm-name> is in the tomcat users file .
<web-app>
<security-constraint>
<web-resource-collection> <web-resource-name>Protected Area</web-resource-name> <url-pattern>/myServlet</url-pattern> <http-method>DELETE</http-method> <http-method>GET</http-method> <http-method>POST</http-method> <http-method>PUT</http-method> </web-resource-collection> <auth-constraint> <role-name>admin</role-name> </auth-constraint> </security-constraint>
<login-config>
<auth-method>BASIC</auth-method> <realm-name>Admin</realm-name> </login-config>
.
.
.
.
<web-app>
|
- A Little message for Carlos !!!! Negrini Lilian
- Re: A Little message for Carlos !!!! shlomi sarfati
- Re: A Little message for Carlos !!!! qazwasyx
