fix(aa-log): ensure we also split quote in log value

fix #229
This commit is contained in:
Alexandre Pujol 2024-10-02 21:06:45 +01:00
parent 3f98e86e24
commit 14a5d8deae
No known key found for this signature in database
GPG key ID: C5469996F0DF68EC
3 changed files with 28 additions and 1 deletions

View file

@ -267,6 +267,27 @@ func TestNew(t *testing.T) {
},
},
},
{
name: "startplasma",
path: filepath.Join(testdata, "audit.log"),
want: AppArmorLogs{
{
"apparmor": "ALLOWED",
"operation": "link",
"class": "file",
"profile": "startplasma",
"name": "@{user_cache_dirs}/ksycoca5_de_LQ6f0J2qZg4vOKgw2NbXuW7iuVU=.isNSBz",
"target": "@{user_cache_dirs}/#@{int}",
"comm": "startplasma-way",
"denied_mask": "k",
"requested_mask": "k",
"fsuid": "1000",
"ouid": "1000",
"FSUID": "user",
"OUID": "user",
},
},
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {