On Mon, Aug 8, 2016 at 5:24 PM, Tobias Klauser wrote:
> On 2016-08-06 at 11:59:05 +0200, Vadim Kochan wrote:
>> On Sat, Aug 6, 2016 at 12:41 PM, Tobias Klauser wrote:
>> > On 2016-08-05 at 22:51:54 +0200, Vadim Kochan wrote:
>> >> Hm,
>> >>
&
ll be possible to generate only via protocol
header functions because with it we have all field metadata. Also
when dynamic fields series will be applied it may be possible also
convert them to pktgen's rand/inc commands.
But again let me know if it might be useful.
Regards,
Vadim Kocha
On Sat, Aug 6, 2016 at 12:41 PM, Tobias Klauser wrote:
> On 2016-08-05 at 22:51:54 +0200, Vadim Kochan wrote:
>> Hm,
>>
>> My version was to keep current strict dependency on libnl by default,
>> so if there is no libnl then
>> netsniff-ng & trafgen will
On Fri, Aug 05, 2016 at 09:26:24AM +0200, Tobias Klauser wrote:
> On 2016-07-26 at 21:35:11 +0200, Vadim Kochan wrote:
> > Add dynamic proto field function which can generate
> > random value in specified range (default 0 - MAX_UINT32).
> >
> >
On Wed, Aug 03, 2016 at 04:32:06PM +0200, Tobias Klauser wrote:
> On 2016-07-26 at 21:35:18 +0200, Vadim Kochan wrote:
> > Add 'dinc()' function in 'field_expr' rules to be used for dynamically
> > incrementing of any specified field:
> >
> > SYNTA
On Wed, Aug 03, 2016 at 04:27:14PM +0200, Tobias Klauser wrote:
> On 2016-07-26 at 21:35:10 +0200, Vadim Kochan wrote:
> > Extended 'struct packet_dyn' with proto fields which has
> > dynamically changing values at runtime.
> >
> > Implement incrementing of
s no libnl
then netsniff-ng & trafgen will be added to build list, and will be
compiled w/o libnl dependency..
So does --disable-libnl makes sense ?
Regards,
Vadim Kochan
On Fri, Aug 5, 2016 at 12:31 PM, Vadim Kochan wrote:
> Sorry for that copy'n'paste ...
>
> On Fri, Aug
On Fri, Aug 5, 2016 at 3:26 PM, Tobias Klauser wrote:
> On 2016-07-26 at 21:35:15 +0200, Vadim Kochan wrote:
>> Update UDP csum field at runtime if:
>>
>> 1) UDP field was changed.
>>
>> 2) IPv4/6 source/destination addresses were changed
>>
Sorry for that copy'n'paste ...
On Fri, Aug 5, 2016 at 12:29 PM, Tobias Klauser wrote:
> On 2016-08-04 at 18:30:20 +0200, Vadim Kochan wrote:
>> Add command line parsing function which allows to compile tools
>> (trafgen, netsniff-ng) without libnl-xxx libraries.
>
messages will be sniffed the noop dissector will be used.
Signed-off-by: Vadim Kochan
---
dissector.h | 4 ++--
dissector_netlink.c | 4
dissector_netlink.h | 4
dissector_sll.c | 5 -
netsniff-ng/Makefile | 27 +--
5 files changed, 31
quot;configure" options handler code
3) Print "[DISABLED]" if --disable-libnl option choosed when checking libnl
4) Skip compilation part in "configure" script for libnl if it is disabled
5) Added build test with --disabled-libnl in travis script
Vadim Kochan (
trafgen uses libnl only to inject mac80211 frames but
it might be not needed in some embedded or switch environments,
so lets make possible to disable this feature.
In case if --rfraw option will be used - user will get the panic message.
Signed-off-by: Vadim Kochan
---
mac80211.c | 1
Add command line parsing function which allows to compile tools
(trafgen, netsniff-ng) without libnl-xxx libraries.
Option --disable-libnl sets CONFIG_LIBNL=0 which means compile tools
without libnl dependencies.
Signed-off-by: Vadim Kochan
---
.travis.yml | 1 +
configure | 25
On Thu, Aug 4, 2016 at 12:19 PM, Tobias Klauser wrote:
> On 2016-08-03 at 10:58:00 +0200, Vadim Kochan wrote:
>> It might be useful only if to compile trafgen or netsniff-ng in environment
>> (or manually w/o needs for rfraw) where is no needed libnl (embedded/switch
>> ser
Ehh, too fast I need to avoid libnl compilation testing if
CONFIG_LIBNL=0, will resend it, sorry ...
On Wed, Aug 3, 2016 at 11:58 AM, Vadim Kochan wrote:
> Add command line parsing function which allows to compile tools
> (trafgen, netsniff-ng) without libnl-xxx libraries.
>
commits to be "configure" related changes 1st
2) Changed CONFIG_NO_LIBNL -> CONFIG_LIBNL
3) Changed "configure" option --no-libnl -> --disable-libnl
Tested on the VM Linux setup with and without libnl packages.
Vadim Kochan (3):
configure: Add option to comp
messages will be sniffed the noop dissector will be used.
Signed-off-by: Vadim Kochan
---
dissector.h | 4 ++--
dissector_netlink.c | 4
dissector_netlink.h | 4
dissector_sll.c | 5 -
netsniff-ng/Makefile | 27 +--
5 files changed, 31
Add command line parsing function which allows to compile tools
(trafgen, netsniff-ng) without libnl-xxx libraries.
Option --disable-libnl sets CONFIG_LIBNL=0 which means compile tools
without libnl dependencies.
Signed-off-by: Vadim Kochan
---
configure | 47
trafgen uses libnl only to inject mac80211 frames but
it might be not needed in some embedded or switch environments,
so lets make possible to disable this feature.
In case if --rfraw option will be used - user will get the panic message.
Signed-off-by: Vadim Kochan
---
mac80211.c | 1
OK, thank you!
On Wed, Aug 3, 2016 at 10:34 AM, Tobias Klauser wrote:
> On 2016-08-02 at 22:17:41 +0200, Vadim Kochan wrote:
>> On Tue, Aug 2, 2016 at 11:23 AM, Tobias Klauser wrote:
>> > On 2016-07-31 at 23:13:16 +0200, Vadim Kochan wrote:
>> >> trafgen uses
Yes, bug_on(x) is good point, so I am expecting you will continue
review the rest patches ?
Thanks,
On Tue, Aug 2, 2016 at 6:50 PM, Tobias Klauser wrote:
> On 2016-07-26 at 21:35:09 +0200, Vadim Kochan wrote:
>> Usually proto fields array is sorted in the same order as related enum,
On Tue, Aug 2, 2016 at 11:23 AM, Tobias Klauser wrote:
> On 2016-07-31 at 23:13:16 +0200, Vadim Kochan wrote:
>> trafgen uses libnl only to inject mac80211 frames but
>> it might be not needed in some embedded or switch environments,
>> so lets make possible to disable t
netlink messages will be sniffed the noop will be used.
Signed-off-by: Vadim Kochan
---
dissector.h | 4 ++--
dissector_netlink.c | 4
dissector_netlink.h | 4
dissector_sll.c | 5 -
netsniff-ng/Makefile | 27 +--
5 files changed, 31
trafgen uses libnl only to inject mac80211 frames but
it might be not needed in some embedded or switch environments,
so lets make possible to disable this feature.
In case if --rfraw option will be used - user will get the panic message.
Signed-off-by: Vadim Kochan
---
mac80211.c | 1
Add command line parsing function which allows to compile tools (trafgen,
netsniff-ng)
without libnl-xxx libraries.
Option --no-libnl sets CONFIG_NO_LIBNL=1.
Signed-off-by: Vadim Kochan
---
configure | 52 +---
1 file changed, 49 insertions
lmsg dissecting. For example
netsniff-ng might be used just for sniffing, and trafgen - send packets to wired
network only.
Therefor added --no-libnl option in ./confiure script which sets make option &
CPP definition which are used to ignore libnl- related code/modules/libraries.
Vadim Kochan (3):
series or after
it will be applied.
Regards,
Vadim Kochan
On Tue, Jul 26, 2016 at 10:35 PM, Vadim Kochan wrote:
> Implemented 'dinc' and 'drnd' functions to be used for proto fields,
> and generate values at runtime. Parsing of proto field values
> for unified to make
Changed parsing logic of field value expression to
be more generic. Such approach will allow to easy
extend field value expression to support dynamic field functions.
Signed-off-by: Vadim Kochan
---
trafgen_parser.y | 358 +--
trafgen_proto.c
Handle 'field_changed' callback to check if IPv4 csum is needed
to be recalculated, if so - update it on 'packet_update' event.
Added 'is_csum_valid' to proto_hdr struct to check if csum needs to
be updated.
Signed-off-by: Vadim Koc
Use same function to calculate csum for packet_update
and for packet_finish events.
Allow update csum if one of the ICMPv6 fields was changed.
Signed-off-by: Vadim Kochan
---
trafgen_l4.c | 26 +++---
1 file changed, 15 insertions(+), 11 deletions(-)
diff --git a
Add explanation about 'drnd' and 'dinc' functions which might
be used for proto field functions.
Signed-off-by: Vadim Kochan
---
trafgen.8 | 34 +-
1 file changed, 33 insertions(+), 1 deletion(-)
diff --git a/trafgen.8 b/trafgen.8
index c95
Update csum if any of ICMPv4 field was chaned.
Signed-off-by: Vadim Kochan
---
trafgen_l4.c | 20
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/trafgen_l4.c b/trafgen_l4.c
index 79c5914..19ebb37 100644
--- a/trafgen_l4.c
+++ b/trafgen_l4.c
@@ -156,25
Update TCP checksum field if any TCP of fields was changed.
Use same checksum update function on 'packet_finish' and 'header update'.
Set 'is_csum_valid = false' if lower IPv4/IPv6 pseudo header was changed.
Signed-off-by: Vadim Kochan
---
trafgen_l3.
Add 'dinc()' function in 'field_expr' rules to be used for dynamically
incrementing of any specified field:
SYNTAX := dinc() | dinc(inc) | dinc(min, max) | dinc(inc, min, max)
EXAMPLES:
{ udp(sport=dinc() }
{ udp(sport=dinc(1) }
{ udp(sport=dinc(5, 100, 125) }
Add syntax for specify dynamic random function for proto field:
drnd() | drnd(min, max)
EXAMPLE:
{ udp(sport=drnd()) }
{ udp(sport=drnd(1000, 2000)) }
Signed-off-by: Vadim Kochan
---
trafgen_parser.y | 9 +
1 file changed, 9 insertions(+)
diff --git a/trafgen_parser.y b
header faster, the reason is that this function
is used for updating UDP csum.
Signed-off-by: Vadim Kochan
---
trafgen_l3.c| 18 ++
trafgen_l4.c| 37 +
trafgen_proto.c | 36 +++-
trafgen_proto.h | 2
Add dynamic proto field function which can generate
random value in specified range (default 0 - MAX_UINT32).
Signed-off-by: Vadim Kochan
---
trafgen_proto.c | 29 +
trafgen_proto.h | 1 +
2 files changed, 30 insertions(+)
diff --git a/trafgen_proto.c b
Till now headers were used only for packet creation at compile time
only, which does not allow to handle dynamic fields update at runtime.
It needs that proto_hdr entries will be not freed after compile is done.
Signed-off-by: Vadim Kochan
---
trafgen_conf.h | 6 ++
trafgen_parser.y | 17
Using of current_packet() is not relevant for dynamically updated
fields so lets keep packet index in proto_hdr struct.
Signed-off-by: Vadim Kochan
---
trafgen_conf.h | 2 ++
trafgen_parser.y | 10 ++
trafgen_proto.c | 13 +++--
trafgen_proto.h | 4
4 files changed
Same code for applying dynamic elements is used in both places
for slow & fast path modes, lets move them into one inlined function.
Signed-off-by: Vadim Kochan
---
trafgen.c | 25 +++--
1 file changed, 11 insertions(+), 14 deletions(-)
diff --git a/trafgen.c b/trafg
Usually proto fields array is sorted in the same order as related enum,
so id may be used as index for faster lookup, it will make
csum field calculation little faster at runtime.
Signed-off-by: Vadim Kochan
---
trafgen_l3.h| 4 ++--
trafgen_proto.c | 8 +---
2 files changed, 3
ield lookup logic to make field set/get operations a little bit faster
by
using field id as index in the array, as usually fields are defined regarding
its index.
Example:
{ eth(sa=11:22:33:44:55:66, sa=dinc()), udp(sp=drnd(), dp=drnd()) }
Vadim Kochan (15):
trafgen: Move applying dynamic
proto header know
when to apply final proto header changes at runtime (csum update).
Signed-off-by: Vadim Kochan
---
trafgen.c | 9 ++
trafgen_conf.h | 7
trafgen_proto.c | 99 +
trafgen_proto.h | 26 +++
4 fi
Do not use user specified LEN field for csum calculation which
is quite dangerous.
Signed-off-by: Vadim Kochan
---
trafgen_l4.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/trafgen_l4.c b/trafgen_l4.c
index c109675..79c5914 100644
--- a/trafgen_l4.c
+++ b/trafgen_l4.c
@@ -44,8 +44,6
It is totally wrong to use user specified IHL field for csum
calculation which might lead to unexpectable cases.
So use new 'hdr->len' field which is calculated automatically after
when header is built.
Signed-off-by: Vadim Kochan
---
trafgen_l3.c| 4 +---
trafge
It is dangerous to use such fields like 'ihl' and 'len' when calculate csum
for IPv4 & UDP headers because these fields are set from user. Instead -
use program calculated values.
Vadim Kochan (2):
trafgen: ipv4: Do not use 'ihl' field when calculate csum
tr
Set default ip proto field to IPPROTO_IPV6(41) if the higher protocol
was specified as ipv6().
Signed-off-by: Vadim Kochan
---
trafgen_l3.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/trafgen_l3.c b/trafgen_l3.c
index ae3f136..012321f 100644
--- a/trafgen_l3.c
+++ b/trafgen_l3.c
On Fri, Jul 15, 2016 at 11:11 PM, Vadim Kochan wrote:
> Set default ip proto field to IPPROTO_IPV6(0x41) if the higher protocol
> was specified as ipv6().
>
> Signed-off-by: Vadim Kochan
> ---
> trafgen_l3.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/
Set default ip proto field to IPPROTO_IPV6(0x41) if the higher protocol
was specified as ipv6().
Signed-off-by: Vadim Kochan
---
trafgen_l3.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/trafgen_l3.c b/trafgen_l3.c
index ae3f136..012321f 100644
--- a/trafgen_l3.c
+++ b/trafgen_l3.c
quot; sign
2) Removed keywords with special icmpv4 message type parameters except
MTU & Address.
Vadim Kochan (3):
trafgen: l3: Add creating ICMPv4 header
trafgen: parser: Add function to build ICMPv4 header
trafgen: man: Add description for icmpv4() function
trafgen
Signed-off-by: Vadim Kochan
---
trafgen_l3.c| 3 +++
trafgen_l4.c| 42 ++
trafgen_l4.h| 10 ++
trafgen_proto.h | 1 +
4 files changed, 56 insertions(+)
diff --git a/trafgen_l3.c b/trafgen_l3.c
index cbdbe6c..ae3f136 100644
--- a/traf
Add description icmpv4() function parameters with few examples.
Signed-off-by: Vadim Kochan
---
trafgen.8 | 44
1 file changed, 44 insertions(+)
diff --git a/trafgen.8 b/trafgen.8
index b011276..e654770 100644
--- a/trafgen.8
+++ b/trafgen.8
0)
seq Set sequence field (default 0)
idSet identifier field (default 0)
addr Set redirect address (default 0)
Example: Send Ping request:
{ icmpv4(echorequest, seq=1, id=1326) }
Signed-off-by: Vadim Kochan
---
trafgen_lexer.l | 6 ++
trafgen_par
On Mon, Jul 11, 2016 at 11:10 AM, Tobias Klauser wrote:
> On 2016-04-30 at 16:39:19 +0200, Vadim Kochan wrote:
>> Add 'icmpv4()' function to create ICMPv4 header.
>>
>> Parameters suported:
>>
>> type Set type field (default 0: Echo reply)
On Mon, May 16, 2016 at 7:58 PM, Vadim Kochan wrote:
> If all packets did not pass the filter then output pcap
> file will be created with pcap header, which might be not what user
> expect - to see only interested pcap files.
>
> Signed-off-by: Vadim Kochan
> ---
>
Hi Tobias,
On Sat, Apr 30, 2016 at 6:01 PM, Tobias Klauser wrote:
> Hi Vadim
>
> Thanks for the series. I'll be travelling for a while starting tomorrow,
> so it will probably take a while until I get to review the patches.
>
> Thanks
> Tobias
Will you look on this series ?
Regards,
--
You r
Hi Tobias,
On Wed, Jun 22, 2016 at 10:25 AM, Tobias Klauser wrote:
> On 2016-05-16 at 19:32:46 +0200, Vadim Kochan wrote:
>> It might be more understandable to print unsupported
>> pcap magic number in hexadecimal format.
>>
>> Signed-off-by: Vadim Kochan
>
> A
It might be more understandable to print unsupported
pcap magic number in hexadecimal format.
Signed-off-by: Vadim Kochan
---
pcap_io.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pcap_io.h b/pcap_io.h
index 5056e58..4e41362 100644
--- a/pcap_io.h
+++ b/pcap_io.h
If all packets did not pass the filter then output pcap
file will be created with pcap header, which might be not what user
expect - to see only interested pcap files.
Signed-off-by: Vadim Kochan
---
netsniff-ng.c | 33 +
1 file changed, 21 insertions(+), 12
After splitting etype & type to different tokens it is possible
to use 'type' for ICMP type field which is used by RFC.
Signed-off-by: Vadim Kochan
---
trafgen.8| 4 ++--
trafgen_lexer.l | 1 -
trafgen_parser.y | 8
3 files changed, 6 insertions(+), 7 deletions(
Add description icmpv4() function parameters with few examples.
Signed-off-by: Vadim Kochan
---
trafgen.8 | 118 ++
1 file changed, 118 insertions(+)
diff --git a/trafgen.8 b/trafgen.8
index 6691e16..6be6f1c 100644
--- a/trafgen.8
Change echorequest to echo-request, and echoreply to echo-reply
which looks more readable.
Signed-off-by: Vadim Kochan
---
trafgen.8 | 6 +++---
trafgen_lexer.l | 4 ++--
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/trafgen.8 b/trafgen.8
index b011276..6691e16 100644
-tos-redirect
ttl-timeout
frag-timeout
Vadim Kochan (6):
trafgen: parser: Split [e]type to separate keywords
trafgen: parser: Replace 'mtype' by 'type'
trafgen: parser: Split echorequest & echoreply with "-"
trafgen: l3: Add creating ICMPv4 header
ddress
Signed-off-by: Vadim Kochan
---
trafgen_l3.c| 3 +++
trafgen_l4.c| 42 ++
trafgen_l4.h| 10 ++
trafgen_proto.h | 1 +
4 files changed, 56 insertions(+)
diff --git a/trafgen_l3.c b/trafgen_l3.c
index cbdbe6c..ae3f136 100644
---
Split [e]etype to separate 'type' & 'etype' keywords,
the reason is that 'type' might be used in other protocol
headers (e.g. ICMP).
Signed-off-by: Vadim Kochan
---
trafgen_lexer.l | 3 ++-
trafgen_parser.y | 3 ++-
2 files changed, 4 insertions(+), 2 deletion
meout Set 'TTL expired in transit' message type
frag-timeoutSet 'Fragment reassembly time exceeded' message type
Examples:
a) Send Ping request:
{ icmpv4(echo-request, seq=1, id=1326) }
b) Send ICMPv4
On Tue, Apr 26, 2016 at 12:00 PM, Tobias Klauser wrote:
> On 2016-04-26 at 10:47:18 +0200, Vadim Kochan wrote:
>> On Tue, Apr 26, 2016 at 10:30:19AM +0200, Tobias Klauser wrote:
>> > On 2016-04-25 at 16:55:53 +0200, Vadim Kochan wrote:
>> > > On Mon, Apr 25, 20
On Tue, Apr 26, 2016 at 10:30:19AM +0200, Tobias Klauser wrote:
> On 2016-04-25 at 16:55:53 +0200, Vadim Kochan wrote:
> > On Mon, Apr 25, 2016 at 11:21:57AM +0200, Tobias Klauser wrote:
> > > On 2016-04-22 at 23:53:01 +0200, Vadim Kochan wrote:
> > > > Hi,
> &
It is better to fill the empty columns for visualization,
so its easier identify the whole line.
Signed-off-by: Vadim Kochan
---
ui.c | 18 +-
ui.h | 1 +
2 files changed, 14 insertions(+), 5 deletions(-)
diff --git a/ui.c b/ui.c
index cfa1471..9f0a0e0 100644
--- a/ui.c
+++ b
Add short description for -d,--dump option, and also
update description for -t,--interval option which might
be used together with -d option.
Signed-off-by: Vadim Kochan
---
flowtop.8 | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/flowtop.8 b/flowtop.8
index
"-->" allows to better separate src & dst peers.
Signed-off-by: Vadim Kochan
---
flowtop.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/flowtop.c b/flowtop.c
index 20b3c25..ab3459a 100644
--- a/flowtop.c
+++ b/flowtop.c
@@ -1020,6 +1020,8 @@ static void draw_flow_
able was changed to be more generic used in both curses & stdout modes,
I think it would be good to make it generate CSV/JSON format in similar usage.
Vadim Kochan (8):
ui: Use custom print function
ui: Allow to use stdout or curses UI output mode
ui: Print "*" for empty or
ut only for delay to collect
such dynamic info like rate. By default interval set to 0 if --dump
option is selected.
Signed-off-by: Vadim Kochan
---
flowtop.c | 134 --
1 file changed, 113 insertions(+), 21 deletions(-)
diff --git a/f
It allows to initialize UI with specific output type
and use same functionality for the output.
Signed-off-by: Vadim Kochan
---
ui.c | 52 +++-
ui.h | 7 +++
2 files changed, 50 insertions(+), 9 deletions(-)
diff --git a/ui.c b/ui.c
index
Remove unused "screen" & "line" arguments in draw_flow_entry(...)
function.
Signed-off-by: Vadim Kochan
---
flowtop.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/flowtop.c b/flowtop.c
index ab3459a..cbd5a33 100644
--- a/flowtop.c
+++ b/fl
Move curses related drawing to separate function. Similary
there will be stdout drawing function.
Signed-off-by: Vadim Kochan
---
flowtop.c | 16 ++--
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/flowtop.c b/flowtop.c
index cbd5a33..65a8ad4 100644
--- a/flowtop.c
Use custom defined ui_print_yx macro to print text to screen.
This is just small preparation to unify printing in STDOUT & CURSES
modes.
Signed-off-by: Vadim Kochan
---
ui.c | 14 --
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/ui.c b/ui.c
index 46062d4..bc9
On Mon, Apr 25, 2016 at 11:21:57AM +0200, Tobias Klauser wrote:
> On 2016-04-22 at 23:53:01 +0200, Vadim Kochan wrote:
> > Hi,
> >
> > I am thinking about to add dump of flows to stdout. It seems OK if
> > to use similar table format like in curses mode by default,
his is just for external text
processing.
Also may be it would be useful to print empty columns with "*" or "-"
it will be more visually readable (probably in curses mode too) and also be
processed by awk.
Regards,
Vadim Kochan
--
You received this message because you are s
Add another tip how to activate conntrack mechanism by
loading required kernel modules via modprobe. This info
might be used to make these modules load automatically at startup.
Signed-off-by: Vadim Kochan
---
flowtop.8 | 8
1 file changed, 8 insertions(+)
diff --git a/flowtop.8 b
Config file.
Fixes: f61f39d (geoip: Allow to get country 3-code)
Reported-by: Daniel Borkmann
Signed-off-by: Vadim Kochan
---
geoip.h | 10 ++
1 file changed, 10 insertions(+)
diff --git a/geoip.h b/geoip.h
index 0cbd619..5d5c221 100644
--- a/geoip.h
+++ b/geoip.h
@@ -104,6 +104,16
Simplify screen refresh logic by removing tricky delay
logic which freezes a little key pressing.
Signed-off-by: Vadim Kochan
---
flowtop.c | 21 +++--
1 file changed, 3 insertions(+), 18 deletions(-)
diff --git a/flowtop.c b/flowtop.c
index 3628d39..20b3c25 100644
--- a
Fill table with empty rows while clearing.
It will allow to get rid of clear() & refresh() each time
before print the flows list.
Signed-off-by: Vadim Kochan
---
ui.c | 12
ui.h | 4 +++-
2 files changed, 15 insertions(+), 1 deletion(-)
diff --git a/ui.c b/ui.c
index 80b
Linux naming.
3) Get rid of clear & refresh screen each time while flows printing.
Vadim Kochan (6):
list: Add re-defined double-linked list API from liburcu
ui: Implement UI table for flows printing
flowtop: Use new UI table API for draw flows list
ui: Print empty rows when c
Add new module ui.c which is responsible to render
different kinds of UI widgets - tables, etc.
Implemented generic API for print table-like list of elements.
This table API might be used for print flows in curses or text mode.
Signed-off-by: Vadim Kochan
---
ui.c | 141
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
---
flowtop.c| 245 +++
flowtop/Makefile | 1 +
2 files changed, 141
Don't use refresh() & clear() as we draw entire screen
and flows table will be filled with empty rows.
Signed-off-by: Vadim Kochan
---
flowtop.c | 13 ++---
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/flowtop.c b/flowtop.c
index 32459aa..3628d39 100644
--- a/
Add definitions for list structure & functions without cds_/CDS_ prefix.
The purpose of this change is to use such linked-list in sorting or
ordering some kind of items (e.g. flowtop - flows, columns).
Signed-off-by: Vadim Kochan
---
list.h | 39 +++
1
On Thu, Apr 21, 2016 at 2:53 PM, Tobias Klauser wrote:
> On 2016-04-17 at 19:31:30 +0200, Vadim Kochan wrote:
>> Add new module ui.c which is responsible to render
>> different kinds of UI widgets - tables, etc.
>>
>> Implemented generic API for print table-like list
You can still review the rest patches except last 2 ones, in case if
you catch some issues, so
I will include them in v3 series, if it is OK for you.
Thanks,
On Thu, Apr 21, 2016 at 12:52 PM, Tobias Klauser wrote:
> On 2016-04-17 at 19:31:23 +0200, Vadim Kochan wrote:
>> Changed f
On Sun, Apr 17, 2016 at 8:31 PM, Vadim Kochan wrote:
> Don't use refresh() & clear() as we draw entire screen
> and flows table will be filled with empty rows.
>
> Signed-off-by: Vadim Kochan
> ---
> flowtop.c | 11 ---
> 1 file changed, 4 insertions(+), 7
On Sun, Apr 17, 2016 at 6:24 PM, Tobias Klauser wrote:
> On 2016-04-17 at 09:06:35 +0200, Vadim Kochan wrote:
>> Hi,
>>
>> I prepared new series for flowtop, I changed state names to this:
>>
>> static const char *cons
Don't use refresh() & clear() as we draw entire screen
and flows table will be filled with empty rows.
Signed-off-by: Vadim Kochan
---
flowtop.c | 11 ---
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/flowtop.c b/flowtop.c
index 32459aa..3060917 100644
--- a/
Simplify screen refresh logic by removing tricky delay
logic which freezes a little key pressing.
Signed-off-by: Vadim Kochan
---
flowtop.c | 21 +++--
1 file changed, 3 insertions(+), 18 deletions(-)
diff --git a/flowtop.c b/flowtop.c
index 3060917..2077fdb 100644
--- a
Fill table with empty rows while clearing.
It will allow to get rid of clear() & refresh() each time
before print the flows list.
Signed-off-by: Vadim Kochan
---
ui.c | 18 ++
ui.h | 4 +++-
2 files changed, 21 insertions(+), 1 deletion(-)
diff --git a/ui.c b/ui.c
i
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
---
flowtop.c| 245 +++
flowtop/Makefile | 1 +
2 files changed, 141
table style. Add new UI module with
generic table API.
2) Add Linux-like list API used from liburcu but with redefinitions
to the Linux naming.
3) Get rid of clear & refresh screen each time while flows printing.
Vadim Kochan (11):
geoip: Allow to get country 3-
Added macros which allow easy specify color pair like:
INIT_COLOR(YELLOW, BLACK);
COLOR(YELLOW, BLACK);
COLOR_ON(YELLOW, BLACK);
by calculating pair id via generic formula. Added shorter
color names via new enum.
Signed-off-by: Vadim Kochan
---
screen.h | 17 +
1
Use new colors definitions via enum variables instead of
numbers which helps to undrerstand better which kind
of color is used.
Signed-off-by: Vadim Kochan
---
flowtop.c | 42 ++
1 file changed, 22 insertions(+), 20 deletions(-)
diff --git a/flowtop.c b
Add new module ui.c which is responsible to render
different kinds of UI widgets - tables, etc.
Implemented generic API for print table-like list of elements.
This table API might be used for print flows in curses or text mode.
Signed-off-by: Vadim Kochan
---
ui.c | 142
201 - 300 of 779 matches
Mail list logo