No description
Find a file
Daniel Borkmann 57ebc6230f Merge branch 'bpf-sockmap-tls-fixes'
Jakub Kicinski says:

====================
John says:

Resolve a series of splats discovered by syzbot and an unhash
TLS issue noted by Eric Dumazet.

The main issues revolved around interaction between TLS and
sockmap tear down. TLS and sockmap could both reset sk->prot
ops creating a condition where a close or unhash op could be
called forever. A rare race condition resulting from a missing
rcu sync operation was causing a use after free. Then on the
TLS side dropping the sock lock and re-acquiring it during the
close op could hang. Finally, sockmap must be deployed before
tls for current stack assumptions to be met. This is enforced
now. A feature series can enable it.

To fix this first refactor TLS code so the lock is held for the
entire teardown operation. Then add an unhash callback to ensure
TLS can not transition from ESTABLISHED to LISTEN state. This
transition is a similar bug to the one found and fixed previously
in sockmap. Then apply three fixes to sockmap to fix up races
on tear down around map free and close. Finally, if sockmap
is destroyed before TLS we add a new ULP op update to inform
the TLS stack it should not call sockmap ops. This last one
appears to be the most commonly found issue from syzbot.

v4:
 - fix some use after frees;
 - disable disconnect work for offload (ctx lifetime is much
   more complex);
 - remove some of the dead code which made it hard to understand
   (for me) that things work correctly (e.g. the checks TLS is
   the top ULP);
 - add selftets.
====================

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
2019-07-22 16:04:18 +02:00
arch powerpc updates for 5.3 2019-07-13 16:08:36 -07:00
block for-5.3/block-20190708 2019-07-09 10:45:06 -07:00
certs Revert "Merge tag 'keys-acl-20190703' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs" 2019-07-10 18:43:43 -07:00
crypto USB / PHY patches for 5.3-rc1 2019-07-11 15:40:06 -07:00
Documentation net/tls: fix transition through disconnect with close 2019-07-22 16:04:17 +02:00
drivers ag71xx: fix return value check in ag71xx_probe() 2019-07-18 20:33:48 -07:00
fs for-5.3/io_uring-20190711 2019-07-13 10:36:53 -07:00
include bpf: sockmap/tls, close can race with map free 2019-07-22 16:04:17 +02:00
init Kbuild updates for v5.3 2019-07-12 16:03:16 -07:00
ipc treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 441 2019-06-05 17:37:17 +02:00
kernel Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf 2019-07-18 14:04:45 -07:00
lib for-5.3/io_uring-20190711 2019-07-13 10:36:53 -07:00
LICENSES LICENSES: Rename other to deprecated 2019-05-03 06:34:32 -06:00
mm Driver Core and debugfs changes for 5.3-rc1 2019-07-12 12:24:03 -07:00
net bpf: sockmap/tls, close can race with map free 2019-07-22 16:04:17 +02:00
samples Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf 2019-07-18 14:04:45 -07:00
scripts powerpc updates for 5.3 2019-07-13 16:08:36 -07:00
security Merge branch 'akpm' (patches from Andrew) 2019-07-12 11:40:28 -07:00
sound Driver Core and debugfs changes for 5.3-rc1 2019-07-12 12:24:03 -07:00
tools selftests/tls: add shutdown tests 2019-07-22 16:04:17 +02:00
usr kbuild: compile-test exported headers to ensure they are self-contained 2019-07-08 23:13:57 +09:00
virt ARM: 2019-07-12 15:35:14 -07:00
.clang-format Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2019-04-17 11:26:25 -07:00
.cocciconfig
.get_maintainer.ignore Opt out of scripts/get_maintainer.pl 2019-05-16 10:53:40 -07:00
.gitattributes
.gitignore kbuild: do not create wrappers for header-test-y 2019-07-09 10:10:27 +09:00
.mailmap MAINTAINERS: Update my email address 2019-06-18 14:37:27 +01:00
COPYING COPYING: use the new text with points to the license files 2018-03-23 12:41:45 -06:00
CREDITS Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2019-06-25 01:32:59 +02:00
Kbuild Kbuild updates for v5.1 2019-03-10 17:48:21 -07:00
Kconfig docs: kbuild: convert docs to ReST and rename to *.rst 2019-06-14 14:21:21 -06:00
MAINTAINERS Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf 2019-07-18 14:04:45 -07:00
Makefile Kbuild updates for v5.3 2019-07-12 16:03:16 -07:00
README Drop all 00-INDEX files from Documentation/ 2018-09-09 15:08:58 -06:00

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the Restructured Text markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.