This week's book giveaway is in the Cloud forum.
We're giving away four copies of The Business Blockchain and have William Mougayar on-line!
See this thread for details.
Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Using ROLES defined in a database in th DD

 
Simran Dass
Ranch Hand
Posts: 183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In Tomcat you can define user and roles in tomcat-users.xml as :-



In the DD we can use these roles in <security-constraint> element ---



But when we define roles in a database how do we access those roles in the DD.
Will we be able to use declarative security then. An example will be of great help.
 
Simran Dass
Ranch Hand
Posts: 183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Ankit.
Read - http://josescalia.wordpress.com/2009/01/27/managin...on-in-tomcat-with-jdbc-realms/
Will try it.


Is this how its done in real projects ( I mean using realms) where supose we are using Jboss,Websphere etc. or is there some other way.
 
Simran Dass
Ranch Hand
Posts: 183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thought instead of asking I should search myself. Found foll. link for Jboss. It looks same .

http://docs.jboss.org/jbossweb/latest/realm-howto.html


Could you please also tell if Container Managed Security is used in most of the cases . I am really confused on this. After clearing SCWCD ( if I do ) these kind of questions might be asked in the interviews.


 
Ankit Garg
Sheriff
Posts: 9577
33
Android Google Web Toolkit Hibernate IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well it depends upon the requirements of the project. Its used in the javaranch wiki I think (while editing it). The javaranch forum doesn't use it for logging in users. I've worked on a few sites in the past and it was not used in any of them...
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic