【问题标题】:Using global catalog in a ldap search with C# library Novell在 C# 库 Novell 的 ldap 搜索中使用全局编录
【发布时间】:2020-07-12 01:15:27
【问题描述】:

到目前为止,我一直在我的 c# 应用程序中使用 System.DirectoryServices。由于我想使用不支持此库的容器平台,我想使用 Novell LDAP 库。

到目前为止,连接字符串看起来像这样:

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

我在 Novell 库中尝试过这样的:

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

我总是收到错误消息“无效地址”。我也尝试过没有域前面的 GC,但是我总是得到一个空的搜索结果。

有人可以帮我吗?谢谢!

【问题讨论】:

  • 如果我没记错的话,System.DirectoryServices 类专门用于 Active Directory。我认为它们不支持 Novell 系统 - 为此,您必须求助于使用低级 ADSI(Active Directory 服务接口)库(与 Novell 一起使用 - 我从我自己的个人经验中知道 - Novell bindery 和 Novell NDS 系统)。
  • @marc_s 感谢您的评论。我的目标是不使用 System.DirectoryServices,而是使用 Novell 或任何其他库,因为 System.DirectoryServices 在我的基于 linux 的容器中不起作用。

标签: c# ldap directoryservices novell


【解决方案1】:

全局编录 (GC) 使用端口 3268,而不是 389。您通常要么使用为您设置端口的GC://,要么使用LDAP:// 并指定端口。这取决于图书馆。如果 Novell 库不支持 GC://,则只需指定端口即可。根据the documentation的说法,它似乎甚至不需要LDAP://,但我从未使用过。

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

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2016-12-30
    • 1970-01-01
    • 1970-01-01
    • 2018-03-20
    • 1970-01-01
    • 2023-03-03
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多