1 From: John Johansen <jjohansen@suse.de>
2 Subject: AppArmor: reintroduce ATTR_FILE
4 The fsetattr patch removed ATTR_FILE but AppArmor needs it to distinguish
7 Note: Now that LSMs must be static, it would be better to add a file
8 pointer argument to security_operations->inode_setattr() instead. Then
9 move the fs.h chunk to patches.apparmor/fsetattr-restore-ia_file. -jeffm
11 Signed-off-by: John Johansen <jjohansen@suse.de>
15 1 file changed, 3 insertions(+)
19 @@ -208,6 +208,9 @@ int do_truncate(struct dentry *dentry, s
20 newattrs.ia_size = length;
21 newattrs.ia_valid = ATTR_SIZE | time_attrs;
24 + newattrs.ia_valid |= ATTR_FILE;
26 /* Remove suid/sgid on truncate too */
27 newattrs.ia_valid |= should_remove_suid(dentry);