• 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
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

Problem with security constraint

 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Everyone,

I am trying to secure a particular web page in my project by using security constraint in my web.xml. I am authenticating against a LDAP Server and am successful in getting the roles for the particular user.

Most of the pages will be seen to anyone who successfully logs in but a few of the pages I want only people with an admin or super super role to see it.

so this is what i put in my web xml



While this seems to be correct the user still has access to the page the constraint then works when they try to use the page ex.(click on a submit button, or link on the page) then the browser displays no authorization page.

Is there anyway to get this working so that when the user gets stopped before they get to the page. I am successful on rendering links based on the roles returned but I want to prevent them from typing in the url to get to the resource.

Thanks in advance for you help

DeAlton
 
DeAlton Jones
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I figured it out. xml is read from the top down I had a public constraint that overrided the protected constraint in the wrong order
 
Legend has it that if you rub the right tiny ad, a genie comes out.
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic