[avr32] move mmc driver to target specific modules.mk
[openwrt/svn-archive/archive.git] / package / kernel / modules / netfilter.mk
1
2 #
3 # Copyright (C) 2006-2010 OpenWrt.org
4 #
5 # This is free software, licensed under the GNU General Public License v2.
6 # See /LICENSE for more information.
7 #
8
9 NF_MENU:=Netfilter Extensions
10 NF_KMOD:=1
11 include $(INCLUDE_DIR)/netfilter.mk
12
13 define KernelPackage/ipt-core
14 SUBMENU:=$(NF_MENU)
15 TITLE:=Netfilter core
16 KCONFIG:= \
17 CONFIG_NETFILTER=y \
18 CONFIG_NETFILTER_ADVANCED=y \
19 $(KCONFIG_IPT_CORE)
20 FILES:=$(foreach mod,$(IPT_CORE-m),$(LINUX_DIR)/net/$(mod).ko)
21 AUTOLOAD:=$(call AutoLoad,40,$(notdir $(IPT_CORE-m)))
22 endef
23
24 define KernelPackage/ipt-core/description
25 Netfilter core kernel modules
26 Includes:
27 - comment
28 - limit
29 - LOG
30 - mac
31 - multiport
32 - REJECT
33 - TCPMSS
34 endef
35
36 $(eval $(call KernelPackage,ipt-core))
37
38
39 define AddDepends/ipt
40 SUBMENU:=$(NF_MENU)
41 DEPENDS+= kmod-ipt-core $(1)
42 endef
43
44
45 define KernelPackage/ipt-conntrack
46 TITLE:=Basic connection tracking modules
47 KCONFIG:=$(KCONFIG_IPT_CONNTRACK)
48 FILES:=$(foreach mod,$(IPT_CONNTRACK-m),$(LINUX_DIR)/net/$(mod).ko)
49 AUTOLOAD:=$(call AutoLoad,41,$(notdir $(IPT_CONNTRACK-m)))
50 $(call AddDepends/ipt)
51 endef
52
53 define KernelPackage/ipt-conntrack/description
54 Netfilter (IPv4) kernel modules for connection tracking
55 Includes:
56 - conntrack
57 - defrag
58 - iptables_raw
59 - NOTRACK
60 - state
61 endef
62
63 $(eval $(call KernelPackage,ipt-conntrack))
64
65
66 define KernelPackage/ipt-conntrack-extra
67 TITLE:=Extra connection tracking modules
68 KCONFIG:=$(KCONFIG_IPT_CONNTRACK_EXTRA)
69 FILES:=$(foreach mod,$(IPT_CONNTRACK_EXTRA-m),$(LINUX_DIR)/net/$(mod).ko)
70 AUTOLOAD:=$(call AutoLoad,42,$(notdir $(IPT_CONNTRACK_EXTRA-m)))
71 $(call AddDepends/ipt,+kmod-ipt-conntrack)
72 endef
73
74 define KernelPackage/ipt-conntrack-extra/description
75 Netfilter (IPv4) extra kernel modules for connection tracking
76 Includes:
77 - connbytes
78 - connmark/CONNMARK
79 - conntrack
80 - helper
81 - recent
82 endef
83
84 $(eval $(call KernelPackage,ipt-conntrack-extra))
85
86
87 define KernelPackage/ipt-filter
88 TITLE:=Modules for packet content inspection
89 KCONFIG:=$(KCONFIG_IPT_FILTER)
90 FILES:=$(foreach mod,$(IPT_FILTER-m),$(LINUX_DIR)/net/$(mod).ko)
91 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_FILTER-m)))
92 $(call AddDepends/ipt,+kmod-lib-textsearch)
93 endef
94
95 define KernelPackage/ipt-filter/description
96 Netfilter (IPv4) kernel modules for packet content inspection
97 Includes:
98 - layer7
99 - string
100 endef
101
102 $(eval $(call KernelPackage,ipt-filter))
103
104
105 define KernelPackage/ipt-ipopt
106 TITLE:=Modules for matching/changing IP packet options
107 KCONFIG:=$(KCONFIG_IPT_IPOPT)
108 FILES:=$(foreach mod,$(IPT_IPOPT-m),$(LINUX_DIR)/net/$(mod).ko)
109 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_IPOPT-m)))
110 $(call AddDepends/ipt)
111 endef
112
113 define KernelPackage/ipt-ipopt/description
114 Netfilter (IPv4) modules for matching/changing IP packet options
115 Includes:
116 - CLASSIFY
117 - dscp/DSCP
118 - ecn/ECN
119 - hl/HL
120 - length
121 - mark/MARK
122 - statistic
123 - tcpmss
124 - time
125 - ttl/TTL
126 - unclean
127 endef
128
129 $(eval $(call KernelPackage,ipt-ipopt))
130
131
132 define KernelPackage/ipt-ipsec
133 TITLE:=Modules for matching IPSec packets
134 KCONFIG:=$(KCONFIG_IPT_IPSEC)
135 FILES:=$(foreach mod,$(IPT_IPSEC-m),$(LINUX_DIR)/net/$(mod).ko)
136 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_IPSEC-m)))
137 $(call AddDepends/ipt)
138 endef
139
140 define KernelPackage/ipt-ipsec/description
141 Netfilter (IPv4) modules for matching IPSec packets
142 Includes:
143 - ah
144 - esp
145 - policy
146 endef
147
148 $(eval $(call KernelPackage,ipt-ipsec))
149
150
151 define KernelPackage/ipt-nat
152 TITLE:=Basic NAT targets
153 KCONFIG:=$(KCONFIG_IPT_NAT)
154 FILES:=$(foreach mod,$(IPT_NAT-m),$(LINUX_DIR)/net/$(mod).ko)
155 AUTOLOAD:=$(call AutoLoad,42,$(notdir $(IPT_NAT-m)))
156 $(call AddDepends/ipt,+kmod-ipt-conntrack)
157 endef
158
159 define KernelPackage/ipt-nat/description
160 Netfilter (IPv4) kernel modules for basic NAT targets
161 Includes:
162 - MASQUERADE
163 endef
164
165 $(eval $(call KernelPackage,ipt-nat))
166
167
168 define KernelPackage/ipt-nat-extra
169 TITLE:=Extra NAT targets
170 KCONFIG:=$(KCONFIG_IPT_NAT_EXTRA)
171 FILES:=$(foreach mod,$(IPT_NAT_EXTRA-m),$(LINUX_DIR)/net/$(mod).ko)
172 AUTOLOAD:=$(call AutoLoad,43,$(notdir $(IPT_NAT_EXTRA-m)))
173 $(call AddDepends/ipt,+kmod-ipt-nat)
174 endef
175
176 define KernelPackage/ipt-nat-extra/description
177 Netfilter (IPv4) kernel modules for extra NAT targets
178 Includes:
179 - NETMAP
180 - REDIRECT
181 endef
182
183 $(eval $(call KernelPackage,ipt-nat-extra))
184
185
186 define KernelPackage/ipt-nathelper
187 TITLE:=Basic Conntrack and NAT helpers
188 KCONFIG:=$(KCONFIG_IPT_NATHELPER)
189 FILES:=$(foreach mod,$(IPT_NATHELPER-m),$(LINUX_DIR)/net/$(mod).ko)
190 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_NATHELPER-m)))
191 $(call AddDepends/ipt,+kmod-ipt-nat)
192 endef
193
194 define KernelPackage/ipt-nathelper/description
195 Default Netfilter (IPv4) Conntrack and NAT helpers
196 Includes:
197 - ftp
198 - irc
199 - tftp
200 endef
201
202 $(eval $(call KernelPackage,ipt-nathelper))
203
204
205 define KernelPackage/ipt-nathelper-extra
206 TITLE:=Extra Conntrack and NAT helpers
207 KCONFIG:=$(KCONFIG_IPT_NATHELPER_EXTRA)
208 FILES:=$(foreach mod,$(IPT_NATHELPER_EXTRA-m),$(LINUX_DIR)/net/$(mod).ko)
209 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_NATHELPER_EXTRA-m)))
210 $(call AddDepends/ipt,+kmod-ipt-nat +kmod-lib-textsearch)
211 endef
212
213 define KernelPackage/ipt-nathelper-extra/description
214 Extra Netfilter (IPv4) Conntrack and NAT helpers
215 Includes:
216 - amanda
217 - h323
218 - mms
219 - pptp
220 - proto_gre
221 - sip
222 - snmp_basic
223 - broadcast
224 endef
225
226 $(eval $(call KernelPackage,ipt-nathelper-extra))
227
228
229 define KernelPackage/ipt-queue
230 TITLE:=Module for user-space packet queueing
231 KCONFIG:=$(KCONFIG_IPT_QUEUE)
232 FILES:=$(foreach mod,$(IPT_QUEUE-m),$(LINUX_DIR)/net/$(mod).ko)
233 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_QUEUE-m)))
234 $(call AddDepends/ipt)
235 endef
236
237 define KernelPackage/ipt-queue/description
238 Netfilter (IPv4) module for user-space packet queueing
239 Includes:
240 - QUEUE
241 endef
242
243 $(eval $(call KernelPackage,ipt-queue))
244
245
246 define KernelPackage/ipt-ulog
247 TITLE:=Module for user-space packet logging
248 KCONFIG:=$(KCONFIG_IPT_ULOG)
249 FILES:=$(foreach mod,$(IPT_ULOG-m),$(LINUX_DIR)/net/$(mod).ko)
250 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_ULOG-m)))
251 $(call AddDepends/ipt)
252 endef
253
254 define KernelPackage/ipt-ulog/description
255 Netfilter (IPv4) module for user-space packet logging
256 Includes:
257 - ULOG
258 endef
259
260 $(eval $(call KernelPackage,ipt-ulog))
261
262
263 define KernelPackage/ipt-debug
264 TITLE:=Module for debugging/development
265 KCONFIG:=$(KCONFIG_IPT_DEBUG)
266 DEFAULT:=n
267 FILES:=$(foreach mod,$(IPT_DEBUG-m),$(LINUX_DIR)/net/$(mod).ko)
268 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_DEBUG-m)))
269 $(call AddDepends/ipt)
270 endef
271
272 define KernelPackage/ipt-debug/description
273 Netfilter modules for debugging/development of the firewall
274 Includes:
275 - TRACE
276 endef
277
278 $(eval $(call KernelPackage,ipt-debug))
279
280
281 define KernelPackage/ipt-led
282 TITLE:=Module to trigger a LED with a Netfilter rule
283 KCONFIG:=$(KCONFIG_IPT_LED)
284 FILES:=$(foreach mod,$(IPT_LED-m),$(LINUX_DIR)/net/$(mod).ko)
285 AUTOLOAD:=$(call AutoLoad,61,$(notdir $(IPT_LED-m)))
286 $(call AddDepends/ipt)
287 endef
288
289 define KernelPackage/ipt-led/description
290 Netfilter target to trigger a LED when a network packet is matched.
291 endef
292
293 $(eval $(call KernelPackage,ipt-led))
294
295 define KernelPackage/ipt-tproxy
296 TITLE:=Transparent proxying support
297 DEPENDS+=+IPV6:kmod-ipv6
298 KCONFIG:= \
299 CONFIG_NETFILTER_TPROXY \
300 CONFIG_NETFILTER_XT_MATCH_SOCKET \
301 CONFIG_NETFILTER_XT_TARGET_TPROXY
302 FILES:= \
303 $(LINUX_DIR)/net/netfilter/nf_tproxy_core.ko \
304 $(foreach mod,$(IPT_TPROXY-m),$(LINUX_DIR)/net/$(mod).ko)
305 AUTOLOAD:=$(call AutoLoad,50,$(notdir nf_tproxy_core $(IPT_TPROXY-m)))
306 $(call AddDepends/ipt)
307 endef
308
309 define KernelPackage/ipt-tproxy/description
310 Kernel modules for Transparent Proxying
311 endef
312
313 $(eval $(call KernelPackage,ipt-tproxy))
314
315 define KernelPackage/ipt-tee
316 TITLE:=TEE support
317 KCONFIG:= \
318 CONFIG_NETFILTER_XT_TARGET_TEE
319 FILES:= \
320 $(LINUX_DIR)/net/netfilter/xt_TEE.ko \
321 $(foreach mod,$(IPT_TEE-m),$(LINUX_DIR)/net/$(mod).ko)
322 AUTOLOAD:=$(call AutoLoad,45,$(notdir nf_tee $(IPT_TEE-m)))
323 $(call AddDepends/ipt)
324 endef
325
326 define KernelPackage/ipt-tee/description
327 Kernel modules for TEE
328 endef
329
330 $(eval $(call KernelPackage,ipt-tee))
331
332
333 define KernelPackage/ipt-u32
334 TITLE:=U32 support
335 KCONFIG:= \
336 CONFIG_NETFILTER_XT_MATCH_U32
337 FILES:= \
338 $(LINUX_DIR)/net/netfilter/xt_u32.ko \
339 $(foreach mod,$(IPT_U32-m),$(LINUX_DIR)/net/$(mod).ko)
340 AUTOLOAD:=$(call AutoLoad,45,$(notdir nf_tee $(IPT_U32-m)))
341 $(call AddDepends/ipt)
342 endef
343
344 define KernelPackage/ipt-u32/description
345 Kernel modules for U32
346 endef
347
348 $(eval $(call KernelPackage,ipt-u32))
349
350
351 define KernelPackage/ipt-iprange
352 TITLE:=Module for matching ip ranges
353 KCONFIG:=$(KCONFIG_IPT_IPRANGE)
354 FILES:=$(foreach mod,$(IPT_IPRANGE-m),$(LINUX_DIR)/net/$(mod).ko)
355 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_IPRANGE-m)))
356 $(call AddDepends/ipt)
357 endef
358
359 define KernelPackage/ipt-iprange/description
360 Netfilter (IPv4) module for matching ip ranges
361 Includes:
362 - iprange
363 endef
364
365 $(eval $(call KernelPackage,ipt-iprange))
366
367
368 define KernelPackage/ipt-extra
369 TITLE:=Extra modules
370 KCONFIG:=$(KCONFIG_IPT_EXTRA)
371 FILES:=$(foreach mod,$(IPT_EXTRA-m),$(LINUX_DIR)/net/$(mod).ko)
372 AUTOLOAD:=$(call AutoLoad,45,$(notdir $(IPT_EXTRA-m)))
373 $(call AddDepends/ipt)
374 endef
375
376 define KernelPackage/ipt-extra/description
377 Other Netfilter (IPv4) kernel modules
378 Includes:
379 - owner
380 - physdev (if bridge support was enabled in kernel)
381 - pkttype
382 - quota
383 endef
384
385 $(eval $(call KernelPackage,ipt-extra))
386
387
388 define KernelPackage/ip6tables
389 SUBMENU:=$(NF_MENU)
390 TITLE:=IPv6 modules
391 DEPENDS:=+kmod-ipv6
392 KCONFIG:=$(KCONFIG_IPT_IPV6)
393 FILES:=$(foreach mod,$(IPT_IPV6-m),$(LINUX_DIR)/net/$(mod).ko)
394 AUTOLOAD:=$(call AutoLoad,49,$(notdir $(IPT_IPV6-m)))
395 endef
396
397 define KernelPackage/ip6tables/description
398 Netfilter IPv6 firewalling support
399 endef
400
401 $(eval $(call KernelPackage,ip6tables))
402
403
404 define KernelPackage/arptables
405 SUBMENU:=$(NF_MENU)
406 TITLE:=ARP firewalling modules
407 FILES:=$(LINUX_DIR)/net/ipv4/netfilter/arp*.ko
408 KCONFIG:=CONFIG_IP_NF_ARPTABLES \
409 CONFIG_IP_NF_ARPFILTER \
410 CONFIG_IP_NF_ARP_MANGLE
411 AUTOLOAD:=$(call AutoLoad,49,$(notdir $(patsubst %.ko,%,$(wildcard $(LINUX_DIR)/net/ipv4/netfilter/arp*.ko))))
412 endef
413
414 define KernelPackage/arptables/description
415 Kernel modules for ARP firewalling
416 endef
417
418 $(eval $(call KernelPackage,arptables))
419
420
421 define KernelPackage/ebtables
422 SUBMENU:=$(NF_MENU)
423 TITLE:=Bridge firewalling modules
424 FILES:=$(foreach mod,$(EBTABLES-m),$(LINUX_DIR)/net/$(mod).ko)
425 KCONFIG:=CONFIG_BRIDGE_NETFILTER=y \
426 $(KCONFIG_EBTABLES)
427 AUTOLOAD:=$(call AutoLoad,49,$(notdir $(EBTABLES-m)))
428 endef
429
430 define KernelPackage/ebtables/description
431 ebtables is a general, extensible frame/packet identification
432 framework. It provides you to do Ethernet
433 filtering/NAT/brouting on the Ethernet bridge.
434 endef
435
436 $(eval $(call KernelPackage,ebtables))
437
438
439 define AddDepends/ebtables
440 SUBMENU:=$(NF_MENU)
441 DEPENDS+=kmod-ebtables $(1)
442 endef
443
444
445 define KernelPackage/ebtables-ipv4
446 TITLE:=ebtables: IPv4 support
447 FILES:=$(foreach mod,$(EBTABLES_IP4-m),$(LINUX_DIR)/net/$(mod).ko)
448 KCONFIG:=$(KCONFIG_EBTABLES_IP4)
449 AUTOLOAD:=$(call AutoLoad,49,$(notdir $(EBTABLES_IP4-m)))
450 $(call AddDepends/ebtables)
451 endef
452
453 define KernelPackage/ebtables-ipv4/description
454 This option adds the IPv4 support to ebtables, which allows basic
455 IPv4 header field filtering, ARP filtering as well as SNAT, DNAT targets.
456 endef
457
458 $(eval $(call KernelPackage,ebtables-ipv4))
459
460
461 define KernelPackage/ebtables-ipv6
462 TITLE:=ebtables: IPv6 support
463 FILES:=$(foreach mod,$(EBTABLES_IP6-m),$(LINUX_DIR)/net/$(mod).ko)
464 KCONFIG:=$(KCONFIG_EBTABLES_IP6)
465 AUTOLOAD:=$(call AutoLoad,49,$(notdir $(EBTABLES_IP6-m)))
466 $(call AddDepends/ebtables)
467 endef
468
469 define KernelPackage/ebtables-ipv6/description
470 This option adds the IPv6 support to ebtables, which allows basic
471 IPv6 header field filtering and target support.
472 endef
473
474 $(eval $(call KernelPackage,ebtables-ipv6))
475
476
477 define KernelPackage/ebtables-watchers
478 TITLE:=ebtables: watchers support
479 FILES:=$(foreach mod,$(EBTABLES_WATCHERS-m),$(LINUX_DIR)/net/$(mod).ko)
480 KCONFIG:=$(KCONFIG_EBTABLES_WATCHERS)
481 AUTOLOAD:=$(call AutoLoad,49,$(notdir $(EBTABLES_WATCHERS-m)))
482 $(call AddDepends/ebtables)
483 endef
484
485 define KernelPackage/ebtables-watchers/description
486 This option adds the log watchers, that you can use in any rule
487 in any ebtables table.
488 endef
489
490 $(eval $(call KernelPackage,ebtables-watchers))
491
492
493 define KernelPackage/nfnetlink
494 SUBMENU:=$(NF_MENU)
495 TITLE:=Netlink-based userspace interface
496 DEPENDS:=+kmod-ipt-core
497 FILES:=$(LINUX_DIR)/net/netfilter/nfnetlink.ko
498 KCONFIG:=CONFIG_NETFILTER_NETLINK
499 AUTOLOAD:=$(call AutoLoad,48,nfnetlink)
500 endef
501
502 define KernelPackage/nfnetlink/description
503 Kernel modules support for a netlink-based userspace interface
504 endef
505
506 $(eval $(call KernelPackage,nfnetlink))
507
508
509 define AddDepends/nfnetlink
510 SUBMENU:=$(NF_MENU)
511 DEPENDS+=+kmod-nfnetlink $(1)
512 endef
513
514
515 define KernelPackage/nfnetlink-log
516 TITLE:=Netfilter LOG over NFNETLINK interface
517 FILES:=$(LINUX_DIR)/net/netfilter/nfnetlink_log.ko
518 KCONFIG:=CONFIG_NETFILTER_NETLINK_LOG
519 AUTOLOAD:=$(call AutoLoad,48,nfnetlink_log)
520 $(call AddDepends/nfnetlink)
521 endef
522
523 define KernelPackage/nfnetlink-log/description
524 Kernel modules support for logging packets via NFNETLINK
525 endef
526
527 $(eval $(call KernelPackage,nfnetlink-log))
528
529
530 define KernelPackage/nfnetlink-queue
531 TITLE:=Netfilter QUEUE over NFNETLINK interface
532 FILES:=$(LINUX_DIR)/net/netfilter/nfnetlink_queue.ko
533 KCONFIG:=CONFIG_NETFILTER_NETLINK_QUEUE
534 AUTOLOAD:=$(call AutoLoad,48,nfnetlink_queue)
535 $(call AddDepends/nfnetlink)
536 endef
537
538 define KernelPackage/nfnetlink-queue/description
539 Kernel modules support for queueing packets via NFNETLINK
540 endef
541
542 $(eval $(call KernelPackage,nfnetlink-queue))
543
544
545 define KernelPackage/nf-conntrack-netlink
546 TITLE:=Connection tracking netlink interface
547 FILES:=$(LINUX_DIR)/net/netfilter/nf_conntrack_netlink.ko
548 KCONFIG:=CONFIG_NF_CT_NETLINK
549 AUTOLOAD:=$(call AutoLoad,49,nf_conntrack_netlink)
550 $(call AddDepends/nfnetlink,+kmod-ipt-conntrack)
551 endef
552
553 define KernelPackage/nf-conntrack-netlink/description
554 Kernel modules support for a netlink-based connection tracking
555 userspace interface
556 endef
557
558 $(eval $(call KernelPackage,nf-conntrack-netlink))
559
560 define KernelPackage/ipt-hashlimit
561 SUBMENU:=$(NF_MENU)
562 TITLE:=Netfilter hashlimit match
563 KCONFIG:=$(KCONFIG_IPT_HASHLIMIT)
564 FILES:=$(LINUX_DIR)/net/netfilter/xt_hashlimit.ko
565 AUTOLOAD:=$(call AutoLoad,50,xt_hashlimit)
566 $(call KernelPackage/ipt)
567 endef
568
569 define KernelPackage/ipt-hashlimit/description
570 Kernel modules support for the hashlimit bucket match module
571 endef
572
573 $(eval $(call KernelPackage,ipt-hashlimit))