diff options
author | Ilya Lesokhin <ilyal@mellanox.com> | 2018-01-16 16:31:52 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-01-18 00:05:28 +0300 |
commit | d91c3e17f75f218022140dee18cf515292184a8f (patch) | |
tree | 16091e4f64022c88fd6d90704d133b945b2d0a5f /COPYING | |
parent | f8b39039cbf2a15f2b8c9f081e1cbd5dee00aaf5 (diff) | |
download | linux-d91c3e17f75f218022140dee18cf515292184a8f.tar.xz |
net/tls: Only attach to sockets in ESTABLISHED state
Calling accept on a TCP socket with a TLS ulp attached results
in two sockets that share the same ulp context.
The ulp context is freed while a socket is destroyed, so
after one of the sockets is released, the second second will
trigger a use after free when it tries to access the ulp context
attached to it.
We restrict the TLS ulp to sockets in ESTABLISHED state
to prevent the scenario above.
Fixes: 3c4d7559159b ("tls: kernel TLS support")
Reported-by: syzbot+904e7cd6c5c741609228@syzkaller.appspotmail.com
Signed-off-by: Ilya Lesokhin <ilyal@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'COPYING')
0 files changed, 0 insertions, 0 deletions