【问题标题】:Active Directory Server with .Net带有 .Net 的 Active Directory 服务器
【发布时间】:2009-11-06 07:15:07
【问题描述】:

我们正在使用 MS Visual Studio 2008 VB .Net 开发我们的应用程序。

我们必须使用 Active Directory Server 来验证登录到应用程序的用户。

有人有集成.Net和ADS的代码示例吗?

【问题讨论】:

    标签: .net vb.net active-directory


    【解决方案1】:

    有关于该主题的 CodeProject 文章:

    System.DirectoryServices 文档中的 MSDN 上,有

    然后是关于 .NET 2.0 和 3.5 的 AD 支持新功能的两篇非常好的文章:

    【讨论】:

      【解决方案2】:
      【解决方案3】:

      假设您要将用户放入 Active Directory 组进行身份验证:

      ' Assume an Active Directory group exists named "MyApp Admins" with users in it.
      If My.User.CurrentPrincipal.IsInRole("MyApp Admins") Then
         ' Do stuff
      End If
      

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2020-07-02
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2014-12-30
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多