Open in the explorer

Prohibit connecting and disconnecting a remote access connection

Interdire la connexion et la déconnexion d’une connexion d’accès à distance

Type
User
GPO path
User Configuration › Policies › Administrative Templates › Network › Network Connections FR: Configuration utilisateur › Stratégies › Modèles d'administration › Réseau › Connexions réseau
Supported on
At least Windows 2000 Service Pack 1 FR: Au minimum Windows 2000 Service Pack 1
ADMX file
NetworkConnections.admx
Internal name
NetworkConnections/NC_RasConnect

Explanation

Determines whether users can connect and disconnect remote access connections.

If you enable this setting (and enable the "Enable Network Connections settings for Administrators" setting), double-clicking the icon has no effect, and the Connect and Disconnect menu items are disabled for all users (including administrators).

Important: If the "Enable Network Connections settings for Administrators" is disabled or not configured, this setting will not apply to administrators on post-Windows 2000 computers.

If you disable this setting or do not configure it, the Connect and Disconnect options for remote access connections are available to all users. Users can connect or disconnect a remote access connection by double-clicking the icon representing the connection, by right-clicking it, or by using the File menu.

French text from Windows 11 26H2

Détermine si les utilisateurs peuvent se connecter et se déconnecter des connexions d’accès à distance.

Si vous activez ce paramètre (ainsi que le paramètre « Activer les paramètres de connexion réseau des administrateurs »), le fait de double-cliquer sur l’icône n’a aucun effet et les éléments du menu Connecter et Déconnecter sont désactivés pour tous les utilisateurs (administrateurs compris).

Important : si le paramètre « Activer les paramètres Connexions réseau pour les administrateurs » est désactivé ou n’est pas configuré, ce paramètre ne s’appliquera pas aux administrateurs sur les ordinateurs sur lesquels une version postérieure à Windows 2000 est installée.

Si vous désactivez ce paramètre ou si vous ne le configurez pas, les options Connecter et Déconnecter pour les connexions d’accès à distance sont disponibles pour tous les utilisateurs. Les utilisateurs peuvent se connecter ou se déconnecter d’une connexion d’accès à distance en double-cliquant sur l’icône représentant la connexion, en cliquant dessus avec le bouton droit de la souris ou en utilisant le menu Fichier.

Registry

HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\Network Connections
Value name
NC_RasConnect
StateValue written
EnabledREG_DWORD = 0
DisabledREG_DWORD = 1

PowerShell

PowerShell commands that write to the registry what the policy would write. Values in angle brackets (<…>) must be replaced.

Writing directly to the registry bypasses Group Policy: if a GPO manages this value, it will be rewritten at the next gpupdate; otherwise the value stays in place (the "tattooing" effect). Prefer a GPO or, locally, LGPO.exe. Run PowerShell as administrator for HKLM. Some policies need a restart or gpupdate /force.

Enable

# Enable: NetworkConnections/NC_RasConnect
$k = 'HKCU:\Software\Policies\Microsoft\Windows\Network Connections'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'NC_RasConnect' -Value 0 -Type DWord

Disable

# Disable: NetworkConnections/NC_RasConnect
$k = 'HKCU:\Software\Policies\Microsoft\Windows\Network Connections'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'NC_RasConnect' -Value 1 -Type DWord

Revert to "Not configured"

# Revert to "Not configured": NetworkConnections/NC_RasConnect
$k = 'HKCU:\Software\Policies\Microsoft\Windows\Network Connections'
Remove-ItemProperty -Path $k -Name 'NC_RasConnect' -ErrorAction SilentlyContinue

Availability