<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/kernel/auditfilter.c, branch v3.8</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v3.8</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.8'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2013-01-10T22:35:23Z</updated>
<entry>
<title>audit: fix auditfilter.c kernel-doc warnings</title>
<updated>2013-01-10T22:35:23Z</updated>
<author>
<name>Randy Dunlap</name>
<email>rdunlap@infradead.org</email>
</author>
<published>2013-01-10T01:12:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bfbbd96c51b441b7a9a08762aa9ab832f6655b2c'/>
<id>urn:sha1:bfbbd96c51b441b7a9a08762aa9ab832f6655b2c</id>
<content type='text'>
Fix new kernel-doc warning in auditfilter.c:

  Warning(kernel/auditfilter.c:1157): Excess function parameter 'uid' description in 'audit_receive_filter'

Signed-off-by: Randy Dunlap &lt;rdunlap@infradead.org&gt;
Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Cc: Eric Paris &lt;eparis@redhat.com&gt;
Cc: linux-audit@redhat.com (subscribers-only)
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>audit: optimize audit_compare_dname_path</title>
<updated>2012-10-12T04:32:02Z</updated>
<author>
<name>Jeff Layton</name>
<email>jlayton@redhat.com</email>
</author>
<published>2012-10-10T19:25:25Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e3d6b07b8ba161f638b026feba0c3c97875d7f1c'/>
<id>urn:sha1:e3d6b07b8ba161f638b026feba0c3c97875d7f1c</id>
<content type='text'>
In the cases where we already know the length of the parent, pass it as
a parm so we don't need to recompute it. In the cases where we don't
know the length, pass in AUDIT_NAME_FULL (-1) to indicate that it should
be determined.

Signed-off-by: Jeff Layton &lt;jlayton@redhat.com&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>audit: make audit_compare_dname_path use parent_len helper</title>
<updated>2012-10-12T04:32:02Z</updated>
<author>
<name>Eric Paris</name>
<email>eparis@redhat.com</email>
</author>
<published>2012-10-10T19:25:24Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=29e9a3467c1367549568d7d411d5f30209ae181b'/>
<id>urn:sha1:29e9a3467c1367549568d7d411d5f30209ae181b</id>
<content type='text'>
Signed-off-by: Eric Paris &lt;eparis@redhat.com&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>audit: remove dirlen argument to audit_compare_dname_path</title>
<updated>2012-10-12T04:32:01Z</updated>
<author>
<name>Jeff Layton</name>
<email>jlayton@redhat.com</email>
</author>
<published>2012-10-10T19:25:24Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=563a0d1236c2c58d584ef122a5cdc9930e5860b3'/>
<id>urn:sha1:563a0d1236c2c58d584ef122a5cdc9930e5860b3</id>
<content type='text'>
All the callers set this to NULL now.

Signed-off-by: Jeff Layton &lt;jlayton@redhat.com&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>audit: set the name_len in audit_inode for parent lookups</title>
<updated>2012-10-12T04:32:01Z</updated>
<author>
<name>Jeff Layton</name>
<email>jlayton@redhat.com</email>
</author>
<published>2012-10-10T19:25:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bfcec7087458812f575d9022b2d151641f34ee84'/>
<id>urn:sha1:bfcec7087458812f575d9022b2d151641f34ee84</id>
<content type='text'>
Currently, this gets set mostly by happenstance when we call into
audit_inode_child. While that might be a little more efficient, it seems
wrong. If the syscall ends up failing before audit_inode_child ever gets
called, then you'll have an audit_names record that shows the full path
but has the parent inode info attached.

Fix this by passing in a parent flag when we call audit_inode that gets
set to the value of LOOKUP_PARENT. We can then fix up the pathname for
the audit entry correctly from the get-go.

While we're at it, clean up the no-op macro for audit_inode in the
!CONFIG_AUDITSYSCALL case.

Signed-off-by: Jeff Layton &lt;jlayton@redhat.com&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>userns: Convert the audit loginuid  to be a kuid</title>
<updated>2012-09-18T01:08:54Z</updated>
<author>
<name>Eric W. Biederman</name>
<email>ebiederm@xmission.com</email>
</author>
<published>2012-09-11T05:39:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e1760bd5ffae8cb98cffb030ee8e631eba28f3d8'/>
<id>urn:sha1:e1760bd5ffae8cb98cffb030ee8e631eba28f3d8</id>
<content type='text'>
Always store audit loginuids in type kuid_t.

Print loginuids by converting them into uids in the appropriate user
namespace, and then printing the resulting uid.

Modify audit_get_loginuid to return a kuid_t.

Modify audit_set_loginuid to take a kuid_t.

Modify /proc/&lt;pid&gt;/loginuid on read to convert the loginuid into the
user namespace of the opener of the file.

Modify /proc/&lt;pid&gt;/loginud on write to convert the loginuid
rom the user namespace of the opener of the file.

Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Cc: Eric Paris &lt;eparis@redhat.com&gt;
Cc: Paul Moore &lt;paul@paul-moore.com&gt; ?
Cc: David Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Eric W. Biederman &lt;ebiederm@xmission.com&gt;
</content>
</entry>
<entry>
<title>audit: Add typespecific uid and gid comparators</title>
<updated>2012-09-18T01:08:09Z</updated>
<author>
<name>Eric W. Biederman</name>
<email>ebiederm@xmission.com</email>
</author>
<published>2012-09-11T09:18:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ca57ec0f00c3f139c41bf6b0a5b9bcc95bbb2ad7'/>
<id>urn:sha1:ca57ec0f00c3f139c41bf6b0a5b9bcc95bbb2ad7</id>
<content type='text'>
The audit filter code guarantees that uid are always compared with
uids and gids are always compared with gids, as the comparason
operations are type specific.  Take advantage of this proper to define
audit_uid_comparator and audit_gid_comparator which use the type safe
comparasons from uidgid.h.

Build on audit_uid_comparator and audit_gid_comparator and replace
audit_compare_id with audit_compare_uid and audit_compare_gid.  This
is one of those odd cases where being type safe and duplicating code
leads to simpler shorter and more concise code.

Don't allow bitmask operations in uid and gid comparisons in
audit_data_to_entry.  Bitmask operations are already denined in
audit_rule_to_entry.

Convert constants in audit_rule_to_entry and audit_data_to_entry into
kuids and kgids when appropriate.

Convert the uid and gid field in struct audit_names to be of type
kuid_t and kgid_t respectively, so that the new uid and gid comparators
can be applied in a type safe manner.

Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Cc: Eric Paris &lt;eparis@redhat.com&gt;
Signed-off-by: "Eric W. Biederman" &lt;ebiederm@xmission.com&gt;
</content>
</entry>
<entry>
<title>audit: Remove the unused uid parameter from audit_receive_filter</title>
<updated>2012-09-18T01:07:07Z</updated>
<author>
<name>Eric W. Biederman</name>
<email>ebiederm@xmission.com</email>
</author>
<published>2012-09-11T07:19:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=017143fecb3364e5fed8107d206799899f5dd684'/>
<id>urn:sha1:017143fecb3364e5fed8107d206799899f5dd684</id>
<content type='text'>
Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Cc: Eric Paris &lt;eparis@redhat.com&gt;
Signed-off-by: "Eric W. Biederman" &lt;ebiederm@xmission.com&gt;
</content>
</entry>
<entry>
<title>audit: Use current instead of NETLINK_CREDS() in audit_filter</title>
<updated>2012-09-18T01:03:31Z</updated>
<author>
<name>Eric W. Biederman</name>
<email>ebiederm@xmission.com</email>
</author>
<published>2012-09-11T06:10:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=02276bda4a2bf094fcde89fb5db4d9e86347ebf4'/>
<id>urn:sha1:02276bda4a2bf094fcde89fb5db4d9e86347ebf4</id>
<content type='text'>
Get caller process uid and gid and pid values from the current task
instead of the NETLINK_CB.  This is simpler than passing NETLINK_CREDS
from from audit_receive_msg to audit_filter_user_rules and avoid the
chance of being hit by the occassional bugs in netlink uid/gid
credential passing.  This is a safe changes because all netlink
requests are processed in the task of the sending process.

Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Cc: Eric Paris &lt;eparis@redhat.com&gt;
Signed-off-by: "Eric W. Biederman" &lt;ebiederm@xmission.com&gt;
</content>
</entry>
<entry>
<title>audit: allow interfield comparison in audit rules</title>
<updated>2012-01-17T21:17:01Z</updated>
<author>
<name>Eric Paris</name>
<email>eparis@redhat.com</email>
</author>
<published>2012-01-03T19:23:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=02d86a568c6d2d335256864451ac8ce781bc5652'/>
<id>urn:sha1:02d86a568c6d2d335256864451ac8ce781bc5652</id>
<content type='text'>
We wish to be able to audit when a uid=500 task accesses a file which is
uid=0.  Or vice versa.  This patch introduces a new audit filter type
AUDIT_FIELD_COMPARE which takes as an 'enum' which indicates which fields
should be compared.  At this point we only define the task-&gt;uid vs
inode-&gt;uid, but other comparisons can be added.

Signed-off-by: Eric Paris &lt;eparis@redhat.com&gt;
</content>
</entry>
</feed>
