Commit Graph

15 Commits

Author SHA1 Message Date
mycroft 6ac2d6c797 For pfil_add_hook(..., PFIL_ALL, ...), if we fail to add the output filter,
make sure to remove the input filter.
2000-02-23 02:35:42 +00:00
darrenr fdf401f582 only call pfil_list_add with one of PFIL_IN or PFIL_OUT defined 2000-02-22 11:30:22 +00:00
darrenr 81069f7a58 return int from pfil_add_hook and pfil_remove_hook to indicate failure
or success, rather than panic'ing
2000-02-22 10:45:47 +00:00
darrenr 4da6dd2324 fix from Mike Pelley to add filters in the reverse order for output
compared with input.
2000-02-22 10:18:49 +00:00
darrenr 4b3916780b pass "struct pfil_head *" to pfil_add_hook and pfil_remove hook rather
than "struct protosw *".
2000-02-20 00:56:33 +00:00
darrenr fd7edad6c3 Change the use of pfil hooks. There is no longer a single list of all
pfil information, instead, struct protosw now contains a structure
which caontains list heads, etc.  The per-protosw pfil struct is passed
to pfil_hook_get(), along with an in/out flag to get the head of the
relevant filter list.  This has been done for only IPv4 and IPv6, at
present, with these patches only enabling filtering for IPPROTO_IP and
IPPROTO_IPV6, although it is possible to have tcp/udp, etc, dedicated
filters now also.  The ipfilter code has been updated to only filter
IPv4 packets - next major release of ipfilter is required for ipv6.
2000-02-17 10:59:32 +00:00
mrg 755a273d97 pass a pointer to the list, rather than passing a copy of it, when removing
functions from the pfil hook lists.  this fixes the "missing function" problem.
also, re-add support for WAITOK that was lost several deltas ago.
1999-10-10 09:07:32 +00:00
mrg 1dd8c9f502 call pfil_list_add with the right flag, to ensure it goes into the right list.
from mike@pelley.com in PR#7802.
1999-06-18 05:59:20 +00:00
mrg 45159fa631 convert pfil(9) in and out lists from <sys/queue.h> LISTs to TAILQs, and
change pfil_add_hook to put output filters at the tail of the queue,
while continuing to place input filters at the head of the queue.  update
the two users of these functions, and document these changes.

fixes PR#4593.
1998-03-19 15:45:30 +00:00
mrg 74f573d85d remove advertising clause from all my licenses. 1997-10-10 05:39:47 +00:00
mrg 2cf2442208 remove pfil_bad. 1996-12-20 08:40:46 +00:00
christos a1dcf4b026 backout previous kprintf change 1996-10-13 02:10:01 +00:00
christos 10191279fb - printf -> kprintf, sprintf -> ksprintf 1996-10-10 22:59:41 +00:00
mrg 7b71cdec46 minor copyright update. 1996-10-05 23:41:53 +00:00
mrg a5f00f16bc move the packet filter hooks in to a saner location. while i'm here, rename
PACKET_FILTER to PFIL_HOOKS.
1996-09-14 14:40:20 +00:00