First step of DHCP analyzer rearchitecture.

Old event prototypes have changed and the events are broken right
now and may be removed in favor of the new generic "dhcp_message"
event.

DHCP option parsing is abstracted from the main code base of the
protocol parser and are all now located in their own file.

Documentation, tests, and final code cleanup are still pending.
This commit is contained in:
Seth Hall 2018-02-02 10:14:15 -05:00
parent ba49ab8201
commit c2f35920fd
14 changed files with 728 additions and 498 deletions

View file

@ -10,11 +10,11 @@ namespace analyzer { namespace dhcp {
class DHCP_Analyzer : public analyzer::Analyzer {
public:
DHCP_Analyzer(Connection* conn);
virtual ~DHCP_Analyzer();
~DHCP_Analyzer() override;
virtual void Done();
virtual void DeliverPacket(int len, const u_char* data, bool orig,
uint64 seq, const IP_Hdr* ip, int caplen);
void Done() override;
void DeliverPacket(int len, const u_char* data, bool orig,
uint64 seq, const IP_Hdr* ip, int caplen) override;
static analyzer::Analyzer* Instantiate(Connection* conn)
{ return new DHCP_Analyzer(conn); }