From: David Miller <davem@davemloft.net>
To: kjlx@templeofstupid.com
Cc: stephen@networkplumber.org, netdev@vger.kernel.org
Subject: Re: [PATCH v2 net-next] Introduce a sysctl that modifies the value of PROT_SOCK.
Date: Thu, 12 Jan 2017 09:22:13 -0500 (EST) [thread overview]
Message-ID: <20170112.092213.864894939381841760.davem@davemloft.net> (raw)
In-Reply-To: <20170112065225.GB2345@templeofstupid.com>
From: Krister Johansen <kjlx@templeofstupid.com>
Date: Wed, 11 Jan 2017 22:52:25 -0800
> Add net.ipv4.ip_unprotected_port_start, which is a per namespace sysctl
> that denotes the first unprotected inet port in the namespace. To
> disable all protected ports set this to zero. It also checks for
> overlap with the local port range. The protected and local range may
> not overlap.
>
> The use case for this change is to allow containerized processes to bind
> to priviliged ports, but prevent them from ever being allowed to modify
> their container's network configuration. The latter is accomplished by
> ensuring that the network namespace is not a child of the user
> namespace. This modification was needed to allow the container manager
> to disable a namespace's priviliged port restrictions without exposing
> control of the network namespace to processes in the user namespace.
>
> Signed-off-by: Krister Johansen <kjlx@templeofstupid.com>
This is what CAP_NET_BIND_SERVICE is for, and why it is a separate
network privilege, please use it.
next prev parent reply other threads:[~2017-01-12 14:22 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-31 4:11 [PATCH] Introduce a sysctl that modifies the value of PROT_SOCK Krister Johansen
2016-12-31 20:55 ` Stephen Hemminger
2017-01-04 10:19 ` Krister Johansen
2017-01-12 6:52 ` [PATCH v2 net-next] " Krister Johansen
2017-01-12 14:22 ` David Miller [this message]
2017-01-14 0:13 ` Krister Johansen
2017-01-12 14:39 ` Eric Dumazet
2017-01-14 0:11 ` Krister Johansen
2017-01-21 1:49 ` [PATCH v3 " Krister Johansen
2017-01-23 20:39 ` David Miller
2017-01-24 17:11 ` David Miller
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=20170112.092213.864894939381841760.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=kjlx@templeofstupid.com \
--cc=netdev@vger.kernel.org \
--cc=stephen@networkplumber.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).