18 lines
802 B
Diff
18 lines
802 B
Diff
--- vnc-4_1_1-unixsrc/common/rfb/SConnection.cxx.authentication 2005-03-11 16:08:41.000000000 +0100
|
|
+++ vnc-4_1_1-unixsrc/common/rfb/SConnection.cxx 2006-05-17 16:15:54.000000000 +0200
|
|
@@ -181,6 +181,15 @@
|
|
vlog.info("Client requests security type %s(%d)",
|
|
secTypeName(secType),secType);
|
|
|
|
+ // Verify that the requested security type should be offered
|
|
+ std::list<rdr::U8> secTypes;
|
|
+ std::list<rdr::U8>::iterator i;
|
|
+ securityFactory->getSecTypes(&secTypes, reverseConnection);
|
|
+ for (i=secTypes.begin(); i!=secTypes.end(); i++)
|
|
+ if (*i == secType) break;
|
|
+ if (i == secTypes.end())
|
|
+ throw Exception("Requested security type not available");
|
|
+
|
|
try {
|
|
state_ = RFBSTATE_SECURITY;
|
|
security = securityFactory->getSSecurity(secType, reverseConnection);
|