[yocto] [oe] meta-selinux

Joe MacDonald Joe_MacDonald at mentor.com
Wed Feb 11 13:46:31 PST 2015


[Re: [yocto] [oe] meta-selinux] On 15.02.11 (Wed 14:43) Philip Tricca wrote:

> On 02/11/2015 11:55 AM, dpquigl wrote:
> > On Wed, 2015-02-11 at 16:29 +0000, Paul Eggleton wrote:
> >> (Adding yocto at yoctoproject.org to CC since that is where meta-selinux patches 
> >> tend to go at least)
> >>
> >> On Wednesday 11 February 2015 10:53:03 dpquigl wrote:
> >>> I'm working on OpenXT and it makes use of the meta-selinux repo hosted
> >>> by the yocto project. I'm trying to use it with a base openembedded core
> >>> and its not in sync with oe-core because its based on pokey. 
> >>
> >> To be clear, poky and OE-Core are in lock-step. No patch to core recipes goes 
> >> into Poky directly, they are applied to OE-Core and then they flow into Poky 
> >> immediately thereafter (Richard, who does the merging of patches into OE-Core, 
> >> does the sync to Poky immediately afterwards.)
> >>
> >> What's more likely happening I suspect is that you are on a newer 
> >> branch/revision of OE-Core/Poky than the meta-selinux maintainers have tested. 
> >> I can't speak to the maintenance schedule for meta-selinux but maybe others 
> >> with knowledge there can chime in.
> > 
> > 
> > I think this makes the most sense. 3 of the problems were bbappend files
> > trying to append the wrong version of a recipe (although with these
> > changes I should move them over to a wildcard) and the last one was with
> > LXC. After that I encountered a typo in one of the recipes where it
> > wasn't able to pull the sources down. 
> 
> I sent out patches to fix these 4 issues to the list a week or so back.
> Reviewing these things and getting them merged takes time though. AFAIK
> the meta-selinux master branch hasn't built for months now mostly
> because of bbappends trailing behind versions in oe-core. I've been
> playing whack-a-mole on this but by the time patches get merged a new
> version has changed elsewhere. I've been using wild-cards as much as
> possible on account of this.
> 
> >>> This made me think of two questions. 1) Why is this not in OE core since so
> >>> many packages in core can potentially have SELinux support enabled and 2) if
> >>> its not supposed to be in core where should turning on SELinux support
> >>> in a recipe go? For example coreutils can have SELinux support enabled.
> >>> Currently this is in meta-selinux as a bbappend to the coreutils
> >>> package. This works out because its always going to be there. However
> >>> there is also a bbappend for an LXC recipe. LXC isn't in core which
> >>> means it has a dependency on a layer not in core.
> >>>
> >>> Ideally I would put the recipes needed for SELinux support in core and
> >>> have a distro feature which is checked in the recipes in core for
> >>> whether or not to add --with-selinux to the build flags. Then LXC could
> >>> check a core distro feature and enable SELinux if it wants to.
> >>
> >> We have to draw the line somewhere for what to include in OE-Core, and at the 
> >> moment I guess we have considered SELinux to be outside its scope. Obviously 
> >> these things get re-evaluated from time to time, and SELinux is a little bit 
> >> painful for this because of how many recipes it has to touch. Ultimately it 
> >> depends on how many people in the embedded space want to enable and use 
> >> SELinux.
> >>
> >> Thoughts from others?
> 
> If SELinux support were to be integrated into oe-core directly this
> would force similar support into other layers too no? The reach of
> meta-selinux has expanded and the layers that must be pulled in to get
> it to build has expanded from just oe-core to meta-virtualization (for
> LXC) as well as a few layers in meta-oe.

All of these I would like to extract again, but I'm concerned we may not
be able to do this without some duplication of meta-python recipes.
Still, that's what I was hoping for.

> I don't know much about the process here but these cross layer
> dependencies would complicate things. I guess this would mean
> integrating SELinux support as a distro feature (or whatever is
> appropriate) into all of these layers directly. Not impossible but
> getting buy-in from the relevant maintainers is necessary.
> 
> > In OpenXT we're using OE to generate images for dom0, a user interface
> > domain, a network driver domain, and various other service domains for
> > isolating tasks in the platform. In addition to that we're using
> > openembedded for building on various embedded research platforms. I'm
> > assuming yocto is using SELinux to some extent since they are
> > maintaining the repository for it and there are quite a few developers
> > using SELiunx on embedded products in Japan.
> 
> I guess I've been wondering the same thing. For OpenXT we had
> implemented our own SELinux support on top of OE (we weren't OSS at the
> time). Now that we are OSS we've re-based on meta-selinux but I don't
> know of anyone else using this layer or at least discussing it publicly.

There's certainly a few other groups / companies, but I'm certain
they're all using the 1.7 branch for now, not master, and manually
updating to the latest refpolicy release (which came out days after we
branched for 1.7) in their own tree.  I'm preparing an update to the
newest refpolicy now, but we're also not far away from the next one, so
I'm almost tempted to wait it out at this point and jump right to the
201503* refpolicy.  I'd be interested to hear opinions on that from
anyone using meta-selinux and wanting to use the master branch.

-- 
-Joe MacDonald.
:wq
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: Digital signature
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20150211/ca17494d/attachment.pgp>


More information about the yocto mailing list