diff options
| author | Stephen D. Smalley <sds@tycho.nsa.gov> | 2005-03-09 16:28:59 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-03-09 16:28:59 -0800 |
| commit | dc3149bd0e300d0fcd245aef94cbbd71bc7ec0ab (patch) | |
| tree | 186a504dd9a8df8bdb3a87a44f596c40148af8b4 /scripts/Lindent | |
| parent | 78b96d12feb4384b623d4e31876d909983978ebf (diff) | |
[PATCH] SELinux: fix selinux_setprocattr
This patch changes the selinux_setprocattr hook function (which handles
writes to nodes in the /proc/pid/attr directory) to ignore an optional
terminating newline at the end of the value, and to handle a value
beginning with a newline or a null in the same manner as a zero length
value (clearing the attribute for the process and resetting it to using the
default policy behavior). This change is to address the divergence from
POSIX in the existing API, as POSIX says that write(2) with a zero count
will return zero with no other effect, as well as to simplify use of the
API from scripts (although that isn't recommended).
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'scripts/Lindent')
0 files changed, 0 insertions, 0 deletions
