Pablo Neira Ayuso [Tue, 15 Mar 2011 17:23:42 +0000 (18:23 +0100)]
build: Linux kernel-style for compilation messages
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Thu, 6 Jan 2011 02:42:49 +0000 (03:42 +0100)]
build: fix `make distcheck'
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Jan Engelhardt [Thu, 30 Dec 2010 22:15:53 +0000 (23:15 +0100)]
build: use -Wall across the entire source
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Thu, 30 Dec 2010 22:15:18 +0000 (23:15 +0100)]
build: create a Make_global.am file
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Thu, 30 Dec 2010 22:09:28 +0000 (23:09 +0100)]
build: remove unused LIBTOOL_DEPS
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Pablo Neira Ayuso [Tue, 7 Dec 2010 09:06:21 +0000 (10:06 +0100)]
doc: fix wrong documentation on NFQNL_COPY_NONE
NFQNL_COPY_NONE means noop and should not be used.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Alessandro Vesely [Sun, 7 Nov 2010 20:38:31 +0000 (21:38 +0100)]
utils: document ENOBUFS in nfqnl_test.c
This patch documents the ENOBUFS error in the example file, that
is a common problem is that question over and over again in the
mailing list.
I (Pablo) have mangled this patch with some comestic cleanups. BTW,
Mistick Levi sent a similar patch in the same timeline (amazing how
sometimes the same works can clash).
Signed-off-by: Alessandro Vesely <vesely@tana.it>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Jan Engelhardt [Sun, 31 Oct 2010 09:11:18 +0000 (10:11 +0100)]
build: use AC_OUTPUT
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 22:33:25 +0000 (00:33 +0200)]
build: default to not building static libraries
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Pablo Neira Ayuso [Wed, 3 Nov 2010 17:58:22 +0000 (18:58 +0100)]
doc: document some performance tweaks for libnetfilter_queue
This patch documents some performance tweaks for libnetfilter_queue
applications.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Jan Engelhardt [Sat, 30 Oct 2010 21:15:19 +0000 (23:15 +0200)]
Update .gitignore
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:54:44 +0000 (23:54 +0200)]
build: remove -fPIC flag
libtool automatically adds PIC flags as needed.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:38:03 +0000 (23:38 +0200)]
build: remove statements without effect
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:11:26 +0000 (23:11 +0200)]
build: set Libs.private for pkgconfig file
Similar to the commit in iptables, add Libs.private to tell about
dependencies for static linking.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:09:45 +0000 (23:09 +0200)]
build: no need for error message in PKG_CHECK_MODULES
PKG_CHECK_MODULES already produces its own (and more verbose) messsage
when a module cannot be found.
Mucking around with CFLAGS and LIBS is also not needed since pkgconfig
takes care of providing variables, so let's use them in Makefile.am.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:07:13 +0000 (23:07 +0200)]
build: run AC_CANONICAL_HOST only
There is no need to call AC_CANONICAL_SYSTEM when only
AC_CANONICAL_HOST is needed. Also, checking for $target is factually
incorrect, since we do not produce object code like a compiler. Use
$host, which specifies the triple/quadrople where the compiled program
is supposed to run.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:02:33 +0000 (23:02 +0200)]
build: use simpler autoreconf in autogen
Note: the use of -i seems required, otherwise autoreconf barfs about
missing tools (depcomp, etc.). Since they are provided in the tarballs
as files anyway rather than like previously as symlinks, I do not see
a problem using -i.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:05:38 +0000 (23:05 +0200)]
build: avoid use of deprecated INCLUDES
Makefile.am: "INCLUDES" is the old name for "AM_CPPFLAGS" (or "*_CPPFLAGS")
And remove unused $(all_includes)
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:04:32 +0000 (23:04 +0200)]
build: use modern call syntax for AC_INIT, AM_INIT_AUTOMAKE
automake options also need to definitely go into configure.ac, otherwise
they only apply to a single directory.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Jan Engelhardt [Sat, 30 Oct 2010 21:03:12 +0000 (23:03 +0200)]
build: build: use autoconf-suggested naming of files
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Pablo Neira Ayuso [Fri, 29 Oct 2010 18:44:04 +0000 (20:44 +0200)]
license: upgrade to GPLv2+
This patch upgrades the license to GPLv2+. I have received an explicit
ACK via email from contributors that are:
* Harald Welte <laforge@netfilter.org>.
* Holger Freyther <zecke@selfish.org>
* Alessandro Vesely <vesely@tana.it>
* Bart Schuymer <bdschuym@pandora.be>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Thu, 15 Jul 2010 09:12:30 +0000 (11:12 +0200)]
nfq: fix redundant LIBVERSION definition
I accidentally inserted LIBVERSION to Makefile.am but the one
used is in src/Makefile.am. This patch removes the previous
definition.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Thu, 15 Jul 2010 08:41:18 +0000 (10:41 +0200)]
nfq: add myself to the copyright notice
This patch adds myself to the copyright notice according to my contributions
in the git repository.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Thu, 15 Jul 2010 08:10:25 +0000 (10:10 +0200)]
nfq: add missing documentation on nfq_snprintf_xml()
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 11 Jul 2010 15:19:12 +0000 (17:19 +0200)]
nfq: bump version to 1.0.0
This patch bumps the library version to 1.0. I have also introduced
LIBVERSION for the API versioning.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 11 Jul 2010 15:19:54 +0000 (17:19 +0200)]
build: add libtool m4 support
libtoolize: Consider adding `AC_CONFIG_MACRO_DIR([m4])' to configure.in and
libtoolize: rerunning libtoolize, to keep the correct libtool macros in-tree.
libtoolize: Consider adding `-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 11 Jul 2010 15:25:30 +0000 (17:25 +0200)]
nfq: remove libipq.h
In
224df57de4479d65d4fec3eeaa8b1a4d63b8213f, we forgot to remove
libipq.h that was introduced to add backward compatibility for
libipq (which was never completed and now everybody should be
using libnetfilter_queue instead).
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 11 Jul 2010 13:08:40 +0000 (15:08 +0200)]
nfq: remove `0x' from HW protocol in output of nfq_snprintf_xml()
This patch removes the prefix `0x' of the HW protocol.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 11 Jul 2010 13:00:13 +0000 (15:00 +0200)]
nfq: fix HW address output in nfq_snprintf_xml()
This patch fixes the output of the HW address in XML files:
<src>800:800:800:800:800:</src>
now it looks fine:
<src>
0019a917a400</src>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 11 Jul 2010 11:22:29 +0000 (13:22 +0200)]
nfq: consistent nfq_snprintf_xml() return value with snprintf()
With this patch, nfq_snprintf_xml() returns the number of characters
printed. If the output was truncated, then the return value is the
number of characters that would have been written if enough space
had been available. This makes nfq_snprintf_xml() consistent with
the behaviour of snprintf().
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 11 Jul 2010 11:42:28 +0000 (13:42 +0200)]
nfq: fix compilation warning in nfq_snprintf_xml()
In
21fd1834b5ce0a1f5b590f7e1ad23bba64fbafdf, we changed nfq_get_payload()
to take an unsigned char * instead of signed char *.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Tue, 26 Jan 2010 13:06:35 +0000 (14:06 +0100)]
add nfq_snprintf_xml() to output a packet in XML format
This patch adds a new function to output the packet in XML format.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
David Fabro [Thu, 10 Jun 2010 13:04:06 +0000 (15:04 +0200)]
added .gitignore for base directory
Signed-off-by: David Favro <netfilter@meta-dynamic.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
David Fabro [Thu, 10 Jun 2010 13:03:44 +0000 (15:03 +0200)]
payload buffer datatypes are consistent
The 'data' parameter to nfq_get_payload() returns pointer to unsigned
char (rather than signed char) to make it consistent with the 'buf'
parameter of nfq_set_verdict(), nfq_set_verdict2(), and
nfq_set_verdict_mark(), all of which refer to the same data. Either
signed or unsigned is fine, but they should be consistent as the output
of nfq_get_payload() may be passed back into nfq_set_verdict*(); in that
case, this change eliminates the need for typecasting in the calling
code when using compilers that enforce strict typecasting.
Signed-off-by: David Favro <netfilter@meta-dynamic.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
David Fabro [Thu, 10 Jun 2010 12:54:41 +0000 (14:54 +0200)]
non-modified payload arguments are pointer-to-const
The payload parameters to nfq_set_verdict(), nfq_set_verdict2(), and
nfq_set_verdict_mark() are not modified by those functions, and
therefore should have datatype pointer-to-const. This both causes the
source-code to more effectively represent what is the purpose of the
parameter, and eliminates the need to cast away const-ness when calling
the functions with compilers that enforce strict casting. All existing
calling code should not need modification as pointer-to-X automatically
converts to pointer-to-const-X.
Signed-off-by: David Favro <netfilter@meta-dynamic.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Mon, 10 May 2010 14:56:28 +0000 (16:56 +0200)]
doc: remove references to deprecated nfq_set_verdict_mark()
Now, we refer to nfq_set_verdict2() instead.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Alessandro Vesely [Mon, 10 May 2010 14:54:37 +0000 (16:54 +0200)]
doc: document possible verdicts on packets and minor change in example
Signed-off-by: Alessandro Vessely <vesely@tana.it>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
David Favro [Mon, 10 May 2010 14:50:09 +0000 (16:50 +0200)]
doc: enhancements
* Several parameters are clarified.
* Several previously undocumented return-values are documented.
* nfq_set_verdict_mark() [now deprecated]: notes that mark is in
network byte order.
Signed-off-by: David Favro <netfilter@meta-dynamic.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Sun, 9 May 2010 21:24:43 +0000 (23:24 +0200)]
nfq: deprecate nfq_set_verdict_mark() in favour of nfq_set_verdict2()
This patch deprecates nfq_set_verdict_mark() in favour of
nfq_set_verdict2() which does exactly the same but it also
convert the mark value from host-byte order to network-byte
order as expected by nfnetlink_queue.
I know, this is hackish, but I prefer adding new functions
instead of API versioning which is also ugly.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Holger Hans Peter Freyther [Sun, 27 Dec 2009 15:02:51 +0000 (16:02 +0100)]
doc: make doxygen.cfg.in work with doxygen 1.6.1
* DETAILS_AT_TOP is deprecated and newer versions of
doxygens are warning about this. Remove this option.
* Empty HTML_HEADER as newer versions of doxygen check
if the file exists and fail if it doesn't. Looking at
the history of this project the file never existed.
* This continues to work with doxygen 1.5.6.
Signed-off-by: Holger Hans Peter Freyther <zecke@selfish.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Patrick McHardy [Thu, 17 Sep 2009 11:46:25 +0000 (13:46 +0200)]
remove libipq_compat
It has never been finished and nowadays people should be using
libnfnetlink_queue directly anyways. In case someone wants to
finish it, it can easily be restored from the history.
Signed-off-by: Patrick McHardy <kaber@trash.net>
Pablo Neira Ayuso [Thu, 16 Jul 2009 07:58:56 +0000 (09:58 +0200)]
nfq: add minor comment in the documentation to warn about privileges
This patch adds a minor notice to warn developers that its
application needs CAP_NET_ADMIN in order to send to and receive
packets from kernel-space.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Fri, 6 Mar 2009 16:01:49 +0000 (17:01 +0100)]
build: bump version to 0.0.17
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Tue, 17 Feb 2009 19:47:21 +0000 (20:47 +0100)]
nfq: replace nfnl_talk by nfnl_query and disable sequence tracking
This patch replaces the nfnl_talk() calls by the newer nfnl_query().
This patch also disables netlink sequence tracking by default.
Spurious race conditions in the sequence tracking may occur while
creating queues and receiving high load of packets at the same time.
Reported-by: Anton Vazir <anton.vazir@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Bart De Schuymer [Mon, 26 Jan 2009 15:33:57 +0000 (16:33 +0100)]
nfqnl_test: add hw src address, physindev and physoutdev support
This adds the hardware source address, physindev and physoutdev support
to nfqnl_test
Signed-off-by: Bart De Schuymer <bdschuym@pandora.be>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Pablo Neira Ayuso [Tue, 6 Jan 2009 12:21:50 +0000 (13:21 +0100)]
doc: put doxygen configuration file into diet
This patch puts the doxygen config file into diet since it was
bloated with tons of comments. If we need help, we can go look
for the official documentation instead of consuming ~50KB.
With this patch, the file results in ~5KB.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Eric Leblond [Mon, 22 Dec 2008 10:52:51 +0000 (11:52 +0100)]
Add doxygen config file.
This patch adds a doxygen configuration file which is generated by
the configure script.
Eric Leblond [Wed, 17 Dec 2008 23:03:52 +0000 (00:03 +0100)]
Switch documentation style to doxygen.
This patch modifies the documentation format to switch to doxygen
format. This leads to a interesting and useful output. An example
can be found at the following url:
http://www.nufw.org/doc/libnetfilter_queue/
Eric Leblond [Wed, 17 Dec 2008 15:29:56 +0000 (16:29 +0100)]
Suppress double call of nfnl_subsys_close()
nfnl_close() is calling nfnl_subsys_close() for all available
subsys. Thus it is not necessary to call it in the nfq_close()
function.
Signed-off-by: Eric Leblond <eric@inl.fr>
Eric Leblond [Wed, 17 Dec 2008 20:27:58 +0000 (21:27 +0100)]
Use nfq_fd function instead of call to nfnetlink function.
This patch modifies the example program to use nfq_fd function
instead of call to nfnetlink function.
Signed-off-by: Eric Leblond <eric@inl.fr>
Eric Leblond [Fri, 31 Oct 2008 12:07:56 +0000 (13:07 +0100)]
Change variable name to have an homogeneous naming
This patch modifies a function to have through the file. Data length
variable was named data_len everywhere but in this function.
Signed-off-by: Eric Leblond <eric@inl.fr>
Eric Leblond [Sun, 26 Oct 2008 21:41:24 +0000 (22:41 +0100)]
doc: complete missing function documentation
This patch adds documentation for functions that were not existing
when the documentation was initially made. It also fixes some minor
typos.
Signed-off-by: Eric Leblond <eric@inl.fr>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Thu, 23 Oct 2008 17:16:50 +0000 (19:16 +0200)]
doc: add library documentation from Brad Fisher
This patch adds the documentation that Brad Fisher <brad@info-link.net>
made time ago, you can get the original post from:
http://lists.netfilter.org/pipermail/netfilter-devel/2006-February/023286.html
This patch contains documentation that I did not have time to review in deep
yet. However, several developers has refered to this documentation as a good
kick-off to start developing applications for libnetfilter_queue.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Pablo Neira Ayuso [Wed, 2 Jul 2008 13:38:36 +0000 (15:38 +0200)]
conditional compilation of testsuite utils
Use `make check' to compile the examples in utils/
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Jan Engelhardt [Tue, 24 Jun 2008 16:14:08 +0000 (18:14 +0200)]
libnfq: mark functions as extern C
mark functions as extern C
This is needed when #included from C++.
Reported-by: Simon <turner25@gmail.com>
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Pablo Neira Ayuso [Fri, 27 Jun 2008 10:10:43 +0000 (12:10 +0200)]
bump version to 0.0.16 and bump libnfnetlink dependencies
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Fabian Hugelshofer [Mon, 23 Jun 2008 14:16:58 +0000 (16:16 +0200)]
fix alignment issues
Signed-off-by: Paul P. Komkoff
fix compilation issues on newer toolchains
remove linux/types.h include
Bump version to 0.0.15
interface index to name API (Eric Leblond)
comment `autoheader' invocation from autogen.sh, we don't need any config.h file to compile the conntrack tool
Bump version
Add patch to set max. queue length (Eric Leblond)
[PATCH 3/6] libnetfilter_queue pkt-config changes (KOVACS Krisztian <hidden@balabit.hu>)
only copy include file from kernel directory if 'autogen.sh' is run with 'distrib' argument
pkg-config enable all netfilter libraries
fix __set_verdict() to correctly handle payload (Closes: #435) (Andreas Florath)
fix segfault due to missing h->nfnlh initialization (Closes: #434) (Andreas Florath)
make sure configure fails if libnfnetlink is too old (< 0.0.16)
Introduce various API changes throughout the library stack
1) make libnfnetlink dynamically allocate it's handles
2) apply that change throughout libnetfilter_*
3) add {nfq,nflog,nfct}_open_nfnl() functions that open
the specific subsystem on top of an existing nfnl_handle,
which is required for upcoming libnetfilter_conntrack_helper
The changes break ABI and API compatibility of libnfnetlink, but don't
break ABI or API compatibility of the libnetfilter_* libraries.
add KERNEL_DIR option to autogen.sh for all new libraries (Krzysztof Oledzki)
This patch add the ability to copy and mangle the kernel headers
required by libnfnetlink and libnetfilter_[queue|log|conntrack] at
autogen.sh stage. (Pablo Neira)
- don't install test program
- use local copy of nfnetlink_queue header
- bump version number to 0.0.11
- add library api versioning
- missing link dependencly from libipq to libnetfilter_queue
fix nfq_get_timestamp() to use struct timeval and be endian correct
we have to link against libnfnetlink, otherwise the dependency is missing
get rid of superfluous 'datalength' parameter of nfq_get_payload() function
rename all data types and functions to get rid of 'nl' (== netlink) part in prefix
abstract 'nfattr' in 'nfnl_q_data'
remove 1.6 specific autotool calls
fix gcc warning
rename files correctly (Eric Leblond)
rename libnfnetlink_queue to libnetfilter_queue
we have to clear the iovec
fix "make dist"
fix include order
fix build of utils against local libtool library
use new accessor functions (Eric Leblond, Harald Welte)
whitespace fix
add libtoolize call (Eric Leblond)
really implement a full test program. returns NF_ACCEPT verdict for all packets
sync with all 'upstream' changes in libnfnetlink_log
add gpl
build fixes following restructuring
add autogen.sh
more restructuring work
directory restructuring
add (incomplete) support for libipq emulation API
add required config.sub and config.guess