summaryrefslogtreecommitdiffstats
path: root/xtables.c
Commit message (Collapse)AuthorAgeFilesLines
* [PATCH 02/10] Wrap dlopen code into NO_SHARED_LIBS/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-04-151-0/+2
|
* [PATCH 01/10] Resolve warnings on 64-bit compile/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-04-151-2/+2
|
* [PATCH 8/8] Implement AF_UNSPEC as a wildcard for extensions/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-04-141-6/+16
|
* [PATCH 05/13] Combine IP{,6}T_LIB_DIR into XTABLES_LIBDIR/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-04-131-43/+51
|
* [PATCH 05/24] Fix -Wshadow warnings and clean up xt_sctp.h/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-04-061-2/+2
| | | | | Note: xt_sctp.h is still not merged upstream in the kernel as of this commit. But a refactoring was really needed.
* [PATCH 04/24] Drop -W from CFLAGS and some tiny code cleanups/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-04-061-1/+1
| | | | | - change "unsigned" to explicit "unsigned int" - remove some casts
* [PATCH]: fix gcc warnings/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-01-291-2/+2
| | | | Max Kellermann <max@duempel.org>
* [PATCH]: escape strings/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-01-291-0/+37
| | | | Max Kellermann <max@duempel.org>
* [PATCH]: rename overlapping function names/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-01-201-0/+318
| | | | | | Rename overlapping function names. Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
* [PATCH]: bunch o' renames/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-01-201-0/+148
| | | | | | | | Move a few functions from iptables.c/ip6tables.c to xtables.c so they are available for combined (both AF_INET and AF_INET6) libxt modules. Rename overlapping function names. Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
* [PATCH]: print warning when dlopen fails/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-01-201-0/+14
| | | | | | | If the file exists but could not be loaded, print the dlerror(). Often it is a missing symbol. Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
* [PATCH]: common error messages/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-01-201-0/+49
| | | | | | | | Error messages vary wildly among modules, and there is a lot of reundance in it too. Introduce a helper function that does all of the parameter checking boilerplate and gives unique messages. Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
* Introduce strtonum(), which works like string_to_number(), but passes/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2008-01-201-0/+44
| | | | | | | | | | | | | | | | | | | | back the 'end' pointer. It is useful where you want to do boundary checking yet work with strings that are not entirely slurped by strtoul(), e.g.: s = "1/2"; /* one half */ if (!strtonum(s, &end, &value, 0, 5)) error("Zero-length string, or value out of bounds"); if (*end != '/') error("Malformed string"); info->param1 = value; if (!strtonum(end + 1, &end, &value, 2, 4)) error(".."); if (*end != '\0') error("Malformed string"); info->param2 = value; Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de>
* [patch] iptables and NO_SHARED_LIBS/dlfcn.h/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2007-12-191-1/+4
| | | | | | | | if NO_SHARED_LIBS is defined, then iptables shouldnt even include dlfcn.h. otherwise you hit a build failure when using toolchains that do not provide dlfcn.h because they do not support shared objects. Signed-Off-By: Mike Frysinger <vapier@gentoo.org>
* Fix showing help text for matches/targets with revision as user/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2007-12-031-0/+9
| | | | | | | When running as a user iptables can't determine the highest supported revision and exits. Assume all revision are supported in case we get a EPERM. If the user is not showing the help text but trying to add new rules he'll get EPERM later anyway.
* [PATCH iptables] print warnings to stderr/C=EU/ST=EU/CN=Patrick McHardy/emailAddress=kaber@trash.net2007-10-171-3/+4
| | | | | | | | iptables prints some of its error messages and warnings to stdout. This patch applies to svn r7075 and will make iptables print diagnostic messages to stderr instead. Signed-off-by: Max Kellermann <max@duempel.org>
* Tries to load libxt_*.so at first./C=JP/ST=JP/CN=Yasuyuki Kozakai/emailAddress=yasuyuki@netfilter.org2007-08-041-15/+22
| | | | If failed, it tries libip[6]t_*.so.
* Moves all declarations in iptables_common.h to xtables.h./C=JP/ST=JP/CN=Yasuyuki Kozakai/emailAddress=yasuyuki@netfilter.org2007-07-241-1/+0
|
* Moves some duplicated functions in ip[6]tables.c to xtables.c/C=JP/ST=JP/CN=Yasuyuki Kozakai/emailAddress=yasuyuki@netfilter.org2007-07-241-0/+103
| | | | | string_to_number_ll, string_to_number_l, string_to_number, service_to_port, parse_port, parse_interface, are moved.
* Introduces xtables match/target registration/C=JP/ST=JP/CN=Yasuyuki Kozakai/emailAddress=yasuyuki@netfilter.org2007-07-241-0/+342
| | | | | | | | | | | | | | | | | | | | | | | - moves lib_dir to xtables.c - introduces struct pfinfo which has protocol family dependent infomations. - unifies load_ip[6]tables_ko() and moves them as load_xtables_ko() - introduces xt_{match,match_rule,target,tryload} and replaces ip[6]t_* with them - unifies following functions and move them to xtables.c - find_{match,find_target} - compatible_revision, compatible_{match,target}_revision - introduces xtables_register_{match,target} and make register_{match,target}[6] call them. xtables_register_* register ONLY matches/targets matched protocol family Some concepts: - source compatibility for libip[6]t_xxx.c with warning on compilation not binary compatibility. - binary compatibility between 2.4/2.6 kernel and iptables/ip6tables, of cause. - xtables is enough to support only one address family at runtime. Then xtables keeps infomations of only the focused address famiy in struct afinfo.
* Moves ip[6]tables_insmod() to xtables.c as xtables_insmod()/C=JP/ST=JP/CN=Yasuyuki Kozakai/emailAddress=yasuyuki@netfilter.org2007-07-241-1/+85
|
* Moves common fw_malloc() and fw_calloc() to xtables.c/C=JP/ST=JP/CN=Yasuyuki Kozakai/emailAddress=yasuyuki@netfilter.org2007-07-241-0/+30
|
* Adds xtables.[ch] and change Makefile to compile it/C=JP/ST=JP/CN=Yasuyuki Kozakai/emailAddress=yasuyuki@netfilter.org2007-07-241-0/+19