Smack: Make the syslog control configurable
The syslog control requires that the calling proccess have the floor ("_") Smack label. Tizen does not run any processes except for kernel helpers with the floor label. This changes allows the admin to configure a specific label for syslog. The default value is the star ("*") label, effectively removing the restriction. The value can be set using smackfs/syslog for anyone who wants a more restrictive behavior. Targeted for git://git.gitorious.org/smack-next/kernel.git Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>
This commit is contained in:
@@ -219,8 +219,6 @@ static int smack_ptrace_traceme(struct task_struct *ptp)
|
||||
* smack_syslog - Smack approval on syslog
|
||||
* @type: message type
|
||||
*
|
||||
* Require that the task has the floor label
|
||||
*
|
||||
* Returns 0 on success, error code otherwise.
|
||||
*/
|
||||
static int smack_syslog(int typefrom_file)
|
||||
@@ -231,7 +229,7 @@ static int smack_syslog(int typefrom_file)
|
||||
if (smack_privileged(CAP_MAC_OVERRIDE))
|
||||
return 0;
|
||||
|
||||
if (skp != &smack_known_floor)
|
||||
if (smack_syslog_label != NULL && smack_syslog_label != skp)
|
||||
rc = -EACCES;
|
||||
|
||||
return rc;
|
||||
|
Reference in New Issue
Block a user