handavid opened a new pull request, #1534:
URL: https://github.com/apache/knox/pull/1534

   [KNOX-3604](https://issues.apache.org/jira/browse/KNOX-3604) - Give imported 
remote attributes usable equality and ordering rules
   
   ## What changes were proposed in this pull request?
   
   An imported remote attribute type that declares no equality or ordering 
matching rule the bundled schema can resolve was registered with that rule left 
null. A strict schema then rejects assertions on it: an equality filter cannot 
be evaluated, and a range (>=, <=) filter fails to even parse with 
ERR_13301_NO_ORDERING_MR_FOR_AT - which blocks Active Directory delta-sync 
clients that filter with e.g. (uSNChanged>=N).
   
   When the rule cannot be resolved, fall back to the octet-string matching 
rules (octetStringMatch for equality, octetStringOrderingMatch for ordering) 
instead of dropping it to null, mirroring the existing octet-string syntax 
fallback and the bundled octet-string attribute types (e.g. objectGUID). The 
ordering fallback is applied only when the bundled schema actually defines the 
rule, so an environment without it keeps the previous behavior. The 
octet-string rules compare raw bytes; the backend forwards the real comparison 
to the remote server, which applies its own schema.
   
   Add unit tests for both fallbacks, including one that reproduces the 
delta-sync range filter that previously failed to parse, and document the 
fallback in the extraAttributes section of service_ldap_server.md.
   
   ## How was this patch tested?
   
   New unit tests were added to that parse a search filter with the imported 
attribute using a range filter.
   
   Manual tests were run against Active Directory using the `uSNChanged` 
attribute. This previously failed with the error 
ERR_13301_NO_ORDERING_MR_FOR_AT but now works.
   ```
   ldapsearch -v -x -H ldap://localhost:3890  -D 
'uid=bind,ou=people,dc=proxy,dc=com' -w bind-password  -E pr=250/noprompt -b 
'ou=people,DC=proxy,DC=com' -s sub 
'(&(objectClass=inetOrgPerson)(|(modifyTimestamp>=20261115074418.0Z)(uSNChanged>=2337200000)))'
 '*' '+'
   ```
   
   ## Integration Tests
   
   No integration tests were added since the remote ldap has the same schema as 
the ldap proxy.
   
   ## UI changes
   
   No UI changes
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to