From: Ivan Gyurdiev <ivg2@cornell.edu>
To: Stephen Smalley <sds@tycho.nsa.gov>
Cc: selinux@tycho.nsa.gov
Subject: Re: [ SEPOL 6 ] Fix all the bugs
Date: Tue, 25 Oct 2005 12:04:01 -0400 [thread overview]
Message-ID: <435E5771.8000606@cornell.edu> (raw)
In-Reply-To: <1130243871.17609.269.camel@moss-spartans.epoch.ncsc.mil>
Stephen Smalley wrote:
> On Sat, 2005-10-22 at 13:25 -0400, Ivan Gyurdiev wrote:
>
>> - simplify the port key check a bit - I'll probably have to have another
>> look at this, because I don't think it will do the right thing on
>> modify() - only on query. When you modify a range with a key as the
>> subset of that range, we want it to punch a hole in the range, and split
>> the declaration, but it will replace it entirely. This is easy to fix in
>> sepol, but I also have to fix it in semanage, where it is not as easy -
>> I'd rather think about this some more than do it the wrong way right now.
>>
>
> The current approach is to simply put the more specific entries at the
> beginning of the list, and to use the first matching entry. Thus, you
> don't need to modify the existing larger range at all - you just need to
> insert your more specific entry before it in the list. checkpolicy
> simply preserves the matching order specified in the net_contexts
> configuration, and we order those entries manually to keep the more
> specific ones at the front. checkpolicy does treat it as an error if it
> finds that one of the later entries would be completely hidden (or
> duplicated) by an earlier entry, but overlap is permitted.
>
The same ordering approach may not be maintained in other backends. Even
currently the file linked list is reversed every time the file is read,
making this scheme not work for local files. I suppose I could change
it, but I think there's better ways to solve the problem than rely on
ordering - ordering is fragile.
--
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.
next prev parent reply other threads:[~2005-10-25 16:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-22 17:25 [ SEPOL 6 ] Fix all the bugs Ivan Gyurdiev
2005-10-25 12:37 ` Stephen Smalley
2005-10-25 16:04 ` Ivan Gyurdiev [this message]
2005-10-25 17:04 ` 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=435E5771.8000606@cornell.edu \
--to=ivg2@cornell.edu \
--cc=sds@tycho.nsa.gov \
--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.