Laxmi Narayan

Greenhorn
+ Follow
since Sep 22, 2003
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Laxmi Narayan

Hi all,
I am getting principal from openLDAP server using JAAS, i am giving security roles and method permissions in my ejb-jar.xml file. can anyone explain me how to pass the principal got from LDAP to EJB container so that the container check the method permission at runtime.
Regards
Laxmi Narayan
Properties properties = new Properties();
properties.put(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory");
properties.put(Context.SECURITY_AUTHENTICATION, "simple");
properties.put(Context.SECURITY_PRINCIPAL, LDAPPrincipal.LDAP_PRICIPAL);
ServiceLocator locator = new ServiceLocator(properties);

ProfileMgmtFacadeHome home =
ProfileMgmtFacadeHome)locator.getRemoteHome("ProfileMgmtFacade", ProfileMgmtFacadeHome.class);
ProfileMgmtFacade profileMgmt = home.create();
Above is the sample code that iam using to pass principal from ldap to EJB Server using initial context and then using the locator object for JNDI lookup. I would like to know from you is this right way to pass principal to EJB server. Will it be any problem if i store the home object in cache. I want to pass pricipal while calling some methods not all.if this is the case i have to write two methods to get initial context. I would like to know from u is their any other way to pass the principal to EJB server.
Thanks Mr.Mallik,
But one thing i would like to ask u, that currently i am passing iam passing the principal got from openldap to the JNDI lookup before calling the EJB method. It is working fine but the problem is, i cannot store the JNDI lookup's in cache since i am sending the principal to JNDI lookup.

I would like to know from u, how we can assign dynamically principal got from openldap to EJB server so that it can check EJB security automatically based on ejb-jar.xml file.
Laxmi Narayan
Hi all,
I am getting principal from openLDAP server using JAAS, i am giving security roles and method permissions in my ejb-jar.xml file. can anyone explain me how to pass the principal got from LDAP to EJB container so that the container check the method permission at runtime.
Regards
Laxmi Narayan
Hi all,
I am getting principal from openLDAP server using JAAS, i am giving security roles and method permissions in my ejb-jar.xml file. can anyone explain me how to pass the principal got from LDAP to EJB container so that the container check the method permission at runtime.
Regards
Laxmi Narayan
19 years ago
Check your ldapManager ip is properly given and your are getting ldapManager object from naming context.
//ldap server
InitialContext ic = new InitialContext();
String ip = (String)ic.lookup(JNDINames.LDAPSERVER_IP);
ldapManager = new LDAPManager(ip);
19 years ago
U can go through the site www.firesight.com for openldap for windows. U can find information regarding ldap in www.openldap.org. u can integrate the openldap with webpshere very easily. if u need any further clarification please ask me.
19 years ago