From: Karl MacMillan <kmacmillan@mentalrootkit.com>
To: Stephen Smalley <sds@tycho.nsa.gov>
Cc: James Athey <jathey@tresys.com>, selinux@tycho.nsa.gov
Subject: Re: [PATCH] libsemanage: add genhomedircon path to semanage.conf parsing
Date: Mon, 02 Oct 2006 11:22:06 -0400 [thread overview]
Message-ID: <45212E9E.5050208@mentalrootkit.com> (raw)
In-Reply-To: <1159542044.8496.68.camel@moss-spartans.epoch.ncsc.mil>
Stephen Smalley wrote:
> On Thu, 2006-09-28 at 17:31 -0400, James Athey wrote:
>
>> This patch adds the ability to specify a path to genhomedircon in semanage.conf, similar to specifying a path to setfiles or load_policy. For example:
>>
>> [genhomedircon]
>> path = /usr/local/sbin/genhomedircon_modified
>> args = -t $@
>> [end]
>>
>> Index: libsemanage/src/conf-parse.y
>> ===================================================================
>> --- libsemanage/src/conf-parse.y (revision 2032)
>> +++ libsemanage/src/conf-parse.y (working copy)
>> @@ -1,6 +1,7 @@
>> -/* Author: Jason Tang <jtang@tresys.com>
>> +/* Authors: Jason Tang <jtang@tresys.com>
>> + * James Athey <jathey@tresys.com>
>> *
>> - * Copyright (C) 2004-2005 Tresys Technology, LLC
>> + * Copyright (C) 2004-2006 Tresys Technology, LLC
>> *
>> * This library is free software; you can redistribute it and/or
>> * modify it under the terms of the GNU Lesser General Public
>> @@ -56,7 +57,7 @@
>> }
>>
>> %token MODULE_STORE VERSION EXPAND_CHECK FILE_MODE
>> -%token LOAD_POLICY_START SETFILES_START
>> +%token LOAD_POLICY_START SETFILES_START GENHOMEDIRCON_START
>> %token VERIFY_MOD_START VERIFY_LINKED_START VERIFY_KERNEL_START BLOCK_END
>> %token PROG_PATH PROG_ARGS
>> %token <s> ARG
>> @@ -137,6 +138,14 @@
>> YYABORT;
>> }
>> }
>> + | GENHOMEDIRCON_START {
>> + semanage_conf_external_prog_destroy(current_conf->genhomedircon);
>> + current_conf->genhomedircon = NULL;
>> + if (new_external_prog(¤t_conf->genhomedircon) == -1) {
>> + parse_errors++;
>> + YYABORT;
>> + }
>> + }
>> ;
>>
>> verify_block: verify_start external_opts BLOCK_END {
>> Index: libsemanage/src/conf-scan.l
>> ===================================================================
>> --- libsemanage/src/conf-scan.l (revision 2032)
>> +++ libsemanage/src/conf-scan.l (working copy)
>> @@ -1,6 +1,7 @@
>> -/* Author: Jason Tang <jtang@tresys.com>
>> +/* Authors: Jason Tang <jtang@tresys.com>
>> + * James Athey <jathey@tresys.com>
>> *
>> - * Copyright (C) 2004-2005 Tresys Technology, LLC
>> + * Copyright (C) 2004-2006 Tresys Technology, LLC
>> *
>> * This library is free software; you can redistribute it and/or
>> * modify it under the terms of the GNU Lesser General Public
>> @@ -43,6 +44,7 @@
>> file-mode return FILE_MODE;
>> "[load_policy]" return LOAD_POLICY_START;
>> "[setfiles]" return SETFILES_START;
>> +"[genhomedircon]" return GENHOMEDIRCON_START;
>> "[verify module]" return VERIFY_MOD_START;
>> "[verify linked]" return VERIFY_LINKED_START;
>> "[verify kernel]" return VERIFY_KERNEL_START;
>>
>
> Acked-by: Stephen Smalley <sds@tycho.nsa.gov>
>
>
Acked-by: Karl MacMillan <kmacmillan@mentalrootkit.com>
I will note, however, that we should eventually remove this parser to
remove the flex dependency in such a low-level library.
Karl
--
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.
prev parent reply other threads:[~2006-10-02 15:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-09-28 21:31 [PATCH] libsemanage: add genhomedircon path to semanage.conf parsing James Athey
2006-09-29 15:00 ` Stephen Smalley
2006-10-02 15:22 ` Karl MacMillan [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=45212E9E.5050208@mentalrootkit.com \
--to=kmacmillan@mentalrootkit.com \
--cc=jathey@tresys.com \
--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.