Please Open an issue if there are any problems or requests.
Are we Windows System Tools? Windows Security Tools? Windows Server Tools? Yes and no. WSTools are all those things and more. Whatever you decide you want to call WSTools is up to you! However, officially, we are Wandering Stag Tools (WSTools). WSTools was written for System Administrators, Help Desk Technicians, and other Network Operations personnel to automate tasks and provide valuable tools. As of May 2023 there are over 330 functions in this module. Some functionality includes:
- Active Directory functions, reports, and shortcuts allowing for easier domain management and awareness
- Computer/Server Management
- Install/uninstall software
- Remediation tasks such as disabling vulnerable SCHANNEL settings
- Set network and system settings
- Reports
- PowerShell snippets in PowerShell ISE and VS Code for easier coding
- Conversions such as image files to base64, int64 to/from IP, uint16 to string
- PowerShell: Most functions in this module have been updated to require version 3 or version 5. Some plans have been made to add some functions that require version 7. Check your version of PowerShell by entering the following command:
$host
Then look at theVersion
attribute. - Active Directory PowerShell module: Not needed for everything but is necessary for 30+ functions.
- NetIQ DRA PowerShell REST Extensions: Not needed for many functions at the moment but there are plans to add more.
- Local Admin Password Solution (LAPS): Actual module name: AdmPwd.PS. There are a handful of functions that require the full install of LAPS to get the module and not just the basic install. However, if you are not using LAPS on your network then there are no worries.
- Microsoft.Exchange.Management.PowerShell.Admin PSSnapin: Required for the very few Exchange server related functions.
-
Install from the PowerShell Gallery using this command:
Install-Module WSTools
-
For only the current user, use this command:
Install-Module WSTools -Scope CurrentUser
General Configuration
- Open PowerShell.
- Type
Set-WSToolsConfig
and then pressEnter
. In the file that opens you will need to update the values so they work on your network.Recommend copying this file (config.ps1) to another location after you modify it so if you download a newer version of WSTools you can just paste the config file back unless there are changes in the config file.
Remote installation of .msu files and a select few other things:
- Open WSTools Module Path then edit InstallRemote.ps1
Typically C:\Program Files\WindowsPowerShell\Modules\WSTools\VersionNumber or C:\Users\<USERNAME>\Documents\WindowsPowerShell\Modules\WSTools\VersionNumber
- On Line 1 of InstallRemote.ps1 change the value of $PatchFolderPath to the directory on remote computers you store windows updates. This is predefined as "C:\Patches".
For adding the Visual Studio Code PowerShell Snippets do the following:
- Open PowerShell.
- Type the following command:
Set-PowerShellJSON
or
- Open the WSTools folder
Typically C:\Program Files\WindowsPowerShell\Modules\WSTools\VersionNumber or C:\Users\<USERNAME>\Documents\WindowsPowerShell\Modules\WSTools\VersionNumber
- Cut and paste powershell.json to %AppData%\Roaming\Code\User\Snippets directory.
or
- Open powershell.json (located in the WSTools module folder) and copy the text then in VSCode Command Palette (Ctrl + Shift + P)
- Type Snippet and select Preferences: Configure User Snippets.
- Type PowerShell then press Enter.
- Select powershell.json.
- Paste the copied text between the { } brackets and save the file.
get more open commands here: https://sysadminstricks.com/tricks/most-useful-microsoft-management-console-snap-in-control-files-msc-files.html