]> git.baikalelectronics.ru Git - kernel.git/commit
Audit: do not print error when LSMs disabled
authorEric Paris <eparis@redhat.com>
Tue, 23 Oct 2012 12:58:35 +0000 (08:58 -0400)
committerEric Paris <eparis@redhat.com>
Thu, 11 Apr 2013 19:39:10 +0000 (15:39 -0400)
commitf5bf1c0ae9c5aaa2e0c37b154bf1d5a826740254
tree66a12a3d4a18a6cca40466462cf9737df0f9f0b7
parent67184800c6c447fccf1dccbf077bab9f3fa6fc6b
Audit: do not print error when LSMs disabled

RHBZ: 785936

If the audit system collects a record about one process sending a signal
to another process it includes in that collection the 'secid' or 'an int
used to represet an LSM label.'  If there is no LSM enabled it will
collect a 0.  The problem is that when we attempt to print that record
we ask the LSM to convert the secid back to a string.  Since there is no
LSM it returns EOPNOTSUPP.

Most code in the audit system checks if the secid is 0 and does not
print LSM info in that case.  The signal information code however forgot
that check.  Thus users will see a message in syslog indicating that
converting the sid to string failed.  Add the right check.

Signed-off-by: Eric Paris <eparis@redhat.com>
kernel/auditsc.c