summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-05-30man: manpage hyphen fixes, take threeKartik Mistry1-7/+7
More hyphen fixes all over. Signed-off-by: Kartik Mistry <kartik@debian.org> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-30man: manpage hyphen fixes, take twoKartik Mistry3-108/+109
Fix hyphens all over. Signed-off-by: Kartik Mistry <kartik@debian.org> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-30ring: set_sockopt_tpacket: rename to set_sockopt_tpacket_v2Daniel Borkmann3-3/+3
Rename it to set_sockopt_tpacket_v2 so that we later on can also add other versions and have it clearly stated which one we use. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-30ifpps: Allocate cpu dependent stats in one placeTobias Klauser1-15/+9
Avoid code duplication by allocating the stats arrays dependent on the number of CPUs in main() rather than screen_main() and term_main(). Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-30ring: remove fanout related bitsDaniel Borkmann1-20/+0
We currently do not support it, so do not keep it here. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-30man: manpages hyphen and spelling mistakesKartik Mistry7-48/+48
Some fixes all over, part 1. Signed-off-by: Kartik Mistry <kartik@debian.org> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-30misc: Fixed spelling mistakesKartik Mistry3-6/+6
Fix for spelling mistakes detected by Lintian. Signed-off-by: Kartik Mistry <kartik@debian.org> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29conf: oui: run oui-update.py script over config fileDaniel Borkmann1-175/+519
Update oui entries. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29docs: minor: fix whitespacing in copying fileDaniel Borkmann1-2/+2
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29docs: move sponsor names into authorsDaniel Borkmann2-14/+7
We don't need to keep an extra file around, put this into the AUTHORS file under sponsor section. Also credit Team Cymru for providing an extra machine for us for ASN mappings. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29make: add DISTRO=1 for compilation on distributionsDaniel Borkmann1-6/+9
For packaging, we cannot use -O3, -march etc, so have an option that allows for distribution build and does less tuning. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29make: allow to append CFLAGS in addition to overwriteDaniel Borkmann1-19/+14
This is needed for distribution packaging purposes. Also remove the warning, because -I/-L paths for nacl could be defined via cmdline as well. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29ifpps: fix segfault in terminal modeDaniel Borkmann1-0/+7
Introduced by commit 0e47d1d5011f ("ifpps: Don't assume a maximum of 32 CPUs"). Also update term_main with initial allocation of CPU data. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29ifpps: Properly zero out allocated statsTobias Klauser1-1/+1
The dynamically allocated members of struct ifstat have an entry for each CPU. Properly consider this when resetting the stats in the STATS_ZERO1 macro. Reported-by: Daniel Borkmann <borkmann@iogearbox.net> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-29ifpps: support mq devices in /proc/interruptsDaniel Borkmann1-2/+7
/proc/interrupts can have such a structure ... 98: 35 0 2902361 PCI-MSI-X eth1-0 106: 61 11 3841 PCI-MSI-X eth1-1 114: 28 0 61452 PCI-MSI-X eth1-2 122: 24 1586 22 PCI-MSI-X eth1-3 130: 2912 0 337 PCI-MSI-X eth1-4 138: 21 0 28 PCI-MSI-X eth1-5 146: 21 0 56 PCI-MSI-X eth1-6 154: 34 1 1 PCI-MSI-X eth1-7 ... and will not count all IRQs for eth1-*. Thus change it to sum up multiple entries. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29ifpps: also show total number of cpusDaniel Borkmann1-2/+2
Just a minor change to also show the total number of cpus in the headline. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-29ifpps: remove unused function snr_to_strDaniel Borkmann1-16/+0
It's not used anywhere anymore, so remove it. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27ifpps: Use strtoul() to convert unsigned valueTobias Klauser1-1/+1
The refresh interval can only be positive and is stored in an uint64_t, so use strtoul() to convert it. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-27ifpps: minor: minor output formatting adaptionDaniel Borkmann1-2/+2
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27man: ifpps: document ifpps behaviour when CPU > 10Daniel Borkmann1-0/+5
Document the behaviour of ifpps when we switch to heavy hitter mode. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27ifpps: fix bug_on trigger when parsing irq numberDaniel Borkmann1-10/+18
When parsing irq numbers on e.g. 24 CPU machines, procfs lines can get very long, so our static temporary buffer size will fail here with: Assertion `!(stats->irq_nr == 0)' failed. So allocate it relative to the CPU number. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27ifpps: beautify output with > 10 cpusDaniel Borkmann1-15/+26
I've tested it on a 24 CPU machine, and it does not look so nice if there's different padding along the lines. This patch fixes it. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27ifpps: Add myself to the copyright holders in --version/--helpTobias Klauser1-0/+2
Add my name to the ouput of --version and --help. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-27ifpps: Don't assume a maximum of 32 CPUsTobias Klauser2-34/+158
There are people with machines containing far more than 32 CPUs. In their case ifpps didn't work until now because of a limitation to 32 CPUs. Rework ifpps to support an arbitrary number of CPUs. In order to still remain within the display space, if more than 10 (TOP_CPUS) CPUs are available, only the 10 top hitting (in terms of usr and sys time or irqs respectively) are displayed. Suggested-by: Daniel Borkmann <borkmann@iogearbox.net> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-27docs: readme: just shortly also mention JIT disassemblerDaniel Borkmann1-1/+1
Just shortly also mention JIT disassembler in conjunction with bpfc. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27bpf: add minimal BPF JIT emitted image disassemblerDaniel Borkmann1-0/+207
This is a minimal stand-alone user space helper, that allows for debugging or verification of emitted BPF JIT images. This is in particular useful for emitted opcode debugging, since minor bugs in the JIT compiler can be fatal. The disassembler is architecture generic and uses libopcodes and libbfd. How to get to the disassembly, example: 1) `echo 2 > /proc/sys/net/core/bpf_jit_enable` 2) Load a BPF filter (e.g. `tcpdump -p -n -s 0 -i eth1 host 192.168.20.0/24`) 3) Run e.g. `bpf_jit_disasm -o` to disassemble the most recent JIT code output `bpf_jit_disasm -o` will display the related opcodes to a particular instruction as well. Example for x86_64: $./bpf_jit_disasm 94 bytes emitted from JIT compiler (pass:3, flen:9) ffffffffa0356000 + <x>: 0: push %rbp 1: mov %rsp,%rbp 4: sub $0x60,%rsp 8: mov %rbx,-0x8(%rbp) c: mov 0x68(%rdi),%r9d 10: sub 0x6c(%rdi),%r9d 14: mov 0xe0(%rdi),%r8 1b: mov $0xc,%esi 20: callq 0xffffffffe0d01b71 25: cmp $0x86dd,%eax 2a: jne 0x000000000000003d 2c: mov $0x14,%esi 31: callq 0xffffffffe0d01b8d 36: cmp $0x6,%eax [...] 5c: leaveq 5d: retq $ ./bpf_jit_disasm -o 94 bytes emitted from JIT compiler (pass:3, flen:9) ffffffffa0356000 + <x>: 0: push %rbp 55 1: mov %rsp,%rbp 48 89 e5 4: sub $0x60,%rsp 48 83 ec 60 8: mov %rbx,-0x8(%rbp) 48 89 5d f8 c: mov 0x68(%rdi),%r9d 44 8b 4f 68 10: sub 0x6c(%rdi),%r9d 44 2b 4f 6c [...] 5c: leaveq c9 5d: retq c3 Note that this is also part of the Linux kernel source tree under tools/net/. We also keep a copy of it here, since it is quite useful in conjunction with bpfc for debugging purposes. However, we do not integrate this small helper into the main build process. People who care to have this need to compile it on their own which is not a big deal. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27man: mausezahn: initial formatting and fixupsDaniel Borkmann1-295/+304
Format larger text sections into subsections, include .PPs and other fixups. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27man: minor: trafgen: add .PPs and modify BUGS sectionDaniel Borkmann1-81/+82
Minor change in BUGS section to bring it up to date. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27man: minor: flowtop: add .PPsDaniel Borkmann1-34/+34
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-27man: minor: astraceroute: add .PPsDaniel Borkmann1-49/+49
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-26man: netsniff-ng: Reword a few sentencesTobias Klauser1-14/+13
Make the 2nd section of the description a bit easier to read by splitting and rearranging sentences. Also add a few missing punctuations or make it more consistent repectively. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-26mausezahn: show long version on cliDaniel Borkmann1-1/+1
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-26make: minor cleanups in MakefileDaniel Borkmann1-6/+14
Remove some unneeded stuff, and move other things around. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-26man: netsniff-ng: add note about multithreadingDaniel Borkmann1-0/+9
Add a paragraph about multi-threading with netsniff-ng. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-25ifpps: Convert mem_free/mem_total members of struct ifstat to uint64_tTobias Klauser1-3/+4
Memory usage can never be negative, so make these members unsigned. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
2013-05-24man: curvetun: grammer, spelling, and other minor correctionsJon Schipp1-17/+15
Signed-off-by: Jon Schipp <jonschipp@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-24make: add HARDENING build optionDaniel Borkmann1-8/+17
Add HARDENING=1 build option and move all hardening-related GCC flags into this condition. This allows the user to choose whether or not he wants to have a hardened build with some possible performance tradeoff at load/runtime. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-24make: minor update in cflagsDaniel Borkmann1-4/+5
Add -z relro for linking, move --param ssp-buffer-size=4 to stack protector flag, and more. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-24misc: fix some minor compile warnings all overDaniel Borkmann4-7/+8
Some regarding unused parameter, some regarding signed/unsigned comparison. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-23man: trafgen: corrections and various edits to manual pageJon Schipp1-16/+16
Signed-off-by: Jon Schipp <jonschipp@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-23make: include build nameDaniel Borkmann9-10/+11
Include long version string into tools when called with --version. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-23bpfc: minor: do a line-break before 80-columnDaniel Borkmann1-1/+2
Just a minor cosmetic fix. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-23bpfc: allow bpf programs to be passed to cppDaniel Borkmann4-8/+48
This patch allows bpf programs to be passed to the C preprocessor before handing over to bpfc. Example: #define ETH_P_IP 0x800 ldh [12] jne #ETH_P_IP, drop ldb [23] jneq #6, drop ldh [20] jset #0x1fff, drop ldxb 4 * ([14] & 0xf) ldh [x + 14] jeq #0x16, pass ldh [x + 16] jne #0x16, drop pass: ret #-1 drop: ret #0 Compile with: bpfc -i foo -p Suggested-by: John Lange <JLange@trendium.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-22man: astraceroute: minor edits all overJon Schipp1-19/+18
Some minor edits all over the place. Signed-off-by: Jon Schipp <jonschipp@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-22docs: minor: say it's staging area, not a branchDaniel Borkmann1-2/+1
The extra branch is history for a while now, it's an internal staging area instead. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-22man: netsniff-ng: edits to the netsniff-ng man pageJon Schipp1-19/+20
Various edits all over. Signed-off-by: Jon Schipp <jonschipp@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-22docs: minor: Add missing word 'it'Jon Schipp1-1/+1
Signed-off-by: Jon Schipp <jonschipp@gmail.com> Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-21curvetun: use free instead of xfreeDaniel Borkmann1-8/+4
Only use xfree where it makes sense, here not really. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-21man: curvetun: finish up initial draft of curvetunDaniel Borkmann1-8/+105
Initial draft of curvetun manpage. Follow-up commits may come to fix formating errors and the like. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-05-21man: curvetun: add option and usage example sectionDaniel Borkmann1-3/+81
This patch implements the option and usage examples of curvetun. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>