On Mon, May 02, 2016 at 12:23:33PM -0500, Goldwyn Rodrigues wrote: > From: Goldwyn Rodrigues <[email protected]> > > We need to initialize common_audit_data so that no garbage comes > in the structure. This fixes the following crash:
> Signed-off-by: Goldwyn Rodrigues <[email protected]> Acked-by: Seth Arnold <[email protected]> Looks good to me, of course John can take it or leave it as he wishes. Thanks > diff --git a/security/apparmor/file.c b/security/apparmor/file.c > index 913f377..6d4898c 100644 > --- a/security/apparmor/file.c > +++ b/security/apparmor/file.c > @@ -108,10 +108,11 @@ int aa_audit_file(struct aa_profile *profile, struct > file_perms *perms, > const char *target, kuid_t ouid, const char *info, int error) > { > int type = AUDIT_APPARMOR_AUTO; > - struct common_audit_data sa; > struct apparmor_audit_data aad = {0,}; > - sa.type = LSM_AUDIT_DATA_NONE; > - sa.aad = &aad; > + struct common_audit_data sa = { > + .type = LSM_AUDIT_DATA_NONE, > + .aad = &aad > + }; > aad.op = op, > aad.fs.request = request; > aad.name = name; >
signature.asc
Description: PGP signature
-- AppArmor mailing list [email protected] Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/apparmor
