apparmor/tests
Tyler Hicks 29469c6e2a tests: Create socketpair test for checking labeling on fds
Bug: https://bugs.launchpad.net/bugs/1235478

This is a test to check the label on file descriptors returned from
socketpair().

In its simple form, it simply calls socketpair() and checks the
labels on both fds.

In its complex form, it has the ability to do the simple test, then set
up an exec transition using aa_change_onexec(), and re-exec itself to
check the labeling after the file descriptors have been passed across an
exec transition.

The complex form is meant to test revalidation at exec. AppArmor
currently keeps the original labeling in place across the exec
transition.

Note that this test does not currently test read/write access to the
file descriptors. It only checks the label, as returned by
aa_getpeercon(2).

Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Acked-by: John Johansen <john.johansen@canonical.com>
2014-05-27 09:19:15 +02:00
..
regression tests: Create socketpair test for checking labeling on fds 2014-05-27 09:19:15 +02:00
stress This patch fixes up a bit that leaked into kees' commit rev 1727 2011-05-23 16:05:10 -07:00
Makefile This patch fixes up a bit that leaked into kees' commit rev 1727 2011-05-23 16:05:10 -07:00