How to Enable Network Level Authentication for RDP
Network Level Authentication (NLA) makes a user prove who they are before Windows builds a Remote Desktop session and shows the logon screen. Without it, the machine starts a full Remote Desktop connection and shows the logon screen before it knows who is connecting. This guide shows how to check NLA, switch it on for one machine or a whole domain, set the RDP encryption level, and fix the errors you may meet afterwards.
What NLA does
- It checks the user first. NLA completes user authentication before the Remote Desktop connection is set up and before the logon screen appears.
- It spends less before it knows who you are. The remote machine uses a limited set of resources until the user is authenticated, which Microsoft says helps reduce the risk of denial-of-service attacks.
- It needs a modern client. The client must support the Credential Security Support Provider (CredSSP) protocol and RDP version 6.0 or later.
Step 1: Check whether NLA is on
The setting lives in the registry value UserAuthentication on the RDP listener. 1 means NLA is required; 0 means it is not.
Get-ItemProperty -Path 'HKLM:\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp' -Name UserAuthenticationThe Remote Desktop WMI provider gives the same answer, and also tells you where the setting came from. Run it from an elevated PowerShell window:
Get-CimInstance -Namespace root\cimv2\TerminalServices -ClassName Win32_TSGeneralSetting -Filter "TerminalName='RDP-Tcp'" |
Select-Object TerminalName, UserAuthenticationRequired, PolicySourceUserAuthenticationRequired, MinEncryptionLevel| Property | Value | Meaning |
|---|---|---|
| UserAuthenticationRequired | 1 | NLA is required |
| UserAuthenticationRequired | 0 | NLA is not required |
| PolicySourceUserAuthenticationRequired | 0 / 1 / 2 | Set on the server / by Group Policy / by default |
Step 2: Check your clients first
Once NLA is required, only clients that support RDP 6.0 or later can connect. Microsoft recommends getting those clients in place before you switch the setting on. To check a Windows client, open Remote Desktop Connection, click the icon in the top-left corner of the window, choose About, and look for the words "Network Level Authentication supported".
Step 3: Turn it on for one machine
In the GUI, open System Properties and go to the Remote tab. Under Remote Desktop, choose the option that allows connections only from computers running Remote Desktop with Network Level Authentication.
In PowerShell, call the documented WMI method. A return value of 0 means it worked:
Get-CimInstance -Namespace root\cimv2\TerminalServices -ClassName Win32_TSGeneralSetting -Filter "TerminalName='RDP-Tcp'" |
Invoke-CimMethod -MethodName SetUserAuthenticationRequired -Arguments @{ UserAuthenticationRequired = 1 }Or set the registry value directly:
Set-ItemProperty -Path 'HKLM:\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp' -Name UserAuthentication -Value 1Step 4: Turn it on across the domain with Group Policy
Edit a GPO linked to the machines you want and enable this setting:
Computer Configuration\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Session Host\Security
Require user authentication for remote connections by using Network Level AuthenticationThe Group Policy setting takes precedence over the Remote tab, so once it applies, the NLA option in System Properties is greyed out. Run gpupdate /force on a test machine, re-run the Step 1 check, then roll out to a small group before the whole domain.
Step 5: Set the RDP encryption level
The encryption level sits next to NLA in the same policy folder:
Computer Configuration\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Session Host\Security
Set client connection encryption levelOn the machine, the active level shows up as MinEncryptionLevel, both in the WMI query from Step 1 and in the RDP-Tcp registry key:
Get-ItemProperty -Path 'HKLM:\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp' -Name MinEncryptionLevel| MinEncryptionLevel | Name | What it does |
|---|---|---|
| 1 | Low | Encrypts only data sent from client to server, with 56-bit encryption. Data from server to client is not encrypted. |
| 2 | Client Compatible | Encrypts both directions at the maximum key strength the client supports. |
| 3 | High | Encrypts both directions with 128-bit encryption. Clients that cannot do this cannot connect. |
| 4 | FIPS Compliant | Encrypts both directions with FIPS 140 algorithms using Microsoft cryptographic modules. |
Errors you may see after enabling NLA
- Older clients are refused. Any client that does not support RDP 6.0 or CredSSP cannot connect. Update the client rather than switching NLA off. Microsoft suggests turning NLA off only temporarily if you have to connect from such a device, and keeping it on whenever possible.
- "This could be due to CredSSP encryption oracle remediation." NLA relies on CredSSP. This error appears when one side has the CredSSP updates for CVE-2018-0886 and the other does not, and policy blocks the insecure connection. Microsoft’s fix is to install the CredSSP updates on both client and server. Its workaround, setting Encryption Oracle Remediation to Vulnerable, exposes the server to attack, so do not leave it in place.
- The NLA checkbox is greyed out. A Group Policy setting is in force. Change it in the GPO, not on the machine.
How Sentrivox checks this
Each time it scans, the Sentrivox agent reads two values under HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp on every Windows endpoint:
- UserAuthentication. A value of 1 passes. Any other value, or a missing value, is reported as a High severity finding.
- MinEncryptionLevel. A value of 2 or higher passes. A value of 1, or a missing value, is reported as a Medium severity finding, with a suggested fix of 3 (High).
The check reads these two registry values directly. It does not read the Group Policy key or query WMI, so if you set NLA by Group Policy, run the Step 1 commands on one machine to confirm what it reports.
Frequently asked questions
Does NLA make it safe to open RDP to the internet?
No. NLA makes users sign in before a remote session starts, but the RDP port is still open. Microsoft advises enabling Remote Desktop only on trusted networks.
Which Remote Desktop clients support NLA?
Microsoft documents that only clients that support RDP version 6.0 or later can connect once NLA is required. In Remote Desktop Connection, open About and look for "Network Level Authentication supported".
Why is the NLA option greyed out in System Properties?
A Group Policy setting is applied to the machine. Microsoft notes that the Group Policy setting takes precedence over the setting on the Remote tab, so change the GPO instead.
Which RDP encryption level should I use?
High (3) where every client supports 128-bit encryption. The setting only applies to native RDP encryption, which Microsoft does not recommend over SSL (TLS). For FIPS, Microsoft points to the System cryptography policy instead.
Sources and further reading
- Microsoft: Configure Network Level Authentication for Terminal Services Connections
- Microsoft: Enable Remote Desktop on your PC
- Microsoft: Win32_TSGeneralSetting class
- Microsoft: SetUserAuthenticationRequired method
- Microsoft: UserAuthentication (unattend setting)
- Microsoft: RemoteDesktopServices Policy CSP
- Microsoft: CredSSP encryption oracle remediation error
