Add LDAP/Active Directory authentication support#1869
Conversation
Adds native LDAP SSO authentication allowing users to sign in with their Active Directory or LDAP directory credentials. Supports plain LDAP, StartTLS (port 389), and LDAPS (port 636). Includes group-to- role mapping, configurable auto-provisioning, and full environment variable support for Docker deployments.
|
Thanks for the PR. Is there any specific reason to prefer using |
|
I used Novell because I was under impression it was more compatible. It was tested against Microsoft Servers LDAP, 2016, 2019, and 2022.
|
|
Thanks for the response. The concern I have here is that |
|
Would you like me to change it to use System.DirectoryServices.Protocols? |
That will be really nice. Also please rebase to the |
Summary
Adds native LDAP authentication to the DNS Server web console, enabling users to sign in with their Active Directory or LDAP directory credentials.
Features
Use SSL+ port 636 = LDAPS,Use SSL+ any other port = StartTLS.user@domain) and full DN formats.(sAMAccountName={0})for Active Directory; any RFC 4515 filter is supported.Domain Admins→Administrators.DNS_SERVER_LDAP_*variables.Environment Variables
DNS_SERVER_LDAP_ENABLEDtrue/falseDNS_SERVER_LDAP_SERVERDNS_SERVER_LDAP_PORT389DNS_SERVER_LDAP_USE_SSLtrueenables StartTLS (port 389) or LDAPS (port 636)DNS_SERVER_LDAP_IGNORE_SSL_ERRORStrue/falseDNS_SERVER_LDAP_BIND_DNDNS_SERVER_LDAP_BIND_PASSWORDDNS_SERVER_LDAP_SEARCH_BASEDC=example,DC=comDNS_SERVER_LDAP_USER_FILTER(sAMAccountName={0})DNS_SERVER_LDAP_GROUP_ATTRIBUTEmemberOfDNS_SERVER_LDAP_ALLOW_SIGNUPtrue/falseDNS_SERVER_LDAP_ALLOW_SIGNUP_ONLY_FOR_MAPPED_USERStrue/falseDNS_SERVER_LDAP_GROUP_MAP[{"remoteGroup":"Domain Admins","localGroup":"Administrators"}]Implementation Notes
Uses
Novell.Directory.Ldap.NETStandard(v3.6.0) rather thanSystem.DirectoryServices.Protocols. The Novell library is pure managed .NET (TcpClient + SslStream) with no dependency on native OpenLDAP libraries, ensuring consistent behaviour on Linux, Windows, macOS, Docker, and ARM.