<feed xmlns='http://www.w3.org/2005/Atom'>
<title>talos-op-linux/security/selinux/ss/conditional.c, branch master</title>
<subtitle>Talos™ II Linux sources for OpenPOWER</subtitle>
<id>https://git.raptorcs.com/git/talos-op-linux/atom?h=master</id>
<link rel='self' href='https://git.raptorcs.com/git/talos-op-linux/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/'/>
<updated>2019-06-05T15:37:10+00:00</updated>
<entry>
<title>treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 372</title>
<updated>2019-06-05T15:37:10+00:00</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2019-05-31T08:09:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=a10e763b87134a9a4ca3a38b5c4b533e75ec63a3'/>
<id>urn:sha1:a10e763b87134a9a4ca3a38b5c4b533e75ec63a3</id>
<content type='text'>
Based on 1 normalized pattern(s):

  this program is free software you can redistribute it and or modify
  it under the terms of the gnu general public license as published by
  the free software foundation version 2

extracted by the scancode license scanner the SPDX license identifier

  GPL-2.0-only

has been chosen to replace the boilerplate/reference in 135 file(s).

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Allison Randal &lt;allison@lohutok.net&gt;
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190531081036.435762997@linutronix.de
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>selinux: convert to kvmalloc</title>
<updated>2019-03-12T17:04:02+00:00</updated>
<author>
<name>Kent Overstreet</name>
<email>kent.overstreet@gmail.com</email>
</author>
<published>2019-03-12T06:31:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=acdf52d97f824019888422842757013b37441dd1'/>
<id>urn:sha1:acdf52d97f824019888422842757013b37441dd1</id>
<content type='text'>
The flex arrays were being used for constant sized arrays, so there's no
benefit to using flex_arrays over something simpler.

Link: http://lkml.kernel.org/r/20181217131929.11727-4-kent.overstreet@gmail.com
Signed-off-by: Kent Overstreet &lt;kent.overstreet@gmail.com&gt;
Cc: Paul Moore &lt;paul@paul-moore.com&gt;
Cc: Stephen Smalley &lt;sds@tycho.nsa.gov&gt;
Cc: Eric Paris &lt;eparis@parisplace.org&gt;
Cc: Alexey Dobriyan &lt;adobriyan@gmail.com&gt;
Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Cc: Dave Hansen &lt;dave.hansen@intel.com&gt;
Cc: Marcelo Ricardo Leitner &lt;marcelo.leitner@gmail.com&gt;
Cc: Matthew Wilcox &lt;willy@infradead.org&gt;
Cc: Neil Horman &lt;nhorman@tuxdriver.com&gt;
Cc: Pravin B Shelar &lt;pshelar@ovn.org&gt;
Cc: Shaohua Li &lt;shli@kernel.org&gt;
Cc: Vlad Yasevich &lt;vyasevich@gmail.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>selinux: Cleanup printk logging in conditional</title>
<updated>2018-06-19T15:39:12+00:00</updated>
<author>
<name>peter enderborg</name>
<email>peter.enderborg@sony.com</email>
</author>
<published>2018-06-12T08:09:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=ab48576c4298f7d8cd93e78f085841a05967e125'/>
<id>urn:sha1:ab48576c4298f7d8cd93e78f085841a05967e125</id>
<content type='text'>
Replace printk with pr_* to avoid checkpatch warnings.

Signed-off-by: Peter Enderborg &lt;peter.enderborg@sony.com&gt;
Signed-off-by: Paul Moore &lt;paul@paul-moore.com&gt;
</content>
</entry>
<entry>
<title>selinux: remove redundant assignment to len</title>
<updated>2017-10-16T22:37:23+00:00</updated>
<author>
<name>Colin Ian King</name>
<email>colin.king@canonical.com</email>
</author>
<published>2017-10-14T15:00:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=73e4977873bfbd8698d5b116ba32d48f2a889276'/>
<id>urn:sha1:73e4977873bfbd8698d5b116ba32d48f2a889276</id>
<content type='text'>
The variable len is being set to zero and this value is never
being read since len is being set to a different value just
a few lines later.  Remove this redundant assignment. Cleans
up clang warning: Value stored to 'len' is never read

Signed-off-by: Colin Ian King &lt;colin.king@canonical.com&gt;
Signed-off-by: Paul Moore &lt;paul@paul-moore.com&gt;
</content>
</entry>
<entry>
<title>selinux: Improve size determinations in four functions</title>
<updated>2017-03-23T20:29:02+00:00</updated>
<author>
<name>Markus Elfring</name>
<email>elfring@users.sourceforge.net</email>
</author>
<published>2017-01-14T10:22:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=fb13a312daa11005b0230695a1d6a0b4e2b27069'/>
<id>urn:sha1:fb13a312daa11005b0230695a1d6a0b4e2b27069</id>
<content type='text'>
Replace the specification of data structures by pointer dereferences
as the parameter for the operator "sizeof" to make the corresponding size
determination a bit safer.

Signed-off-by: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Signed-off-by: Paul Moore &lt;paul@paul-moore.com&gt;
</content>
</entry>
<entry>
<title>selinux: Delete an unnecessary return statement in cond_compute_av()</title>
<updated>2017-03-23T20:25:42+00:00</updated>
<author>
<name>Markus Elfring</name>
<email>elfring@users.sourceforge.net</email>
</author>
<published>2017-01-14T10:00:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=e34cfef901badc0e17c2b296a535e7412ef038f3'/>
<id>urn:sha1:e34cfef901badc0e17c2b296a535e7412ef038f3</id>
<content type='text'>
The script "checkpatch.pl" pointed information out like the following.

WARNING: void function return statements are not generally useful

Thus remove such a statement in the affected function.

Signed-off-by: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Signed-off-by: Paul Moore &lt;paul@paul-moore.com&gt;
</content>
</entry>
<entry>
<title>selinux: Use kmalloc_array() in cond_init_bool_indexes()</title>
<updated>2017-03-23T20:21:41+00:00</updated>
<author>
<name>Markus Elfring</name>
<email>elfring@users.sourceforge.net</email>
</author>
<published>2017-01-14T09:48:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=f6076f704aa29679fdba114b0f60e71e0884840a'/>
<id>urn:sha1:f6076f704aa29679fdba114b0f60e71e0884840a</id>
<content type='text'>
* A multiplication for the size determination of a memory allocation
  indicated that an array data structure should be processed.
  Thus use the corresponding function "kmalloc_array".

  This issue was detected by using the Coccinelle software.

* Replace the specification of a data type by a pointer dereference
  to make the corresponding size determination a bit safer according to
  the Linux coding style convention.

Signed-off-by: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Signed-off-by: Paul Moore &lt;paul@paul-moore.com&gt;
</content>
</entry>
<entry>
<title>selinux: fix overflow and 0 length allocations</title>
<updated>2016-08-30T19:45:50+00:00</updated>
<author>
<name>William Roberts</name>
<email>william.c.roberts@intel.com</email>
</author>
<published>2016-08-30T16:28:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=7c686af071ade663d0995aa30b262495a6c68c88'/>
<id>urn:sha1:7c686af071ade663d0995aa30b262495a6c68c88</id>
<content type='text'>
Throughout the SELinux LSM, values taken from sepolicy are
used in places where length == 0 or length == &lt;saturated&gt;
matter, find and fix these.

Signed-off-by: William Roberts &lt;william.c.roberts@intel.com&gt;
Signed-off-by: Paul Moore &lt;paul@paul-moore.com&gt;
</content>
</entry>
<entry>
<title>selinux: fix bug in conditional rules handling</title>
<updated>2015-11-24T18:44:32+00:00</updated>
<author>
<name>Stephen Smalley</name>
<email>sds@tycho.nsa.gov</email>
</author>
<published>2015-11-23T21:07:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=f3bef67992e8698897b584616535803887c4a73e'/>
<id>urn:sha1:f3bef67992e8698897b584616535803887c4a73e</id>
<content type='text'>
commit fa1aa143ac4a ("selinux: extended permissions for ioctls")
introduced a bug into the handling of conditional rules, skipping the
processing entirely when the caller does not provide an extended
permissions (xperms) structure.  Access checks from userspace using
/sys/fs/selinux/access do not include such a structure since that
interface does not presently expose extended permission information.
As a result, conditional rules were being ignored entirely on userspace
access requests, producing denials when access was allowed by
conditional rules in the policy.  Fix the bug by only skipping
computation of extended permissions in this situation, not the entire
conditional rules processing.

Reported-by: Laurent Bigonville &lt;bigon@debian.org&gt;
Signed-off-by: Stephen Smalley &lt;sds@tycho.nsa.gov&gt;
[PM: fixed long lines in patch description]
Cc: stable@vger.kernel.org # 4.3
Signed-off-by: Paul Moore &lt;pmoore@redhat.com&gt;
</content>
</entry>
<entry>
<title>selinux: extended permissions for ioctls</title>
<updated>2015-07-13T17:31:58+00:00</updated>
<author>
<name>Jeff Vander Stoep</name>
<email>jeffv@google.com</email>
</author>
<published>2015-07-10T21:19:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-op-linux/commit/?id=fa1aa143ac4a682c7f5fd52a3cf05f5a6fe44a0a'/>
<id>urn:sha1:fa1aa143ac4a682c7f5fd52a3cf05f5a6fe44a0a</id>
<content type='text'>
Add extended permissions logic to selinux. Extended permissions
provides additional permissions in 256 bit increments. Extend the
generic ioctl permission check to use the extended permissions for
per-command filtering. Source/target/class sets including the ioctl
permission may additionally include a set of commands. Example:

allowxperm &lt;source&gt; &lt;target&gt;:&lt;class&gt; ioctl unpriv_app_socket_cmds
auditallowxperm &lt;source&gt; &lt;target&gt;:&lt;class&gt; ioctl priv_gpu_cmds

Where unpriv_app_socket_cmds and priv_gpu_cmds are macros
representing commonly granted sets of ioctl commands.

When ioctl commands are omitted only the permissions are checked.
This feature is intended to provide finer granularity for the ioctl
permission that may be too imprecise. For example, the same driver
may use ioctls to provide important and benign functionality such as
driver version or socket type as well as dangerous capabilities such
as debugging features, read/write/execute to physical memory or
access to sensitive data. Per-command filtering provides a mechanism
to reduce the attack surface of the kernel, and limit applications
to the subset of commands required.

The format of the policy binary has been modified to include ioctl
commands, and the policy version number has been incremented to
POLICYDB_VERSION_XPERMS_IOCTL=30 to account for the format
change.

The extended permissions logic is deliberately generic to allow
components to be reused e.g. netlink filters

Signed-off-by: Jeff Vander Stoep &lt;jeffv@google.com&gt;
Acked-by: Nick Kralevich &lt;nnk@google.com&gt;
Signed-off-by: Paul Moore &lt;pmoore@redhat.com&gt;
</content>
</entry>
</feed>
