/[rdesktop]/sourceforge.net/trunk/rdesktop/secure.c
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /sourceforge.net/trunk/rdesktop/secure.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 557 by stargo, Wed Dec 10 08:02:59 2003 UTC revision 580 by astrand, Fri Jan 23 08:35:52 2004 UTC
# Line 628  sec_parse_crypt_info(STREAM s, uint32 * Line 628  sec_parse_crypt_info(STREAM s, uint32 *
628                  uint32 certcount;                  uint32 certcount;
629    
630                  DEBUG_RDP5(("We're going for the RDP5-style encryption\n"));                  DEBUG_RDP5(("We're going for the RDP5-style encryption\n"));
631                  in_uint32_le(s, certcount); /* Number of certificates */                  in_uint32_le(s, certcount);     /* Number of certificates */
632    
633                  if(certcount < 2)                  if (certcount < 2)
634                  {                  {
635                          error("Server didn't send enough X509 certificates\n");                          error("Server didn't send enough X509 certificates\n");
636                          return False;                          return False;
637                  }                  }
638    
639                  for(; certcount > 2; certcount--)                  for (; certcount > 2; certcount--)
640                  { /* ignore all the certificates between the root and the signing CA */                  {               /* ignore all the certificates between the root and the signing CA */
641                          uint32 ignorelen;                          uint32 ignorelen;
642                          X509 *ignorecert;                          X509 *ignorecert;
643    
# Line 647  sec_parse_crypt_info(STREAM s, uint32 * Line 647  sec_parse_crypt_info(STREAM s, uint32 *
647                          DEBUG_RDP5(("Ignored Certificate length is %d\n", ignorelen));                          DEBUG_RDP5(("Ignored Certificate length is %d\n", ignorelen));
648                          ignorecert = d2i_X509(NULL, &(s->p), ignorelen);                          ignorecert = d2i_X509(NULL, &(s->p), ignorelen);
649    
650                          if(ignorecert == NULL)                          if (ignorecert == NULL)
651                          { /* XXX: error out? */                          {       /* XXX: error out? */
652                                  DEBUG_RDP5(("got a bad cert: this will probably screw up the rest of the communication\n"));                                  DEBUG_RDP5(("got a bad cert: this will probably screw up the rest of the communication\n"));
653                          }                          }
654    
655  #ifdef WITH_DEBUG_RDP5  #ifdef WITH_DEBUG_RDP5
656                          DEBUG_RDP5(("cert #%d (ignored):\n",certcount));                          DEBUG_RDP5(("cert #%d (ignored):\n", certcount));
657                          X509_print_fp(stdout, ignorecert);                          X509_print_fp(stdout, ignorecert);
658  #endif  #endif
659                  }                  }

Legend:
Removed from v.557  
changed lines
  Added in v.580

  ViewVC Help
Powered by ViewVC 1.1.26