Solved

tomcat 4.0.1 jdbc realm user-role question

Posted on 2002-06-21
5
257 Views
Last Modified: 2010-04-01
hi all,

how do i set tomcat not to look for a role when validating a user using jdbcrealm? if i omit the
<auth-constraint> it wont' validate anything it will just forward you to the resouce.

thanks.

    <security-constraint>
     
     <web-resource-collection>
         <web-resource-name>User Protected Area</web-resource-name>
          <url-pattern>/ovdc/*</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></role-name>
      </auth-constraint>

    </security-constraint>
0
Comment
Question by:ahuen
  • 3
  • 2
5 Comments
 
LVL 19

Accepted Solution

by:
cheekycj earned 25 total points
ID: 7098913
try overriding the hasRole() method.

CJ
0
 

Author Comment

by:ahuen
ID: 7098961
CJ,

where? in JDBCRealm?
I am subclassing JDBCRealm.

thanks.
0
 
LVL 19

Expert Comment

by:cheekycj
ID: 7098969
yes when you subclass JDBC Realm you should override the hasRole() method to always return true.. Its just an idea but it should work.

CJ
0
 

Author Comment

by:ahuen
ID: 7098976
awesome....

thanks.
0
 
LVL 19

Expert Comment

by:cheekycj
ID: 7098985
Thanx for the "A".  Good luck.

CJ
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Hyena v12.2 is now available for downloading and is available in English, French, German and Spanish versions.
Is your company's data protection keeping pace with virtualization? Here are 7 dynamic ways to adapt to rapid breakthroughs in technology.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now