diff --git a/thorlog/v3/process.go b/thorlog/v3/process.go index 19a8c3e..2b5839d 100644 --- a/thorlog/v3/process.go +++ b/thorlog/v3/process.go @@ -33,11 +33,7 @@ type ProcessInfo struct { Image *File `json:"image" textlog:"image,expand"` - ParentInfo struct { - Pid int32 `json:"pid" textlog:"ppid"` - Exe string `json:"exe" textlog:"parent"` - CommandLine string `json:"command" textlog:"parent_command"` - } `json:"parent_info,omitempty" textlog:",expand,omitempty"` + ParentInfo ParentProcessInfo `json:"parent_info,omitempty" textlog:",expand,omitempty"` ProcessTree StringList `json:"tree" textlog:"tree,omitempty" jsonschema:"nullable"` @@ -49,6 +45,12 @@ type ProcessInfo struct { Sections Sections `json:"sections,omitempty" textlog:"-"` } +type ParentProcessInfo struct { + Pid int32 `json:"pid" textlog:"ppid"` + Exe string `json:"exe" textlog:"parent"` + CommandLine string `json:"command" textlog:"parent_command"` +} + type Sections []Section // Section describes a memory range in a process's virtual memory.