简体   繁体   中英

Using global catalog in a ldap search with C# library Novell

Until now I was always using the System.DirectoryServices in my c# application. Due to the fact that I want to use a container platform which doesn't support this library I wanted to use the Novell LDAP library.

Until now the connection string looked like this:

new Directoryentry("GC://domain.com")

I tried it with the Novell library like this:

LDAPConnection().connect("GC://domain.com",389);

I always get the error message "INVALID ADDRESS". I also tried it without the GC infront of the domain, but then I always get an empty search result.

Could someone please help me? Thanks!

The global catalog (GC) uses port 3268, not 389. You usually either use GC:// , which sets the port for you, or use LDAP:// along with specifying the port. It depends on the library. If the Novell library doesn't support GC:// , then just specify the port. According to the documentation , it doesn't seem to even require LDAP:// , but I've never used it.

LDAPConnection().connect("example.com", 3268);

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM