Skip to contentSkip to conversation

SELinux port for 2.4.28 (and incoming backport from 2.6) released.

DISCUSSION Lorenzo Hernandez Garcia-Hierro 2 participants 4 messages Dec 4, 2004 – Dec 6, 2004 SELinux security module

lore
Share & tools
lore
#0 lore raw

Hi,

I was wondering for a backport of SELinux patch for the 2.4 brand, and i've observed that there's just a patch, deprecated, for 2.4.26.

As the first move for trying to backport the current 2.6 patch capabilities i've ported the old 2.4.26 patch to 2.4.28, without huge problems and just fixing some errors with proc fs stuff and others.

I've not tested it yet, but hopefully works.

I want to know if someone is interested in doing this, as the main reasons are that 2.4 kernels are used by many people, possibly more than the ones using revisions from the 2.6 brand, and also that we can offer the possibility of using the SELinux enhancements without changing the kernel.In addition, if you compare 2.6 revisions changelogs with 2.4 ones you can see that many things change between releases, and not in 2.4 that are only security related and critical or major enhancements.

The gzip'ed patch can be found at:
https://sourceforge.net/project/showfiles.php?group_id=118309&package_id=137453

Joshua was telling me that many things changed in the 2.6 releases, and that many things are deprecated or obsolete in the old 2.4.26 patch, so, i will appreciate any help for backporting them and giving support for those new capabilities.

I'm CC'ing the LKML because this could be of interest for the kernel hackers, in an hypothetical case of including a backported and updated version of SELinux patch in the 2.4 brand.

Cheers and enjoy,
PS: I'm not an experienced developer in C terms, i just do what i can do and often i get obsessed when i can't get something done, so, i think that equilibrates the balance of knowledge<->attitudes (it's not easy to fit all of this in time when you're just fifteen years old, but i can't excuse unexpected kernel panics :) ).

Signature · 3 lines
Lorenzo Hernández García-Hierro [1024D/6F2B2DEC]
Hardened Debian head developer & project manager.
http://www.debian-hardened.org 
#1 lore raw
Quoted 1 line · Lorenzo Hernandez Garcia-Hierro

I've not tested it yet, but hopefully works.

For that kernel, you'll have to pass the -c 15 option to checkpolicy to tell it to build a version 15 policy, as the 2.4-based SELinux doesn't support newer policy versions. Specifically, the 2.4-based SELinux was never updated for the conditional policy support (policy booleans), ipv6 support, and fine-grained netlink classes. See
http://marc.theaimsgroup.com/?l=selinux&m=107643944721568&w=2.

Signature · 8 lines
Stephen Smalley <[email protected]>
National Security Agency


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.
#2 lore raw

Hi Stephen,

Quoted 9 lines · Stephen Smalley
Quoted 1 line · Lorenzo Hernandez Garcia-Hierro

I've not tested it yet, but hopefully works.

For that kernel, you'll have to pass the -c 15 option to checkpolicy to tell it to build a version 15 policy, as the 2.4-based SELinux doesn't support newer policy versions. Specifically, the 2.4-based SELinux was never updated for the conditional policy support (policy booleans), ipv6 support, and fine-grained netlink classes. See
http://marc.theaimsgroup.com/?l=selinux&m=107643944721568&w=2.

Yes, the conditional policy (v16) could be ported to it, as i have the diff of the first release (2.6) that came with it, anyway, other stuff could be hard to backport.

It would be great to have somewhere a SCM to see real diffs and the evolution of the 2.6 brand, and the old 2.4 one, to compare what things need to be backported and how to do it.

I will take a look in it later.

Cheers,

Signature · 3 lines
Lorenzo Hernández García-Hierro [1024D/6F2B2DEC]
Hardened Debian head developer & project manager.
http://www.debian-hardened.org 
#3 lore raw
Quoted 7 lines · Lorenzo Hernandez Garcia-Hierro

Yes, the conditional policy (v16) could be ported to it, as i have the diff of the first release (2.6) that came with it, anyway, other stuff could be hard to backport.

It would be great to have somewhere a SCM to see real diffs and the evolution of the 2.6 brand, and the old 2.4 one, to compare what things need to be backported and how to do it.

Hmm...well, there is Linus' BitKeeper tree, and there is the CVS tree under the sourceforge selinux project.

I'd expect that you could easily back port the latest security server code (security/selinux/ss/*), as it is not tightly coupled to the core kernel. That would let you use the latest policy version even if the hook function code isn't making full use of it (although the fine-grained netlink classes might cause you some pain until you get that support back ported into the hook functions, which shouldn't be difficult).

Signature · 8 lines
Stephen Smalley <[email protected]>
National Security Agency


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.