Skip to content

Instantly share code, notes, and snippets.

@ezeeetm
Created April 12, 2016 19:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ezeeetm/e55bbb1ee7c389a20726029211c76c71 to your computer and use it in GitHub Desktop.
Save ezeeetm/e55bbb1ee7c389a20726029211c76c71 to your computer and use it in GitHub Desktop.
# Note: the script below is to determine the SMB version of a standalone Windows system
# If you are checking a file server or other system with known active SMB connections, simply run Get-SmbConnection in admin shell,
# and observe the various negotiated SMB dialects of the individual sessions
$loopBack = dir \\localhost\c$
$smbVer = Get-SmbConnection -ServerName localhost | Select Dialect | Sort-Object -Unique
$smbVer
<#
This will return something like:
Dialect
-------
3.02
The values listed under 'Dialect' represent the Samba version
#>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment