Network-Music  0.1
An audible representation of network traffic
 All Classes Namespaces Files Functions Variables Typedefs Macros Pages
packetcapturer.cpp File Reference
#include "packetcapturer.h"
#include <pcap.h>
#include <qdebug.h>
#include <QApplication>
Include dependency graph for packetcapturer.cpp:

Classes

struct  packetprocess::sniff_ethernet
struct  packetprocess::sniff_ip
struct  packetprocess::sniff_tcp

Namespaces

namespace  packetprocess

Macros

#define ETHERTYPE_EAP   (0x888e) /* eap authentication */
#define TYPE_TCP   (6)
#define IP_RF   0x8000 /* reserved fragment flag */
#define IP_DF   0x4000 /* dont fragment flag */
#define IP_MF   0x2000 /* more fragments flag */
#define IP_OFFMASK   0x1fff /* mask for fragmenting bits */
#define IP_HL(ip)   (((ip)->ip_vhl) & 0x0f)
#define IP_V(ip)   (((ip)->ip_vhl) >> 4)
#define TH_OFF(th)   (((th)->th_offx2 & 0xf0) >> 4)
#define TH_FIN   0x01
#define TH_SYN   0x02
#define TH_RST   0x04
#define TH_PUSH   0x08
#define TH_ACK   0x10
#define TH_URG   0x20
#define TH_ECE   0x40
#define TH_CWR   0x80
#define TH_FLAGS   (TH_FIN|TH_SYN|TH_RST|TH_ACK|TH_URG|TH_ECE|TH_CWR)

Typedefs

typedef u_int packetprocess::tcp_seq

Functions

void packetprocess::Callback_ProcessPacket (u_char *useless, const pcap_pkthdr *pkthdr, const u_char *packet)

Variables

u_short packetprocess::recentFreq = 100
QObject * packetprocess::parent

Macro Definition Documentation

#define ETHERTYPE_EAP   (0x888e) /* eap authentication */
#define IP_DF   0x4000 /* dont fragment flag */
#define IP_HL (   ip)    (((ip)->ip_vhl) & 0x0f)
#define IP_MF   0x2000 /* more fragments flag */
#define IP_OFFMASK   0x1fff /* mask for fragmenting bits */
#define IP_RF   0x8000 /* reserved fragment flag */
#define IP_V (   ip)    (((ip)->ip_vhl) >> 4)
#define TH_ACK   0x10
#define TH_CWR   0x80
#define TH_ECE   0x40
#define TH_FIN   0x01
#define TH_FLAGS   (TH_FIN|TH_SYN|TH_RST|TH_ACK|TH_URG|TH_ECE|TH_CWR)
#define TH_OFF (   th)    (((th)->th_offx2 & 0xf0) >> 4)
#define TH_PUSH   0x08
#define TH_RST   0x04
#define TH_SYN   0x02
#define TH_URG   0x20
#define TYPE_TCP   (6)