summaryrefslogtreecommitdiffstats
path: root/sys/security
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2009-07-01 16:56:56 +0000
committerrwatson <rwatson@FreeBSD.org>2009-07-01 16:56:56 +0000
commit9f2c78b3f9e8fee455c43e6025959a41def8d05c (patch)
tree17df965f74c1db32b96f98787ed33d0f1a9ef39d /sys/security
parent53a5aa36f727a7601d32284c8e756c3469b6ccd7 (diff)
downloadFreeBSD-src-9f2c78b3f9e8fee455c43e6025959a41def8d05c.zip
FreeBSD-src-9f2c78b3f9e8fee455c43e6025959a41def8d05c.tar.gz
When auditing unmount(2), capture FSID arguments as regular text strings
rather than as paths, which would lead to them being treated as relative pathnames and hence confusingly converted into absolute pathnames. Capture flags to unmount(2) via an argument token. Approved by: re (audit argument blanket) MFC after: 3 days
Diffstat (limited to 'sys/security')
-rw-r--r--sys/security/audit/audit_bsm.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/security/audit/audit_bsm.c b/sys/security/audit/audit_bsm.c
index 1eb9679..4b2b6f1 100644
--- a/sys/security/audit/audit_bsm.c
+++ b/sys/security/audit/audit_bsm.c
@@ -1070,7 +1070,15 @@ kaudit_to_bsm(struct kaudit_record *kar, struct au_record **pau)
break;
case AUE_UMOUNT:
+ if (ARG_IS_VALID(kar, ARG_VALUE)) {
+ tok = au_to_arg32(1, "flags", ar->ar_arg_value);
+ kau_write(rec, tok);
+ }
UPATH1_VNODE1_TOKENS;
+ if (ARG_IS_VALID(kar, ARG_TEXT)) {
+ tok = au_to_text(ar->ar_arg_text);
+ kau_write(rec, tok);
+ }
break;
case AUE_MSGCTL:
OpenPOWER on IntegriCloud