Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4101 3789f03b-4d11-0410-bbf8-ca57d06f2519tags/v1.0.90
@@ -39,7 +39,7 @@ using namespace std; | |||
static LogWriter vlog("CVeNCrypt"); | |||
CSecurityVeNCrypt::CSecurityVeNCrypt(void) : csecurity(NULL) | |||
CSecurityVeNCrypt::CSecurityVeNCrypt(Security* sec) : csecurity(NULL), security(sec) | |||
{ | |||
haveRecvdMajorVersion = false; | |||
haveRecvdMinorVersion = false; |
@@ -35,7 +35,7 @@ namespace rfb { | |||
class CSecurityVeNCrypt : public CSecurity { | |||
public: | |||
CSecurityVeNCrypt(void); | |||
CSecurityVeNCrypt(Security* sec); | |||
~CSecurityVeNCrypt(); | |||
virtual bool processMsg(CConnection* cc);// { return true; } | |||
int getType() const {return chosenType;} | |||
@@ -46,6 +46,7 @@ namespace rfb { | |||
static CSecurityStack* getCSecurityStack(int secType); | |||
CSecurity *csecurity; | |||
Security *security; | |||
bool haveRecvdMajorVersion; | |||
bool haveRecvdMinorVersion; | |||
bool haveSentVersion; |
@@ -60,7 +60,7 @@ StringParameter SSecurityVeNCrypt::secTypesStr | |||
"TLSVnc, TLSPlain, X509None, X509Vnc, X509Plain)", | |||
"TLSVnc,TLSPlain,X509Vnc,X509Plain"); | |||
SSecurityVeNCrypt::SSecurityVeNCrypt(void) | |||
SSecurityVeNCrypt::SSecurityVeNCrypt(Security *sec) : security(sec) | |||
{ | |||
ssecurity = NULL; | |||
haveSentVersion = false; |
@@ -40,7 +40,7 @@ namespace rfb { | |||
class SSecurityVeNCrypt : public SSecurity { | |||
public: | |||
SSecurityVeNCrypt(void); | |||
SSecurityVeNCrypt(Security *sec); | |||
~SSecurityVeNCrypt(); | |||
virtual bool processMsg(SConnection* sc);// { return true; } | |||
virtual int getType() const { return secTypeVeNCrypt; } | |||
@@ -57,6 +57,7 @@ namespace rfb { | |||
static SSecurityStack* getSSecurityStack(int secType); | |||
SSecurity *ssecurity; | |||
Security *security; | |||
bool haveSentVersion, haveRecvdMajorVersion, haveRecvdMinorVersion; | |||
bool haveSentTypes, haveChosenType; | |||
rdr::U8 majorVersion, minorVersion, numTypes; |
@@ -117,7 +117,7 @@ SSecurity* Security::GetSSecurity(U32 secType) | |||
case secTypeNone: return new SSecurityNone(); | |||
case secTypeVncAuth: return new SSecurityVncAuth(); | |||
#ifdef HAVE_GNUTLS | |||
case secTypeVeNCrypt: return new SSecurityVeNCrypt(); | |||
case secTypeVeNCrypt: return new SSecurityVeNCrypt(this); | |||
#endif | |||
} | |||
@@ -136,7 +136,7 @@ CSecurity* Security::GetCSecurity(U32 secType) | |||
case secTypeNone: return new CSecurityNone(); | |||
case secTypeVncAuth: return new CSecurityVncAuth(); | |||
#ifdef HAVE_GNUTLS | |||
case secTypeVeNCrypt: return new CSecurityVeNCrypt(); | |||
case secTypeVeNCrypt: return new CSecurityVeNCrypt(this); | |||
#endif | |||
} | |||