返回顶部

Powershell操作wmi

Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_Share #共享
Get-WmiObject -Namespace ROOT\CIMV2 -Class CIM_DataFile #⽂件/⽬录列表
Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_Volume #磁盘卷列表
Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_Process #当前进程
Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_Service #列举服务
Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_NtLogEvent #⽇志
Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_LoggedOnUser #登陆账户
Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_QuickFixEngineering #补丁
Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct #杀毒软件
###操作系统相关信息 Get
-WmiObject -Namespace ROOT\CIMV2 -Class Win32_OperatingSystem Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_ComputerSystem Get-WmiObject -Namespace ROOT\CIMV2 -Class Win32_BIOS ###
###注册表操作 Get
-WmiObject -Namespace ROOT\DEFAULT -Class StdRegProv
Push
-Location HKLM:SOFTWARE\Microsoft\Windows\CurrentVersion\Run Get-ItemProperty OptionalComponents

 

posted @ 2021-09-07 15:54  御用闲人  阅读(319)  评论(0编辑  收藏  举报