Wireshark
4.5.0
The Wireshark network protocol analyzer
Toggle main menu visibility
Main Page
Related Pages
Topics
Namespaces
Namespace List
Namespace Members
All
Variables
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
a
b
c
d
e
f
g
h
i
m
o
p
r
s
t
u
v
w
Variables
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
Files
File List
File Members
All
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
Functions
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
Variables
Typedefs
a
b
c
d
e
f
g
h
i
m
p
r
s
t
u
v
w
Enumerations
Enumerator
a
b
c
e
f
h
i
n
o
r
s
t
w
Macros
_
a
b
c
d
e
f
g
h
i
j
m
n
o
p
r
s
t
u
v
w
x
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Modules
Pages
Loading...
Searching...
No Matches
capture
iface_monitor.h
Go to the documentation of this file.
1
11
#ifndef IFACE_MONITOR_H
12
#define IFACE_MONITOR_H
13
14
#include <wireshark.h>
15
16
#ifdef __cplusplus
17
extern
"C"
{
18
#endif
/* __cplusplus */
19
20
#ifdef HAVE_LIBPCAP
21
22
/*
23
* Callback for interface changes.
24
*
25
* iface is a pointer to the name of the interface.
26
*
27
* up is 1 if the interface is up, 0 if it's down.
28
*
29
* XXX - we really want "gone", not "down", where "gone" may include
30
* "down" if the OS requires an interface to be up in order to start
31
* a capture on it (as is the case in Linux and in macOS prior to
32
* Lion), but should also include *gone*, as in "there is no longer
33
* an interface with this name, so it's neither down nor up".
34
*
35
* We also may want other events, such as address changes, so what
36
* we might want is "add", "remove", and "modify" as the events.
37
*/
38
typedef
void (*iface_mon_cb)(
const
char
*iface,
int
added,
int
up);
39
40
/*
41
* Start watching for interface changes.
42
*/
43
int
44
iface_mon_start(iface_mon_cb cb);
45
46
/*
47
* Stop watching for interface changes.
48
*/
49
void
50
iface_mon_stop(
void
);
51
52
/*
53
* Get the socket on which interface changes are delivered, so that
54
* we can add it to the event loop.
55
*
56
* XXX - what if it's not a socket or other file descriptor?
57
*/
58
int
59
iface_mon_get_sock(
void
);
60
61
/*
62
* Call this if something is readable from the interface change socket.
63
* It will call the callback as appropriate.
64
*/
65
void
66
iface_mon_event(
void
);
67
68
/*
69
* Temporarily enable or disable watching for interface changes. This has
70
* no effect if interface monitoring has not been started.
71
*
72
* This is for Linux, where setting rfmon mode on an interface can create
73
* or destroy another (virtual) interface on the same wiphy, to avoid infinite
74
* loops. It is a no-op on other platforms.
75
*/
76
void
77
iface_mon_enable(
bool
enable);
78
79
#endif
/* HAVE_LIBPCAP */
80
81
#ifdef __cplusplus
82
}
83
#endif
/* __cplusplus */
84
85
#endif
/* IFACE_MONITOR_H */
Generated by
1.9.8