This discussion is archived
1 Reply Latest reply: Oct 17, 2013 11:50 AM by BhaskerOFM RSS

How to access an External LDAP on a weblogic server using OPSS APIs.

BhaskerOFM Newbie
Currently Being Moderated

Hi,

 

Can anyone let me know how I can access an External LDAP configured on a weblogic server using OPSS APIs( or alternative APIs).

 

I'm currently using the below snippet and I'm getting only the Users and groups from the DefaultAutheticator on the weblogic server and not the external LDAP Server.

 

I've verified the providers, users and groups on the weblogic server console and can see that external LDAP server content is being picked, but my below code does not query them.

 

import oracle.security.idm.IMException;

import oracle.security.idm.IdentityStore;

import oracle.security.idm.Role;

import oracle.security.jps.JpsContext;

import oracle.security.jps.JpsContextFactory;

import oracle.security.jps.JpsException;

import oracle.security.jps.service.idstore.IdentityStoreService;

 

List<Role> rowData = null;

JpsContextFactory ctxf = JpsContextFactory.getContextFactory();

JpsContext ctx = ctxf.getContext();

IdentityStoreService storeService = ctx.getServiceInstance(IdentityStoreService.class);

IdentityStore idStore = storeService.getIdmStore();

rowData = this.getRoles(idStore, "*");

 

Any help or pointers are highly appreciated.

 

Thanks,

Bhasker

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points