-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make System.DirectoryServices.DirectorySearcher cross-plattform (Linux/macOS support) #102601
Comments
Yes that assembly is cross-platform. Can you use that cross-plaform |
Well... there is a reason E.g. I then found LinqToLdap, which also wraps around SearchRequest, but e.g. amends it with features like:
Also, it supports more features than
|
Also ping @joperezr for input |
It's been a while since I looked at it so this is very outdated, but IIRC the assembly (as I didn't just look at this type specifically) had a lot of windows-specific concepts which would make it hard/impossible or maybe just misleading to have it be cross platform. For instance, some of the APIs were leaking COM objects. We picked |
Of course, it might (or might not) be possible to re-implement |
Closing; not planned \ feasible. |
Then what about adding support for paging and possibly other features I currently miss (which are not platform-dependent) or so in |
Sounds like a nice opportunity for an open-source project 😄 |
...like .NET runtime 😉 |
Description
In #14734 support for Windows has been added, in #23944 (comment) / #35380 Linux support for
System.DirectoryServices.Protocols
has been added.#84831 and #37100 tracks related progress for making
System.DirectoryServices.AccountManagement
cross-plattform.However, I'd really only like to use
DirectorySearcher
to simplify search the AD/LDAP for users.Reproduction Steps
There are other simple wrappers around
System.DirectoryServices.Protocols
that already work and are the only cross-platform alternative. OrLinqToLdap
, which unfortunately does not seem to be maintained anymore, (but is recommend by OWASP)Expected behavior
Support that wrapper around LDAP just for searching on Linux/macOS, too.
Actual behavior
When importing it, I get error
CA1416
.The doc also confirms this it "applies to" Windows Desktop (only), compared with
System.DirectoryServices.Protocols.DirectoryRequest.SearchRequest
, which applies to all .NET versions.Regression?
No response
Known Workarounds
Use wrapper linked above.
Configuration
No response
Other information
#25121 is also about this issue.
The text was updated successfully, but these errors were encountered: