Skip to content

Commit f7e8dc5

Browse files
committed
fix(processors): Skip hidden registry keys
If the registry value is found within the hidden key, skip reading the value as it would inevitably fail.
1 parent e5e91ca commit f7e8dc5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

internal/etw/processors/registry_windows.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,11 @@ func (r *registryProcessor) processEvent(e *kevent.Kevent) (*kevent.Kevent, erro
124124
return e, nil
125125
}
126126

127+
// values within hidden keys cannot be read
128+
if strings.HasSuffix(keyName, "\\") {
129+
return e, nil
130+
}
131+
127132
rootkey, subkey := key.Format(keyName)
128133
if rootkey != key.Invalid {
129134
typ, val, err := rootkey.ReadValue(subkey)

0 commit comments

Comments
 (0)