wood burning stoves 2.0*
The moose likes BEA/Weblogic and the fly likes How to programmatically authorize a User based upon User Group Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "How to programmatically authorize a User based upon User Group" Watch "How to programmatically authorize a User based upon User Group" New topic
Author

How to programmatically authorize a User based upon User Group

Tarun Chatterjee
Greenhorn

Joined: Mar 07, 2005
Posts: 25
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

Joined: Mar 08, 2004
Posts: 66
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

Joined: Mar 08, 2004
Posts: 66
Also please consider the warnings in the Specs about coding Security
Policies.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to programmatically authorize a User based upon User Group