directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emmanuel Lecharny (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (DIRAPI-286) AdDirSync Control does not support multiple flags
Date Tue, 29 Nov 2016 12:43:58 GMT

     [ https://issues.apache.org/jira/browse/DIRAPI-286?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Emmanuel Lecharny resolved DIRAPI-286.
--------------------------------------
       Resolution: Fixed
    Fix Version/s: 1.0.0-RC3

Patch applied with http://svn.apache.org/viewvc?rev=1771899&view=rev

FTR, I have done a few minor modifications :
- using Set instead of EnumSet (EnumSet is used internally, but not exposed)
- fixed a few comments

All in all, nothing fancy that changes the patch logic.

May thanks for the patch, I'm impressed by its completeness and quality !


> AdDirSync Control does not support multiple flags
> -------------------------------------------------
>
>                 Key: DIRAPI-286
>                 URL: https://issues.apache.org/jira/browse/DIRAPI-286
>             Project: Directory Client API
>          Issue Type: Bug
>    Affects Versions: 1.0.0-RC2
>            Reporter: Caleb McQuillin
>             Fix For: 1.0.0-RC3
>
>         Attachments: AdDirSyncPatch.diff
>
>
> When creating an initial search request using the DirSync control, I would like to pass
multiple flags. [Microsoft's documentation|https://msdn.microsoft.com/en-us/library/windows/desktop/aa366978(v=vs.85).aspx]
states:
> {quote}*Flags*
> Contains optional flags for use with the LDAP_SERVER_DIRSYNC_OID control. This can be
zero or a combination of one or more of the values listed in the following list.{quote}
> Unfortunately, [the IETF document|https://tools.ietf.org/html/draft-armijo-ldap-dirsync-01]
that was linked in the ticket for supporting DirSync (DIRAPI-189) doesn't match the actual
implementation, as specified by Microsoft in the link above. The IETF document only specifies
a {{parentsFirst}} flag in the SearchRequest, but there are four potential SearchRequest flags
(all of which can be found in AdDirFlags). AdDirSync specifies methods for getting and setting
both a {{parentsFirst}} field and a {{flag}} field. In reality, there should be a single {{flags}}
field that is a collection of applicable flags. Additionally, it appears the {{flag}} field
is ignored during encoding and decoding - only the {{parentsFirst}} field is considered.
> My recommendation for resolving this issue revolves around Java's EnumSet class which
seems to be commonly used for bitmasks in Java. I've drafted a patch for use in my project
that is utilizing the Directory Client API, I'd be happy to attach that patch here to be used
at least as a base for resolution of this issue.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message