From: cpebenito@tresys.com (Christopher J. PeBenito)
To: refpolicy@oss.tresys.com
Subject: [refpolicy] [PATCH 1/1] Separate domtrans/run interfaces for portage_fetch
Date: Tue, 13 Sep 2011 12:34:04 -0400 [thread overview]
Message-ID: <4E6F85FC.8040603@tresys.com> (raw)
In-Reply-To: <20110909192712.GA32612@siphos.be>
On 09/09/11 15:27, Sven Vermeulen wrote:
> Since the introduction of the portage_fetch_t domain, access to the
> domain was governed through the portage_domtrans and portage_run
> interfaces. To support calling portage only (but no fetch domain) or
> vice versa, the interfaces need to be split up.
>
> In this patch, we introduce the interfaces portage_domtrans_fetch and
> portage_run_fetch which will be used later in the domains that need to
> call portage/layman/emerge-webrsync/...
This doesn't remove the portage fetch transition in portage_domtrans(), nor does it update any callers that actually need the fetch transition.
> Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
> ---
> portage.if | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 files changed, 50 insertions(+), 0 deletions(-)
>
> diff --git a/portage.if b/portage.if
> index 9f7d652..ea892d1 100644
> --- a/portage.if
> +++ b/portage.if
> @@ -213,6 +213,56 @@ interface(`portage_compile_domain',`
>
> ########################################
> ## <summary>
> +## Execute tree management functions (fetching, layman, ...)
> +## in the portage_fetch_t domain.
> +## </summary>
> +## <param name="domain">
> +## <summary>
> +## Domain allowed to transition.
> +## </summary>
> +## </param>
> +#
> +interface(`portage_domtrans_fetch',`
> + gen_require(`
> + type portage_fetch_t, portage_fetch_exec_t;
> + ')
> +
> + files_search_usr($1)
> + corecmd_search_bin($1)
> +
> + domtrans_pattern($1, portage_fetch_exec_t, portage_fetch_t)
> +')
> +
> +########################################
> +## <summary>
> +## Execute tree management functions (fetching, layman, ...)
> +## in the portage_fetch_t domain, and allow the specified role
> +## the portage_fetch_t domain.
> +## </summary>
> +## <param name="domain">
> +## <summary>
> +## Domain allowed to transition.
> +## </summary>
> +## </param>
> +## <param name="role">
> +## <summary>
> +## The role to allow the portage domain.
> +## </summary>
> +## </param>
> +## <rolecap/>
> +#
> +interface(`portage_run_fetch',`
> + gen_require(`
> + type portage_fetch_t;
> + ')
> +
> + portage_domtrans_fetch($1)
> + role $2 types portage_fetch_t;
> +')
> +
> +
> +########################################
> +## <summary>
> ## Execute gcc-config in the gcc_config domain.
> ## </summary>
> ## <param name="domain">
--
Chris PeBenito
Tresys Technology, LLC
www.tresys.com | oss.tresys.com
prev parent reply other threads:[~2011-09-13 16:34 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-09 19:27 [refpolicy] [PATCH 1/1] Separate domtrans/run interfaces for portage_fetch Sven Vermeulen
2011-09-13 16:34 ` Christopher J. PeBenito [this message]
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=4E6F85FC.8040603@tresys.com \
--to=cpebenito@tresys.com \
--cc=refpolicy@oss.tresys.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.