[
https://issues.apache.org/jira/browse/KNOX-3574?focusedWorklogId=1055807&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-1055807
]
ASF GitHub Bot logged work on KNOX-3574:
----------------------------------------
Author: ASF GitHub Bot
Created on: 18/Nov/26 23:42
Start Date: 18/Nov/26 23:42
Worklog Time Spent: 10m
Work Description: handavid commented on code in PR #1523:
URL: https://github.com/apache/knox/pull/1523#discussion_r4622402505
##########
gateway-server/src/main/java/org/apache/knox/gateway/services/ldap/backend/LdapProxyBackend.java:
##########
@@ -586,8 +769,8 @@ public List<Entry> search(String searchBase, SearchScope
searchScope, String fil
try {
connection = getConnection();
List<Entry> results = new ArrayList<>();
- boolean memberOfRequested = isAttributeRequested(attributes,
proxyEntryGroupMembershipAttributeType, schemaManager);
- String[] remoteAttributes = memberOfRequested && useMemberOf ?
ALL_ATTRIBUTES_AND_MEMBEROF : ALL_ATTRIBUTES;
+ boolean memberOfRequested = isAttributeRequested(attributes,
MEMBER_OF, schemaManager);
+ String[] remoteAttributes = memberOfRequested && useMemberOf ?
addMemberOfAttribute(attributes) : attributes;
Review Comment:
thanks! I've fixed this and added a test.
I can't assert that the extra attributes don't leak in a unit test.
Attributes that are not requested are removed in the SchemaInterceptor.
Issue Time Tracking
-------------------
Worklog Id: (was: 1055807)
Time Spent: 50m (was: 40m)
> LDAP proxy backend returns operational attributes
> -------------------------------------------------
>
> Key: KNOX-3574
> URL: https://issues.apache.org/jira/browse/KNOX-3574
> Project: Apache Knox
> Issue Type: Improvement
> Components: LDAP
> Affects Versions: 3.0.0
> Reporter: David Han
> Assignee: David Han
> Priority: Major
> Fix For: 3.1.0
>
> Time Spent: 50m
> Remaining Estimate: 0h
>
> The returned attributes from the search should be passed directly to the
> backend so that operational attributes will be returned when specified.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)