summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-05-12dissector: ip_ipv6_mobility_hdr: NULL check before dereferenceTobias Klauser1-4/+8
Check return value of pkt_pull before dereferencing it. This was discovered by the coverity scanner. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-12dissector: ip_authentication_hdr: Remove trailing whitespacesTobias Klauser1-2/+2
Remove two trailing whitespaces on emtpy lines. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-10make: allow to overwrite CFLAGS, CCACHEDaniel Borkmann3-43/+47
Allow to define custom compile flags, e.g. ... make CFLAGS="-O2 -Wall" ... and also allow to overwrite ccache variable: make CCACHE= all Also do some minor fixes when built with -O2 -Wall. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-10docs: minor: fix mentioning of Documentation/Daniel Borkmann3-3/+3
The Documentation/ folder no longer exists. Either everything important can be found in the man pages or other documentation files. Fix the mentioning of Documentation/. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-10man: trafgen: update documentation for hex, bin formsDaniel Borkmann1-2/+2
Also update examples for the man-page. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-10trafgen: lexer: also allow short forms for hex and binaryDaniel Borkmann1-4/+6
Also allow for ... - hex: 0xff, xff - binary: 0b11110000, b11110000 Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-10pcap_io: minor: fix some quirksDaniel Borkmann1-3/+3
We can just replace int with uin32_t, that's no problem. Also fix one case where we moved to uint16_t. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-10man: add description about different pcap formatsDaniel Borkmann1-0/+30
Add a more detailled description of netsniff-ng's -D option into the man-page. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-10pcap: let netsniff-ng also record pkt timestamp sourceDaniel Borkmann1-3/+26
With commit [1] in the kernel, we can also store the timestamp source in the pcap packet header for later analysis. We do this by splitting the netsniff-ng's u32 ifindex into u16 tsource and u16 ifindex. Older kernel do not support the timestamp source in PF_PACKET, so it will stay 0 and is compatible with older netsniff-ng binaries. [1] http://thread.gmane.org/gmane.linux.network/266878/ Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-10make: force to overwrite symlinkDaniel Borkmann1-1/+1
When doing to successive ``make install'' ln will throw an error that the symlink already exist, so simply force it to overwrite. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-06docs: install: mention recommended toolsDaniel Borkmann1-2/+2
Mention pkg-config and gpg as optional tools for verifying tags resp. getting build flags. If they are not wanted / present, then relative Makefiles need to be edited by hand. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-06man: finish astraceroute man pageDaniel Borkmann1-2/+65
Finish writing up the remaining section of the astraceroute man page. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-05man: start man page of astracerouteDaniel Borkmann1-0/+140
Here's at least a start that needs some more details to be filled out during the next week. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-05bpf_comp: minor: fix linebreakDaniel Borkmann1-2/+2
Add a newline after this long one. Also, after opening braces there should be no newline. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-05make: rename trafgen stddef.h fileDaniel Borkmann2-1/+2
Rename it to not confuse the build with header inclusions. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-05oui: minor: rename update fileDaniel Borkmann1-0/+0
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-05misc: move file to source rootDaniel Borkmann15-4/+4
Only have Makefile specific folders in the project root where the binaries are stored, the rest should be part of the repository root. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-30man: trafgen: finish trafgen manpageDaniel Borkmann1-1/+40
Finish the last part, which is usage examples. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-30man: trafgen: finish syntax sectionDaniel Borkmann1-1/+4
Counter description was missing. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-30man: trafgen: configuration syntax sectionDaniel Borkmann1-4/+160
This adds the packet configuration syntax section for trafgen's man page. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-30man: trafgen: finish options sectionDaniel Borkmann1-3/+15
There are still 3 sections on todo, but for now we can already push out the option section that is ready. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-30man: trafgen: add initial versionDaniel Borkmann1-0/+235
Add an initial version of the trafgen man-page. There are still a couple of TODO marked section that need to be addressed in follow-up commits. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-30man: netsniff-ng: add documentation for optionDaniel Borkmann1-1/+3
This was left forgotten during writing of the man page, so fix it up and add missing documentation. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-29dissector: show sw/hw timestamp sourceDaniel Borkmann2-2/+28
Now, with PF_PACKET's extension, we can see what kind of sw/hw timestamp is being reported to us [1]. Thus, report it in the dissector. [1] http://thread.gmane.org/gmane.linux.network/266878/ Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-23ring: tstamp: no need for tx tsDaniel Borkmann1-1/+1
Set TX timestamping to HWTSTAMP_TX_OFF. We do not use it, therefore do not waist time keeping track of it. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-23netsniff-ng: remove set_sockopt_hwtimestamp callDaniel Borkmann1-1/+0
For TX this call is completly useless and has no effect whatsoever. Therefore, remove it. For the RX part, this call makes perfect sense, not for the other one currently. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-23man: netsniff-ng: refine ethtool sectionDaniel Borkmann1-1/+2
Just add yet another example for ethtool, nothing more. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-23man: flowtop: Fix typo of flowtop's nameTobias Klauser1-1/+1
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-04-22ring_tx: user_may_pull_from_tx: fix check for user frameDaniel Borkmann1-1/+1
TP_STATUS_AVAILABLE is 0, thus the condition will always be successful. Fix this bug by properly checking kernel flags. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-12man: add flowtop's man pageDaniel Borkmann1-0/+132
This is an initial version of flowtop's man page that includes a writeup of its purpose, what it can do and what its limits are and what options are available for use. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-12man: netsniff-ng: add geoip db mirror conf fileDaniel Borkmann1-0/+1
The list of used config files missed the geoip.conf. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11gitignore: minor: remove obsolete fileDaniel Borkmann1-1/+0
It contained an non-existing file. So remove it from the ignore list. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11docs: install: update mausezahn locationDaniel Borkmann1-1/+1
It is accessable e.g. through: git pull git://repo.or.cz/netsniff-ng-old.git with-mausezahn Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11build: currently do not copy docs to shared docsDaniel Borkmann1-7/+0
Maybe in short term future, before the next release, we will think about putting the README file for users into DOCDIRE, since the rest is not really interesting for users, but probably only for developers. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11docs: readme: add steps to verify a Git releaseDaniel Borkmann1-15/+16
We should only put the things here that are interesting for users, thus, add steps to verify a release from the Workflow document. [1] http://pub.netsniff-ng.org/docs/Workflow Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11docs: move some of them to the root directoryDaniel Borkmann10-762/+31
Lets move CodingStyle, SubmittingPatches, and Sponsors into the root directory of netsniff-ng and remove the Documentation folder. Some of those files are quite bloated, and most of these things should be in the man-pages anyway. They should be the only big sources of documentation, nothing else. The rest is currently put here: http://pub.netsniff-ng.org/docs/ Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11man: netsniff-ng: include known bug from docsDaniel Borkmann1-0/+48
Add the known bug from Documentation/KnownIssues into the man page so that at some point in time, we can remove this document and maintain that stuff within the man page. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11netsniff-ng: mlock: only lock current and future pages when rootDaniel Borkmann1-2/+4
When we're still root, we tell the kernel to lock/protect all current and future pages in memory so that they will not be swapped out in case the system uses up too much. Now when we do xzmalloc_aligned(), it calls internally posix_memalign() that can call mmap(2), thus we will get an EAGAIN as errno, since we're not root anymore and since we wanted to touch sth. that belongs to root. Nasty. Fix this up by only protecting these pages when we do not use -u/-g. Reported-by: Doug Burks <doug.burks@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11trafgen: parser: fix regression on last pkt elementDaniel Borkmann1-2/+7
Jon Schipp reported that a arbitrary packet config such as ... { "MyPacket", "MyPacket", "MyPacket", "MyPacket", "MyPacket", "MyPacket", "MyPacket", "MyPacket", } ... doesn't work anymore, although it used to work. This regression was introduced by commit f9591eebe40c ("trafgen: lexer/parser: fix cpu() selection and whitespacing"). Reported-by: Jon Schipp <jonschipp@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-11man: netsniff-ng: Do some wordsmithingTobias Klauser1-5/+5
Fix wording and phrasing in some of the usage examples. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-04-11man: netsniff-ng: Fix typo of 'privileges'Tobias Klauser1-2/+2
Replace 'priviledges' by 'privileges'. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-04-11man: netsniff-ng: Fix a typoTobias Klauser1-1/+1
Replace 'networkoing' by 'networking'. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-04-09pcap_io: introduce init_once helper that is called with priviledgesDaniel Borkmann5-7/+23
When using netsniff-ng with dropping priviledges, we have to introduce another pcap helper function that is called once before we drop the priviledges. In this function we have to invoke the disc I/O scheduler policy, because it needs priviledges. Otherwise netsniff-ng will fail with "Failed to set io prio for pid" on startup, since we're not root anymore. Reported-by: Doug Burks <doug.burks@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-09trafgen: do not care if device is running yetDaniel Borkmann1-2/+0
E.g. when executing trafgen on tap devices, trafgen will complain that it is not up and running although it was brought up. Remove this usability restriction and let the kernel decide if it may send the packets or not. Reported-by: Aimal Khan <aimal.khan98@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-08man: ifpps: add bugs sectionDaniel Borkmann1-0/+6
Add a section of known bugs/todos for bpfc. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-08man: finish netsniff-ng man pageDaniel Borkmann1-29/+163
Fill in the rest of the gaps for this man page. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-08man: netsniff-ng: add description paragraph and some optionsDaniel Borkmann1-3/+84
This patch continues on the netsniff-ng man page. It adds a program description and documents some options, not yet all. More to come. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-08man: netsniff-ng: finish usage examples and add filter examplesDaniel Borkmann1-7/+80
The usage examples are good so far. Most of the things one needs to know. Also, add a short howto on how to use bpfc filtering or pcap-like high-level filters. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-08man: start netsniff-ng.8 man pageDaniel Borkmann1-0/+157
Not yet finished, but it already contains some useful example descriptions and notes for tuning. More to come very soon. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-04-07man: finish bpfc man pageDaniel Borkmann1-0/+199
This patch adds BPF architecture and instruction description with supported Linux extensions. Also, essential bpfc examples are given. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>