File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to programmatically authorize a User based upon User Group

 
Tarun Chatterjee
Greenhorn
Posts: 25
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello

I have a user group which has been passed to be from a java program.
How can i check the access control of that user group to access a resource programmatically.?

Kindly help, as this is Urgent?

Regards
Tarun
 
Ken Rubin
Ranch Hand
Posts: 66
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I'm not a security expert and I'm not sure what kind of resources
you refer to, but here is a start.

If you are interested in EJBs get the EJB Spec at
http://java.sun.com/products/ejb/docs.html
Find the Security Management chapter and look at Bean Provider's Responsibilities. The spec is readable. See explanation of
isCallerInRole and getCallerPrincipal functions.

The same functions seem to be used in Servlets.
For Servlet Spec
http://jcp.org/en/jsr/detail?id=154
For JSP Spec
http://jcp.org/en/jsr/detail?id=152
http://java.sun.com/security/ has links to the JAAS Java Authentication
and Authorization Service API.

http://edocs.bea.com/wls/docs81/secintro/concepts.html - Security Concepts in Weblogic including JAAS.

Good Luck!!!
 
Ken Rubin
Ranch Hand
Posts: 66
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Also please consider the warnings in the Specs about coding Security
Policies.
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic