Dibbler - a portable DHCPv6  1.0.2RC1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
SrvOptTA.h
Go to the documentation of this file.
1 /*
2  * Dibbler - a portable DHCPv6
3  *
4  * authors: Tomasz Mrugalski <thomson@klub.com.pl>
5  *
6  * released under GNU GPL v2 only licence
7  */
8 
9 class TSrvOptTA;
10 #ifndef SRVOPTTA_H
11 #define SRVOPTTA_H
12 
13 #include "OptTA.h"
14 #include "SrvOptIAAddress.h"
15 #include "SmartPtr.h"
16 #include "DUID.h"
17 #include "SrvCfgMgr.h"
18 #include "SrvAddrMgr.h"
19 #include "Container.h"
20 #include "IPv6Addr.h"
21 
22 class TSrvOptTA : public TOptTA
23 {
24  public:
25 /* Constructor used in answers to: SOLICIT, SOLICIT (with RAPID_COMMIT) and REQUEST */
26  TSrvOptTA(SPtr<TSrvOptTA> queryOpt, SPtr<TSrvMsg> clientMsg, int msgType, TMsg* parent);
27  TSrvOptTA(char * buf, int bufsize, TMsg* parent);
28  TSrvOptTA(int iaid, TMsg* parent);
29  TSrvOptTA(int iaid, int statusCode, std::string txt, TMsg* parent);
31  void releaseAllAddrs(bool quiet);
32 
33  bool doDuties();
34  private:
37 
39  int Iface;
40 
42  void solicit(SPtr<TSrvMsg> clientMsg, SPtr<TSrvOptTA> queryOpt);
43  void request(SPtr<TSrvMsg> clientMsg, SPtr<TSrvOptTA> queryOpt);
44  void release(SPtr<TSrvOptTA> queryOpt);
45  void confirm(SPtr<TSrvOptTA> queryOpt);
46 
47  void solicitRequest(SPtr<TSrvMsg> clientMsg, SPtr<TSrvOptTA> queryOpt, bool solicit);
48 
49  int OrgMessage; // original message, which we are responding to
50 };
51 
52 #endif
53