diff options
author | Robert Watson <rwatson@FreeBSD.org> | 2001-07-05 17:10:46 +0000 |
---|---|---|
committer | Robert Watson <rwatson@FreeBSD.org> | 2001-07-05 17:10:46 +0000 |
commit | a0f75161f939e6bc72757d6a0db657a7b245bbf2 (patch) | |
tree | 12e1eac2ac7b907cb9e647b6cd5c337073cd615c /sys/fs/procfs/procfs_mem.c | |
parent | 0b848380bb7ca163535c2003a15cc5b409bb248b (diff) |
o Replace calls to p_can(..., P_CAN_xxx) with calls to p_canxxx().
The p_can(...) construct was a premature (and, it turns out,
awkward) abstraction. The individual calls to p_canxxx() better
reflect differences between the inter-process authorization checks,
such as differing checks based on the type of signal. This has
a side effect of improving code readability.
o Replace direct credential authorization checks in ktrace() with
invocation of p_candebug(), while maintaining the special case
check of KTR_ROOT. This allows ktrace() to "play more nicely"
with new mandatory access control schemes, as well as making its
authorization checks consistent with other "debugging class"
checks.
o Eliminate "privused" construct for p_can*() calls which allowed the
caller to determine if privilege was required for successful
evaluation of the access control check. This primitive is currently
unused, and as such, serves only to complicate the API.
Approved by: ({procfs,linprocfs} changes) des
Obtained from: TrustedBSD Project
Notes
Notes:
svn path=/head/; revision=79335
Diffstat (limited to 'sys/fs/procfs/procfs_mem.c')
-rw-r--r-- | sys/fs/procfs/procfs_mem.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/fs/procfs/procfs_mem.c b/sys/fs/procfs/procfs_mem.c index e109146289b3..dcba9b095ef5 100644 --- a/sys/fs/procfs/procfs_mem.c +++ b/sys/fs/procfs/procfs_mem.c @@ -263,7 +263,7 @@ procfs_domem(curp, p, pfs, uio) * All in all, quite yucky. */ - if (p_can(curp, p, P_CAN_DEBUG, NULL) && + if (p_candebug(curp, p) && !(uio->uio_rw == UIO_READ && procfs_kmemaccess(curp))) return EPERM; |