Add `WMI` activity telemetry

Abierto
#710 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
35/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Tranquilo
Stack tecnológico
go
Área
security

Línea de trabajo

Start with the existing WMI telemetry work the issue refers to, and with how the ParamDecoder decodes event payloads. The change adds four event types from the Microsoft-Windows-WMI-Activity provider: event 11 on the /Trace channel as Wmi, and events 5859 and 5861 on /Operational as SubscribeWmiFilter and BindWmiFilter. Done means each event is subscribed to, decoded with the listed fields, and covered by decoder tests using sample payloads.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

needs: config scope: events/telemetry type: feature

Motivation

WMI is a common vector for lateral movement, remote execution, and persistence (e.g. Win32_Process::Create, permanent WMI event subscriptions via __EventFilter/__EventConsumer/__FilterToConsumerBinding). Fibratus has no visibility into WMI activity today. The Microsoft-Windows-WMI-Activity provider exposes both live operation calls (OperationStart) and the operational-log events that track event filter registration, consumer execution, and filter-to-consumer bindings. This is the exact mechanism abused for WMI-based persistence.

Expectation

Fibratus gains new event types sourced from the Microsoft-Windows-WMI-Activity provider.

Event ID Channel Fibratus event type Purpose
11 /Trace Wmi Every IWbemServices call (OperationStart)
5859 /Operational SubscribeWmiFilter A registered event filter's notification query is activated against a provider
5861 /Operational BindWmiFilter An __EventFilter is bound to a __EventConsumer. This is the classic permanent-subscription persistence mechanism

Proposal

  • Attach to both the Microsoft-Windows-WMI-Activity/Trace and Microsoft-Windows-WMI-Activity/Operational channels

  • Event 11 (OperationStart, version 0) maps to Wmi event type as previously specified: CorrelationId (string), GroupOperationId (uint32), OperationId (uint32), Operation (string represents the IWbemServices::() call, e.g. ExecQuery/GetObject/PutInstance/DeleteInstance/ExecMethod/CreateClass), ClientMachine (string), ClientMachineFQDN (string), User (string), ClientProcessId (uint32), ClientProcessCreationTime (uint64), NamespaceName (string), IsLocal (bool)

  • Event 5859 (version 0) maps to SubscribeWmiFilter event type:

Field Type Notes
NamespaceName string WMI namespace the filter is registered in
Query string The notification query (NotificationQuery). The WQL filter text, e.g. SELECT * FROM __InstanceCreationEvent...
User string Owner of the filter (OwnerName)
processid uint32 Hosting process ID (HostProcessID)
providerName string WMI provider servicing the query
queryid uint32 Query identifier
PossibleCause string Diagnostic hint supplied by WMI
  • Event 5861 (version 0) maps to BindWmiFilter event type.
Field Type Notes
Namespace string Namespace containing the binding
ESS string The __EventFilter name (event message calls this Eventfilter; correlates to the filter activated in event 5859)
CONSUMER string The __EventConsumer name the filter is bound to
PossibleCause string Diagnostic hint supplied by WMI
  • Decode all four event types via the ParamDecoder, consistent with the rest of the WMI telemetry work
Lenguaje dominante
Go
Estrellas
2.6k
Forks
222
Merge medio
16 h 23 min
PR fusionados (30 d)
11

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de rabbitstack/fibratus

Todos los issues de rabbitstack/fibratus

Issues similares

Más issues de Go

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.