Migrate a production environment from SMBv1 to SMBv2/v3

%3CLINGO-SUB%20id%3D%22lingo-sub-3071478%22%20slang%3D%22en-US%22%3EMigrate%20a%20production%20environment%20from%20SMBv1%20to%20SMBv2%2Fv3%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3071478%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20everyone%2C%3C%2FP%3E%3CP%3EI%20would%20like%20to%20get%20your%20help%20and%20advice%20in%20order%20to%20migrate%20successfully%20my%20production%20environment%20from%20SMBv1%20to%20SMBv2%2Fv3.%20In%20test%2C%20I'm%20able%20to%20implement%20this%20change%20but%20in%20production%20this%20change%20is%20more%20tricky...%3C%2FP%3E%3CP%3ELet%20me%20describes%20what%20I've%20done%20and%20what%20my%20production%20looks%20like%3A%3C%2FP%3E%3CP%3E%3CSTRONG%3EIn%20test%3A%3C%2FSTRONG%3E%3C%2FP%3E%3CP%3E-%20Implementing%20a%20GPO%20with%20the%20following%20registry%20changes%20on%20a%20test%20server%20and%20on%20the%20unique%20test%20domain%20controller%20I%20have%3C%2FP%3E%3CP%3E-%20Restart%20these%20servers%3C%2FP%3E%3CP%3E-%26nbsp%3BWireshark%20shows%20that%20SMBv1%20is%20well%20disabled%20and%20that%20all%20SMB%20communications%20are%20in%20SMBv2%20between%20my%20test%20server%20and%20my%20test%20DC.%3C%2FP%3E%3CP%3E-%20I%E2%80%99m%20still%20working%20on%20the%20SMBv3%20implementation%20or%20switch%20from%20SMBv2%20to%20SMBv3%20(not%20done%20yet).%3C%2FP%3E%3CP%3E-%20I%20need%20to%20configure%20a%20Linux%20server%20in%20SMBv2%2Fv3%20and%20test%20too%26nbsp%3B(not%20done%20yet).%3C%2FP%3E%3CP%3E%3CSTRONG%3EGPO%20details%3A%3C%2FSTRONG%3E%3C%2FP%3E%3CP%3E%3CSTRONG%3E1%C2%B0)%20Disable%20SMBv1%20in%20LanmanServer%3A%3C%2FSTRONG%3E%3CBR%20%2F%3EAction%3A%20Update%3CBR%20%2F%3EHive%3A%20HKEY_LOCAL_MACHINE%3CBR%20%2F%3EKey%20Path%3A%20SYSTEM%5CCurrentControlSet%5CServices%5CLanmanServer%5CParameters%3CBR%20%2F%3EValue%20name%3A%20SMB1%3CBR%20%2F%3EValue%20type%3A%20REG_DWORD%3CBR%20%2F%3EValue%20data%3A%200%3C%2FP%3E%3CP%3E%3CSTRONG%3E2%C2%B0)%20Disable%20SMBv1%20in%20LanmanWorkstation%3A%3C%2FSTRONG%3E%3CBR%20%2F%3EAction%3A%20Update%3CBR%20%2F%3EHive%3A%20HKEY_LOCAL_MACHINE%3CBR%20%2F%3EKey%20Path%3A%20SYSTEM%5CCurrentControlSet%5Cservices%5Cmrxsmb10%3CBR%20%2F%3EValue%20name%3A%20Start%3CBR%20%2F%3EValue%20type%3A%20REG_DWORD%3CBR%20%2F%3EValue%20data%3A%204%20(%3Ddisable)%3C%2FP%3E%3CP%3E%3CSTRONG%3E3%C2%B0)%20Delete%20SMBv1%20dependancy%20of%20the%20LanmanWorkstation%20service%3A%3C%2FSTRONG%3E%3CBR%20%2F%3EAction%3A%20Replace%3CBR%20%2F%3EHive%3A%20HKEY_LOCAL_MACHINE%3CBR%20%2F%3EKey%20Path%3A%20SYSTEM%5CCurrentControlSet%5CServices%5CLanmanWorkstation%3CBR%20%2F%3EValue%20name%3A%20DependOnService%3CBR%20%2F%3EValue%20type%20REG_MULTI_SZ%3CBR%20%2F%3EValue%20data%3A%3CBR%20%2F%3EBowser%3CBR%20%2F%3EMRxSmb20%3CBR%20%2F%3ENSI%3C%2FP%3E%3CP%3E%3CSTRONG%3E4%C2%B0)%20Require%20signing%20SMBv2%2Fv3%20for%20LanmanServer%20service%3A%3C%2FSTRONG%3E%3CBR%20%2F%3EAction%3A%20Update%3CBR%20%2F%3EHive%3A%20HKEY_LOCAL_MACHINE%3CBR%20%2F%3EKey%20Path%3A%20SYSTEM%5CCurrentControlSet%5CServices%5CLanmanServer%5CParameters%3CBR%20%2F%3EValue%20name%3A%20RequireSecuritySignature%3CBR%20%2F%3EValue%20type%3A%20REG_DWORD%3CBR%20%2F%3EValue%20data%3A%201%3C%2FP%3E%3CP%3E%3CSTRONG%3E5%C2%B0)%20Require%20signing%20SMBv2%2Fv3%20for%20LanmanWorkstation%20server%3A%3C%2FSTRONG%3E%3CBR%20%2F%3EAction%3A%20Update%3CBR%20%2F%3EHive%3A%20HKEY_LOCAL_MACHINE%3CBR%20%2F%3EKey%20Path%3A%20SYSTEM%5CCurrentControlSet%5CServices%5CLanmanWorkstation%5CParameters%3CBR%20%2F%3EValue%20name%3A%20RequireSecuritySignature%3CBR%20%2F%3EValue%20type%3A%20REG_DWORD%3CBR%20%2F%3EValue%20data%3A%201%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIn%20production%2C%20I%20have%20a%20lot%20of%20servers%20in%20different%20AWS%20regions%20with%20different%20DC%2C%20a%20mix%20of%20linux%20servers%20and%20Windows%20servers.%26nbsp%3B%3C%2FP%3E%3CP%3EMy%20challenge%20is%20to%20migrate%20without%20production%20impact.%26nbsp%3B%3C%2FP%3E%3CP%3E-%20Does%20someone%20has%20already%20performed%20this%20kind%20of%20migration%20%3F%3C%2FP%3E%3CP%3E-%20Modifications%20are%20at%20the%20packet%20level%2C%20do%20you%20already%20experienced%20issue%20when%20migrating%20from%20SMBv1%20to%20SMBv2%2Fv3%20%3F%3C%2FP%3E%3CP%3EAll%20advices%20are%20welcome!%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ERegards%2C%3C%2FP%3E%3CP%3EBernard.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-3071478%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EActive%20Directory%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESecurity%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EWindows%20Server%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-3073970%22%20slang%3D%22en-US%22%3ERe%3A%20Migrate%20a%20production%20environment%20from%20SMBv1%20to%20SMBv2%2Fv3%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3073970%22%20slang%3D%22en-US%22%3EHello%2C%3CBR%20%2F%3E%3CBR%20%2F%3EKeep%20in%20mind%20recent%20releases%20of%20Windows%20clients%2Fservers%20do%20not%20have%20SMB1%20enabled%20by%20default%20(and%20I%20hope%20you%20didn't%20enable%20it).%20Thus%20you%20do%20not%20need%20this%20kind%20of%20Group%20Policy%20parameters%20(which%20may%20really%20messed%20up%20OSes%20and%20are%20quite%20difficult%20to%20rollback).%3CBR%20%2F%3EWhat%20you%20need%20to%20look%20out%20for%20is%20%3A%3CBR%20%2F%3E-%20Very%20old%20Windows%20OS%20(Windows%20XP%2F2003)%20%3A%20those%20are%20a%20security%20nightmare.%20Get%20rid%20of%20them.%3CBR%20%2F%3E-%20Very%20old%20Unix%2FLinux%20OS%20%3A%20see%20above%3CBR%20%2F%3E-%20Printers%20and%20scanners%20still%20relying%20on%20SMBv1%20%3A%20this%20is%20quite%20painful%20to%20check.%20You%20must%20inventory%20everything%2C%20then%20check%20compatibility%20per%20model%20and%20per%20firmware.%20You%20may%20need%20to%20update%20(or%20even%20replace%20entirely)%20printers%20before%20moving%20your%20file%20servers%20away%20from%20SMBv1.%3CBR%20%2F%3E-%20Apps.%20Test%2C%20test%2C%20test.%20Hope%20you%20still%20have%20editor's%20support%20for%20them.%3CBR%20%2F%3E%3CBR%20%2F%3EBest%20tip%20%3A%20browse%20SMB%20Product%20Team%20here%20%3A%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fstorage-at-microsoft%2Fstop-using-smb1%2Fba-p%2F425858%22%20target%3D%22_blank%22%3Ehttps%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fstorage-at-microsoft%2Fstop-using-smb1%2Fba-p%2F425858%3C%2FA%3E%3CBR%20%2F%3E%3CBR%20%2F%3EYou'll%20get%20detailed%20how-to%20and%20ton%20of%20tips%20directly%20from%20Microsoft.%3C%2FLINGO-BODY%3E
Occasional Contributor

Hi everyone,

I would like to get your help and advice in order to migrate successfully my production environment from SMBv1 to SMBv2/v3. In test, I'm able to implement this change but in production this change is more tricky...

Let me describes what I've done and what my production looks like:

In test:

- Implementing a GPO with the following registry changes on a test server and on the unique test domain controller I have

- Restart these servers

- Wireshark shows that SMBv1 is well disabled and that all SMB communications are in SMBv2 between my test server and my test DC.

- I’m still working on the SMBv3 implementation or switch from SMBv2 to SMBv3 (not done yet).

- I need to configure a Linux server in SMBv2/v3 and test too (not done yet).

GPO details:

1°) Disable SMBv1 in LanmanServer:
Action: Create
Hive: HKEY_LOCAL_MACHINE
Key Path: SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters
Value name: SMB1
Value type: REG_DWORD
Value data: 0

2°) Disable SMBv1 in LanmanWorkstation:
Action: Update
Hive: HKEY_LOCAL_MACHINE
Key Path: SYSTEM\CurrentControlSet\services\mrxsmb10
Value name: Start
Value type: REG_DWORD
Value data: 4 (=disable)

3°) Delete SMBv1 dependancy of the LanmanWorkstation service:
Action: Replace
Hive: HKEY_LOCAL_MACHINE
Key Path: SYSTEM\CurrentControlSet\Services\LanmanWorkstation
Value name: DependOnService
Value type REG_MULTI_SZ
Value data:
Bowser
MRxSmb20
NSI

4°) Require signing SMBv2/v3 for LanmanServer service:
Action: Update
Hive: HKEY_LOCAL_MACHINE
Key Path: SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters
Value name: RequireSecuritySignature
Value type: REG_DWORD
Value data: 1

5°) Require signing SMBv2/v3 for LanmanWorkstation server:
Action: Update
Hive: HKEY_LOCAL_MACHINE
Key Path: SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters
Value name: RequireSecuritySignature
Value type: REG_DWORD
Value data: 1

 

In production, I have a lot of servers in different AWS regions with different DC, a mix of linux servers and Windows servers. 

My challenge is to migrate without production impact. 

- Does someone has already performed this kind of migration ?

- Modifications are at the packet level, do you already experienced issue when migrating from SMBv1 to SMBv2/v3 ?

All advices are welcome! 

 

Regards,

Bernard.

 

4 Replies
Hello,

Keep in mind recent releases of Windows clients/servers do not have SMB1 enabled by default (and I hope you didn't enable it). Thus you do not need this kind of Group Policy parameters (which may really messed up OSes and are quite difficult to rollback).
What you need to look out for is :
- Very old Windows OS (Windows XP/2003) : those are a security nightmare. Get rid of them.
- Very old Unix/Linux OS : see above
- Printers and scanners still relying on SMBv1 : this is quite painful to check. You must inventory everything, then check compatibility per model and per firmware. You may need to update (or even replace entirely) printers before moving your file servers away from SMBv1.
- Apps. Test, test, test. Hope you still have editor's support for them.

Best tip : browse SMB Product Team here : https://techcommunity.microsoft.com/t5/storage-at-microsoft/stop-using-smb1/ba-p/425858

You'll get detailed how-to and ton of tips directly from Microsoft.
Hello Alban,
Thanks for your reply, I use Windows Server 2016 and I've never enabled the SMBv1 on them. This is odd, when checking via powershell SMBv1 seems enabled on my servers, I will continue to find why...
My goal was initialy to remediate a vulnerability founded which told me that smb signing wasn't enabled. But SMBv2/v3 don't use "enablesiging" registry keys, they use "RequireSecuritySignature" key instead. My main issue is to find the way to enable it without get impact on all my domain controller and member servers... If my DC require siging but my member servers don't have this setting set yet, what is the result ? network issue ? Hard to deploy it smoothly, I'm going to listen your link too. Thanks, your help is appreciated ;)
Hi Bernard,

It’s always best go with the phase wise approach by scoping few servers from each site in the GPO which disables outdated protocols.

For example if we have 10 sites and each site has got 5 servers then we can scope at least 3 servers in the GPO which disables the vulnerable protocol, this way we will have other 2 servers to serve the requests if in case if anything breaks.

In my experience even after following this approach I ran into issues with printers and file servers.

Hence I would suggest you to list all the print servers n file servers to quickly turn on this protocols if anyone raises complaints.

Keep the rollback plan ready and share it with the concerned technical teams for a quick fix.

The most important lesson I learnt from this migration is:
In my case I used GPO preferences to delete registries on servers as a rollback plan but I realised the the quick workaround (in critical sites ) to bring back the service would be to login locally on the Server or use Powershell to delete the registries real quick before the GPO deletes it.

If you are using GP preferences for creation or deletion of registries take a special care of GPO tattooing issue to avoid delays in roll back if in case anything breaks.

Regards,
Manoj

Hello Manoj94,
Thank to have take time to update my topic.
My environment doesn't have printers and file servers. it remains to me basically 2 questions:
=> Can we include domain controllers as file server if they only manage users/groups/Computer and GPO ? In conclusion can my domain communication be impacted ?
=> My servers communicate principaly through sftp/ssh or https/https, can these protocols be impacted too if I disable SMBv1 and enable requiresigning feature?
Thank you very much in advance for your support !