Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit ab2e937e authored by Alexey Kodanev's avatar Alexey Kodanev Committed by Usaamah Patel
Browse files

UPSTREAM: dccp: check sk for closed state in dccp_sendmsg()

This fixes CVE-2018-1130.
(https://github.com/torvalds/linux/commit/67f93df79aeefc3add4e4b31a752600f834236e2

)

dccp_disconnect() sets 'dp->dccps_hc_tx_ccid' tx handler to NULL,
therefore if DCCP socket is disconnected and dccp_sendmsg() is
called after it, it will cause a NULL pointer dereference in
dccp_write_xmit().

This crash and the reproducer was reported by syzbot. Looks like
it is reproduced if commit 69c64866ce07 ("dccp: CVE-2017-8824:
use-after-free in DCCP code") is applied.

Change-Id: I548d41f19110b62854f1d65feb944c715894d45b
Reported-by: default avatar <syzbot+f99ab3887ab65d70f816@syzkaller.appspotmail.com>
Signed-off-by: default avatarAlexey Kodanev <alexey.kodanev@oracle.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent afb6777a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment