Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sctp_pcb_finish does not destroy sctp_it_ctl.it_mtx if __Userspace__ is true #713

Open
docfaraday opened this issue Jun 12, 2024 · 0 comments

Comments

@docfaraday
Copy link

The SCTP_ITERATOR_LOCK_DESTROY call is wrapped in an #if !(defined(FreeBSD) && !defined(Userspace)) check:

https://github.com/sctplab/usrsctp/blame/master/usrsctplib/netinet/sctp_pcb.c#L6874

The corresponding call to SCTP_ITERATOR_LOCK_INIT is not wrapped in that check:

https://github.com/sctplab/usrsctp/blob/master/usrsctplib/netinet/sctp_bsd_addr.c#L180

This means that shutting down the sctp stack and re-initializing it will lead to undefined behavior from a double init, unless I'm missing something.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant