Date: Sat, 4 May 2019 10:06:18 +0000 (UTC) From: Michael Tuexen <tuexen@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org Subject: svn commit: r347091 - stable/12/sys/netinet Message-ID: <201905041006.x44A6Inw097778@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: tuexen Date: Sat May 4 10:06:17 2019 New Revision: 347091 URL: https://svnweb.freebsd.org/changeset/base/347091 Log: MFC r343960: Fix a locking issue in the IPPROTO_SCTP level SCTP_PEER_ADDR_THLDS socket option. The problem affects only setsockopt with invalid parameters. This issue was found by syzkaller. Modified: stable/12/sys/netinet/sctp_usrreq.c Directory Properties: stable/12/ (props changed) Modified: stable/12/sys/netinet/sctp_usrreq.c ============================================================================== --- stable/12/sys/netinet/sctp_usrreq.c Sat May 4 10:04:00 2019 (r347090) +++ stable/12/sys/netinet/sctp_usrreq.c Sat May 4 10:06:17 2019 (r347091) @@ -6335,6 +6335,9 @@ sctp_setopt(struct socket *so, int optname, void *optv } } if (thlds->spt_pathcpthld != 0xffff) { + if (stcb != NULL) { + SCTP_TCB_UNLOCK(stcb); + } error = EINVAL; SCTP_LTRACE_ERR_RET(inp, NULL, NULL, SCTP_FROM_SCTP_USRREQ, error); break;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201905041006.x44A6Inw097778>