Windows OS Hub
  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu
  • Home
  • About

Windows OS Hub

  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu

 Windows OS Hub / Windows 10 / How to Disable/Enable SMB v 1.0 in Windows 10/Server 2016?

May 10, 2023 Group PoliciesWindows 10Windows Server 2016Windows Server 2019

How to Disable/Enable SMB v 1.0 in Windows 10/Server 2016?

In Windows Server 2016/2019 and Windows 10 (starting with build 1709), the Server Message Block 1.0 (SMBv1) network protocol used to access shared folders is disabled by default. In most cases, this protocol is required to access shared folders hosted on legacy systems, such as no longer supported Windows XP, Windows Server 2003 and older OSs. In this article, we’ll look on how to enable or disable SMBv1 client and server support on Windows 10 and Windows Server 2016/2019.

If there are no SMB 1.x clients left on your network, you must completely disable SMBv1 on all Windows devices. By disabling SMB 1.0, you can protect Windows computers from a wide range of vulnerabilities in this legacy protocol (the most famous public exploit for SMBv1 is EternalBlue). As a result, your devices will use new, more efficient, secure and functional versions of the SMB protocol when accessing network shares.

In one of the previous articles, we showed the table of client- and server-side SMB version compatibility. According to the table, old client versions (XP, Server 2003 and some *nix clients) can access network shared folders only using SMB v1.0 protocol. If there are no such clients in the network, you can completely disable SMB 1.0 on the side of file servers (including AD domain controllers) and client desktops.

In Windows 10 and Windows Server 2016, the SMBv1 protocol is split into two separate components – SMB client and SMB server, which can be enabled/disabled independently.

Contents:
  • Auditing Shared Folder Access via SMB v1.0
  • Enable/Disable SMB 1.0 on Windows Server 2016/2019
  • How to Enable/Disable SMBv1 on Windows 10?
  • Disabling SMBv1 Client and Server via Group Policy

Auditing Shared Folder Access via SMB v1.0

Before disabling or completely removing SMB 1.0 driver on the side of the SMB file server, it’s worth making sure that there are no legacy clients that use it in your network. To do this, enable the audit of file server access over SMB v1.0 using the following PowerShell command:

Set-SmbServerConfiguration –AuditSmb1Access $true

After a couple of days, open the Event Viewer on the server, check the log Applications and Services -> Microsoft -> Windows -> SMBServer -> Audit and see if any clients accessed the file server over SMB1.

Tip. You can display the list of events from this event log using the following PowerShell command:
Get-WinEvent -LogName Microsoft-Windows-SMBServer/Audit

In our example, an event with EventID 3000 from the SMBServer source was found in the log. The event indicates that the client 192.168.1.10 is trying to access the server using the SMB1 protocol.

SMB1 access
Client Address: 192.168.1.10
Guidance:
This event indicates that a client attempted to access the server using SMB1. To stop auditing SMB1 access, use the Windows PowerShell cmdlet Set-SmbServerConfiguration.

Set-SmbServerConfiguration - enable audit access via smb1

You need to find this computer or device on the network and update the OS or firmware to a version that supports newer SMB protocol versions: SMBv2 or SMBv3.

In our case we’ll ignore this information, but you should bear in mind that later this client won’t be able to access shared folders on this SMB server.

Enable/Disable SMB 1.0 on Windows Server 2016/2019

In Windows Server 2016 starting with build 1709 and Windows Server 2019, SMBv1 is disabled by default. To enable support for the SMBv1 client protocol in newer versions of Windows Server, you need to install the separate SMB 1.0/CIFS File Sharing Support feature.

You can install the SMBv1 feature using Server Manager, or through PowerShell.

SMB 1.0 / CIFS File Sharing Support feature on windows server 2016

You can check that SMBv1 is enabled with the PowerShell command:

Get-WindowsFeature | Where-Object {$_.name -eq "FS-SMB1"} | ft Name,Installstate

To install the FS-SMB1 feature, run:

Install-WindowsFeature FS-SMB1

To uninstall the SMBv1 client feature (requires a reboot), run the command:

Uninstall-WindowsFeature –Name FS-SMB1 –Remove

Another PowerShell command that also removes the SMB1Protocol feature:

Disable-WindowsOptionalFeature -Online -FeatureName SMB1Protocol -Remove

In order for your server to handle SMBv1.0 client access, you need to enable SMBv1 support at the SMB file server level in addition to the FS-SMB1 component. To check if SMBv1 access is enabled for network shares on your server, run:

Get-SmbServerConfiguration

Get-SmbServerConfiguration smb1protocol is enabled

The line “EnableSMB1Protocol: True” means that you are allowed to access shared folders on this server using the SMBv1 protocol. To disable SMBv1 server support in Windows Server, run the PowerShell command:

Set-SmbServerConfiguration -EnableSMB1Protocol $false -Force

Now use the Get-SmbServerConfiguration cmdlet to make sure SMB1 server is disabled.

disable smb1 using cmdlet set-SmbServerConfiguration

To enable SMBv1 support on the server, run the command:

Set-SmbServerConfiguration -EnableSMB1Protocol $True -Force

On Windows 7/8 and Windows Server 2008 R2/2012, in order to disable the SMB 1.0 client, you need to disable the service and the SMBv1 access driver with the commands:

sc.exe config lanmanworkstation depend= bowser/mrxsmb20/nsi
sc.exe config mrxsmb10 start= disabled

delete smb1 driver on client: sc.exe config mrxsmb10 start= disabled

How to Enable/Disable SMBv1 on Windows 10?

As we already said, in all new builds of Windows10  (starting from 1709) support for the SMB1 protocol is disabled (guest access via the SMBv2 protocol is also disabled).

In Windows 10, you can check the status of the SMBv1 protocol components with the DISM command:

Dism /online /Get-Features /format:table | find "SMB1Protocol"

smb1protocol disabled in windows10

In our example, you can see that all SMBv1 features are disabled:

SMB1Protocol                                | Disabled
SMB1Protocol-Client                         | Disabled
SMB1Protocol-Server                         | Disabled
SMB1Protocol-Deprecation                    | Disabled

In Windows 10, you can also manage SMB 1 features from the Control Panel (optionalfeatures.exe). Expand the SMB 1.0 /CIFS File Sharing Support option. As you can see, 3 SMBv1 components are also available here:

  • SMB 1.0/CIFS Automatic Removal
  • SMB 1.0/CIFS Client
  • SMB 1.0/CIFS Server

Windows10 feature SMB 1.0/CIFS File Sharing Support

You can enable SMBv1 client and server on Windows 10 from the feature management window or using the commands:

Dism /online /Enable-Feature /FeatureName:"SMB1Protocol"
Dism /online /Enable-Feature /FeatureName:"SMB1Protocol-Client"
Dism /online /Enable-Feature /FeatureName:"SMB1Protocol-Server"

You can also enable SMBv1 server and client in Windows 10 using PowerShell:

Enable-WindowsOptionalFeature -Online -FeatureName SMB1Protocol-Server
Enable-WindowsOptionalFeature -Online -FeatureName SMB1Protocol-Client

If after enabling SMBv1 client, it is not used for more than 15 days, it is automatically disabled.

Automatic removal of SMBv1 client is a one-time operation. If the administrator manually enables SMBv1 again, it won’t be disabled automatically.

To disable SMB1 client and server support in Windows 10, run the following DISM commands:

Dism /online /Disable-Feature /FeatureName:"SMB1Protocol"
Dism /online /Disable-Feature /FeatureName:"SMB1Protocol-Client"
Dism /online /Disable-Feature /FeatureName:"SMB1Protocol-Server"

If you disabled the SMBv1 client in Windows 10, then when you access a snared folder on a file server that only supports SMBv1 (the SMBv2 and v3 protocols are disabled or not supported), you may receive the following errors:

  • 0x80070035 The network path was not found;
  • Unable to connect to file shares because it is not secure. This share requires the obsolete SMB1 protocol, which is not secure and could expose your system to attacks;
  • You can’t connect to the file share because it’s not secure. This share requires the obsolete SMB1 protocol, which is unsafe and could expose your system to attack. Your system requires SMB2 or higher.

    windows10 smb 1.0 access error

    Read more about it in the article Unable to access shared folder on Windows 10 .

Additionally, if you disable the SMBv1 client, the Computer Browser service, which is used by the legacy NetBIOS protocol to discover devices on the network, stops working on the computer. To correctly display neighboring computers on the Windows 10 network, you must configure the Feature Discovery Provider Host service (check this article).

Disabling SMBv1 Client and Server via Group Policy

In an Active Directory domain environment, you can disable SMBv1 on all servers and computers using Group Policies (GPOs). Since there is no separate SMB configuration policy in the standard Windows Group Policies, you will have to disable it through the registry policy.

  1. Open the Group Policy Management console (gpmc.msc), create a new GPO (disableSMBv1) and link it to the OU containing the computers on which you want to disable SMB1;
  2. Switch to the policy editing mode. Expand the GPO section Computer Configuration -> Preferences -> Windows Settings -> Registry;
  3. Create a new Registry Item with the following setting:
    Action: Update
    Hive: HKEY_LOCAL_MACHINE
    Key Path: SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters
    Value name: SMB1
    Value type: REG_DWORD
    Value data: 0
    smb1 server disable via gpo
    This policy will disable support for the SMBv1 server component through the registry on all computers.
    You can exclude some version of Windows from this policy using the WMI filter.

If you want to disable the SMB client on domain computers via GPO, create two additional registry parameters:

  • The Start parameter (REG_DWORD type) with value 4 in the registry key HKLM\SYSTEM\CurrentControlSet\services\mrxsmb10;
  • The DependOnService parameter (REG_MULTI_SZ type) with the value Bowser, MRxSmb20, NSI (each value on a new line) in the reg key HKLM\SYSTEM\CurrentControlSet\Services\LanmanWorkstation.

disable smb v1.0 client driver group policy

It remains to update the Group Policy settings on the clients (gpupdate /force) after the reboot make sure that the SMBv1 components are completely disabled.

The Security Baseline GPOs from the Microsoft Security Compliance Toolkit have a separate administrative template MS Security Guide (SecGuide.adml and SecGuide.admx files) that have separate options for disabling the SMB server and client:

  • Configure SMB v1 server;
  • Configure SMB v1 client driver.

ms security guide gpo: disable smbv1 client driver and server

5 comments
2
Facebook Twitter Google + Pinterest
previous post
How to Install Only Specific Apps in Office 2016/Office 365?
next post
VMWare Error: Unable to Access a File Since It Is Locked

Related Reading

How to Connect VPN Before Windows Logon

November 14, 2023

Using WPAD (Web Proxy Auto-Discovery Protocol) on Windows

November 7, 2023

Zabbix: How to Get Data from PowerShell Scripts

October 27, 2023

Tracking Printer Usage with Windows Event Viewer Logs

October 19, 2023

How to Use Ansible to Manage Windows Machines

September 25, 2023

5 comments

markus September 29, 2020 - 2:32 pm

cool thank you

Reply
Luis December 3, 2020 - 4:49 pm

Excelente articulo

Reply
Lex IT April 2, 2021 - 10:24 am

I have found out that i have a chicken / egg situation. If i disable SMB1 on the domain workstations these wont be able to contact the servers anymore and if i disable the smb1 on the servers they can’t connect to the servers either. If i use the GPO solution and i do disable the servers during the Night, will the client computers still be able to update the group policy from sysvol folder to update their policy and disable the smb1 as well ?

This way i can tell the users to reboot their computers after the first error messages appear …. Otherwise i need to figure out how to do a big bang but this will be very difficult to achieve

Reply
Maybe just maybe December 16, 2021 - 10:21 pm

What about creating a small script to accomplish the task, and push out a GPO to create a scheduled task for all targeted systems to kick off simultaneously at a later, synchronized date?

Reply
Dioxaz August 26, 2021 - 2:27 pm

Hello. I’d like to warn people about using the “Uninstall-WindowsFeature –Name FS-SMB1 –Remove” command. Unfortunately, I can’t install SMB 1.0 anymore after using this command. Now Windows complains that it can’t find the “sources” anymore.
So beware to anybody, don’t us this command hastly!

Reply

Leave a Comment Cancel Reply

Categories

  • Active Directory
  • Group Policies
  • Exchange Server
  • Microsoft 365
  • Azure
  • Windows 11
  • Windows 10
  • Windows Server 2022
  • Windows Server 2019
  • Windows Server 2016
  • PowerShell
  • VMWare
  • Hyper-V
  • Linux
  • MS Office

Recent Posts

  • How to Connect VPN Before Windows Logon

    November 14, 2023
  • Removing Azure Arc Setup Feature on Windows Server 2022

    November 9, 2023
  • Using WPAD (Web Proxy Auto-Discovery Protocol) on Windows

    November 7, 2023
  • Send Emails with Microsoft Graph API and PowerShell

    November 6, 2023
  • Zabbix: How to Get Data from PowerShell Scripts

    October 27, 2023
  • Tracking Printer Usage with Windows Event Viewer Logs

    October 19, 2023
  • PowerShell: Configure Certificate-Based Authentication for Exchange Online (Azure)

    October 15, 2023
  • Reset Root Password in VMware ESXi

    October 12, 2023
  • How to Query and Change Teams User Presence Status with PowerShell

    October 8, 2023
  • How to Increase Size of Disk Partition in Ubuntu

    October 5, 2023

Follow us

  • Facebook
  • Twitter
  • Telegram
Popular Posts
  • How to Hide or Show User Accounts from Login Screen on Windows 10/11?
  • Configuring Proxy Settings on Windows Using Group Policy Preferences
  • How to Disable NetBIOS and LLMNR Protocols in Windows Using GPO?
  • Changing Desktop Background Wallpaper in Windows through GPO
  • Restricting Group Policy with WMI Filtering
  • Windows: Block Remote Network Access for Local User Accounts
  • How to Disable/Remove Thumbs.db File on Network Folders in Windows?
Footer Logo

@2014 - 2023 - Windows OS Hub. All about operating systems for sysadmins


Back To Top