HomeFreeBSD

Since r353292 on input path we are always in network epoch, when

Description

Since r353292 on input path we are always in network epoch, when
we lookup PCBs. Thus, do not enter epoch recursively in
in_pcblookup_hash() and in6_pcblookup_hash(). Same applies to
tcp_ctlinput() and tcp6_ctlinput().

This leaves several sysctl(9) handlers that return PCB credentials
unprotected. Add epoch enter/exit to all of them.

Differential Revision: https://reviews.freebsd.org/D22197

Details

Provenance
glebiusAuthored on
Differential Revision
D22197: Refactor PCB hash read lock (the epoch)
Parents
rS354476: Remove unnecessary recursive epoch enter via INP_INFO_RLOCK
Branches
Unknown
Tags
Unknown