summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* NFCT: fix NULL dereference when hashtable is fullPablo Neira Ayuso2009-06-231-0/+9
| | | | | | | | This patch fixes a NULL dereference to the timestamp structure when hashtable_add() fails, for example, because the hashtable is full. Reported-by: Bernhard Schmidt <berni@birkenwald.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
* Revert "ulogd: permit compilation of plugin outside of tree"Eric Leblond2009-04-183-4/+2
| | | | | | This reverts commit 0ff525cb0506b2c043bc9df6d7e7b486c865bc38. A stable and clean API should be provided if we choose to offer for external module capability.
* Documentation: information about procedure variable.Eric Leblond2009-04-181-1/+9
| | | | | This patch documents the "procedure" option in the database plugin configurations.
* DB plugins: fixed bug with INSERT* proceduresRomain Bignon2009-04-181-10/+13
| | | | | | | When procedure begins with INSERT* (without space), it considers it as an INSERT statement. Signed-off-by: Romain Bignon <romain@inl.fr>
* DB plugin: add capability to specify complete INSERT commandEric Leblond2009-04-171-3/+8
| | | | | This patch modifies the procedure name parsing to be able to specify a complete INSERT command.
* ulogd: configure all plugins before resolving keys.Pierre Chifflier2009-04-171-7/+13
| | | | | | | | | | Split the 'resolve keys' step in two parts: first call the configure fonction for all plugins (in reverse order), then loop again to resolve the keys. This allows dynamic construction of the input and output keys, even for filter plugins. Signed-off-by: Pierre Chifflier <chifflier@inl.fr>
* ulogd: permit compilation of plugin outside of treeEric Leblond2009-04-053-2/+4
| | | | | This patch modifies Makefile.am to install the headers needed for compilation of plugins outside of the source tree.
* ulogd: include config.h in all files.Eric Leblond2009-03-101-0/+1
| | | | | This patch adds config.h inclusion in ulogd.h to be able to use all defined value in the whole project.
* db plugins: free memory at exit.Eric Leblond2009-03-101-0/+7
| | | | This patches frees an allocated buffer when ulogd is quitting.
* ip2bin: add AF_BRIDGE family support.Eric Leblond2009-03-061-1/+27
| | | | | This patch adds support for AF_BRIDGE family. It synchronizes code of IP2BIN module with the one of IP2STR.
* hwhdr: suppress explicit allocationEric Leblond2009-03-061-12/+12
| | | | | This patch suppresses all allocation and use a statically created array instead.
* ip2bin: suppress explicit allocation of some output key valuesEric Leblond2009-03-061-14/+14
| | | | | This patch suppresses explicit allocation and free for each packet and use a statically created array instead.
* ip2str: suppress explicit allocation of some output key valuesEric Leblond2009-03-061-17/+16
| | | | | This patch suppresses explicit allocation and free for each packet and use a statically created array instead.
* ifindex: avoid memory allocationEric Leblond2009-03-061-21/+16
| | | | | This patch modifies the interp function to avoid to do an explicit allocation of memory.
* nflog: adjust unit which was inaccurate.Eric Leblond2009-03-061-2/+2
| | | | | Timeout unit is 10ms and not 1ms. This patch fixes an invalid comment in the configuration file.
* build: bump version to 2.00beta3ulogd-2.0.0beta3Pablo Neira Ayuso2009-03-061-1/+1
| | | | Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
* Delete timer in destructor function.Eric Leblond2009-02-081-0/+2
| | | | This patch deletes the overrun timer in the destructor function.
* pgsql: fix type of mac_protocol and oob_protocol.Eric Leblond2009-02-082-2/+2
| | | | | The oob_protocol does not fit into a smallint (IPv6 case for example). This patch switches the length of the related field to an integer.
* Add threshold and timeout option to NFLOG plugin.Eric Leblond2009-01-292-1/+49
| | | | | This patch adds support for setting NFLOG threshold and timeout from ulogd.
* Explicitely type PCAP input key.Eric Leblond2009-01-271-5/+15
| | | | This patch affect type and flag to PCAP input key.
* Display which keys are optional in info mode.Eric Leblond2009-01-271-1/+6
| | | | | This patch adds a "optional" keyword to description of input key which are optional when --info is used to dump information about a plugin.
* Replace INCLUDES by AM_CPPFLAGS in Makefile.am.Eric Leblond2009-01-2212-12/+12
| | | | | This patch fixes autotools warning about deprecated usage of INCLUDES in Makefile.am.
* build: update configure.acJan Engelhardt2009-01-202-11/+9
| | | | | | | Some constructs in there are old-fashioned. Replace them by their modern counterparts. Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
* build: resolve autotools suggestions to use AC_CONFIG_MACRO_DIRJan Engelhardt2009-01-203-0/+4
| | | | | | | | libtoolize: Consider adding `AC_CONFIG_MACRO_DIR([m4])' to configure.ac 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: Jan Engelhardt <jengelh@medozas.de>
* build: use -avoid-version for modulesJan Engelhardt2009-01-2010-23/+23
| | | | | | | The modules are pretty much bound to ulogd, and it does not seem to make sense to specially version these. Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
* Update .gitignore and remove install-shJan Engelhardt2009-01-203-251/+25
| | | | | | install-sh is autogenerated. Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
* build: compile fixJan Engelhardt2009-01-181-0/+1
| | | | | | | | | ulogd_inpflow_NFCT.c: In function 'propagate_ct': ulogd_inpflow_NFCT.c:483: error: 'IPPROTO_UDPLITE' undeclared (first use in this function) (and more for IPPROTO_SCTP) Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
* HWHDR: Fix size of allocated string.Eric Leblond2009-01-131-1/+1
| | | | | This patch fixes a incorrect computing of the allocation size of a string.
* Fix crash on IPv6 packet.Eric Leblond2009-01-131-1/+4
| | | | | Incorrect definition of a IPv6 input key handling function was causing a crash in ulogd.
* Display logfile to check in case of error.Eric Leblond2009-01-131-2/+7
| | | | | This patch adds the display of the used logging file to look at if there is a critical error.
* fix config file: MAC2STR has been renamed to HWHDR.Eric Leblond2009-01-131-2/+2
| | | | | This patch replaces all MAC2STR occurences by HWHDR to sync with the renaming of the plugin.
* Flat SQL schema for MySQLPierre Chifflier2009-01-071-0/+478
| | | | | | | This schema is designed for performance, by putting all fields in a single table. It should be used in combination with plain INSERT. Signed-off-by: Pierre Chifflier <chifflier@inl.fr>
* Flat SQL schema for PostgreSQLPierre Chifflier2009-01-071-0/+406
| | | | | | | This schema is designed for performance, by putting all fields in a single table. It should be used in combination with plain INSERT. Signed-off-by: Pierre Chifflier <chifflier@inl.fr>
* PostgreSQL: allow local connectionsPierre Chifflier2009-01-071-1/+2
| | | | | | | | This patch allows to connect to the server using the local (unix) socket, thus not using a network socket and SSL encryption. Local connection is used if host parameter is omitted or empty. Signed-off-by: Pierre Chifflier <chifflier@inl.fr>
* DBI: lower column name before comparing to keyPierre Chifflier2009-01-071-0/+14
| | | | | | | Some databases (e.g Oracle) return column name in uppercase, while key name is in lowercase. This patch allows to match keys correctly. Signed-off-by: Pierre Chifflier <chifflier@inl.fr>
* Allow plain INSERT instead of procedurePierre Chifflier2009-01-071-1/+26
| | | | | | | | | If the procedure name specified in configuration is INSERT, than use a regular insertion instead of a stored procedure. This should be used when performance is needed, with a flat SQL schema, to reduce the cost of SQL procedure calls. Signed-off-by: Pierre Chifflier <chifflier@inl.fr>
* PostgreSQL schema: drop useless constraintsPierre Chifflier2009-01-071-5/+0
| | | | | | | Constraints on TCP/UDP port number validity are useless and only slow down insertions. Signed-off-by: Pierre Chifflier <chifflier@inl.fr>
* Add variable to force binding of nfnetlink_log.Eric Leblond2009-01-052-7/+22
| | | | | | | | | | | | | This patch updates the behaviour of the NFLOG input plugin to fix an issue related to kernel older than 2.6.29. The call to nflog_bind_pf() that can be necessary to receive packet from the nfnetlink_log was only done if the used group was 0 (system logging). This is logic for the newest kernel (NFLOG really sends message to nfnetlink_log and not to the nf_log logger). But this is unsufficient for older one. By forcing the binding with the new configuration variable bind, it is now possible to trigger the binding from the ulogd2 configuration file. This gives users a way to be sure that ulogd will receive packets if the NFLOG input plugin is used.
* Return true/false instead of ULOGD_IRET_OK/STOPThomas Jacob2008-12-091-2/+2
| | | | | Signed-off-by: Thomas Jacob <jacob@internet24.de> Signed-off-by: Eric Leblond <eric@inl.fr>
* Add valgrind compilation option.Eric Leblond2008-12-091-0/+4
| | | | | | Valgrind messages are obscur when the plugins are unloaded. This patch adds a macro that can be used to desactivate unloading. To use it, you have to specify 'CPPFLAGS=-DDEBUG_VALGRIND' on configure line.
* Fix memory leak in destructor_nfct().Eric Leblond2008-12-091-0/+11
| | | | | This patch fixes a memory leak in the destructor function which was not releasing the memory allocated for each connection tracking entry.
* Free stacks when exiting.Eric Leblond2008-12-091-0/+12
| | | | This patch modifies ulogd2 to have it free the stacks when leaving.
* Introduce config_stop() functionEric Leblond2008-12-093-0/+9
| | | | | This patch adds the config_stop function which is in charge of releasing ressources allocated for configuration file parsing.
* Unload plugins when quitting.Eric Leblond2008-12-092-1/+28
| | | | | This patch adds unloading of plugins (call dlclose()) in ulogd2. This make valgrind happy and will be useful for daemon live reconfiguration.
* Add SIGINT to list of terminal signal.Eric Leblond2008-12-091-1/+2
| | | | | This patch modifies ulogd to intercept SIGINT signal and quit nicely when this signal is received.
* Call pluginstance stop function when exitingEric Leblond2008-12-091-1/+25
| | | | | | The stop function of plugin was not called when ulogd2 was preparing to quit. This patch adds a call to stop for all plugins in each stack and free pluginstance.
* Fix minor memory leak in NFLOG plugin.Eric Leblond2008-12-091-0/+2
| | | | This patch fix a minor memory leak at NFLOG plugin exit.
* Don't free pluginstance when leavingEric Leblond2008-12-092-3/+0
| | | | | If we free pluginstance in the stop function we won't be able to iter anymore on the stack linked list.
* Fix stop function of NFCT plugin.Eric Leblond2008-12-092-3/+5
| | | | | This patch fixes some crashes in NFCT plugin that were triggered by the call of the destructor_nfct function (during stop).
* Treat nice function return.Eric Leblond2008-12-091-1/+7
| | | | | gcc was warning that the return of the nice function should be treated. This patch adds an error message in case of failure.