| | |
| | | |
| | | try |
| | | { |
| | | // FIXME -- We need to determine whether the current user has |
| | | // permission to make this determination. |
| | | SearchFilter filter = assertControl.getSearchFilter(); |
| | | |
| | | // Check if the current user has permission to make |
| | | // this determination. |
| | | if (!AccessControlConfigManager.getInstance(). |
| | | getAccessControlHandler().isAllowed(this, currentEntry, filter)) |
| | | { |
| | | throw new DirectoryException( |
| | | ResultCode.INSUFFICIENT_ACCESS_RIGHTS, |
| | | ERR_CONTROL_INSUFFICIENT_ACCESS_RIGHTS.get(oid)); |
| | | } |
| | | |
| | | if (! filter.matchesEntry(currentEntry)) |
| | | { |
| | | throw new DirectoryException(ResultCode.ASSERTION_FAILED, |
| | |
| | | } |
| | | } |
| | | |
| | | // Check access controls on the entry and strip out |
| | | // any not allowed attributes. |
| | | SearchResultEntry searchEntry = |
| | | AccessControlConfigManager.getInstance(). |
| | | getAccessControlHandler().filterEntry(this, entry); |
| | | // FIXME -- Check access controls on the entry to see if it should |
| | | // be returned or if any attributes need to be stripped |
| | | // out.. |
| | | SearchResultEntry searchEntry = new SearchResultEntry(entry); |
| | | LDAPPreReadResponseControl responseControl = |
| | | new LDAPPreReadResponseControl(preReadRequest.isCritical(), |
| | | searchEntry); |
| | |
| | | } |
| | | } |
| | | |
| | | // Check access controls on the entry and strip out |
| | | // any not allowed attributes. |
| | | SearchResultEntry searchEntry = |
| | | AccessControlConfigManager.getInstance(). |
| | | getAccessControlHandler().filterEntry(this, entry); |
| | | // FIXME -- Check access controls on the entry to see if it should |
| | | // be returned or if any attributes need to be stripped |
| | | // out.. |
| | | SearchResultEntry searchEntry = new SearchResultEntry(entry); |
| | | LDAPPostReadResponseControl responseControl = |
| | | new LDAPPostReadResponseControl(searchEntry); |
| | | |