Bug 8278 - DirectorySearch/LDAP filter: german umlauts do not work
Summary: DirectorySearch/LDAP filter: german umlauts do not work
Status: NEW
Alias: None
Product: Class Libraries
Classification: Mono
Component: System ()
Version: unspecified
Hardware: All All
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
Depends on:
Reported: 2012-11-08 03:22 UTC by sbhwhd
Modified: 2012-11-08 03:24 UTC (History)
2 users (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report for Bug 8278 on GitHub or Developer Community if you have new information to add and do not yet see a matching new report.

If the latest results still closely match this report, you can use the original description:

  • Export the original title and description: GitHub Markdown or Developer Community HTML
  • Copy the title and description into the new report. Adjust them to be up-to-date if needed.
  • Add your new information.

In special cases on GitHub you might also want the comments: GitHub Markdown with public comments

Related Links:

Description sbhwhd 2012-11-08 03:22:24 UTC
Hi all.

I have created an LDAPBrowser using MonoDevelop and GTK#.

I have discoverd, that filtering for german umlauts does not work, if I use my LDAPBrowser with mono;
on the other hand: if I use my LDAPBrowser on windows with .net-runtime (not mono), german umlauts work fine.

So, this is clearly a bug in the mono runtime.

I did some further debugging and analysis.

So I have discovered, that mono just encapsulates the Novell LDAP libraries, which you can get here: ftp://sdk.provo.novell.com/ndk/ldapcsharp/ldapcsharp/ But I couldn't find out, which version.

Anyhow: a small test showed, that the latest available version from Novell (2.1.11) already fixed this problem - more than 3 years ago!

Further debugging showed me, where the bug is:

The old line
Array.Copy((System.Array) SupportClass.ToByteArray(utf8Bytes), 0, (System.Array)SupportClass.ToByteArray( octets), iOctets, utf8Bytes.Length);

just must be changed to
Array.Copy((System.Array) (utf8Bytes), 0, (System.Array) octets, iOctets, utf8Bytes.Length);

In the file "RfcFilter.cs", this was the only update between the oldest Novell LDAP version (V2.0)
and the latest Novell LDAP version (V2.1.11).

So, please just update this one line, and the bug will be gone!

Btw: Perhaps it would be a good idea, to update all the LDAP classes ...