lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20191107.151225.1298112792540927971.davem@davemloft.net>
Date:   Thu, 07 Nov 2019 15:12:25 -0800 (PST)
From:   David Miller <davem@...emloft.net>
To:     stranche@...eaurora.org
Cc:     netdev@...r.kernel.org, subashab@...eaurora.org
Subject: Re: [PATCH net-next v2] net: Fail explicit bind to local reserved
 ports

From: Sean Tranchetti <stranche@...eaurora.org>
Date: Mon,  4 Nov 2019 17:25:41 -0700

> Reserved ports may have some special use cases which are not suitable for
> use by general userspace applications. Currently, ports specified in
> ip_local_reserved_ports will not be returned only in case of automatic port
> assignment.
> 
> In some cases, it maybe required to prevent the host from assigning the
> ports even in case of explicit binds. Consider the case of a transparent
> proxy where packets are being redirected. In case a socket matches this
> connection, packets from this application would be incorrectly sent to one
> of the endpoints.
> 
> Add a boolean sysctl flag 'reserved_port_bind'. Default value is 1 which
> preserves the existing behavior. Setting the value to 0 will prevent
> userspace applications from binding to these ports even when they are
> explicitly requested.
> 
> Signed-off-by: Sean Tranchetti <stranche@...eaurora.org>
> Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@...eaurora.org>

I think that someone with CAP_NET_BIND_SERVICE should be able to
override this.

Really, this is just extending the usual 0-->PROT_SOCK restriction.

This whole area is a mess of knobs and conditions, so I'd rather see
this implemented with some consolidation rather than layering yet
another thing on top of what we already have.

Thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ