hi all;
I am kind of newbie when it comes to LDAP.I am not able to figure out how to search in all organizational units present in my dc
The code I am using to search user is like below


try {
DirContext authContext = new InitialDirContext(env);
try {
Attributes answer = authContext.getAttributes("uid=" + username + "," + basedn, Attributes);
for (NamingEnumeration ae = answer.getAll(); ae.hasMore() {
Attribute attr = (Attribute) ae.next();
NamingEnumeration e = attr.getAll();
String value = "";
while (e.hasMore()) {
value += e.next();
}
map.put(attr.getID(), value);
}
} catch (NamingException e) {
env = null;
Logger.getLogger(AuthenticationAPI.class.getName()).log(Level.SEVERE, null, e);
}




Please Somebody help me if any changes required in this to make user search in all ous ireespective of what is the relative dn by just specifying dc=example,dc=com,

Thnks in advance
John