mirror of
https://github.com/roddhjav/apparmor.d.git
synced 2025-01-29 22:35:15 +01:00
feat(aa-log): also decode comm.
This commit is contained in:
parent
f20ccedf4f
commit
6665e3861f
1 changed files with 7 additions and 3 deletions
|
@ -189,9 +189,13 @@ func NewApparmorLogs(file io.Reader, profile string) AppArmorLogs {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
aa["profile"] = decodeHex(aa["profile"])
|
aa["profile"] = decodeHex(aa["profile"])
|
||||||
if name, ok := aa["name"]; ok {
|
toDecode := []string{"profile", "name", "comm"}
|
||||||
aa["name"] = decodeHex(name)
|
for _, name := range toDecode {
|
||||||
|
if value, ok := aa[name]; ok {
|
||||||
|
aa[name] = decodeHex(value)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
aaLogs = append(aaLogs, aa)
|
aaLogs = append(aaLogs, aa)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -285,7 +289,7 @@ func init() {
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
flag.Parse()
|
||||||
if help {
|
if help {
|
||||||
fmt.Printf(`aa-log [-h] [-d] [-f file] [profile]
|
fmt.Printf(`aa-log [-h] [-s] [-f file] [profile]
|
||||||
|
|
||||||
Review AppArmor generated messages in a colorful way.
|
Review AppArmor generated messages in a colorful way.
|
||||||
It can be given an optional profile name to filter the output with.
|
It can be given an optional profile name to filter the output with.
|
||||||
|
|
Loading…
Reference in a new issue