home *** CD-ROM | disk | FTP | other *** search
/ The Hacker's Encyclopedia 1998 / hackers_encyclopedia.iso / hacking / general / cert0091.txt < prev    next >
Encoding:
Text File  |  2003-06-11  |  14.2 KB  |  388 lines

  1.  
  2. -----BEGIN PGP SIGNED MESSAGE-----
  3.  
  4. =============================================================================
  5. CERT(sm) Advisory CA-95:03a
  6. Original issue date:  March 3, 1995
  7. Last revised: August 30, 1996
  8.               Information previously in the README was inserted
  9.               into the advisory.
  10.  
  11. A complete revision history is at the end of this file.
  12.  
  13. Topic: Telnet Encryption Vulnerability
  14. - -----------------------------------------------------------------------------
  15.  
  16.                 *** This advisory supersedes CA-95:03. ***
  17.  
  18. The CERT Coordination Center has received reports of a serious security
  19. problem in the Berkeley Telnet clients that provide support for the
  20. experimental Telnet encryption option using the Kerberos V4 authentication.
  21. All known released versions of the BSD Telnet that support Kerberos V4
  22. authentication and encryption are affected.
  23.  
  24. We recommend that all sites that use encrypted telnet in conjunction with
  25. Kerberos V4 obtain a patch or upgraded version of Telnet according to the
  26. instructions in Section III below.
  27.  
  28. We will update this advisory as we receive additional information.
  29. Please check advisory files regularly for updates that relate to your site.
  30. - ---------------------------------------------------------------------------
  31.  
  32. I.   Description
  33.  
  34.      There is a vulnerability in Berkeley Telnet clients that support
  35.      encryption and Kerberos V4 authentications. This vulnerability
  36.      substantially reduces the effectiveness of the encryption.
  37.  
  38. II.  Impact
  39.  
  40.      Anyone who can access and read packets that make up the encrypted
  41.      Telnet session can easily decrypt the session. This is possible, for
  42.      example, when an intruder uses a packet sniffer on the network to
  43.      intercept the Telnet sessions.
  44.  
  45. III. Solution
  46.  
  47.      Obtain and install the appropriate patch according to the instructions
  48.      included with the patch.
  49.  
  50.      In Appendix A is a summary of the vendors who have reported to us and 
  51.      the status they provided, including how to obtain patches.
  52.      We will update the appendix as we receive more information from vendors.
  53.      
  54. .............................................................................
  55.  
  56. Appendix A: Vendor Information
  57.  
  58. Below is information we have received from vendors who have patches available
  59. or upcoming, along with names of vendors who have reported that their
  60. products do not have the problem.
  61.  
  62. If you have an encrypting Telnet from a vendor who is not listed, please
  63. contact that vendor for information regarding how to get a fixed version.
  64.  
  65.      Vendor or Source                     Status
  66.      ----------------                     ------------
  67.      Berkeley SW Distribution (BSD)       source-code patch available from
  68.                                           Berkeley; also in Appendix B of 
  69.                                           this advisory
  70.      Data General Corporation             not affected by the vulnerability
  71.      Digital Equipment Corporation        not affected by the vulnerability
  72.      FTP Software, Inc.                   patch available
  73.      Harris NightHawk System              not affected by the vulnerability
  74.      Hewlett-Packard Company              not affected by the vulnerability
  75.      Nat'l. Center for Supercomputer
  76.        Applications (NCSA)                upgrade available
  77.      Open Software Foundation             not affected by the vulnerability
  78.      The Santa Cruz Operation, Inc.(SCO)  not affected by the vulnerability
  79.      Sequent Computer Systems             not affected by the vulnerability
  80.      Sun Microsystems, Inc.               not affected by the vulnerability
  81.  
  82.    
  83. PATCH INFORMATION
  84. - -------------
  85. Berkeley Software Distribution (BSD)
  86.  
  87.      A source-code patch, along with the domestic version of the most
  88.      recently released Telnet sources from Berkeley, are available by
  89.      anonymous FTP from
  90.      
  91.          net-dist.mit.edu:/pub/telnet/telnet.patch
  92.          MD5 65d56befe3d0f1699d38de5509552578
  93.  
  94.      There is also a PGP ASCII signature file for the patch in
  95.          
  96.           net-dist.mit.edu:/pub/telnet/telnet.patch.sig
  97.           
  98.      This patch can also be found in CERT Advisory CA-95:03a, Appendix B.
  99.      (Note: Do not calculate a checksum for Appendix B alone. It will not
  100.      match the checksum of the FTP version of the patch because the tabs in
  101.      the FTP copy have been replaced with blank spaces in the CA-95:03a
  102.      Appendix B copy.)
  103.  
  104. - -------------
  105. FTP Software, Inc.
  106.  
  107.      Customers of FTP Software with an encrypting telnet (provided in the
  108.      PC/TCP or OnNet packages) should call the FTP technical support line
  109.      at 1-800-282-4387 and ask for the "tn encrypt patch".
  110.  
  111. - -------------
  112. National Center for Supercomputer Applications (NCSA)
  113.  
  114.      Users of NCSA Telnet should upgrade to the NCSA Telnet 2.6.1d7, AND
  115.      install the appropriate Kerberos plug-in which are available by
  116.      anonymous FTP from ftp.ncsa.uiuc.edu
  117.  
  118.      Upgrade
  119.  
  120.         /Mac/Telnet/Telnet2.6/prerelease/d7/Telnet2.6.1d7(68K).sit.hqx
  121.         MD5  b34b9fda59421b3b83f8df08a83f83b5
  122.  
  123.         /Mac/Telnet/Telnet2.6/prerelease/d7/Telnet2.6.1d7(fat).sit.hqx
  124.         MD5  877add7c3d298111889fc3f2f272ce6f
  125.  
  126.      Kerberos plug-ins
  127.  
  128.         /Mac/Telnet/Telnet2.6/prerelease/AuthMan.plugin.1.0b1.hqx
  129.         MD5  df727eae184b22125f90ef1a31513fd4
  130.         
  131.         /Mac/Telnet/Telnet2.6/prerelease/Kerberos_Telnet_plugin.sit.hqx
  132.         MD5  dbda691efe9038648f234397895c734d
  133.  
  134.      Questions regarding NCSA Telnet should be directed to
  135.      mactel@ncsa.uiuc.edu
  136.  
  137.  
  138.  
  139. .............................................................................
  140.  
  141. Appendix B: Patch for Vulnerability in Telnet Encryption Option
  142.  
  143. Index: auth.c
  144. ===================================================================
  145. RCS file: /mit/krb5/.cvsroot/src/appl/telnet/libtelnet/auth.c,v
  146. retrieving revision 5.5
  147. retrieving revision 5.7
  148. diff -u -r5.5 -r5.7
  149. - --- auth.c      1994/08/18 21:06:45     5.5
  150. +++ auth.c      1994/11/08 04:39:02     5.7
  151. @@ -244,7 +244,7 @@
  152.  {
  153.         register int x;
  154.  
  155. - -       if (strcasecmp(type, AUTHTYPE_NAME(0))) {
  156. +       if (!strcasecmp(type, AUTHTYPE_NAME(0))) {
  157.                 *maskp = -1;
  158.                 return(1);
  159.         }
  160. @@ -260,14 +260,14 @@
  161.  
  162.         int
  163.  auth_enable(type)
  164. - -       int type;
  165. +       char * type;
  166.  {
  167.         return(auth_onoff(type, 1));
  168.  }
  169.  
  170.         int
  171.  auth_disable(type)
  172. - -       int type;
  173. +       char * type;
  174.  {
  175.         return(auth_onoff(type, 0));
  176.  }
  177. @@ -277,15 +277,20 @@
  178.         char *type;
  179.         int on;
  180.  {
  181. - -       int mask = -1;
  182. +       int i, mask = -1;
  183.         Authenticator *ap;
  184.  
  185.         if (!strcasecmp(type, "?") || !strcasecmp(type, "help")) {
  186.                  printf("auth %s 'type'\n", on ? "enable" : "disable");
  187.                 printf("Where 'type' is one of:\n");
  188.                 printf("\t%s\n", AUTHTYPE_NAME(0));
  189. - -               for (ap = authenticators; ap->type; ap++)
  190. +               mask = 0;
  191. +               for (ap = authenticators; ap->type; ap++) {
  192. +                       if ((mask & (i = typemask(ap->type))) != 0)
  193. +                               continue;
  194. +                       mask |= i;
  195.                         printf("\t%s\n", AUTHTYPE_NAME(ap->type));
  196. +               }
  197.                 return(0);
  198.         }
  199.  
  200. @@ -293,7 +298,6 @@
  201.                 printf("%s: invalid authentication type\n", type);
  202.                 return(0);
  203.         }
  204. - -       mask = getauthmask(type, &mask);
  205.         if (on)
  206.                 i_wont_support &= ~mask;
  207.         else
  208. @@ -317,16 +321,22 @@
  209.  auth_status()
  210.  {
  211.         Authenticator *ap;
  212. +       int i, mask;
  213.  
  214.         if (i_wont_support == -1)
  215.                 printf("Authentication disabled\n");
  216.         else
  217.                 printf("Authentication enabled\n");
  218.  
  219. - -       for (ap = authenticators; ap->type; ap++)
  220. +       mask = 0;
  221. +       for (ap = authenticators; ap->type; ap++) {
  222. +               if ((mask & (i = typemask(ap->type))) != 0)
  223. +                       continue;
  224. +               mask |= i;
  225.                 printf("%s: %s\n", AUTHTYPE_NAME(ap->type),
  226.                         (i_wont_support & typemask(ap->type)) ?
  227.                                         "disabled" : "enabled");
  228. +       }
  229.         return(1);
  230.  }
  231.  
  232. Index: kerberos.c
  233. ===================================================================
  234. RCS file: /mit/krb5/.cvsroot/src/appl/telnet/libtelnet/kerberos.c,v
  235. retrieving revision 5.5
  236. retrieving revision 5.8
  237. diff -u -r5.5 -r5.8
  238. - --- kerberos.c  1994/08/18 21:07:02     5.5
  239. +++ kerberos.c  1994/11/14 21:33:58     5.8
  240. @@ -225,9 +225,10 @@
  241.                 register int i;
  242.  
  243.                 des_key_sched(cred.session, sched);
  244. - -               des_set_random_generator_seed(cred.session);
  245. - -               des_new_random_key(challenge);
  246. - -               des_ecb_encrypt(challenge, session_key, sched, 1);
  247. +               des_init_random_number_generator(cred.session);
  248. +               des_new_random_key(session_key);
  249. +               des_ecb_encrypt(session_key, session_key, sched, 0);
  250. +               des_ecb_encrypt(session_key, challenge, sched, 0);
  251.                 /*
  252.                  * Increment the challenge by 1, and encrypt it for
  253.                  * later comparison.
  254. @@ -320,6 +321,11 @@
  255.                         break;
  256.                 }
  257.  
  258. +               /*
  259. +                * Initialize the random number generator since it's
  260. +                * used later on by the encryption routine.
  261. +                */
  262. +               des_init_random_number_generator(session_key);
  263.                 des_key_sched(session_key, sched);
  264.                 memcpy((void *)datablock, (void *)data, sizeof(Block));
  265.                 /*
  266. @@ -337,7 +343,7 @@
  267.                  * increment by one, re-encrypt it and send it back.
  268.                  */
  269.                 des_ecb_encrypt(datablock, challenge, sched, 0);
  270. - -               for (r = 7; r >= 0; r++) {
  271. +               for (r = 7; r >= 0; r--) {
  272.                         register int t;
  273.                         t = (unsigned int)challenge[r] + 1;
  274.                         challenge[r] = t;       /* ignore overflow */
  275.  
  276. Index: commands.c
  277. ===================================================================
  278. RCS file: /mit/krb5/.cvsroot/src/appl/telnet/telnet/commands.c,v
  279. retrieving revision 5.14
  280. retrieving revision 5.16
  281. diff -u -r5.14 -r5.16
  282. - --- commands.c  1994/08/18 21:07:37     5.14
  283. +++ commands.c  1994/11/08 06:42:49     5.16
  284. @@ -1919,8 +1919,8 @@
  285.  };
  286.  
  287.  extern int
  288. - -       auth_enable P((int)),
  289. - -       auth_disable P((int)),
  290. +       auth_enable P((char *)),
  291. +       auth_disable P((char *)),
  292.         auth_status P((void));
  293.  static int
  294.         auth_help P((void));
  295. @@ -1959,6 +1959,12 @@
  296.  {
  297.      struct authlist *c;
  298.  
  299. +    if (argc < 2) {
  300. +      fprintf(stderr,
  301. +          "Need an argument to 'auth' command.  'auth ?' for help.\n");
  302. +      return 0;
  303. +    }
  304. +
  305.      c = (struct authlist *)
  306.                 genget(argv[1], (char **) AuthList, sizeof(struct authlist));
  307.      if (c == 0) {
  308. @@ -2015,7 +2021,7 @@
  309.                                                 EncryptEnable, 1, 1, 2 },
  310.      { "disable", "Disable encryption. ('encrypt enable ?' for more)",
  311.                                                 EncryptDisable, 0, 1, 2 },
  312. - -    { "type", "Set encryptiong type. ('encrypt type ?' for more)",
  313. +    { "type", "Set encryption type. ('encrypt type ?' for more)",
  314.                                                 EncryptType, 0, 1, 1 },
  315.      { "start", "Start encryption. ('encrypt start ?' for more)",
  316.                                                 EncryptStart, 1, 0, 1 },
  317. @@ -2058,6 +2064,12 @@
  318.      char *argv[];
  319.  {
  320.      struct encryptlist *c;
  321. +
  322. +    if (argc < 2) {
  323. +       fprintf(stderr,
  324. +           "Need an argument to 'encrypt' command.  'encrypt ?' for help.\n");
  325. +       return 0;
  326. +    }
  327.  
  328.      c = (struct encryptlist *)
  329.                 genget(argv[1], (char **) EncryptList, sizeof(struct encryptlist));
  330.  
  331. - ---------------------------------------------------------------------------
  332. The CERT Coordination Center wishes to thank Theodore Ts'o of the
  333. Massachusetts Institute of Technology for identifying and developing a
  334. solution to this problem. We also thank Douglas Engert of Argonne National
  335. Laboratory for pointing out the omission in our original Appendix B.
  336. - ---------------------------------------------------------------------------
  337.  
  338. If you believe that your system has been compromised, contact the CERT
  339. Coordination Center or your representative in Forum of Incident Response
  340. and Security Teams (FIRST).
  341.  
  342. If you wish to send sensitive incident or vulnerability information to CERT
  343. staff by electronic mail, we strongly advise that the e-mail be encrypted.
  344. The CERT Coordination Center can support a shared DES key, PGP (public key
  345. available via anonymous FTP on info.cert.org), or PEM (contact CERT staff
  346. for details).
  347.  
  348. Internet E-mail: cert@cert.org
  349. Telephone: +1 412-268-7090 (24-hour hotline)
  350.            CERT personnel answer 8:30 a.m.-5:00 p.m. EST(GMT-5)/EDT(GMT-4),
  351.            and are on call for emergencies during other hours.
  352. Fax: +1 412-268-6989
  353.  
  354. CERT Coordination Center
  355. Software Engineering Institute
  356. Carnegie Mellon University
  357. Pittsburgh, PA 15213-3890
  358. USA
  359.  
  360. Past advisories, CERT bulletins, information about FIRST representatives,
  361. and other information related to computer security are available for
  362. anonymous FTP from info.cert.org.
  363.  
  364. CERT is a service mark of Carnegie Mellon University.
  365.  
  366. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  367. Revision history
  368.  
  369. Aug. 30, 1996   Information previously in the README was inserted
  370.                       into the advisory.
  371. Mar. 03, 1995   Appendix A summary list - Digital Equipment and Sequent added
  372.                       as "not affected by the vulnerability"
  373. Mar. 03, 1995   This advisory superseded CA-95:03, which had a portion of the
  374.                        patch missing from Appendix B.
  375.  
  376.  
  377.  
  378. -----BEGIN PGP SIGNATURE-----
  379. Version: 2.6.2
  380.  
  381. iQCVAwUBMiSy7nVP+x0t4w7BAQEtGAP9G2uuhfS7Q+x5fZVKtw6ERlRVGaCE17c4
  382. QUUnKGVX4Fm1p7cQ/MeZGiFDnk/XN1xXOzNmIx9iaJSA/2JgXYNFftnEoy80PYpT
  383. 42sJr/xP247IwzyaZjwQAIIP1UXWH89ZgunZPSmPd9L2ts3qtGDcbhoYx7VeGTJU
  384. Go2JaixjZME=
  385. =7Wu6
  386. -----END PGP SIGNATURE-----
  387.  
  388.