All of lore.kernel.org
 help / color / mirror / Atom feed
From: Guido Trentalancia <guido@trentalancia.com>
To: russell@coker.com.au
Cc: SE-Linux <selinux@tycho.nsa.gov>
Subject: Re: SE Linux use - was: Question: and the policy grows...
Date: Sat, 19 Mar 2011 15:37:15 +0100	[thread overview]
Message-ID: <1300545435.3034.4.camel@tesla.lan> (raw)
In-Reply-To: <201103191052.04191.russell@coker.com.au>

Hello Russell !

On Sat, 19/03/2011 at 10.52 +1100, Russell Coker wrote:
> On Sat, 19 Mar 2011, Guido Trentalancia <guido@trentalancia.com> wrote:
> > I do not agree with you. MAC policy development requires knowledge of
> > the whole underlying OS including very silly details about location of
> > files (and including very silly details such as tiny differences in
> > different distributions).
> 
> Most of the policy is developed by people who don't have a good knowledge of 
> other distributions.  They develop for the distribution they support and let 
> other people support their own distributions.
> 
> Knowing how the entire OS works is necessary for the people who architect the 
> policy, that is pretty much only Tresys and NSA employees at the moment.
> 
> Writing policy to suit an uncommon configuration of an application is usually 
> a matter of just relabeling files and putting the output of audit2allow into a 
> .te file, it's not particularly difficult.
> 
> > Developing SELinux userspace mostly requires
> > knowledge of libc, libselinux and friends (which have extensive
> > documentation as info and man pages as opposed to very short embedded
> > comments for interfaces in the .if files). Developing SELinux kernel is
> > probably something in between the two things when it comes to
> > difficulty, at least in my perception.
> 
> Developing kernel code requires long build times and it's hard to debug (Linus 
> has long been resistant to kernel debuggers).  Bugs in kernel code often crash 
> the system which makes it difficult to diagnose them and may require some 
> effort to get the system working again.
> 
> Developing library code isn't so simple either, a bug in libselinux or 
> libsepol could make init fail which would also be more challenging than the 
> usual debugging session.
> 
> A policy error that makes the system unbootable can be resolved by booting 
> with enforcing=0 and then reading audit messages.
> 
> Also when doing user-space development you have to deal with the different 
> programming styles of all the different applications and lots of shared object 
> issues.  Debugging pam modules is one thing that's really not fun, setuid 
> programs can't be ptraced and the pam interface isn't the easiest thing to 
> work with.
> 
> > Writing C code is easier at least for me. And testing C code is easier
> > at least for me. For example the C compiler gives much more meaningful
> > warnings and messages. And you've got the debugger as well !
> 
> Nowadays most sysadmins aren't C coders.

Meaningful thoughts, perhaps some of them would fit at the bottom of the
FAQ @selinuxproject.org as an intermediate level type of question ? It
gives an idea of the main difficulties that should be faced when
approaching development.

Regards,

Guido


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.

  reply	other threads:[~2011-03-19 14:40 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-17 13:50 [refpolicy] Question: and the policy grows Guido Trentalancia
2011-03-17 14:25 ` Daniel J Walsh
2011-03-17 16:04   ` Guido Trentalancia
2011-03-17 16:44     ` Daniel J Walsh
2011-03-17 17:54       ` Christopher J. PeBenito
2011-03-17 18:34         ` Daniel J Walsh
2011-03-17 19:49           ` Daniel J Walsh
2011-03-18 13:30           ` Christopher J. PeBenito
2011-03-17 20:15         ` Guido Trentalancia
2011-03-18 13:35           ` Christopher J. PeBenito
2011-03-18 15:25             ` Guido Trentalancia
2011-03-17 19:40       ` Guido Trentalancia
2011-03-17 19:55         ` Daniel J Walsh
2011-03-17 20:27           ` Guido Trentalancia
2011-03-18 13:38             ` Christopher J. PeBenito
2011-03-17 20:24         ` Sven Vermeulen
2011-03-17 21:08           ` Guido Trentalancia
2011-03-17 21:34             ` Sven Vermeulen
2011-03-17 23:04               ` Guido Trentalancia
2011-03-18 13:52               ` Christopher J. PeBenito
2011-03-18 15:20                 ` Guido Trentalancia
2011-03-17 23:08           ` Mark Montague
2011-03-18  6:06             ` Sven Vermeulen
2011-03-18 10:19               ` Dominick Grift
2011-03-18 12:31               ` Guido Trentalancia
2011-03-17 22:56         ` Mark Montague
2011-03-18 10:12           ` Dominick Grift
2011-03-18 13:37           ` Stephen Smalley
2011-03-18 15:37           ` Dominick Grift
2011-03-17 23:24         ` SE Linux use - was: " Russell Coker
2011-03-18  0:33           ` Guido Trentalancia
2011-03-18  2:11           ` Jason Axelson
2011-03-18 13:23           ` James Carter
2011-03-18 14:33             ` Russell Coker
2011-03-18 14:57               ` Christopher J. PeBenito
2011-03-18 15:48                 ` Guido Trentalancia
2011-03-18 23:40                 ` Russell Coker
2011-03-18 15:45               ` Guido Trentalancia
2011-03-18 23:52                 ` Russell Coker
2011-03-19 14:37                   ` Guido Trentalancia [this message]
2011-03-18 14:08           ` Christopher J. PeBenito
2011-03-18 13:45         ` [refpolicy] " Christopher J. PeBenito
2011-03-18 15:09           ` Guido Trentalancia
2011-03-18 17:14           ` [refpolicy] dual mailing list (was Question: and the policy grows...) Guido Trentalancia
2011-03-18 18:40             ` Daniel J Walsh
2011-03-18 19:13               ` Guido Trentalancia

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=1300545435.3034.4.camel@tesla.lan \
    --to=guido@trentalancia.com \
    --cc=russell@coker.com.au \
    --cc=selinux@tycho.nsa.gov \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.