- macOS 10.4+
Cookie value specified when the filter attach was called.
The socket the filter is attached to.
The addres the data is from, may be NULL if the socket is connected.
The data being received. Control data may appear in the mbuf chain, be sure to check the mbuf types to find control data.
Control data being passed separately from the data.
Flags to indicate if this is out of band data or a record.
Return: 0 - The caller will continue with normal processing of the data. EJUSTRETURN - The caller will stop processing the data, the data will not be freed. Anything Else - The caller will free the data and stop processing.
sf_data_in_func is called to filter incoming data. If your filter intercepts data for later reinjection, it must queue all incoming data to preserve the order of the data. Use sock_inject_data_in to later reinject this data if you return EJUSTRETURN. Warning: This filter is on the data path. Do not spend excesive time. Do not wait for data on another socket.