Pārlūkot izejas kodu

Bug fix: SSH bug "Replies to requests on closed channels" was always enabled + Hidden configuration option for SSH bug "Replies to requests on closed channels"

Source commit: dcc230a8c5fcff149e7870d3284b758ac02ef630
Martin Prikryl 8 gadi atpakaļ
vecāks
revīzija
9b95cbbbcd

+ 1 - 0
source/core/SecureShell.cpp

@@ -271,6 +271,7 @@ Conf * __fastcall TSecureShell::StoreToConfig(TSessionData * Data, bool Simple)
   conf_set_int(conf, CONF_sshbug_ignore2, Data->Bug[sbIgnore2]);
   conf_set_int(conf, CONF_sshbug_winadj, Data->Bug[sbWinAdj]);
   conf_set_int(conf, CONF_sshbug_oldgex2, Data->Bug[sbOldGex2]);
+  conf_set_int(conf, CONF_sshbug_chanreq, Data->Bug[sbChanReq]);
 
   if (!Data->TunnelPortFwd.IsEmpty())
   {

+ 2 - 0
source/core/SessionData.cpp

@@ -666,6 +666,7 @@ void __fastcall TSessionData::DoLoad(THierarchicalStorage * Storage, bool PuttyI
   READ_BUG(Ignore2);
   READ_BUG(OldGex2);
   READ_BUG(WinAdj);
+  READ_BUG(ChanReq);
   #undef READ_BUG
 
   if ((Bug[sbHMAC2] == asAuto) &&
@@ -988,6 +989,7 @@ void __fastcall TSessionData::DoSave(THierarchicalStorage * Storage,
   WRITE_BUG(Ignore2);
   WRITE_BUG(OldGex2);
   WRITE_BUG(WinAdj);
+  WRITE_BUG(ChanReq);
   #undef WRITE_BUG
   #undef WRITE_DATA_CONV_FUNC
 

+ 2 - 2
source/core/SessionData.h

@@ -27,8 +27,8 @@ enum TGssLib { gssGssApi32, gssSspi, gssCustom };
 #define GSSLIB_COUNT (gssCustom+1)
 // names have to match PuTTY registry entries (see settings.c)
 enum TSshBug { sbIgnore1, sbPlainPW1, sbRSA1, sbHMAC2, sbDeriveKey2, sbRSAPad2,
-  sbPKSessID2, sbRekey2, sbMaxPkt2, sbIgnore2, sbOldGex2, sbWinAdj };
-#define BUG_COUNT (sbWinAdj+1)
+  sbPKSessID2, sbRekey2, sbMaxPkt2, sbIgnore2, sbOldGex2, sbWinAdj, sbChanReq };
+#define BUG_COUNT (sbChanReq+1)
 enum TSftpBug { sbSymlink, sbSignedTS };
 #define SFTP_BUG_COUNT (sbSignedTS+1)
 extern const wchar_t * PingTypeNames;