forked from osmocom/wireshark
README.tapping: minor changes.
Change-Id: I0614d4c0cc8c9aada8660297b9d08f9d03129e29 Reviewed-on: https://code.wireshark.org/review/33433 Reviewed-by: Jaap Keuter <jaap.keuter@xs4all.nl>
This commit is contained in:
parent
23ec0666c5
commit
01a30c1018
|
@ -4,7 +4,7 @@ In order to use the tapping system, very little knowledge of Wireshark
|
|||
internals are required.
|
||||
|
||||
As examples on how to use the tap system see the implementation of
|
||||
tap-rpcstat.c (tshark version)
|
||||
tap-rpcprogs.c (tshark version)
|
||||
ui/qt/rpc_service_response_time_dialog.cpp (wireshark version)
|
||||
|
||||
If all you need is to keep some counters, there's the stats_tree API,
|
||||
|
@ -18,11 +18,8 @@ protocol dissector, and
|
|||
2, event driven code in an extension such as tap-rpcstat.c that registers
|
||||
a tap listener and processes received data.
|
||||
|
||||
|
||||
|
||||
So you want to hack together a tap application?
|
||||
|
||||
|
||||
TAP
|
||||
===
|
||||
First you must decide which protocol you are interested in writing a tap
|
||||
|
@ -55,11 +52,10 @@ need.
|
|||
|
||||
TAP LISTENER
|
||||
============
|
||||
(see tap-rpcstat.c as an example)
|
||||
(see tap-rpcprogs.c as an example)
|
||||
Interfacing your application is not that much harder either.
|
||||
Only 4 callbacks and two functions.
|
||||
|
||||
|
||||
The two functions to start or stop tapping are
|
||||
|
||||
register_tap_listener(const char *tapname, void *tapdata, const char *fstring,
|
||||
|
@ -69,14 +65,14 @@ register_tap_listener(const char *tapname, void *tapdata, const char *fstring,
|
|||
void (*draw)(void *tapdata),
|
||||
void (*finish)(void *tapdata));
|
||||
|
||||
This function is used to register an instance of a tap application
|
||||
to the tap system.
|
||||
|
||||
remove_tap_listener(void *tapdata);
|
||||
|
||||
|
||||
remove_tap_listener(void *tapdata)
|
||||
This function is used to deregister and stop a tap listener.
|
||||
|
||||
register_tap_listener() is used to register an instance of a tap application
|
||||
to the tap system.
|
||||
The parameters have the following meanings:
|
||||
|
||||
*tapname
|
||||
is the name of the tap we want to listen to. I.e. the name used in
|
||||
|
@ -239,8 +235,5 @@ Well, try this :
|
|||
Let struct contain a command line and make (*packet) execute it?
|
||||
The possibilities are rather large.
|
||||
|
||||
|
||||
|
||||
See tap-rpcstat.c for an example
|
||||
See tap.c as well. It contains lots of comments and descriptions on the tap
|
||||
system.
|
||||
|
|
Loading…
Reference in New Issue