Skip to content

Clients Windows 10 et intégration au nouveau domaine se4ad

Created by: jhaesselbacher

Concernant le changement de domaine, la sortie du domaine sambaedu3 et le passage sur le nouveau domaine voila ou j'en suis

Pour désactiver le protocole smb1 et que le service netlogon du poste client windows fonctionne encore après cette opération il faut suivre précisément ces étapes

En effet, jusqu'ici dans nos test la désactivation de smb1 et la réactivation de smb2/3 provoquait un dysfonctionnement du service netlogon Windows ( le service refuse de démarrer car il est encore associé au protocole smb1 )

    1. Ces commandes powershell sont à lancer en cmd en tant qu'administrateur et forcent l'utilisation de smb2/3 par le service netlogon ( en ayant préalablement désactiver l'utilisation de smb1 par netlogon ).

powershell.exe -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "& {Set-itemproperty -path “HKLM:\System\CurrentControlSet\Services\LanmanServer\Parameters” SMB1 -Type Dword -Value 0 -Force}"

powershell.exe -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "& {Set-itemProperty -path “HKLM:\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters” SMB2 -Type Dword -Value 1 -Force}"

powershell.exe -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "& {Set-itemProperty -path “HKLM:\SYSTEM\CurrentControlSet\services\lanmanworkstation” -name “DependOnService” -value “Bowser”, “MRxSmb20”, “NSI” -type MultiString}"

powershell.exe -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "& {Set-itemProperty -path “HKLM:\SYSTEM\CurrentControlSet\services\mrxsmb10” -name “Start” -type Dword -Value 4 -Force}"

powershell.exe -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "& {Set-itemProperty -path “HKLM:\SYSTEM\CurrentControlSet\services\mrxsmb20” -name “Start” -type Dword -Value 2 -Force}"

    1. Les clefs de registre à nettoyer

reg.exe delete "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\NetworkProvider\HardenedPaths" /v "\\netlogon" /F reg.exe delete "HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Policies\Microsoft\Windows\NetworkProvider\HardenedPaths" /v "\\netlogon" /F reg.exe delete "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "DomainCompatibilityMode" /F reg.exe delete "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanWorkstation\Parameters" /v "DNSNameResolutionRequired" /F

    1. La désinstallation de smb1

Echo necessaire pour W10 > 1709, ne pose pas de probleme pour les versions anterieures dism.exe /online /disable-feature /quiet /norestart /featurename:SMB1Protocol dism.exe /online /disable-feature /quiet /norestart /featurename:SMB1Protocol-Client dism.exe /online /disable-feature /quiet /norestart /featurename:SMB1Protocol-Server dism.exe /online /enable-feature /quiet /norestart /featurename:SMB1Protocol-Deprecation

    1. La Suppression des GPO

del /Q /S /F c:\windows\System32\GroupPolicy*

Une fois ces commandes passées netlogon fonctionne bien mais nous sommes tout de même encore obligés de joindre manuellement le nouveau domaine se4ad avant de pouvoir ouvrir une session sur ce dernier ( changement de domaine à scripter via un vbs ou une commande powershell