[BACK]Return to schnorr.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / ssh

Diff for /src/usr.bin/ssh/Attic/schnorr.c between version 1.3 and 1.4

version 1.3, 2009/03/05 07:18:19 version 1.4, 2010/09/20 04:50:53
Line 134 
Line 134 
                 error("%s: g_x < 1", __func__);                  error("%s: g_x < 1", __func__);
                 return -1;                  return -1;
         }          }
           if (BN_cmp(g_x, grp_p) >= 0) {
                   error("%s: g_x > g", __func__);
                   return -1;
           }
   
         h = g_v = r = tmp = v = NULL;          h = g_v = r = tmp = v = NULL;
         if ((bn_ctx = BN_CTX_new()) == NULL) {          if ((bn_ctx = BN_CTX_new()) == NULL) {
Line 258 
Line 262 
         /* Avoid degenerate cases: g^0 yields a spoofable signature */          /* Avoid degenerate cases: g^0 yields a spoofable signature */
         if (BN_cmp(g_x, BN_value_one()) <= 0) {          if (BN_cmp(g_x, BN_value_one()) <= 0) {
                 error("%s: g_x < 1", __func__);                  error("%s: g_x < 1", __func__);
                   return -1;
           }
           if (BN_cmp(g_x, grp_p) >= 0) {
                   error("%s: g_x >= p", __func__);
                 return -1;                  return -1;
         }          }
   

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4