summaryrefslogtreecommitdiff
path: root/flowtop
AgeCommit message (Collapse)AuthorFilesLines
2017-05-23flowtop: take PKG_CONFIG into account for libnetfilter_conntrackBaruch Siach1-1/+1
Use $PKG_CONFIG to determine the linker flags for libnetfilter_conntrack. This fixes static link failure like the following: LD flowtop .../usr/x86_64-buildroot-linux-musl/sysroot/usr/lib/../lib64/libnetfilter_conntrack.a(main.o): In function `nfct_open_nfnl': main.c:(.text+0x52): undefined reference to `nfnl_subsys_open' main.c:(.text+0x69): undefined reference to `nfnl_subsys_close' main.c:(.text+0x87): undefined reference to `nfnl_subsys_open' main.c:(.text+0xa3): undefined reference to `nfnl_subsys_close' .../usr/x86_64-buildroot-linux-musl/sysroot/usr/lib/../lib64/libnetfilter_conntrack.a(main.o): In function `nfct_open': main.c:(.text+0xc9): undefined reference to `nfnl_open' main.c:(.text+0xf0): undefined reference to `nfnl_close' ... Signed-off-by: Baruch Siach <baruch@tkos.co.il> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2016-04-22flowtop: Use new UI table API for draw flows listVadim Kochan1-0/+1
Used new UI table API for flows printing to make it more generic. Also it will allow to have same code to dump flows in text mode. Signed-off-by: Vadim Kochan <vadim4j@gmail.com> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-11-16lookup: Use lookup module for OUI lookup as wellTobias Klauser1-1/+0
Do not needlessly duplicate code between the oui and the lookup module. Instead, add an additional lookup table for OUIs to the lookup module. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-11-05build: Handle libnetfilter-conntrack with pkg-configMartin Hauke1-1/+2
Needed for openSUSE since they have versioned libnetfilter-header files. Signed-off-by: Martin Hauke <mardnh@gmx.de> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-08-07flowtop: Remove tprintf.o from object dependenciesTobias Klauser1-1/+0
The tprintf module isn't used in flowtop, no need to link it in. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-07-20sysctl: Add sysctl module with /proc/sys helpersVadim Kochan1-0/+1
Moved sysctl get/set funcs from flowtop to separated sysctl module. Signed-off-by: Vadim Kochan <vadim4j@gmail.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
2015-07-17flowtop, netsniff-ng: Move process name extraction to own functionTobias Klauser1-0/+1
flowtop and the netsniff-ng's netlink message dissector both need to get the process name for a pid from /proc/<pid>/exe, thus move that functionality to an own function. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-04-23build: Restore support for cross-compiling the netsniff-ng toolkitTobias Klauser1-3/+3
Ever since we switched to the hand-crafted ./configure script, support for cross-compiling the netsniff-ng toolkit was basically broken. Restore the abaility to cross-compile our tools by making ./configure consider the CROSS_COMPILE and SYSROOT variables. Example for cross-compiling on arm: $ CROSS_COMPILE=arm-linux-gnueabihf- \ SYSROOT=/usr/arm-linux-gnueabihf \ ./configure $ make assuming the cross-compiled libraries (and their respective pkg-config information) are in /usr/arm-linux-gnueabihf. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2015-04-21netsniff-ng: Delete rfmon mac80211 device in case of panicVadim Kochan1-0/+1
netsniff-ng does not delete created rfmon device in case of panic (for example - bad pcap filter expression), so added ability to add callback func when panic will be happen and delete rfmon device. Signed-off-by: Vadim Kochan <vadim4j@gmail.com> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-07-23build: flowtop: Only build ioops with GeoIP support enabledTobias Klauser1-2/+2
Follow commit 9ad7f8882097 ("build: astraceroute: Only build ioops with GeoIP support enabled"). The ioops module is only needed in geoip.o, thus make it dependent on CONFIG_GEOIP. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-06-13lookup: Move UDP/TCP port and Ethernet type lookup into own moduleTobias Klauser1-7/+2
Up to now, the lookup of TCP/UDP port names and Ethernet types was tightly integrated with the dissector infrastructure, since it is its main user. However, flowtop also makes use of the name lookup functionality without needing the actual dissector infrastructure. Thus, the basic dissector infrastructure also needs to be linked into flowtop without actually being used. Fix this by extracting the port/ethertype lookup into an own module which can then be used either directly (for flowtop) or as part of the dissector infrastructure (for netsniff-ng). This also reverts the quick & dirty fix introduced in commit f3322c6 ("flowtop: Include netlink dissector to fix build temporarily"). Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-06-13flowtop: Include netlink dissector to fix build temporarilyTobias Klauser1-1/+3
flowtop links in the dissector modules just for the TC/UDP port lookup feature. Since dissector.h now includes libnl headers, we also need to include the libnl CFLAGS for flowtop build and thus also make it depend on libnl. The real fix for this in the future would be to extract the port lookup from dissector_eth.c and the just link in this module into flowtop instead of the entire dissector stuff. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2014-05-27build: Allow to build astraceroute and flowtop without GeoIP supportTobias Klauser1-4/+10
Both tools are already prepared to handle NULL return values of the geoip_* lookup functions, so we might as well build them without geoip support if not needed/present. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-12-18debian: compile fix for programs using ncursesJesper Dangaard Brouer1-2/+3
For some reason the Debian ncurses version does not contain a ncurses.pc pkg-config file. Fix this by echoing "-lncurses" if the command fails: pkg-config --libs ncurses This fix will make ifpps compile on Debian Squeeze 6.0.8. Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>
2013-11-24ifpps, flowtop: Fix DSO ncurses terminal interface linking problemTeguh1-0/+1
Add LDFLAGS for libtinfo for cases where it is separate from ncurses. [tklauser: Whitespace fixes in ifpps/Makefile and added patch description] Signed-off-by: Teguh <info@egeektronic.com> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-07-30build: reduce Extra contents to bare minimumDaniel Borkmann1-0/+4
Improve the build system, so that configuration files are installed per tool basis. Also, introduce post_install targets, so that config files can be altered in some way, e.g. done by trafgen. Moreover, move custom targets from Extra to tool-specific Makefiles. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-07-11build: refactor tool specific flags into <tool>/MakefileDaniel Borkmann1-0/+2
To get the normal Makefile a bit cleaner, push the tool specific build options into <tool>/Makefile. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-24ifpps, flowtop: Move ncurses init and end to common moduleTobias Klauser1-0/+1
ncurses (de-)initialization is duplicated across flowtop and ifpps, so move it to an own module and use it from both tools. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-06-04xutils: eliminate xutils, move rest to epoll2Daniel Borkmann1-1/+0
Finally eliminate xutils.{c,h} and move the rest to epoll2. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-04sig: add signal handling functionsDaniel Borkmann1-0/+1
Add an extra file for signal handling functions. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-04link: add link management functionsDaniel Borkmann1-0/+1
Same here as usual, break out link functions from xutils. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-04sock: add socket management functionsDaniel Borkmann1-0/+1
Remove them from xutils, and add them to socket management. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-04xutils: move device management functions out of xutilsDaniel Borkmann1-0/+1
Move those functions out so that they can be more easily maintained in its separate file. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-04xio: rename xio to ioops and reduce its includesDaniel Borkmann1-1/+1
Rename xio to ioops (io-ops) and boil its include files down to a minimum. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-04xutils: break out string handling and lockingDaniel Borkmann1-0/+1
Break out all string handling functions and lockme stuff in order to further eliminate the big code blob in xutils, so that it can be easier maintained. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-03-15build: Find libncurses by using pkg-configDaniel Borkmann1-1/+1
Call pkg-config --cflags and pkg-config --libs to find correct CFLAGS and LDFLAGS respectively. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-03-15all: import netsniff-ng 0.5.8-rc0 sourceDaniel Borkmann2-0/+23
We decided to get rid of the old Git history and start a new one for several reasons: *) Allow / enforce only high-quality commits (which was not the case for many commits in the history), have a policy that is more close to the one from the Linux kernel. With high quality commits, we mean code that is logically split into commits and commit messages that are signed-off and have a proper subject and message body. We do not allow automatic Github merges anymore, since they are total bullshit. However, we will either cherry-pick your patches or pull them manually. *) The old archive was about ~27MB for no particular good reason. This basically derived from the bad decision that also some PDF files where stored there. From this moment onwards, no binary objects are allowed to be stored in this repository anymore. The old archive is not wiped away from the Internet. You will still be able to find it, e.g. on git.cryptoism.org etc. Signed-off-by: Daniel Borkmann <dborkman@redhat.com> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>