From: Todd O. <to...@us...> - 2014-12-10 19:18:28
|
Update of /cvsroot/yassl/yassl/include In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv8346/include Modified Files: yassl_int.hpp Log Message: 2.3.7 explicitly check duplicate recvd messages Index: yassl_int.hpp =================================================================== RCS file: /cvsroot/yassl/yassl/include/yassl_int.hpp,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -d -r1.27 -r1.28 *** yassl_int.hpp 31 Aug 2011 23:40:45 -0000 1.27 --- yassl_int.hpp 10 Dec 2014 19:18:25 -0000 1.28 *************** *** 117,120 **** --- 117,139 ---- + // track received messages to explicitly disallow duplicate messages + struct RecvdMessages { + uint8 gotClientHello_; + uint8 gotServerHello_; + uint8 gotCert_; + uint8 gotServerKeyExchange_; + uint8 gotCertRequest_; + uint8 gotServerHelloDone_; + uint8 gotCertVerify_; + uint8 gotClientKeyExchange_; + uint8 gotFinished_; + RecvdMessages() : gotClientHello_(0), gotServerHello_(0), gotCert_(0), + gotServerKeyExchange_(0), gotCertRequest_(0), + gotServerHelloDone_(0), gotCertVerify_(0), + gotClientKeyExchange_(0), gotFinished_(0) + {} + }; + + // combines all states class States { *************** *** 125,128 **** --- 144,148 ---- ConnectState connectState_; AcceptState acceptState_; + RecvdMessages recvdMessages_; char errorString_[MAX_ERROR_SZ]; YasslError what_; *************** *** 147,150 **** --- 167,171 ---- char* useString(); void SetError(YasslError); + int SetMessageRecvd(HandShakeType); private: States(const States&); // hide copy |