From: Chris PeBenito <pebenito@ieee.org>
To: "Sugar, David" <dsugar@tresys.com>,
"selinux-refpolicy@vger.kernel.org"
<selinux-refpolicy@vger.kernel.org>
Subject: Re: [PATCH 1/2] Add interface to read efivarfs_t directory
Date: Thu, 26 Dec 2019 12:00:56 -0500 [thread overview]
Message-ID: <fe3a48c2-0042-291b-7a37-2efeb6003955@ieee.org> (raw)
In-Reply-To: <20191217233412.585669-1-dsugar@tresys.com>
On 12/17/19 6:34 PM, Sugar, David wrote:
> I'm seeing the following denial when using 'efivars --list'. This
> interface grants access
> 2019-12-17T15:22:06-05:00 ip-tsc-black tag_audit_log: type=AVC msg=audit(1576596109.149:95): avc: denied { read } for pid=2329 comm="efivar" name="/" dev="efivarfs" ino=11266 scontext=system_u:system_r:my_app_t:s0 tcontext=system_u:object_r:efivarfs_t:s0 tclass=dir permissive=1
>
> Signed-off-by: Dave Sugar <dsugar@tresys.com>
> ---
> policy/modules/kernel/filesystem.if | 18 ++++++++++++++++++
> 1 file changed, 18 insertions(+)
>
> diff --git a/policy/modules/kernel/filesystem.if b/policy/modules/kernel/filesystem.if
> index 62911f12..98f3af5d 100644
> --- a/policy/modules/kernel/filesystem.if
> +++ b/policy/modules/kernel/filesystem.if
> @@ -1982,6 +1982,24 @@ interface(`fs_manage_dos_files',`
> manage_files_pattern($1, dosfs_t, dosfs_t)
> ')
>
> +########################################
> +## <summary>
> +## List dirs in efivarfs filesystem.
> +## </summary>
> +## <param name="domain">
> +## <summary>
> +## Domain allowed access.
> +## </summary>
> +## </param>
> +#
> +interface(`fs_list_efivars',`
> + gen_require(`
> + type efivarfs_t;
> + ')
> +
> + list_dirs_pattern($1, efivarfs_t, efivarfs_t)
> +')
> +
> #######################################
> ## <summary>
> ## Read files in efivarfs
Merged.
--
Chris PeBenito
prev parent reply other threads:[~2019-12-26 17:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-17 23:34 [PATCH 1/2] Add interface to read efivarfs_t directory Sugar, David
2019-12-17 23:34 ` [PATCH 2/2] Fix indent to match the rest of the file (space -> tab) Sugar, David
2019-12-26 17:00 ` Chris PeBenito
2019-12-26 17:00 ` Chris 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=fe3a48c2-0042-291b-7a37-2efeb6003955@ieee.org \
--to=pebenito@ieee.org \
--cc=dsugar@tresys.com \
--cc=selinux-refpolicy@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).