decoders/decode_dns.h

Go to the documentation of this file.
00001 #ifndef _HLBR_DECODE_DNS_H_
00002 #define _HLBR_DECODE_DNS_H_
00003 
00004 #include "../config.h"
00005 #include "../engine/hlbr.h"
00006 #include "decode.h"
00007 
00008 #define MAX_DNS_QUESTIONS       5
00009 #define MAX_DNS_QUERY_LEN       1024
00010 
00011 /***********************************************
00012 * I'm making these up as I go so these will
00013 * probably have to be rewritten
00014 ***********************************************/
00015 
00016 typedef struct dns_header_1 {
00017         unsigned short  TransactionID;
00018         unsigned short  Flags;
00019         unsigned short  Questions;
00020         unsigned short  AnswerRR;
00021         unsigned short  AuthorityRR;
00022         unsigned short  AdditoinalRR;
00023 } DNSHeader1;
00024 
00025 typedef struct dns_qestion{
00026         unsigned char                   Query[MAX_DNS_QUERY_LEN];
00027         unsigned short*                 Type;
00028         unsigned short*                 Class;
00029 } DNSQuestion;
00030 
00031 #define DNS_FLAG_QUERY          0x80
00032 
00033 typedef struct dns_data{
00034         DNSHeader1*             Header1;
00035         DNSQuestion             Q[MAX_DNS_QUESTIONS];
00036 } DNSData;
00037 
00038 
00039 int InitDecoderDNS();
00040 
00041 #endif

Generated on Sat Jul 7 23:33:10 2007 for HLBR by  doxygen 1.5.2