mbox series

[testsuite,v2,0/3] Fix refpolicy build & build test_policy.pp in Travis

Message ID 20191115151623.265770-1-omosnace@redhat.com (mailing list archive)
Headers show
Series Fix refpolicy build & build test_policy.pp in Travis | expand

Message

Ondrej Mosnacek Nov. 15, 2019, 3:16 p.m. UTC
This series fixes the remaining test_policy.pp build errors under
refpolicy and enables building the test policy under both Fedora policy
and refpolicy in Travis CI.

Changes in v2:
 - report policy version 999 in the fake selinuxfs to force building
   latest version
 - install userspace tools and libraries straight from source instead
   of working around maissing features in the Ubuntu builds
 - install also latest keyutils from source to allow the new 'keys'
   subtest helpers to build

Ondrej Mosnacek (3):
  policy: consolidate macros for home dirs access
  policy: add fallbacks for Fedora-specific macros
  travis: test building the test policy package

 .travis.yml                         | 48 ++++++++++++++++++++++++++---
 policy/Makefile                     | 11 ++++---
 policy/test_overlayfs.te            |  6 ++--
 policy/test_policy.if               | 23 ++++++++++++--
 travis-ci/enable-policy.sh          | 10 ++++++
 travis-ci/setup-policy-fedora.sh    | 33 ++++++++++++++++++++
 travis-ci/setup-policy-refpolicy.sh | 19 ++++++++++++
 7 files changed, 136 insertions(+), 14 deletions(-)
 create mode 100644 travis-ci/enable-policy.sh
 create mode 100644 travis-ci/setup-policy-fedora.sh
 create mode 100644 travis-ci/setup-policy-refpolicy.sh

Comments

Ondrej Mosnacek Nov. 15, 2019, 3:28 p.m. UTC | #1
On Fri, Nov 15, 2019 at 4:16 PM Ondrej Mosnacek <omosnace@redhat.com> wrote:
> This series fixes the remaining test_policy.pp build errors under
> refpolicy and enables building the test policy under both Fedora policy
> and refpolicy in Travis CI.
>
> Changes in v2:
>  - report policy version 999 in the fake selinuxfs to force building
>    latest version
>  - install userspace tools and libraries straight from source instead
>    of working around maissing features in the Ubuntu builds
>  - install also latest keyutils from source to allow the new 'keys'
>    subtest helpers to build

Demo Travis run:
https://travis-ci.org/WOnder93/selinux-testsuite/builds/612431495

>
> Ondrej Mosnacek (3):
>   policy: consolidate macros for home dirs access
>   policy: add fallbacks for Fedora-specific macros
>   travis: test building the test policy package
>
>  .travis.yml                         | 48 ++++++++++++++++++++++++++---
>  policy/Makefile                     | 11 ++++---
>  policy/test_overlayfs.te            |  6 ++--
>  policy/test_policy.if               | 23 ++++++++++++--
>  travis-ci/enable-policy.sh          | 10 ++++++
>  travis-ci/setup-policy-fedora.sh    | 33 ++++++++++++++++++++
>  travis-ci/setup-policy-refpolicy.sh | 19 ++++++++++++
>  7 files changed, 136 insertions(+), 14 deletions(-)
>  create mode 100644 travis-ci/enable-policy.sh
>  create mode 100644 travis-ci/setup-policy-fedora.sh
>  create mode 100644 travis-ci/setup-policy-refpolicy.sh
>
> --
> 2.23.0
Stephen Smalley Nov. 15, 2019, 3:52 p.m. UTC | #2
On 11/15/19 10:16 AM, Ondrej Mosnacek wrote:
> This series fixes the remaining test_policy.pp build errors under
> refpolicy and enables building the test policy under both Fedora policy
> and refpolicy in Travis CI.
> 
> Changes in v2:
>   - report policy version 999 in the fake selinuxfs to force building
>     latest version
>   - install userspace tools and libraries straight from source instead
>     of working around maissing features in the Ubuntu builds
>   - install also latest keyutils from source to allow the new 'keys'
>     subtest helpers to build

Doesn't appear to have addressed any of my comments on the first version 
of the first two patches:

https://lore.kernel.org/selinux/6df6dafe-56a6-7de0-0196-d2b714b453bb@tycho.nsa.gov/

https://lore.kernel.org/selinux/c7521035-8608-c24e-4056-c58aa02de387@tycho.nsa.gov/

> 
> Ondrej Mosnacek (3):
>    policy: consolidate macros for home dirs access
>    policy: add fallbacks for Fedora-specific macros
>    travis: test building the test policy package
> 
>   .travis.yml                         | 48 ++++++++++++++++++++++++++---
>   policy/Makefile                     | 11 ++++---
>   policy/test_overlayfs.te            |  6 ++--
>   policy/test_policy.if               | 23 ++++++++++++--
>   travis-ci/enable-policy.sh          | 10 ++++++
>   travis-ci/setup-policy-fedora.sh    | 33 ++++++++++++++++++++
>   travis-ci/setup-policy-refpolicy.sh | 19 ++++++++++++
>   7 files changed, 136 insertions(+), 14 deletions(-)
>   create mode 100644 travis-ci/enable-policy.sh
>   create mode 100644 travis-ci/setup-policy-fedora.sh
>   create mode 100644 travis-ci/setup-policy-refpolicy.sh
>
Ondrej Mosnacek Nov. 15, 2019, 3:59 p.m. UTC | #3
On Fri, Nov 15, 2019 at 4:53 PM Stephen Smalley <sds@tycho.nsa.gov> wrote:
> On 11/15/19 10:16 AM, Ondrej Mosnacek wrote:
> > This series fixes the remaining test_policy.pp build errors under
> > refpolicy and enables building the test policy under both Fedora policy
> > and refpolicy in Travis CI.
> >
> > Changes in v2:
> >   - report policy version 999 in the fake selinuxfs to force building
> >     latest version
> >   - install userspace tools and libraries straight from source instead
> >     of working around maissing features in the Ubuntu builds
> >   - install also latest keyutils from source to allow the new 'keys'
> >     subtest helpers to build
>
> Doesn't appear to have addressed any of my comments on the first version
> of the first two patches:
>
> https://lore.kernel.org/selinux/6df6dafe-56a6-7de0-0196-d2b714b453bb@tycho.nsa.gov/
>
> https://lore.kernel.org/selinux/c7521035-8608-c24e-4056-c58aa02de387@tycho.nsa.gov/

Ah, sorry, I got back to this after a long delay and forgot about
those... I'll address them in v3 then.

>
> >
> > Ondrej Mosnacek (3):
> >    policy: consolidate macros for home dirs access
> >    policy: add fallbacks for Fedora-specific macros
> >    travis: test building the test policy package
> >
> >   .travis.yml                         | 48 ++++++++++++++++++++++++++---
> >   policy/Makefile                     | 11 ++++---
> >   policy/test_overlayfs.te            |  6 ++--
> >   policy/test_policy.if               | 23 ++++++++++++--
> >   travis-ci/enable-policy.sh          | 10 ++++++
> >   travis-ci/setup-policy-fedora.sh    | 33 ++++++++++++++++++++
> >   travis-ci/setup-policy-refpolicy.sh | 19 ++++++++++++
> >   7 files changed, 136 insertions(+), 14 deletions(-)
> >   create mode 100644 travis-ci/enable-policy.sh
> >   create mode 100644 travis-ci/setup-policy-fedora.sh
> >   create mode 100644 travis-ci/setup-policy-refpolicy.sh
> >
>