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] [thread-next>] [day] [month] [year] [list]
Message-Id: <1450114197-73779-1-git-send-email-lorenzo@google.com>
Date:	Tue, 15 Dec 2015 02:29:53 +0900
From:	Lorenzo Colitti <lorenzo@...gle.com>
To:	netdev@...r.kernel.org
Cc:	davem@...emloft.net, hannes@...essinduktion.org,
	eric.dumazet@...il.com, ek@...gle.com, tom@...bertland.com,
	zenczykowski@...il.com
Subject: Re: Add a SOCK_DESTROY operation to close sockets from userspace

Here is a an updated version. The external behaviour of this
patchset is the same as v4; for more details, see that cover
letter at http://www.spinics.net/lists/netdev/msg354303.html .

This version fixes two bugs spotted by Eric, and implements Tom's
suggestion of making the socket destroy code a per-protocol
function pointer so that in-kernel callers can use it. The
resulting code is a bit longer but a bit more generic, and
exposes fewer TCP implementation details.

The operation is still called SOCK_DESTROY, but given that its
main implementation is the TCP ABORT operation, and that the
word "destroy" is used in the inet_csk code to refer to freeing
a socket, and in the inet_diag code to refer to broadcasts about
sockets being freed, perhaps it could be renamed to SOCK_ABORT.

Tested using net_test. Tests check that TCP resets are sent in
the right states, that accept(), read() and connect() are
interrupted, that closing sockets makes the socket unusable,
and that destroying non-TCP sockets returns EOPNOTSUPP. Tests
at https://android-review.googlesource.com/#/c/187491/ .

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ