Details
-
Bug
-
Resolution: Obsolete
-
Minor
-
None
-
None
-
None
-
None
Description
In SimpleCachedLDAPAuthorizationMap.processQueryResults():
while (results.hasMore()) { SearchResult result = results.next(); AuthorizationEntry entry = null; try { entry = getEntry(map, new LdapName(result.getNameInNamespace()), destinationType); } catch (Exception e) { LOG.error("Policy not applied! Error parsing authorization policy entry under {}", result.getNameInNamespace(), e); continue; } applyACL(entry, result, permissionType); }
The statement:
SearchResult result = results.next();
can throw an exception. While this is caught by the caller, a misleading/incorrect message is logged. Note as well that:
results.hasMore()
can also throw an exception. Essentially, all of the code in the processQueryResults() method should be in the try/catch block.