Try something like this: | makeresults
| fields - _time
| eval _raw="{
\"timestamp\": \"2024-03-07T07:46:27Z\",
\"eventName\": \"ProcessEvent\",
\"computer\": {
\"name\": \"randomMacBook-P...
See more...
Try something like this: | makeresults
| fields - _time
| eval _raw="{
\"timestamp\": \"2024-03-07T07:46:27Z\",
\"eventName\": \"ProcessEvent\",
\"computer\": {
\"name\": \"randomMacBook-Pro.local\",
\"uuid\": \"9b85f341-3a24-4f70-a371-8863f8a72f1c\"
},
\"processInfo\": {
\"imageName\": \"bash\",
\"pid\": 51097,
\"systemProcess\": false,
\"imagePath\": \"/bin/bash\",
\"commandLine\": \"-c pmset -g batt\",
\"exeHash\": {
\"sha1\": \"87FD78930606102F09D607FC7305996CEFA6E028\",
\"sha256\": null
},
\"sid\": \"\",
\"username\": \"randomuser:staff\",
\"sidNameUse\": 0,
\"startTime\": \"2024-03-07T07:46:27Z\",
\"currentDirPath\": \"/\",
\"isCompromised\": false,
\"lnkPath\": \"\",
\"parentProcess\": {
\"imageName\": \"randomprocess1\",
\"pid\": 51097,
\"systemProcess\": false,
\"imagePath\": \"%APPLICATIONS%/randomprocess1.app/contents/macos/randomprocess1\",
\"commandLine\": \"/Applications/RandomProcess1.app/Contents/MacOS/RandomProcess1 -runMode autoLaunched\",
\"exeHash\": {
\"sha1\": \"E31C5F2840F47A094D58A181586B802FA8531C7E\",
\"sha256\": null
},
\"sid\": \"\",
\"username\": \"randomuser:staff\",
\"sidNameUse\": 0,
\"startTime\": \"2024-03-07T07:46:27Z\",
\"currentDirPath\": \"/\",
\"isCompromised\": false,
\"lnkPath\": \"\",
\"parentProcess\": {
\"imageName\": \"randomprocess2\",
\"pid\": 603,
\"systemProcess\": false,
\"imagePath\": \"%APPLICATIONS%/randomprocess2.app/contents/macos/randomprocess2\",
\"commandLine\": \"/Applications/RandomProcess2.app/Contents/MacOS/RandomProcess2 -runMode autoLaunched\",
\"exeHash\": {
\"sha1\": \"E31C5F2840F47A094D58A181586B802FA8531C7E\",
\"sha256\": null
},
\"sid\": \"\",
\"username\": \"randomuser:staff\",
\"sidNameUse\": 0,
\"startTime\": \"2024-03-01T08:02:32Z\",
\"currentDirPath\": \"/\",
\"isCompromised\": false,
\"lnkPath\": \"\",
\"parentProcess\": {
\"imageName\": \"launchd\",
\"pid\": 603,
\"systemProcess\": false,
\"imagePath\": \"/sbin/launchd\",
\"commandLine\": \"\",
\"exeHash\": {
\"sha1\": \"AA7A8F25AE7BE3BFF0DB33A8FB0D0C49361D1176\",
\"sha256\": null
},
\"sid\": \"\",
\"username\": \"root:wheel\",
\"sidNameUse\": 0,
\"startTime\": \"2024-03-01T08:02:32Z\",
\"currentDirPath\": \"/\",
\"isCompromised\": false,
\"lnkPath\": \"\",
\"parentProcess\": {
\"imageName\": \"launchd\",
\"pid\": 1,
\"systemProcess\": false,
\"imagePath\": \"/sbin/launchd\",
\"commandLine\": \"\",
\"exeHash\": {
\"sha1\": \"AA7A8F25AE7BE3BFF0DB33A8FB0D0C49361D1176\",
\"sha256\": null
},
\"sid\": \"\",
\"username\": \"root:wheel\",
\"sidNameUse\": 0,
\"startTime\": \"2024-03-01T07:57:30Z\",
\"currentDirPath\": \"/\",
\"isCompromised\": false,
\"lnkPath\": \"\",
\"parentProcess\": {
\"imageName\": \"kernel_task\",
\"pid\": 1,
\"systemProcess\": true,
\"imagePath\": \"kernel_task\",
\"commandLine\": \"\",
\"exeHash\": {
\"sha1\": \"24BF148FA83C8A5D908C33954B5CA91A5E4E3659\",
\"sha256\": null
},
\"sid\": \"\",
\"username\": \"root:wheel\",
\"sidNameUse\": 0,
\"startTime\": \"2024-02-27T10:17:35Z\",
\"currentDirPath\": \"\",
\"isCompromised\": false,
\"lnkPath\": \"\",
\"parentProcess\": {
\"imageName\": \"kernel_task\",
\"pid\": 0,
\"systemProcess\": true,
\"imagePath\": \"kernel_task\",
\"commandLine\": \"\",
\"exeHash\": {
\"sha1\": \"24BF148FA83C8A5D908C33954B5CA91A5E4E3659\",
\"sha256\": null
},
\"sid\": \"\",
\"username\": \"root:wheel\",
\"sidNameUse\": 0,
\"startTime\": \"2024-02-27T10:17:35Z\",
\"currentDirPath\": \"\",
\"isCompromised\": false,
\"lnkPath\": \"\"
}
}
}
}
}
}
},
\"eventType\": \"Process/PosixExec\"
}"
| spath
| eval processChain='processInfo.imagePath'." ".'processInfo.commandLine'
| foreach processInfo*.parentProcess.imagePath
[| eval processChain=mvappend(processChain,'<<FIELD>>'." ".'processInfo<<MATCHSEG1>>.parentProcess.commandLine')] You end up with a multi-value field which you can use mvjoin to format as you wish