HomeFreeBSD

sctp: Always check for a vanishing inpcb when processing COOKIE-ECHO

Description

sctp: Always check for a vanishing inpcb when processing COOKIE-ECHO

We previously did this only in the normal case where no association
exists yet. However, it is not safe to process COOKIE-ECHO even if an
association exists, as sctp_process_cookie_existing() may dereference
the socket pointer.

See also commit 0c7dc84076b64ef74c24f04400d572f75ef61bb4.

Reviewed by: tuexen
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D31755

Details

Provenance
markjAuthored on Sep 1 2021, 2:28 PM
Reviewer
tuexen
Differential Revision
D31755: sctp: Always check for a vanishing inpcb when processing COOKIE-ECHO
Parents
rGd35be50f5779: sctp: Hold association locks across socket wakeups when freeing
Branches
Unknown
Tags
Unknown