summaryrefslogtreecommitdiff
path: root/libopie2/opienet/opcap.h
Side-by-side diff
Diffstat (limited to 'libopie2/opienet/opcap.h') (more/less context) (show whitespace changes)
-rw-r--r--libopie2/opienet/opcap.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/libopie2/opienet/opcap.h b/libopie2/opienet/opcap.h
index a031dd1..f0d1d81 100644
--- a/libopie2/opienet/opcap.h
+++ b/libopie2/opienet/opcap.h
@@ -112,48 +112,53 @@ class QSocketNotifier;
* OIPPacket* ip = (OIPPacket*) p->child( "IP" ); // returns 0, if no such child exists
* odebug << "got ip packet from " << ip->fromIPAddress().toString() << " to " << ip->toIPAddress().toString() << oendl;
*
*/
class OPacket : public QObject
{
Q_OBJECT
friend class OPacketCapturer;
public:
OPacket( int datalink, packetheaderstruct, const unsigned char*, QObject* parent );
virtual ~OPacket();
timevalstruct timeval() const;
int caplen() const;
int len() const;
QString dump( int = 32 ) const;
void updateStats( QMap<QString,int>&, QObjectList* );
private:
+
+ void dumpStructure( QObjectList* );
+ QString _dumpStructure( QObjectList* );
+
+ private:
const packetheaderstruct _hdr; // pcap packet header
const unsigned char* _data; // pcap packet data
const unsigned char* _end; // end of pcap packet data
};
/*======================================================================================
* OEthernetPacket - DLT_EN10MB frame
*======================================================================================*/
class OEthernetPacket : public QObject
{
Q_OBJECT
public:
OEthernetPacket( const unsigned char*, const struct ether_header*, QObject* parent = 0 );
virtual ~OEthernetPacket();
OMacAddress sourceAddress() const;
OMacAddress destinationAddress() const;
int type() const;
private:
const struct ether_header* _ether;
};