All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel J Walsh <dwalsh@redhat.com>
To: Eric Paris <eparis@redhat.com>
Cc: selinux@tycho.nsa.gov
Subject: Re: concept of a permissive domain
Date: Tue, 11 Sep 2007 16:31:33 -0400	[thread overview]
Message-ID: <46E6FB25.5070507@redhat.com> (raw)
In-Reply-To: <1189537981.3407.51.camel@localhost.localdomain>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Eric Paris wrote:
> So there was a brief conversation between dan, karl, and myself today
> about implementing a permissive subject domain.  Basically there would
> be some new language construct possibly "permissive httpd_t true;" which
> would then set a flag.  If this flag was set, all denials would be
> logged but the operation would be permitted.  This would make it
> possible to create a type_exec_t and type_t for your new domain, mark it
> as permissive/unconfined and run it as long as you like.  Once you get
> all your new allow rules you just remove the permissive bit.  You didn't
> have to setenforce the whole system.
> 
> First thought from Karl was to use the 'char primary' field of the
> struct type_datum.  Seems reasonable enough, after we have that
> information in kernel it shouldn't take me too much playing around in
> avc_has_perm_noaudit to check if this flag is set on a denial.  I don't
> think slowing down the denial path a little by having to call back in to
> see if this flag was set for a given source sid is that big of deal.
> Maybe I could keep it just about as fast by adding more flags
> audit_allow_once (can't really reuse audit_allow) to the avd or
> something like that, but it seems like a large waste of space to carry
> another set of audit flags that won't be used much.
> 
> Thoughts?  Other ways to implement this?  Problems with the basic premis
> of an unconfined domain?
> 
> -Eric
> 
> 
> --
> 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.

Lets not call it an unconfined domain.   This is a permissive domain.
The idea is to collect avc messages as if it was confined, and allow me
to write policy based on this.

This would solve several problems.

1. Customers want to be able to write policy and distribute it within
their environments and let it run for a couple of months in permissive
mode,  Continuously gathering AVC messages and updating policy.  When
they are satisfied that the policy works as defined.  They can turn off
the permissive mode and have a feeling of confidence that the policy
will not break their application.  They fear that putting  out too
restrictive of a policy will cause them to loose money.
2. Customers are upset that they lost disable_trans, because they
sometimes want to say just let a domain run and don't care about it.
So if they could turn that domain to permissive they could maintain
their security on other domains.  Currently they have to put the machine
in permissive mode or become policy writers.  (chcon -t bin_t works but
does not survive a relabel)

3 When writing policy we currently tell people to turn their machine to
permissive, which is a security risk.  If we could just run the domain
in permissive mode, we would not decrease the overall security of the
system.

4 Finally as we introduce the concept of confined user domains, it would
be interesting to apply a confined admin domain to a admin user and then
record the avc's he generates while in permissive mode.  It would allow
us to better understand the needs of a admin user.

One other feature/requirement would be to not override dontaudit rules.
So if I have a domain in permissive mode and I have a dontaudit rule  on
reading /etc/shadow.  The app should still be denied reading
/etc/shadow.  (This is not a show stopper, but would allow us to force
apps to take the code paths they will take in enforcing mode.)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iD8DBQFG5vslrlYvE4MpobMRAphWAKDrykJk05Y3gUT+8zB9ZLJGtp8c/QCfXRoh
pzE/k8a/YDqE/FIKadMDxy0=
=GtJx
-----END PGP SIGNATURE-----

--
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:[~2007-09-11 20:31 UTC|newest]

Thread overview: 71+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-11 19:13 concept of a permissive domain Eric Paris
2007-09-11 20:31 ` Daniel J Walsh [this message]
2007-09-11 21:26   ` Karl MacMillan
2007-09-11 21:47     ` Eric Paris
2007-09-12 13:27       ` Karl MacMillan
2007-09-12 13:57         ` Daniel J Walsh
2007-09-13 14:08     ` Stephen Smalley
2007-09-13 14:46       ` Karl MacMillan
2007-09-13 14:57         ` Stephen Smalley
2007-09-13 15:25           ` Karl MacMillan
2007-09-13 19:25           ` Daniel J Walsh
2007-09-13 19:38             ` Stephen Smalley
2007-09-13 20:16               ` Eric Paris
2007-09-18 20:24                 ` Stephen Smalley
2007-09-18 20:50                   ` Joshua Brindle
2007-09-18 21:54                   ` Chad Sellers
2007-09-19 12:56                     ` Daniel J Walsh
2007-09-19 14:22                       ` Chad Sellers
2007-10-12 13:50                       ` Daniel J Walsh
2007-10-12 17:49                         ` Joshua Brindle
2007-10-12 18:07                           ` Eric Paris
2007-10-12 19:03                             ` Karl MacMillan
2007-10-12 19:09                               ` Stephen Smalley
2007-10-12 18:40                         ` Chad Sellers
2007-10-12 19:05                           ` Karl MacMillan
2007-10-12 20:43                             ` Chad Sellers
2007-10-12 21:01                               ` Stephen Smalley
2007-10-12 21:21                               ` Karl MacMillan
2007-10-12 23:38                                 ` Chad Sellers
2007-10-13 13:38                                   ` Daniel J Walsh
2007-10-14 10:14                                     ` Stefan Schulze Frielinghaus
2007-10-15 12:40                                       ` Daniel J Walsh
2007-10-15 16:52                                         ` Brett Lentz
2007-10-15 16:58                                           ` Stephen Smalley
2007-10-15 18:32                                             ` Daniel J Walsh
2007-10-15 18:40                                               ` Stephen Smalley
2007-10-15 18:57                                                 ` Karl MacMillan
2007-10-15 19:09                                                 ` Eric Paris
2007-10-17 19:47                                                   ` Stephen Smalley
2007-10-17 21:50                                                     ` Recurring SELinux events for similar violations Hasan Rezaul-CHR010
2007-10-17 22:18                                                       ` Eric Paris
2007-10-17 22:22                                                         ` Hasan Rezaul-CHR010
2007-10-18 13:13                                                           ` Stephen Smalley
2007-10-18 14:32                                                             ` Hasan Rezaul-CHR010
2007-11-29 20:06                                                             ` Hasan Rezaul-CHR010
2007-11-29 20:16                                                               ` Stephen Smalley
2007-11-29 21:26                                                                 ` Hasan Rezaul-CHR010
2007-11-29 21:32                                                                   ` Stephen Smalley
2007-11-29 21:45                                                                     ` Stephen Smalley
2007-10-15 17:26                                           ` concept of a permissive domain Chad Sellers
2007-10-12 19:07                           ` Stephen Smalley
2007-10-12 19:30                             ` Stephen Smalley
2007-09-19 16:35                     ` Martin Orr
2007-09-19 16:41                       ` Eric Paris
2007-09-20 14:41                         ` Joshua Brindle
2007-09-20 14:46                           ` Joshua Brindle
2007-09-19 16:52                       ` Stephen Smalley
2007-09-24 14:59                   ` Karl MacMillan
2007-09-13 20:25               ` Karl MacMillan
2007-09-14 14:15               ` James Carter
2007-09-14 14:45                 ` Joshua Brindle
2007-09-14 15:15                   ` Karl MacMillan
2007-09-11 22:57 ` Joshua Brindle
2007-09-12 13:26   ` Karl MacMillan
2007-09-13 13:11 ` Stephen Smalley
2007-09-13 13:19   ` Karl MacMillan
2007-09-13 13:25     ` Stephen Smalley
2007-09-13 13:59       ` Eric Paris
2007-09-13 14:23         ` Stephen Smalley
2007-09-13 14:36           ` Stephen Smalley
2007-09-13 14:42           ` Karl MacMillan

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=46E6FB25.5070507@redhat.com \
    --to=dwalsh@redhat.com \
    --cc=eparis@redhat.com \
    --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.