From: Pascal Ouyang <xin.ouyang@windriver.com>
To: <rongqing.li@windriver.com>, <yocto@yoctoproject.org>
Subject: Re: [PATCH 1/1] refpolicy: allow portmap to create portmap_t type socket
Date: Thu, 13 Feb 2014 17:31:15 +0800 [thread overview]
Message-ID: <52FC90E3.40804@windriver.com> (raw)
In-Reply-To: <8089f0d19f757ecf65f957d6a196e66c90bd7911.1392019016.git.rongqing.li@windriver.com>
于 14-2-10 下午3:58, rongqing.li@windriver.com 写道:
> From: Roy Li <rongqing.li@windriver.com>
>
> Signed-off-by: Roy Li <rongqing.li@windriver.com>
> ---
> .../portmap-allow-portmap-to-create-socket.patch | 28 ++++++++++++++++++++
> .../refpolicy/refpolicy_2.20130424.inc | 1 +
> 2 files changed, 29 insertions(+)
> create mode 100644 recipes-security/refpolicy/refpolicy-2.20130424/portmap-allow-portmap-to-create-socket.patch
>
> diff --git a/recipes-security/refpolicy/refpolicy-2.20130424/portmap-allow-portmap-to-create-socket.patch b/recipes-security/refpolicy/refpolicy-2.20130424/portmap-allow-portmap-to-create-socket.patch
> new file mode 100644
> index 0000000..aa89a98
> --- /dev/null
> +++ b/recipes-security/refpolicy/refpolicy-2.20130424/portmap-allow-portmap-to-create-socket.patch
> @@ -0,0 +1,28 @@
> +portmap: allow portmap to manage portmap_t type socket
> +
> +Upstream-Status: Pending
> +
> +portmap needs to create socket to receive message
> +
> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
> +---
> + policy/modules/contrib/portmap.te | 3 +++
> + 1 file changed, 3 insertions(+)
> +
> +diff --git a/policy/modules/contrib/portmap.te b/policy/modules/contrib/portmap.te
> +index 18b255e..bacf66b 100644
> +--- a/policy/modules/contrib/portmap.te
> ++++ b/policy/modules/contrib/portmap.te
> +@@ -16,6 +16,9 @@ type portmap_helper_exec_t;
> + init_system_domain(portmap_helper_t, portmap_helper_exec_t)
> + role portmap_helper_roles types portmap_helper_t;
> +
> ++allow portmap_t self:tcp_socket create_socket_perms;
> ++allow portmap_t self:udp_socket create_socket_perms;
> ++
> + type portmap_initrc_exec_t;
> + init_script_file(portmap_initrc_exec_t)
> +
> +--
> +1.7.10.4
> +
> diff --git a/recipes-security/refpolicy/refpolicy_2.20130424.inc b/recipes-security/refpolicy/refpolicy_2.20130424.inc
> index a052a2c..5d55030 100644
> --- a/recipes-security/refpolicy/refpolicy_2.20130424.inc
> +++ b/recipes-security/refpolicy/refpolicy_2.20130424.inc
> @@ -52,6 +52,7 @@ SRC_URI += "file://poky-policy-fix-xconsole_device_t-as-a-dev_node.patch \
> file://poky-policy-fix-dmesg-to-use-dev-kmsg.patch \
> file://hostname-do-not-audit-attempts-by-hostname-to-read-a.patch \
> file://sysnetwork-dhcpc-binds-socket-to-random-high-udp-por.patch \
> + file://portmap-allow-portmap-to-create-socket.patch \
> "
>
> # Backport from upstream
>
Ack.
These rules are in old versions, and droped in 12d4d8.
https://github.com/xinpascal/selinux-refpolicy-contrib/commit/12d4d86602452c9b6fd6f74fc47ce29d5ae55ba9
It is better if you have time to dig.
Any way, I agree to merge this.
Thanks, Roy. :)
--
- Pascal
prev parent reply other threads:[~2014-02-13 9:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-10 7:58 [PATCH 0/1] refpolicy: allow portmap to create portmap_t type socket rongqing.li
2014-02-10 7:58 ` [PATCH 1/1] " rongqing.li
2014-02-13 9:31 ` Pascal Ouyang [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=52FC90E3.40804@windriver.com \
--to=xin.ouyang@windriver.com \
--cc=rongqing.li@windriver.com \
--cc=yocto@yoctoproject.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 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.