tracedump
single application IP packet sniffer
|
#include "tracedump.h"
Go to the source code of this file.
Defines | |
#define | PORT_SET(list, port) list[port/8] |= 1 << (port%8) |
#define | PORT_ISSET(list, port) ((list[port/8] >> (port%8)) & 1) |
Functions | |
void | port_init (struct tracedump *td) |
Start the garbage collector thread. | |
void | port_deinit (struct tracedump *td) |
Stop the garbage collector thread. | |
void | port_add (struct sock *ss, bool local) |
Add port by socket. | |
void * | port_list (struct tracedump *td, bool tcp) |
Get list of all local ports from procfs. |
Definition at line 29 of file port.h.
Referenced by gc_thread().
Definition at line 28 of file port.h.
Referenced by port_list().
void port_add | ( | struct sock * | ss, |
bool | local | ||
) |
Add port by socket.
local | if true, port in socket is a local port |
Definition at line 99 of file port.c.
Referenced by handle_socket().
void port_deinit | ( | struct tracedump * | td | ) |
void port_init | ( | struct tracedump * | td | ) |
void* port_list | ( | struct tracedump * | td, |
bool | tcp | ||
) |
Get list of all local ports from procfs.
tcp | if true, list for TCP; UDP otherwise |
NULL | error |
Definition at line 129 of file port.c.
Referenced by gc_thread().