summaryrefslogtreecommitdiff
path: root/libopie2/opienet/opcap.h
authormickeyl <mickeyl>2003-10-04 01:34:13 (UTC)
committer mickeyl <mickeyl>2003-10-04 01:34:13 (UTC)
commita4793f5226e9eb5c8a718cca9335c23530e08b08 (patch) (unidiff)
tree9e18d900f9c0a96170c8221ba4e60e7b7937cf39 /libopie2/opienet/opcap.h
parente2716e3862915582d0ce48aaacc967f5b0cf6550 (diff)
downloadopie-a4793f5226e9eb5c8a718cca9335c23530e08b08.zip
opie-a4793f5226e9eb5c8a718cca9335c23530e08b08.tar.gz
opie-a4793f5226e9eb5c8a718cca9335c23530e08b08.tar.bz2
Although not yet complete, the DHCP decoding is now usable
Diffstat (limited to 'libopie2/opienet/opcap.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opienet/opcap.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/libopie2/opienet/opcap.h b/libopie2/opienet/opcap.h
index 0c9e7da..a031dd1 100644
--- a/libopie2/opienet/opcap.h
+++ b/libopie2/opienet/opcap.h
@@ -490,26 +490,36 @@ class OUDPPacket : public QObject
490/*====================================================================================== 490/*======================================================================================
491 * ODHCPPacket 491 * ODHCPPacket
492 *======================================================================================*/ 492 *======================================================================================*/
493 493
494class ODHCPPacket : public QObject 494class ODHCPPacket : public QObject
495{ 495{
496 Q_OBJECT 496 Q_OBJECT
497 497
498 public: 498 public:
499 ODHCPPacket( const unsigned char*, const struct dhcp_packet*, QObject* parent = 0 ); 499 ODHCPPacket( const unsigned char*, const struct dhcp_packet*, QObject* parent = 0 );
500 virtual ~ODHCPPacket(); 500 virtual ~ODHCPPacket();
501 501
502 QHostAddress clientAddress() const;
503 QHostAddress yourAddress() const;
504 QHostAddress serverAddress() const;
505 QHostAddress relayAddress() const;
506
507 bool isRequest() const;
508 bool isReply() const;
509 QString type() const;
510
502 private: 511 private:
503 const struct dhcp_packet* _dhcphdr; 512 const struct dhcp_packet* _dhcphdr;
513 unsigned char _type;
504}; 514};
505 515
506/*====================================================================================== 516/*======================================================================================
507 * OTCPPacket 517 * OTCPPacket
508 *======================================================================================*/ 518 *======================================================================================*/
509 519
510class OTCPPacket : public QObject 520class OTCPPacket : public QObject
511{ 521{
512 Q_OBJECT 522 Q_OBJECT
513 523
514 public: 524 public:
515 OTCPPacket( const unsigned char*, const struct tcphdr*, QObject* parent = 0 ); 525 OTCPPacket( const unsigned char*, const struct tcphdr*, QObject* parent = 0 );