• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

need help with declarative security

 
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm using Eclipse 3.1 and Tomcat 5.5.12 to develop an application, and now i'm trying to get the servlet container to provide the login work. I know the xml is right but for some reason i'm unable to login.

This my install_dir/conf/tomcat-users.xml



Here is relevant section of web.xml



...and finally my login page..



...So why when i try to access the preotected page referrenced by "/preotected", why am I getting this error:

HTTP Status 403 - Access to the requested resource has been denied.

Some pls help....

[ May 29, 2006: Message edited by: kwame Iwegbue ]
[ May 29, 2006: Message edited by: kwame Iwegbue ]
 
kwame Iwegbue
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
After hrs of working on this problem, i still have no answer!! But it seems I only get that error message when i enter the correct username/password. With incorrect username/password, i get the login-error page! what does this mean?
 
kwame Iwegbue
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think it's an Eclipse problem. The application works well, if run directly by placing .war in tomcat, but not if launched from Eclipse 5.5 with WTP 1.02 pluggin. Please can anyone help with this?

I know there is an Eclipse forum, but I don't think i should post same question twice.. or should I?
[ May 30, 2006: Message edited by: kwame Iwegbue ]
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am facing the same problem. I get this " HTTP 403 - Access to the specified resource (Access to the requested resource has been denied) has been forbidden. ". I am using a dynamic web project in eclipse and have configured my tomcat-users.xml file as shown below -

<?xml version='1.0' encoding='utf-8'?>
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="role1"/>
<role rolename="manager"/>
<role rolename="admin"/>
<user username="techops" password="" roles="admin"/>
<user username="arcampbe" password="" roles="admin"/>
<user username="ranagara" password="" roles="admin"/>
<user username="odechang" password="" roles="admin"/>
<user username="daniobri" password="" roles="admin"/>
<user username="pbasaval" password="" roles="admin"/>
<user username="tomcat" password="tomcat" roles="tomcat"/>
<user username="both" password="tomcat" roles="tomcat,role1"/>
<user username="tdick" password="" roles="role1"/>
<user username="lsellin" password="" roles="role1"/>
<user username="malwu" password="" roles="role1"/>
<user username="admin" password="admin" roles="admin,manager"/>
</tomcat-users>
I have no clue how I can tackle this error. If you have any ideas, please let me know.
 
s ganti
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I forgot to mention, I read in some posts that this happens with tomcat 5.5 where the admin 'package' has to be downloaded separately, but I am using tomcat 4.1.37 with eclipse 3.2.2....
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic