Using LDAP - LDAPS

Mecit Agar

New member
Joined
Sep 3, 2020
Messages
1
Programming Experience
1-3
Hi,

i am using LDAP / VB.NET 2017

Dim domain = New DirectoryServices.AccountManagement.PrincipalContext(DirectoryServices.AccountManagement.ContextType.Domain, "servername:389",nothing, "username", "pwd")
Dim user = DirectoryServices.AccountManagement.UserPrincipal.FindByIdentity(domain, "username")

how do i this for LDAPS on port 636?
this is not working
Dim domain = New DirectoryServices.AccountManagement.PrincipalContext(DirectoryServices.AccountManagement.ContextType.Domain, "servername:636",nothing, "username", "pwd")
Dim user = DirectoryServices.AccountManagement.UserPrincipal.FindByIdentity(domain, "username")
 
Last edited by a moderator:
Top Bottom