Troubleshoot LDAP over SSL (LDAPS) Connection Problems on Port 636

LDAPS to a domain controller fails on port 636: check the Server Authentication certificate, chain and private key with certutil, multiple certificates, test with Ldp.exe, read events 1220 and 36884 and turn on Schannel logging.

Home › Guides › LDAPS connection problems

Last updated 21 November 2026

Quick answer

When LDAP over SSL (LDAPS) to a domain controller fails, Microsoft's troubleshooting article (KB 938703) has five steps:

  1. Verify the Server Authentication certificate on the DC: the DC's FQDN in the Subject CN or a SAN DNS entry, the Server Authentication EKU 1.3.6.1.5.5.7.3.1, the private key present, and a chain that is valid on the client.
  2. Verify any Client Authentication certificate on the client, because LDAPS can use one if it is available.
  3. Check for multiple valid SSL certificates: Schannel may not pick the one you want.
  4. Test LDAPS on the DC itself with Ldp.exe on port 636, and read the errors and the event logs.
  5. Turn on Schannel event logging on the server and the client.

Event 1220 on the DC means it could not obtain a certificate for LDAPS; Schannel 36884 on the client means a name mismatch (see the 36884 guide).

Ports and how LDAPS starts

LDAPS uses TCP 636; LDAPS to a global catalog server uses TCP 3269. On those ports SSL/TLS is negotiated before any LDAP traffic is exchanged. There is no user interface for configuring LDAPS: installing a valid certificate on a DC makes the LDAP service listen for, and automatically accept, SSL connections for both LDAP and global catalog traffic. Besides LDAP over SSL, LDAP clients can issue the StartTLS command; Windows updates KB5014668 and KB5014665 (released 6/21/2022) added TLS 1.3 support for both.

Step 1: check the Server Authentication certificate

certutil -v -urlfetch -verify serverssl.cer > output.txt

Open Output.txt and search for errors.

Step 2: check a Client Authentication certificate

In some cases LDAPS uses a Client Authentication certificate if one is available on the client. If there is one, it must have the Client Authentication EKU 1.3.6.1.5.5.7.3.2, its private key must be available on the client (certutil -verifykeys), and its chain must be valid on the DC: export it on the client to Clientssl.cer, copy it to the server, run the same certutil -v -urlfetch -verify command there with the output sent to Outputclient.txt, and search that file for errors.

Step 3: more than one valid certificate

Schannel (the Microsoft SSL provider) selects the first valid certificate it finds in the Local Computer store. With several valid certificates there, it may not select the correct one. Microsoft also warns of a conflict with a CA certificate when the CA is installed on the DC you are trying to reach over LDAPS.

The way out on Windows Server 2008 and later: put the LDAPS certificate in the NTDS service's Personal store. AD DS looks for certificates there before the Local Machine store, picks up a new certificate dropped into it without a restart, and makes it easier to control which certificate is used. If a DC finds multiple certificates in its store, it chooses one at random. The import steps are in enable LDAPS with a third-party CA certificate.

Step 4: test with Ldp.exe on the DC

  1. Start ldp (Run as administrator).
  2. Connection > Connect. In Server type the host name, set Port to 636, clear Connectionless, select SSL and click OK.
  3. RootDSE information in the right pane means the connection worked. Cannot open connection means LDAP-over-SSL binding is not configured properly.
  4. Connection > Bind > OK. The output should show the user name and domain you bound with.

If it fails, read the errors Ldp.exe shows and check the Event Viewer logs.

Events to look for

EventWhereMeaning
1220 (DIRLOG_LDAP_SSL_NO_CERT)DC, source Microsoft-Windows-ActiveDirectory_DomainServiceLDAP over Secure Sockets Layer (SSL) will be unavailable at this time because the server was unable to obtain a certificate. Logged when clients try LDAPS but SSL is not enabled on the directory.
36884Client, System log, source SchannelThe certificate received from the remote server does not contain the expected name.

For 1220, either give AD DS a certificate (see the enable guide) or, if you don't want to support LDAPS, find the clients that are trying to make LDAPS connections.

Step 5: turn on Schannel event logging

On both the server and the client, back up the registry, then open HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\SecurityProviders\SCHANNEL, set the EventLogging REG_DWORD to one of these values and restart (logging doesn't take effect until the restart). The values combine: errors 0x0001 plus warnings 0x0002 gives 0x0003.

ValueLogs
0x0000Nothing
0x0001Error messages (the default)
0x0002Warnings
0x0003Warnings and error messages
0x0004Informational and success events
0x0005Informational and success events and error messages
0x0006Informational and success events and warnings
0x0007Informational and success events, warnings and error messages (all levels)

The events go to the System log. Schannel event logging is not the same as Schannel debug logging, which needs the checked version of Schannel.dll.

TLS 1.3 compatibility

If you need to disable TLS 1.3 for LDAP for compatibility reasons, Microsoft documents these values (back up the registry first):

Trace the LDAP client

Windows can trace LDAP client activity, including TLS, with ETW:

  1. Create the registry subkey HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\ldap\Tracing\<ProcessName> with the full process name, for example ldp.exe. An optional DWORD PID limits tracing to one process ID. Without a subkey for at least one process, the trace is empty.
  2. Start the trace; flag 0x18180380 is for connection establishment problems (0x1A59AFA3 covers most needs, 0x1bddbf73 is verbose):
logman create trace "ds_ds" -ow -o c:\ds_ds.etl -p "Microsoft-Windows-LDAP-Client" 0x18180380 0xff -nb 16 16 -bs 1024 -mode Circular -f bincirc -max 4096 -ets
logman stop "ds_ds" -ets
netsh trace convert input=c:\ds_ds.etl output=LDAP_CLIENT-formatted.txt

Reproduce the failure between the start and stop commands.

Related tools and guides

Look up AD DS 1220 and Schannel 36884 in the Windows Event ID Lookup, copy the certutil -verifykeys, certutil -verify and logman lines from the PowerShell Cheat Sheet, search certutil -verify output for errors with the Regex Tester, check the client and DC subnets for TCP 636 and 3269 with the IPv4 Subnet Calculator or IPv6 Subnet Calculator, and identify the network adapter vendor of a client whose LDAPS connection fails with the MAC Vendor Lookup. Related guides: LDAPS Schannel event 36884, enable LDAPS with a third-party CA certificate, Group Policy event 1006 (LDAP bind failed) and common AD replication errors.

Hardening LDAP on the domain controllers? See LDAP signing and channel binding (events 2887 and 2889).

Every AD replication error code with its cause and fix: common Active Directory replication errors.

FAQ

Which ports does LDAPS use?

TCP 636 for LDAP over SSL and TCP 3269 for LDAPS to a global catalog server. On those ports SSL/TLS is negotiated before any LDAP traffic is exchanged.

What must the domain controller certificate have for LDAPS?

The DC FQDN as the Subject CN or a SAN DNS entry, the Server Authentication EKU 1.3.6.1.5.5.7.3.1, a private key available on the DC (check with certutil -verifykeys), and a chain that is valid on the client.

How do I test LDAPS on a domain controller?

Run ldp, choose Connection and Connect, type the host name, port 636, select SSL and clear Connectionless. RootDSE output means it works; Cannot open connection means LDAP over SSL binding is not configured properly.

What does event 1220 mean?

DIRLOG_LDAP_SSL_NO_CERT: LDAP over SSL will be unavailable at this time because the server was unable to obtain a certificate. Clients tried LDAPS but SSL is not enabled on the directory. Add a certificate, or find the clients if you do not want LDAPS.

How do I turn on Schannel event logging?

Set the EventLogging REG_DWORD under HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\SecurityProviders\SCHANNEL, for example 0x0007 for all levels, and restart. The default 0x0001 logs only errors. Events go to the System log.

Want the full kit?

Runbooks, checklists and helpdesk templates: IT Admin Packs on Gumroad.