Commit Graph

43 Commits

Author SHA1 Message Date
joerg f9c2736326 Disable a couple of warnings until further investigation. 2017-01-11 12:19:43 +00:00
khorben 22024d321d Typo 2016-12-26 00:11:14 +00:00
ozaki-r 09973b35ac Separate nexthop caches from the routing table
By this change, nexthop caches (IP-MAC address pair) are not stored
in the routing table anymore. Instead nexthop caches are stored in
each network interface; we already have lltable/llentry data structure
for this purpose. This change also obsoletes the concept of cloning/cloned
routes. Cloned routes no longer exist while cloning routes still exist
with renamed to connected routes.

Noticeable changes are:
- Nexthop caches aren't listed in route show/netstat -r
  - sysctl(NET_RT_DUMP) doesn't return them
  - If RTF_LLDATA is specified, it returns nexthop caches
- Several definitions of routing flags and messages are removed
  - RTF_CLONING, RTF_XRESOLVE, RTF_LLINFO, RTF_CLONED and RTM_RESOLVE
- RTF_CONNECTED is added
  - It has the same value of RTF_CLONING for backward compatibility
- route's -xresolve, -[no]cloned and -llinfo options are removed
  - -[no]cloning remains because it seems there are users
  - -[no]connected is introduced and recommended
    to be used instead of -[no]cloning
- route show/netstat -r drops some flags
  - 'L' and 'c' are not seen anymore
  - 'C' now indicates a connected route
- Gateway value of a route of an interface address is now not
  a L2 address but "link#N" like a connected (cloning) route
- Proxy ARP: "arp -s ... pub" doesn't create a route

You can know details of behavior changes by seeing diffs under tests/.

Proposed on tech-net and tech-kern:
  http://mail-index.netbsd.org/tech-net/2016/03/11/msg005701.html
2016-04-04 07:37:07 +00:00
christos ffeb8dbf4e Define _KERNTYPES for things that need it. 2016-01-23 21:22:45 +00:00
khorben 532807571a Correct the example for the port range syntax 2015-12-28 19:32:22 +00:00
prlw1 c71e0745a5 fix typos 2015-08-11 16:06:52 +00:00
khorben 1d8d50afe0 Fix for PR kern/48109 (and its duplicate kern/49807)
As provided by Takahiro HAYASHI in PR kern/48109. Additional error
registration in ipf(8) by myself. Changes tested with GENERIC and
XEN3_DOM0. Thanks!

XXX pull-up netbsd-7
2015-04-02 00:12:58 +00:00
apb 1643706715 Fix the description of "< x" and "x <> y" for port numbers.
Patch for "< x" from Timo Buhrmester, and for "x <> y" from me.
2015-03-24 19:46:58 +00:00
martin 1f1e1f765b Do not compile md5.c (while usning system md5.h headers) - instead just
use the libc version.
Patch from Yasushi Oshima in PR bin/49580.
2015-01-17 11:25:30 +00:00
prlw1 f44489f8dc MKINET6=no build fixes
http://mail-index.netbsd.org/tech-net/2014/12/13/msg004898.html
2014-12-20 13:15:48 +00:00
darrenr 656cd05412 #552 destination port not zero after parsing nat rule
3561691 gethost never returns an ipv6 address
2014-06-29 08:58:01 +00:00
darrenr 19d3d51e86 #551 ipf.conf address structure not properly zero filled 2014-06-29 08:53:08 +00:00
darrenr e3b9d7cc54 #536 ipnat can try to print rule as dstlist incorrectly 2014-06-29 08:51:01 +00:00
darrenr 032564a48d 3561690 ipv6 address for test.hosts.dots in wrong byte order 2014-06-29 05:06:46 +00:00
darrenr b816f84312 #534 destination list hashing not endian neutral 2014-06-28 07:59:26 +00:00
christos 84b1233b4e From Darren Reed: #548 ipfstat hits a bus error on netbsd/sparc64 2014-06-16 12:37:58 +00:00
joerg ca8a9c6fc0 Fix build. 2014-06-12 22:15:25 +00:00
christos 10ed35f153 From Darren Reed:
This patch fixes "ipfstat" not displaying group rules and fixes problems
being able to remove individual rules using ipf/ipnat.

#547 rule parsing puts junk at the end of ipf rules
#546 ipfstat -io does not list rules in groups aside from 0

Due to unforeseen circumstances I'm not able to commit this myself.
2014-06-12 17:23:06 +00:00
christos 64a05fe87b fix unused variable warnings 2013-10-20 03:09:11 +00:00
joerg 3657cb7f1d Update LLVM/Clang snapshot to r191105. This brings in a better detection
of unused static variables and functions. Disable this for some external
code and for ioconf.c in the kernel.
2013-09-21 22:28:12 +00:00
christos eb1b7900cb ipfitler -> ipfilter 2013-05-08 18:20:14 +00:00
dsl 3a052f167f There is some very dubious code to locate the values of
tcb.rcv_adv, tcb.snd_nxt and tcb.rcv_nxt for a socket.
so set CPPFLAGS+=      -D_KMEMUSER
2013-01-02 18:41:49 +00:00
dsl 29dbe6c092 # There is some very dubious code to locate the values of
# tcb.rcv_adv, tcb.snd_nxt and tcb.rcv_nxt for a socket.
so add: CPPFLAGS+=     -D_KMEMUSER
2013-01-02 15:50:34 +00:00
nakayama b41cd0dbf9 Remove ipl overwrite. Which was missed in previous. 2012-10-27 20:07:12 +00:00
christos f29054e9cf copy structures for alignment purposes 2012-10-26 23:05:14 +00:00
christos 48c5746230 Don't play stupid pet tricks with alignments and simplify the code not
to allocate/copy.
2012-10-22 04:35:17 +00:00
christos 83ff0d3d9d missed a const commit 2012-10-22 01:21:57 +00:00
christos 2f6d4dae96 - fix alignment issues in ipmon
- protoize ipmon.c, use void *, size_t instead of char *, int.
2012-10-21 22:57:48 +00:00
plunky 2bcdfeae54 install example rules from the 5.1.2 distribution in external/bsd/ipf/dist
rather than the old one..  "mediaone" does not seem to exist though, so
mark it obsolete
2012-09-15 17:33:27 +00:00
plunky 80f5e4f0af the result of the construct
#define FOO	defined(BAR)

#if FOO
 [conditional code]
#endif

is "undefined", according to C99 6.10.1 note 4. So, change code like
that to use the following paradigm

#if defined(BAR)
#define FOO	1
#else
#define FOO	0
#endif

#if FOO
 [conditional code]
#endif
2012-09-15 16:56:05 +00:00
martin e45fceb35a Fix printf formats 2012-07-22 18:09:16 +00:00
darrenr 13885a6659 Merge IPFilter 5.1.2 into HEAD 2012-07-22 14:27:35 +00:00
darrenr c9d5dc6c77 Import IPFilter 5.1.2 2012-07-22 13:44:10 +00:00
martin d6ad405412 PRIu64 is not the right format string for unsigned long long. 2012-03-25 09:50:45 +00:00
tron 288a9e6b4c Set "BINDIR" to get binaries installed in the correct directory. 2012-03-24 18:27:16 +00:00
christos fe7112e3e3 bring back all our fixes. 2012-03-24 02:19:00 +00:00
christos e7d50bf676 Make this build from our own tree. 2012-03-24 02:08:34 +00:00
matt 15d35d9c93 Use sys/external, not sys/dist 2012-03-24 00:32:50 +00:00
christos 500828b37a deal with tests 2012-03-23 23:14:34 +00:00
christos 8e2bdc9a64 Build gluons 2012-03-23 21:29:44 +00:00
christos 37fde22ea8 make this work again. Kill tests and kernel module for now 2012-03-23 21:29:34 +00:00
christos ccd7c017b0 kill caddr_t 2012-03-23 21:28:57 +00:00
christos bc4097aacf import 5.1.1 2012-03-23 21:19:53 +00:00