From bf14cecdac28e331cbb73b33c3b95ad6a44a66cf Mon Sep 17 00:00:00 2001 From: Alexandre B Date: Sat, 14 Sep 2024 16:38:39 -0400 Subject: [PATCH] Update powershell.md --- assets/powershell.md | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/assets/powershell.md b/assets/powershell.md index 1711c548d..0fc2048af 100644 --- a/assets/powershell.md +++ b/assets/powershell.md @@ -92,20 +92,23 @@ Get-Process -Id 10500 | Stop-Process ## Get-WmiObject -Get-WmiObject has a parameter called -Class this allows you to specify the -WMI object you wish to access. The command below will get a list of WMI -classes, -Get-WmiObject -List -Class Win32* -Once you know the name of the WMI class, you can execute Get-WmiObject -to return useful information from a local or remote computer. Below is a list +__Get-WmiObject__ has a parameter called -Class this allows you to specify the WMI object you wish to access. The command below will get a list of WMI +classes, Get-WmiObject -List -Class Win32* + + +Once you know the name of the WMI class, you can execute __Get-WmiObject__ to return useful information from a local or remote computer. Below is a list of the most important WMI classes you may need: -Win32_PhysicalMemory - information about available memory -Win32_Processor - Processor information -Win32_LogicalDisk - Logical disk drive information -Win32_DiskDrive - Physical disk information -Win32_OperatingSystem - Information about the operating system +- Win32_PhysicalMemory - information about available memory +- Win32_Processor - Processor information +- Win32_LogicalDisk - Logical disk drive information +- Win32_DiskDrive - Physical disk information +- Win32_OperatingSystem - Information about the operating system + To get information about the operating system, run the command below: + +``` Get-WmiObject -Class Win32_OperatingSystem +```