From: "Christopher J. PeBenito" <cpebenito@tresys.com>
To: paul.moore@hp.com
Cc: selinux@tycho.nsa.gov
Subject: Re: [RFC 1/2] Reference policy: NetLabel policy additions
Date: Tue, 10 Oct 2006 14:10:04 -0400 [thread overview]
Message-ID: <1160503804.20774.82.camel@sgc> (raw)
In-Reply-To: <20061010172154.448485000@hp.com>
On Tue, 2006-10-10 at 13:15 -0400, paul.moore@hp.com wrote:
> plain text document attachment (netlabel-refpolicy_core)
> This patch adds basic NetLabel support to the reference policy.
The main problem is that there are references to types that are not
owned by this module. These have to be changed to use interfaces that
are provided by the modules that own the types.
> +interface(`netlabel_udp_recvfrom',`
> + gen_require(`
> + type unlabeled_t;
> + ')
> +
> + allow $1 unlabeled_t:udp_socket recvfrom;
> +')
> +interface(`netlabel_tcp_recvfrom',`
> + gen_require(`
> + type unlabeled_t;
> + ')
> +
> + allow $1 unlabeled_t:tcp_socket recvfrom;
> +')
Unlabeled_t is not declared in this module, so kernel should provide
these interfaces. To make things clearer, interfaces in corenetwork
should be added that just call the kernel interfaces. See
corenet_non_ipsec_sendrecv() (I realize its somewhat misnamed in light
of netlabel) and kernel_sendrecv_unlabeled_association() to see what I
mean by the above.
> +# sending netlabel'd packets does not require a selinux privilege, however
> +# receiving netlabel's packets does
> +allow staff_t unlabeled_t:{ tcp_socket udp_socket } recvfrom;
> +allow user_t unlabeled_t:{ tcp_socket udp_socket } recvfrom;
Should be added to userdomain via interface. Also, why not sysadm_t?
> +# allow sysadm_t to run netlabelctl
> +domain_auto_trans(sysadm_t,netlabelctl_exec_t,netlabelctl_t)
Also should be added to userdomain via interface. A domtrans interface
should be added to this module. See clock_domtrans() for an example.
--
Chris PeBenito
Tresys Technology, LLC
(410) 290-1411 x150
--
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:[~2006-10-10 18:09 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-10 17:15 [RFC 0/2] NetLabel changes for Reference policy paul.moore
2006-10-10 17:15 ` [RFC 1/2] Reference policy: NetLabel policy additions paul.moore
2006-10-10 18:10 ` Christopher J. PeBenito [this message]
2006-10-10 19:52 ` Paul Moore
2006-10-10 21:07 ` Paul Moore
2006-10-10 17:15 ` [RFC 2/2] Reference policy: Restrict NetLabel to same MLS label connections by default paul.moore
2006-10-10 18:12 ` Christopher J. PeBenito
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=1160503804.20774.82.camel@sgc \
--to=cpebenito@tresys.com \
--cc=paul.moore@hp.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.