selinux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Smalley <sds@tycho.nsa.gov>
To: paul@paul-moore.com
Cc: selinux@vger.kernel.org, omosnace@redhat.com,
	richard_c_haines@btinternet.com
Subject: Re: [PATCH] testsuite: enable running over labeled NFS
Date: Wed, 5 Feb 2020 12:09:35 -0500	[thread overview]
Message-ID: <89070869-6054-3691-4f36-ecb2787bcd72@tycho.nsa.gov> (raw)
In-Reply-To: <20200129202922.88027-1-sds@tycho.nsa.gov>

On 1/29/20 3:29 PM, Stephen Smalley wrote:
> Certain tests cannot succeed on nfs and therefore should
> be skipped in that case.  This allows the testsuite to
> be run on a labeled NFS mount as described below without
> triggering any (additional) failures relative to running
> on a local filesystem like ext4.
> 
> The tests that are skipped or modified and the corresponding rationale is:
> file: 1 test skipped - flock not supported over NFS
> capable_file: all tests skipped - file capabilities not supported over NFS
> capable_sys: 1 test skipped - CAP_SYS_RAWIO not supported over NFS
> overlay: all tests skipped - NFS not supported as an upperdir
> mac_admin: one test modified - undefined contexts not exported over NFS
> 
> This partly addresses
> https://github.com/SELinuxProject/selinux-testsuite/issues/32.
> 
> Test sequence for labeled NFS is:
> $ cat nfs.sh
> MOUNT=/home # must be a top-level mount
> TESTDIR=$MOUNT/path/to/selinux-testsuite
> systemctl start nfs-server
> exportfs -orw,no_root_squash,security_label localhost:$MOUNT
> mkdir -p /mnt/selinux-testsuite
> mount -t nfs -o vers=4.2 localhost:$TESTDIR /mnt/selinux-testsuite
> pushd /mnt/selinux-testsuite
> make test
> popd
> umount /mnt/selinux-testsuite
> exportfs -u localhost:$MOUNT
> systemctl stop nfs-server
> 
> Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>

This is now applied.

> ---
>   tests/capable_file/test | 28 +++++++++++++++++++---------
>   tests/capable_sys/test  | 32 +++++++++++++++++++++++---------
>   tests/file/test         | 22 +++++++++++++++++-----
>   tests/mac_admin/test    | 18 ++++++++++++++----
>   tests/overlay/test      | 11 ++++++++---
>   5 files changed, 81 insertions(+), 30 deletions(-)

[...]



      reply	other threads:[~2020-02-05 17:08 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-29 20:29 [PATCH] testsuite: enable running over labeled NFS Stephen Smalley
2020-02-05 17:09 ` Stephen Smalley [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=89070869-6054-3691-4f36-ecb2787bcd72@tycho.nsa.gov \
    --to=sds@tycho.nsa.gov \
    --cc=omosnace@redhat.com \
    --cc=paul@paul-moore.com \
    --cc=richard_c_haines@btinternet.com \
    --cc=selinux@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).