| 1 |
# WMI specific artifacts. |
| 2 |
--- |
| 3 |
name: WMIAccountUsersDomain |
| 4 |
doc: | |
| 5 |
Fill out user AD domain information based on username. |
| 6 |
|
| 7 |
We expect this artifact to be collected with WindowsRegistryProfiles |
| 8 |
to supply the rest of the user information. This artifact optimizes retrieval |
| 9 |
of user information by limiting the WMI query to users for which we have |
| 10 |
a username for. Specifically this solves the issue that in a domain setting, |
| 11 |
querying for all users via WMI will give you the list of all local and domain |
| 12 |
accounts which means a large data transfer from an Active Directory server. |
| 13 |
This artifact relies on having the users.username field populated in the knowledge |
| 14 |
base. Unfortunately even limiting by username this query can be slow, and |
| 15 |
this artifact runs it for each user present on the system. |
| 16 |
sources: |
| 17 |
- type: WMI |
| 18 |
attributes: {query: SELECT * FROM Win32_UserAccount WHERE name='%%users.username%%'} |
| 19 |
provides: [users.userdomain] |
| 20 |
supported_os: [Windows] |
| 21 |
urls: ['http://msdn.microsoft.com/en-us/library/windows/desktop/aa394507(v=vs.85).aspx'] |
| 22 |
--- |
| 23 |
name: WMIAntivirusProduct |
| 24 |
doc: Enumerate the registered antivirus. |
| 25 |
sources: |
| 26 |
- type: WMI |
| 27 |
attributes: {query: SELECT * FROM AntivirusProduct, base_object: 'winmgmts:\root\SecurityCenter2'} |
| 28 |
supported_os: [Windows] |
| 29 |
--- |
| 30 |
name: WMIComputerSystemProduct |
| 31 |
doc: Computer System Product including Identifiying number queried from WMI. |
| 32 |
sources: |
| 33 |
- type: WMI |
| 34 |
attributes: {query: SELECT * FROM Win32_ComputerSystemProduct} |
| 35 |
supported_os: [Windows] |
| 36 |
urls: ['http://msdn.microsoft.com/en-us/library/aa394105(v=vs.85).aspx'] |
| 37 |
--- |
| 38 |
name: WMIDNSClientCache |
| 39 |
doc: DNS client cache via Windows Management Instrumentation (WMI). |
| 40 |
sources: |
| 41 |
- type: WMI |
| 42 |
attributes: {query: SELECT * from MSFT_DNSClientCache, base_object: 'winmgmts:\root\StandardCimv2'} |
| 43 |
supported_os: [Windows] |
| 44 |
urls: ['https://docs.microsoft.com/en-us/previous-versions/windows/desktop/dnsclientcimprov/msft-dnsclientcache'] |
| 45 |
--- |
| 46 |
name: WMIDrivers |
| 47 |
doc: Installed drivers via Windows Management Instrumentation (WMI). |
| 48 |
sources: |
| 49 |
- type: WMI |
| 50 |
attributes: {query: 'SELECT DisplayName, Description, InstallDate, Name, PathName, Status, State, ServiceType from Win32_SystemDriver'} |
| 51 |
supported_os: [Windows] |
| 52 |
--- |
| 53 |
name: WMIEnumerateASEC |
| 54 |
doc: Enumerate instances of ActiveScriptEventConsumer. |
| 55 |
sources: |
| 56 |
- type: WMI |
| 57 |
attributes: {query: SELECT * FROM ActiveScriptEventConsumer, base_object: 'winmgmts:\root\subscription'} |
| 58 |
supported_os: [Windows] |
| 59 |
--- |
| 60 |
name: WMIEnumerateCLEC |
| 61 |
doc: Enumerate instances of CommandLineEventConsumer. |
| 62 |
sources: |
| 63 |
- type: WMI |
| 64 |
attributes: {query: SELECT * FROM CommandLineEventConsumer, base_object: 'winmgmts:\root\subscription'} |
| 65 |
supported_os: [Windows] |
| 66 |
--- |
| 67 |
name: WMIHotFixes |
| 68 |
doc: Installed hotfixes via Windows Management Instrumentation (WMI). |
| 69 |
sources: |
| 70 |
- type: WMI |
| 71 |
attributes: {query: SELECT * from Win32_QuickFixEngineering} |
| 72 |
supported_os: [Windows] |
| 73 |
--- |
| 74 |
name: WMIInstalledSoftware |
| 75 |
doc: Installed software via Windows Management Instrumentation (WMI). |
| 76 |
sources: |
| 77 |
- type: WMI |
| 78 |
attributes: {query: 'SELECT Name, Vendor, Description, InstallDate, InstallDate2, Version from Win32_Product'} |
| 79 |
supported_os: [Windows] |
| 80 |
--- |
| 81 |
name: WMILastBootupTime |
| 82 |
doc: Last system boot time (UTC) retrieved from WMI. |
| 83 |
sources: |
| 84 |
- type: WMI |
| 85 |
attributes: {query: SELECT LastBootUpTime FROM Win32_OperatingSystem} |
| 86 |
supported_os: [Windows] |
| 87 |
urls: ['https://msdn.microsoft.com/en-us/library/windows/desktop/aa394239(v=vs.85).aspx'] |
| 88 |
--- |
| 89 |
name: WMILogicalDisks |
| 90 |
doc: Disk information via Windows Management Instrumentation (WMI). |
| 91 |
sources: |
| 92 |
- type: WMI |
| 93 |
attributes: {query: SELECT * FROM Win32_LogicalDisk} |
| 94 |
supported_os: [Windows] |
| 95 |
urls: ['http://msdn.microsoft.com/en-us/library/aa394173(v=vs.85).aspx'] |
| 96 |
--- |
| 97 |
name: WMILoggedOnSessions |
| 98 |
doc: Logged on users queried from WMI. |
| 99 |
sources: |
| 100 |
- type: WMI |
| 101 |
attributes: {query: SELECT * FROM Win32_LogonSession} |
| 102 |
supported_os: [Windows] |
| 103 |
--- |
| 104 |
name: WMILoggedOnUsers |
| 105 |
doc: Logged on users queried from WMI. |
| 106 |
sources: |
| 107 |
- type: WMI |
| 108 |
attributes: {query: SELECT * FROM Win32_LoggedonUser} |
| 109 |
supported_os: [Windows] |
| 110 |
--- |
| 111 |
name: WMILoginUsers |
| 112 |
doc: | |
| 113 |
Login Users via Windows Management Instrumentation (WMI). |
| 114 |
|
| 115 |
This WMI query may take a long time to complete when run on a domain and |
| 116 |
will create load on a domain controller. |
| 117 |
sources: |
| 118 |
- type: WMI |
| 119 |
attributes: {query: SELECT * from Win32_GroupUser where Name = "login_users"} |
| 120 |
supported_os: [Windows] |
| 121 |
--- |
| 122 |
name: WMINetNeighbors |
| 123 |
doc: TCP/IP neighbors via Windows Management Instrumentation (WMI). |
| 124 |
sources: |
| 125 |
- type: WMI |
| 126 |
attributes: {query: SELECT * from MSFT_NetNeighbor, base_object: 'winmgmts:\root\StandardCimv2'} |
| 127 |
supported_os: [Windows] |
| 128 |
urls: ['https://docs.microsoft.com/en-us/previous-versions/windows/desktop/nettcpipprov/msft-netneighbor'] |
| 129 |
--- |
| 130 |
name: WMINetTCPConnections |
| 131 |
doc: TCP connections via Windows Management Instrumentation (WMI). |
| 132 |
sources: |
| 133 |
- type: WMI |
| 134 |
attributes: {query: SELECT * from MSFT_NetTCPConnection, base_object: 'winmgmts:\root\StandardCimv2'} |
| 135 |
supported_os: [Windows] |
| 136 |
urls: ['https://docs.microsoft.com/en-us/previous-versions/windows/desktop/nettcpipprov/msft-nettcpconnection'] |
| 137 |
--- |
| 138 |
name: WMINetUDPEndpoints |
| 139 |
doc: UDP endpoints via Windows Management Instrumentation (WMI). |
| 140 |
sources: |
| 141 |
- type: WMI |
| 142 |
attributes: {query: SELECT * from MSFT_NetUDPEndpoint, base_object: 'winmgmts:\root\StandardCimv2'} |
| 143 |
supported_os: [Windows] |
| 144 |
urls: ['https://docs.microsoft.com/en-us/previous-versions/windows/desktop/nettcpipprov/msft-netudpendpoint'] |
| 145 |
--- |
| 146 |
name: WMIOperatingSystem |
| 147 |
doc: Operating system installed on the computer via Windows Management Instrumentation (WMI). |
| 148 |
sources: |
| 149 |
- type: WMI |
| 150 |
attributes: {query: SELECT * from Win32_OperatingSystem} |
| 151 |
supported_os: [Windows] |
| 152 |
urls: ['https://docs.microsoft.com/en-us/windows/desktop/cimwin32prov/win32-operatingsystem'] |
| 153 |
--- |
| 154 |
name: WMIPhysicalMemory |
| 155 |
doc: Physical memory information via Windows Management Instrumentation (WMI). |
| 156 |
sources: |
| 157 |
- type: WMI |
| 158 |
attributes: {query: SELECT * from Win32_PhysicalMemory} |
| 159 |
supported_os: [Windows] |
| 160 |
urls: ["http://msdn.microsoft.com/en-us/library/aa394347%28v=vs.85%29.aspx"] |
| 161 |
--- |
| 162 |
name: WMIProcessList |
| 163 |
doc: Process listing via Windows Management Instrumentation (WMI). |
| 164 |
sources: |
| 165 |
- type: WMI |
| 166 |
attributes: {query: SELECT * from Win32_Process} |
| 167 |
supported_os: [Windows] |
| 168 |
--- |
| 169 |
name: WMIProfileUsersHomeDir |
| 170 |
doc: | |
| 171 |
Get user homedir from Win32_UserProfile based on a known user's SID. |
| 172 |
|
| 173 |
This artifact relies on having the SID field users.sid populated in the knowledge |
| 174 |
base. We expect it to be collected with WindowsRegistryProfiles to |
| 175 |
supply the rest of the user information. |
| 176 |
sources: |
| 177 |
- type: WMI |
| 178 |
attributes: {query: SELECT * FROM Win32_UserProfile WHERE SID='%%users.sid%%'} |
| 179 |
provides: [users.homedir] |
| 180 |
supported_os: [Windows] |
| 181 |
urls: ['http://msdn.microsoft.com/en-us/library/windows/desktop/ee886409(v=vs.85).aspx'] |
| 182 |
--- |
| 183 |
name: WMIScheduledTasks |
| 184 |
doc: Scheduled tasks that are registered on the computer via Windows Management Instrumentation (WMI). |
| 185 |
sources: |
| 186 |
- type: WMI |
| 187 |
attributes: {query: SELECT * from MSFT_ScheduledTask, base_object: 'winmgmts:\root\Microsoft\Windows\TaskScheduler'} |
| 188 |
supported_os: [Windows] |
| 189 |
urls: ['https://wutils.com/wmi/root/microsoft/windows/taskscheduler/msft_scheduledtask/'] |
| 190 |
--- |
| 191 |
name: WMIServices |
| 192 |
doc: Services queried from WMI. |
| 193 |
sources: |
| 194 |
- type: WMI |
| 195 |
attributes: {query: SELECT * FROM Win32_Service} |
| 196 |
supported_os: [Windows] |
| 197 |
--- |
| 198 |
name: WMIStartupCommands |
| 199 |
doc: Commands that run automatically when a user logs onto the computer system via Windows Management Instrumentation (WMI). |
| 200 |
sources: |
| 201 |
- type: WMI |
| 202 |
attributes: {query: SELECT * from Win32_StartupCommand} |
| 203 |
supported_os: [Windows] |
| 204 |
urls: ['https://docs.microsoft.com/en-us/windows/desktop/cimwin32prov/win32-startupcommand'] |
| 205 |
--- |
| 206 |
name: WMIUsers |
| 207 |
doc: | |
| 208 |
Users via Windows Management Instrumentation (WMI). |
| 209 |
|
| 210 |
Note that in a domain setup, this will probably return all users in the |
| 211 |
domain which will be expensive and slow. Consider limiting by SID like |
| 212 |
WMIProfileUsersHomeDir. |
| 213 |
sources: |
| 214 |
- type: WMI |
| 215 |
attributes: {query: SELECT * FROM Win32_UserAccount} |
| 216 |
supported_os: [Windows] |
| 217 |
urls: ['http://msdn.microsoft.com/en-us/library/windows/desktop/aa394507(v=vs.85).aspx'] |
| 218 |
--- |
| 219 |
name: WMIVolumeShadowCopies |
| 220 |
doc: A List of Volume Shadow Copies from WMI. |
| 221 |
sources: |
| 222 |
- type: WMI |
| 223 |
attributes: {query: SELECT * FROM Win32_ShadowCopy} |
| 224 |
supported_os: [Windows] |
| 225 |
--- |
| 226 |
name: WMICCMRUA |
| 227 |
doc: Enumerate instances of CCM_RecentlyUsedApps. |
| 228 |
sources: |
| 229 |
- type: WMI |
| 230 |
attributes: {query: SELECT * FROM CCM_RecentlyUsedApps, base_object: 'winmgmts:\root\ccm\SoftwareMeteringAgent'} |
| 231 |
supported_os: [Windows] |
| 232 |
urls: ['https://forensics.wiki/windows#ccm-recentlyusedapps'] |