svn commit: r347656 - stable/11/sys/netinet
Michael Tuexen
tuexen at FreeBSD.org
Thu May 16 08:42:21 UTC 2019
Author: tuexen
Date: Thu May 16 08:42:20 2019
New Revision: 347656
URL: https://svnweb.freebsd.org/changeset/base/347656
Log:
MFC r343951:
Fix locking for IPPROTO_SCTP level SCTP_DEFAULT_PRINFO socket option.
This problem occurred when calling setsockopt() will invalid parameters.
This issue was found by running syzkaller.
Modified:
stable/11/sys/netinet/sctp_usrreq.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/netinet/sctp_usrreq.c
==============================================================================
--- stable/11/sys/netinet/sctp_usrreq.c Thu May 16 08:40:10 2019 (r347655)
+++ stable/11/sys/netinet/sctp_usrreq.c Thu May 16 08:42:20 2019 (r347656)
@@ -6209,6 +6209,9 @@ sctp_setopt(struct socket *so, int optname, void *optv
SCTP_FIND_STCB(inp, stcb, info->pr_assoc_id);
if (info->pr_policy > SCTP_PR_SCTP_MAX) {
+ if (stcb) {
+ SCTP_TCB_UNLOCK(stcb);
+ }
SCTP_LTRACE_ERR_RET(inp, NULL, NULL, SCTP_FROM_SCTP_USRREQ, EINVAL);
error = EINVAL;
break;
More information about the svn-src-stable-11
mailing list