[PATCH 0/3] iptraf-ng: new packet capturing interface
by Vitezslav Samel
Vitezslav Samel (3):
introduce packet capturing abstraction
capt.c: add capturing using recvmmsg()
capt.c: add capturing using mmap()ed PACKET_RX_RING memory
Makefile | 15 +++++
src/capt-mmap-v2.c | 147 +++++++++++++++++++++++++++++++++++++++++++++++
src/capt-mmap-v2.h | 6 ++
src/capt-recvmmsg.c | 138 ++++++++++++++++++++++++++++++++++++++++++++
src/capt-recvmmsg.h | 6 ++
src/capt-recvmsg.c | 89 ++++++++++++++++++++++++++++
src/capt-recvmsg.h | 6 ++
src/capt.c | 153 +++++++++++++++++++++++++++++++++++++++++++++++++
src/capt.h | 31 ++++++++++
src/capture-pkt.c | 18 +++---
src/detstats.c | 27 ++++-----
src/hostmon.c | 26 ++++-----
src/ifstats.c | 21 ++++---
src/iptraf-ng-compat.h | 1 +
src/itrafmon.c | 23 +++-----
src/packet.c | 92 +----------------------------
src/packet.h | 13 +----
src/pktsize.c | 25 ++++----
src/serv.c | 26 ++++-----
19 files changed, 663 insertions(+), 200 deletions(-)
create mode 100644 src/capt-mmap-v2.c
create mode 100644 src/capt-mmap-v2.h
create mode 100644 src/capt-recvmmsg.c
create mode 100644 src/capt-recvmmsg.h
create mode 100644 src/capt-recvmsg.c
create mode 100644 src/capt-recvmsg.h
create mode 100644 src/capt.c
create mode 100644 src/capt.h
--
1.9.1
9 years, 1 month
[PATCH 0/4] iptraf-ng: cleanups
by Vitezslav Samel
Last batch of cleanups before capturing interface refactor.
Vitezslav Samel (4):
ipmon(): move keypress handling into separate function
ipmon(): move packet handling into separate function
pktsize.c: move keypress and packet handling into separate functions
ipmon(): call init/destroy functions in LIFO order
src/itrafmon.c | 701 ++++++++++++++++++++++++++++-----------------------------
src/othptab.c | 5 +
src/pktsize.c | 59 ++---
src/tcptable.c | 7 +
4 files changed, 382 insertions(+), 390 deletions(-)
--
1.9.1
9 years, 5 months
[PATCH 0/9] iptraf-ng: treewide: lists deletion simplification
by Vitezslav Samel
Vitezslav Samel (9):
ipfrag.c: kill unused variable from struct fragent
tui/winops.c: simplify tx_colorwin() and tx_wcoloreol()
tui/input.c: simplify tx_destroyfields()
tui/menurt.c: simplify tx_destroymenu()
fltedit.c: simplify destroyfilter()
fltmgr.c: simplify destroyfilterlist()
hostmon.c: simplify destroyethtab()
ipfrag.c: simplify destroyholes()
othptab.c: simplify destroyothptable()
src/fltedit.c | 26 +++++++++-----------------
src/fltmgr.c | 14 ++++----------
src/hostmon.c | 11 +++--------
src/ipfrag.c | 21 +++++----------------
src/othptab.c | 17 +++++------------
src/tui/input.c | 19 ++++++++-----------
src/tui/menurt.c | 21 ++++++++-------------
src/tui/winops.c | 28 +++++-----------------------
8 files changed, 47 insertions(+), 110 deletions(-)
--
1.9.1
9 years, 5 months
[PATCH 00/12] iptraf-ng: another cleanups
by Vitezslav Samel
Vitezslav Samel (12):
hostmon(): shuffle with init/destroy code
hostmon(): call init/destroy functions in LIFO order
hostmon(): optimize: move some checks away from the hot path
hostmon(): refactor various time computing
hostmon(): change do {} while() construct into while() {}
timer.c: cleanup printelapsedtime()
print_packet_drops(): use getmaxy() to get the last line
packet_size_breakdown(): refactor initialization
packet_size_breakdown(): optimize: move some checks away from the hot path
packet_size_breakdown(): refactor various time computing
packet_size_breakdown(): change do {} while() construct into while() {}
refactor pktsize.c to print in and out counters
src/deskman.c | 4 +-
src/deskman.h | 2 +-
src/detstats.c | 4 +-
src/hostmon.c | 168 +++++++++++++-------------
src/ifstats.c | 4 +-
src/itrafmon.c | 5 +-
src/pktsize.c | 366 +++++++++++++++++++++++++++++++--------------------------
src/serv.c | 4 +-
src/timer.c | 12 +-
src/timer.h | 2 +-
10 files changed, 299 insertions(+), 272 deletions(-)
--
1.9.1
9 years, 5 months
[PATCH 00/11] iptraf-ng: serv.c cleanups
by Vitezslav Samel
Vitezslav Samel (11):
serv.c: simplify destroyporttab()
servmon(): optimize: move some checks away from the hot path
servmon(): call init/destroy functions in LIFO order
servmon(): refactor various time computing
serv.c: move check for NULL barptr into addtoportlist()
serv.c: addtoportlist(): initialize span variable
serv.c: kill unused struct definition
serv.c: simplify destroyportlist()
serv.c: struct portlistent: kill unused variable
serv.c: struct portlist: kill unused variable
servmon(): move window handling functions
src/serv.c | 234 +++++++++++++++++++++++++++----------------------------------
1 file changed, 105 insertions(+), 129 deletions(-)
--
1.8.4
9 years, 5 months
[PATCH 00/10] iptraf-ng: ifstats() and detstats() cleanups
by Vitezslav Samel
Vitezslav Samel (10):
ifstats(): optimize: move some checks away from the hot path
ifstats(): call init/destroy functions in LIFO order
ifstats(): refactor various time computing
counters.c: rename functions to have the action last
detstats(), servmon(): use explicit counters reset functions
detstats(): refactor rates updating and printing
detstats(): call init/destroy functions in LIFO order
detstats(): optimize: move some checks away from the hot path
detstats(): refactor various time computing
detstats(): move keypress and packet handling into separate functions
src/counters.c | 27 ++-
src/counters.h | 7 +-
src/detstats.c | 619 +++++++++++++++++++++++++++++++--------------------------
src/ifstats.c | 101 +++++-----
src/serv.c | 12 +-
5 files changed, 423 insertions(+), 343 deletions(-)
--
1.9.1
9 years, 5 months
[PATCH 00/20] iptraf-ng: ipmon() cleanups
by Vitezslav Samel
Vitezslav Samel (20):
ipmon(): remove screen_idx variable
ipmon(): remove baridx variable
ipmon(): move mode variable into struct tcptable
ipmon(): no need to redraw sort win
itrafmon.c: refactor TCP screen scrolling
othptab.c: use struct in_addr for IPv4 address
ipmon(): move dropped packets count
itrafmon.c: refactor other packet screen scrolling
ipmon(): allow scrolling with Home, End keys
tcptable.c: simplify destroy_closed_entries()
tcptable.c: simplify destroytcptable()
struct tcptablent: kill unused starttime variable
updateentry(): rename transpacket variable to tcp
ipmon(): move statwin nad statpanel variables into struct tcptable
ipmon(): move NULL check into print_flowrate()
move_tcp_bar(): print flow rate after moving the bar
itrafmon.c: rename update_flowrate() to update_flowrates()
ipmon(): optimize: move some checks away from the hot path
ipmon(): refactor various time computing
ipmon(): simplify timeouted TCP entries handling
src/itrafmon.c | 575 +++++++++++++++++++++++++--------------------------------
src/othptab.c | 26 +--
src/othptab.h | 4 +-
src/tcptable.c | 268 ++++++++++++---------------
src/tcptable.h | 24 +--
5 files changed, 394 insertions(+), 503 deletions(-)
--
1.8.4
9 years, 5 months
Feature Request
by GH
an option to display netflow and have the ability to block/deny those
flows in realtime
9 years, 5 months
iptraf-ng
by 倪元椿
iptraf-ng
上海,北京,深圳,广东,微-信-营@销,即将开课
火热报名中,期待您的莅临。
倪元椿祝您生活愉快。
wiwkl
9 years, 5 months