Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Security in EJB

 
Siva Masilamani
Ranch Hand
Posts: 385
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

i was going through one of web site and came across the following code.


Why do we need to use DeclareRoles annotation in the above code?

I thought we would be using this annotatation only when we use programmatic security,but as we can clearly see there is no such a code ?

Also if container can built up a role by inspecting the RolesAllowed annotation why do we need to use DeclareRoles in the code?

Thanks.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic