提交 ac71676c 编写于 作者: M Maciej Żenczykowski 提交者: David S. Miller

net: Fix a documentation bug wrt. ip_unprivileged_port_start

It cannot overlap with the local port range - ie. with autobind selectable
ports - and not with reserved ports.

Indeed 'ip_local_reserved_ports' isn't even a range, it's a (by default
empty) set.

Fixes: 4548b683 ("Introduce a sysctl that modifies the value of PROT_SOCK.")
Signed-off-by: NMaciej Żenczykowski <maze@google.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 fd567ac2
...@@ -904,8 +904,9 @@ ip_local_port_range - 2 INTEGERS ...@@ -904,8 +904,9 @@ ip_local_port_range - 2 INTEGERS
Defines the local port range that is used by TCP and UDP to Defines the local port range that is used by TCP and UDP to
choose the local port. The first number is the first, the choose the local port. The first number is the first, the
second the last local port number. second the last local port number.
If possible, it is better these numbers have different parity. If possible, it is better these numbers have different parity
(one even and one odd values) (one even and one odd value).
Must be greater than or equal to ip_unprivileged_port_start.
The default values are 32768 and 60999 respectively. The default values are 32768 and 60999 respectively.
ip_local_reserved_ports - list of comma separated ranges ip_local_reserved_ports - list of comma separated ranges
...@@ -943,8 +944,8 @@ ip_unprivileged_port_start - INTEGER ...@@ -943,8 +944,8 @@ ip_unprivileged_port_start - INTEGER
This is a per-namespace sysctl. It defines the first This is a per-namespace sysctl. It defines the first
unprivileged port in the network namespace. Privileged ports unprivileged port in the network namespace. Privileged ports
require root or CAP_NET_BIND_SERVICE in order to bind to them. require root or CAP_NET_BIND_SERVICE in order to bind to them.
To disable all privileged ports, set this to 0. It may not To disable all privileged ports, set this to 0. They must not
overlap with the ip_local_reserved_ports range. overlap with the ip_local_port_range.
Default: 1024 Default: 1024
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册