diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-08-01 13:26:23 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-08-01 13:26:23 -0400 |
commit | a0e881b7c189fa2bd76c024dbff91e79511c971d (patch) | |
tree | 0c801918565b08921d21aceee5b326f64d998f5f /kernel/audit.c | |
parent | eff0d13f3823f35d70228cd151d2a2c89288ff32 (diff) | |
parent | dbc6e0222d79e78925fe20733844a796a4b72cf9 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull second vfs pile from Al Viro:
"The stuff in there: fsfreeze deadlock fixes by Jan (essentially, the
deadlock reproduced by xfstests 068), symlink and hardlink restriction
patches, plus assorted cleanups and fixes.
Note that another fsfreeze deadlock (emergency thaw one) is *not*
dealt with - the series by Fernando conflicts a lot with Jan's, breaks
userland ABI (FIFREEZE semantics gets changed) and trades the deadlock
for massive vfsmount leak; this is going to be handled next cycle.
There probably will be another pull request, but that stuff won't be
in it."
Fix up trivial conflicts due to unrelated changes next to each other in
drivers/{staging/gdm72xx/usb_boot.c, usb/gadget/storage_common.c}
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (54 commits)
delousing target_core_file a bit
Documentation: Correct s_umount state for freeze_fs/unfreeze_fs
fs: Remove old freezing mechanism
ext2: Implement freezing
btrfs: Convert to new freezing mechanism
nilfs2: Convert to new freezing mechanism
ntfs: Convert to new freezing mechanism
fuse: Convert to new freezing mechanism
gfs2: Convert to new freezing mechanism
ocfs2: Convert to new freezing mechanism
xfs: Convert to new freezing code
ext4: Convert to new freezing mechanism
fs: Protect write paths by sb_start_write - sb_end_write
fs: Skip atime update on frozen filesystem
fs: Add freezing handling to mnt_want_write() / mnt_drop_write()
fs: Improve filesystem freezing handling
switch the protection of percpu_counter list to spinlock
nfsd: Push mnt_want_write() outside of i_mutex
btrfs: Push mnt_want_write() outside of i_mutex
fat: Push mnt_want_write() outside of i_mutex
...
Diffstat (limited to 'kernel/audit.c')
-rw-r--r-- | kernel/audit.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/kernel/audit.c b/kernel/audit.c index 4a3f28d2ca65..ea3b7b6191c7 100644 --- a/kernel/audit.c +++ b/kernel/audit.c | |||
@@ -1456,6 +1456,27 @@ void audit_log_key(struct audit_buffer *ab, char *key) | |||
1456 | } | 1456 | } |
1457 | 1457 | ||
1458 | /** | 1458 | /** |
1459 | * audit_log_link_denied - report a link restriction denial | ||
1460 | * @operation: specific link opreation | ||
1461 | * @link: the path that triggered the restriction | ||
1462 | */ | ||
1463 | void audit_log_link_denied(const char *operation, struct path *link) | ||
1464 | { | ||
1465 | struct audit_buffer *ab; | ||
1466 | |||
1467 | ab = audit_log_start(current->audit_context, GFP_KERNEL, | ||
1468 | AUDIT_ANOM_LINK); | ||
1469 | audit_log_format(ab, "op=%s action=denied", operation); | ||
1470 | audit_log_format(ab, " pid=%d comm=", current->pid); | ||
1471 | audit_log_untrustedstring(ab, current->comm); | ||
1472 | audit_log_d_path(ab, " path=", link); | ||
1473 | audit_log_format(ab, " dev="); | ||
1474 | audit_log_untrustedstring(ab, link->dentry->d_inode->i_sb->s_id); | ||
1475 | audit_log_format(ab, " ino=%lu", link->dentry->d_inode->i_ino); | ||
1476 | audit_log_end(ab); | ||
1477 | } | ||
1478 | |||
1479 | /** | ||
1459 | * audit_log_end - end one audit record | 1480 | * audit_log_end - end one audit record |
1460 | * @ab: the audit_buffer | 1481 | * @ab: the audit_buffer |
1461 | * | 1482 | * |