All of lore.kernel.org
 help / color / mirror / Atom feed
From: Darrel Goeddel <dgoeddel@TrustedCS.com>
To: Joshua Brindle <jbrindle@tresys.com>
Cc: Stephen Smalley <sds@tycho.nsa.gov>,
	Venkat Yekkirala <vyekkirala@TrustedCS.com>,
	selinux@tycho.nsa.gov, Chad Hanson <chanson@TrustedCS.com>,
	dwalsh@redhat.com, jmorris@redhat.com, latten@austin.ibm.com,
	Paul Moore <paul.moore@hp.com>,
	Karl MacMillan <kmacmillan@mentalrootkit.com>
Subject: Re: Labeled networking packets
Date: Mon, 25 Sep 2006 11:43:59 -0500	[thread overview]
Message-ID: <4518074F.10607@trustedcs.com> (raw)
In-Reply-To: <1159199759.3169.29.camel@twoface.columbia.tresys.com>

Joshua Brindle wrote:
> On Mon, 2006-09-25 at 11:35 -0400, Stephen Smalley wrote:
> 
>>On Sat, 2006-09-23 at 10:13 -0400, Joshua Brindle wrote:
>>
>>>>From: Venkat Yekkirala [mailto:vyekkirala@TrustedCS.com] 
>>>>Let's go back to the drawing board, first of all define the 
>>>>problems we are trying to solve, and come up with a design.
>>>>
>>>
>>>My single requirement is that getpeercon() returns the full context of
>>>the remote process (or some translation negotiated by racoon). 
>>
>>That single requirement is bogus - you'll never get it.  At most, you'll
>>get the full context of the remote socket endpoint.  Which might be the
>>same as the process, but not necessarily.
>>
> 
> 
> That's fine, it matches the semantics of getpeercon() locally. Policy
> can dictate that the socket endpoint is necessarily the domain context.

True.  But we must remember to differentiate your usage on the client
end (policy dictating socket = process) with what the mechanism allows
(just about anything) when placing limitations on the mechanism for the
server end.

This comment is kinda going back to the complaint of mixing "process
types" with "object types" in the secid reconciliation approach...  The
idea of using the best available information for packet labeling really
seems like a good idea to me.  Treating the iptables label as the most
accurate label we can come up with locally given the information, and
sticking that into the secmark field of the buffer is good.  Then, if
something says it has better information about the packets label, like
ipsec, we should listen to that.  We make sure that the label ipsec
presents up with matches up in some way with what we thought we would be
getting (the flow_in) check, then we replace the secmark field with this
label (I think this is where we also introduced a transition to allow
for more flexibility via policy) because we consider this a higher
authority when it comes to labeling.  Now we have the best information
represented via the secmark field on the buffer.  Now... if that buffer
goes to userland or is getting forwarded, the correct (at least in my
world) label would be available for use in access checks.  Locally
generated packets also get their secmark field populated with the label
of the socket at creation so they also have properly labeling wherever
they go.  Now that the secmark field is always up-to-date, we just check
that against the iptables context on the way out.  Back to the complaint
- the mixing of "process types" and "object types" is really a product
of your configuration.  I think the mechanism supports you adapting to
your own constraints via the ipsec/iptables transition.  Now, it is
still true that the label in secmark may have come from different
sources (so your the idea behind the mixing argument still has some
validity), but it does always reflect the best information we have
available at the time for labeling.  That is what we really need to
manage the routing case and it is also something I would like to see
available to applications, they need to know labeling information about
the data no matter where it comes from - everything must have a label.
Wether that is getdatacon() or getpeercon() or
getthebestconthatwehaveavailabe() really make no difference to me.

> Nonetheless, if I can't get something that represents the exact domain
> (not an SA that can be used by lots of domains) I can't do access
> control on network clients (at least not with getpeercon().. there would
> have to be oob transfer of the context which is additional complication
> and infrastructure). 
> 
> Additionally, though this is farther in the future, getpeercon() might
> need to return something that represents the remote domain but in a way
> that the local machine can understand. For example, if one machine is
> running targeted and one is running strict, there will have to be a
> translation from a local context to a remote context that is negotiated.
> (that is the "or some translation negotiated by racoon" in my original
> response)

I'm sure that someone on this list has something interesting to say about
implementations that handle the issue mentioned above...

-- 

Darrel

--
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:[~2006-09-25 16:44 UTC|newest]

Thread overview: 106+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-22 21:55 Labeled networking packets Venkat Yekkirala
2006-09-23 14:13 ` Joshua Brindle
2006-09-25 15:35   ` Stephen Smalley
2006-09-25 15:55     ` Joshua Brindle
2006-09-25 16:43       ` Darrel Goeddel [this message]
2006-09-25 17:02       ` Stephen Smalley
2006-09-25 18:14         ` Karl MacMillan
2006-09-25 19:58           ` James Morris
2006-09-25 16:35     ` Karl MacMillan
2006-09-25 18:04       ` Stephen Smalley
2006-09-25 18:25         ` Joshua Brindle
2006-09-25 18:41           ` Karl MacMillan
2006-09-25 18:53             ` Joshua Brindle
2006-09-25 19:00             ` Paul Moore
2006-09-25 19:25               ` Stephen Smalley
2006-09-25 19:38                 ` Paul Moore
2006-09-25 19:56                   ` Stephen Smalley
2006-09-25 18:49           ` Stephen Smalley
2006-09-25 19:21             ` Stephen Smalley
2006-09-25 14:59 ` Karl MacMillan
2006-09-25 17:58   ` Stephen Smalley
2006-09-25 18:38     ` Karl MacMillan
2006-09-25 18:54       ` Paul Moore
2006-09-25 20:04     ` James Morris
2006-09-25 20:54       ` James Morris
  -- strict thread matches above, loose matches on Subject: below --
2006-09-27 19:35 Venkat Yekkirala
2006-09-27 19:15 Joy Latten
2006-09-27 16:46 Venkat Yekkirala
2006-09-27 16:14 Joy Latten
2006-09-26 22:04 Venkat Yekkirala
2006-09-26 22:43 ` James Morris
2006-09-27 11:37   ` Stephen Smalley
2006-09-27 12:40     ` Joshua Brindle
2006-09-27 12:58       ` Stephen Smalley
2006-09-27 13:15         ` Joshua Brindle
2006-09-27 12:59     ` James Morris
2006-09-27 13:29       ` Stephen Smalley
2006-09-27 17:03         ` James Morris
2006-09-27 17:08         ` James Morris
2006-09-26 15:58 Venkat Yekkirala
2006-09-26 15:51 Venkat Yekkirala
2006-09-26 16:47 ` Stephen Smalley
2006-09-26 20:01 ` James Morris
2006-09-25 21:53 Venkat Yekkirala
2006-09-25 22:00 ` James Morris
2006-09-25 21:46 Venkat Yekkirala
2006-09-26 13:35 ` Stephen Smalley
2006-09-25 20:02 Chad Hanson
2006-09-25 20:47 ` Stephen Smalley
2006-09-25 18:56 Chad Hanson
2006-09-25 19:24 ` Stephen Smalley
2006-09-25 15:28 Chad Hanson
2006-09-25 16:41 ` Karl MacMillan
2006-09-25 18:00 ` Stephen Smalley
2006-09-25 14:45 Chad Hanson
2006-09-25 15:54 ` Casey Schaufler
2006-09-22 23:39 Joy Latten
2006-09-22 23:25 Joy Latten
2006-09-22 21:42 Venkat Yekkirala
2006-09-22 20:30 Venkat Yekkirala
2006-09-22 17:23 Venkat Yekkirala
2006-09-22 17:47 ` Paul Moore
2006-09-22 20:44   ` James Morris
2006-09-22 21:07     ` Paul Moore
2006-09-22 18:52 ` Joshua Brindle
2006-09-22 20:45   ` James Morris
2006-09-22 20:57 ` Stephen Smalley
2006-09-25 14:30   ` Karl MacMillan
2006-09-22 16:14 Venkat Yekkirala
2006-09-22 16:05 Venkat Yekkirala
2006-09-22 16:21 ` Paul Moore
2006-09-22 15:56 Venkat Yekkirala
2006-09-22 16:20 ` Paul Moore
2006-09-22 15:45 Venkat Yekkirala
2006-09-22 16:07 ` Paul Moore
2006-09-22 15:41 Venkat Yekkirala
2006-09-22 15:55 ` Paul Moore
2006-09-22 15:36 Venkat Yekkirala
2006-09-22 15:50 ` Paul Moore
2006-09-22 15:21 Venkat Yekkirala
2006-09-22 15:38 ` Joshua Brindle
2006-09-22 15:15 Venkat Yekkirala
2006-09-22 15:30 ` Paul Moore
2006-09-22 15:09 Venkat Yekkirala
2006-09-22 14:57 Venkat Yekkirala
2006-09-22  0:44 Venkat Yekkirala
2006-09-22  2:04 ` Joshua Brindle
2006-09-22 12:47   ` Stephen Smalley
2006-09-22 13:02     ` Joshua Brindle
2006-09-22 14:47       ` Paul Moore
2006-09-22 14:58         ` Joshua Brindle
2006-09-22 15:25           ` Paul Moore
2006-09-22 19:48             ` James Morris
2006-09-22 19:49           ` Stephen Smalley
2006-09-22 19:02       ` Stephen Smalley
2006-09-22 13:26     ` Karl MacMillan
2006-09-22 13:50       ` Joshua Brindle
2006-09-22 15:01         ` James Morris
2006-09-22 19:17         ` Stephen Smalley
2006-09-22 19:07       ` Stephen Smalley
2006-09-21 17:14 Venkat Yekkirala
2006-09-21 19:37 ` Karl MacMillan
2006-09-21 16:27 Venkat Yekkirala
2006-09-21 16:47 ` Karl MacMillan
2006-09-21 15:01 Venkat Yekkirala
2006-09-21 15:55 ` Stephen Smalley

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=4518074F.10607@trustedcs.com \
    --to=dgoeddel@trustedcs.com \
    --cc=chanson@TrustedCS.com \
    --cc=dwalsh@redhat.com \
    --cc=jbrindle@tresys.com \
    --cc=jmorris@redhat.com \
    --cc=kmacmillan@mentalrootkit.com \
    --cc=latten@austin.ibm.com \
    --cc=paul.moore@hp.com \
    --cc=sds@tycho.nsa.gov \
    --cc=selinux@tycho.nsa.gov \
    --cc=vyekkirala@TrustedCS.com \
    /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.