00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042 #ifndef __EAP_CLIENT_SESSION_H__
00043 #define __EAP_CLIENT_SESSION_H__
00044
00045 #include <string>
00046 #include <list>
00047 #include "ace/Synch.h"
00048 #include "diameter_api.h"
00049 #include "diameter_eap_client_fsm.hxx"
00050 #include "diameter_eap_parser.hxx"
00051
00052 class DiameterEapClientSession;
00053
00055 class DIAMETER_EAP_CLIENT_EXPORTS DEA_Handler :
00056 public AAASessionMessageHandler
00057 {
00058 public:
00059 DEA_Handler(AAAApplicationCore &appCore, DiameterEapClientSession &s)
00060 : AAASessionMessageHandler(appCore, EapCommandCode),
00061 session(s)
00062 {}
00063 private:
00064 AAAReturnCode HandleMessage (AAAMessage &msg);
00065 DiameterEapClientSession &session;
00066 };
00067
00071 class DIAMETER_EAP_CLIENT_EXPORTS DiameterEapClientSession :
00072 public AAAClientSession, public DiameterEapClientStateMachine
00073 {
00074 public:
00075
00077 DiameterEapClientSession(AAAApplicationCore&, DiameterJobHandle &h);
00078
00080 ~DiameterEapClientSession() {}
00081
00082 DiameterEapClientSession* Self() { return this; }
00083
00090 AAAReturnCode HandleMessage(AAAMessage &msg);
00091
00098 AAAReturnCode HandleDisconnect();
00099
00101 AAAReturnCode HandleSessionTimeout();
00102
00104 AAAReturnCode HandleAuthLifetimeTimeout();
00105
00107 AAAReturnCode HandleAuthGracePeriodTimeout();
00108
00114 AAAReturnCode HandleTimeout();
00115
00121 AAAReturnCode HandleAbort() { return AAA_ERR_SUCCESS; }
00122
00123 void Start() throw (AAA_Error)
00124 {
00125 DiameterEapClientStateMachine::Start();
00126 AAAClientSession::Start();
00127 }
00128
00129 protected:
00130 private:
00131
00132 DEA_Handler answerHandler;
00133 };
00134
00135 #endif