Browse Source

Fixing order of new PuTTY 0.78 KEX DH Group algorithms

Source commit: 30e7e34fc4e683759bca6f647843439236beadd4
Martin Prikryl 3 năm trước cách đây
mục cha
commit
74266d15ae
2 tập tin đã thay đổi với 3 bổ sung3 xóa
  1. 2 2
      source/core/PuttyIntf.cpp
  2. 1 1
      source/core/SessionData.cpp

+ 2 - 2
source/core/PuttyIntf.cpp

@@ -1137,8 +1137,8 @@ TStrings * SshKexList()
   std::unique_ptr<TStrings> Result(new TStringList());
   // Same order as DefaultKexList
   const ssh_kexes * Kexes[] = {
-    &ssh_ecdh_kex, &ssh_diffiehellman_gex, &ssh_diffiehellman_group14,
-    &ssh_diffiehellman_group15, &ssh_diffiehellman_group16, &ssh_diffiehellman_group17, &ssh_diffiehellman_group18,
+    &ssh_ecdh_kex, &ssh_diffiehellman_gex,
+    &ssh_diffiehellman_group18, &ssh_diffiehellman_group17, &ssh_diffiehellman_group16, &ssh_diffiehellman_group15, &ssh_diffiehellman_group14,
     &ssh_rsa_kex, &ssh_diffiehellman_group1 };
   for (unsigned int Index = 0; Index < LENOF(Kexes); Index++)
   {

+ 1 - 1
source/core/SessionData.cpp

@@ -40,7 +40,7 @@ const TCipher DefaultCipherList[CIPHER_COUNT] =
   { cipAES, cipChaCha20, cipAESGCM, cip3DES, cipWarn, cipDES, cipBlowfish, cipArcfour };
 // Update also order in SshKexList()
 const TKex DefaultKexList[KEX_COUNT] =
-  { kexECDH, kexDHGEx, kexDHGroup14, kexRSA, kexDHGroup15, kexDHGroup16, kexDHGroup17, kexDHGroup18, kexWarn, kexDHGroup1 };
+  { kexECDH, kexDHGEx, kexDHGroup18, kexDHGroup17, kexDHGroup16, kexDHGroup15, kexDHGroup14, kexRSA, kexWarn, kexDHGroup1 };
 const THostKey DefaultHostKeyList[HOSTKEY_COUNT] =
   { hkED448, hkED25519, hkECDSA, hkRSA, hkDSA, hkWarn };
 const TGssLib DefaultGssLibList[GSSLIB_COUNT] =