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

  1.  
  2. -----BEGIN PGP SIGNED MESSAGE-----
  3.  
  4. =============================================================================
  5. CERT* Advisory CA-97.19
  6. Original issue date: June 25, 1997
  7. Last revised: --
  8.  
  9. Topic: lpr Buffer Overrun Vulnerability
  10. - -----------------------------------------------------------------------------
  11.             The technical content of this advisory was 
  12.             originally published by AUSCERT (AA-96.12), 
  13.             who last updated the information on June 19, 1997.
  14.             We use it here with their permission.
  15.  
  16. - ---------------------------------------------------------------------------
  17. There is a vulnerability in the BSD-based printing software, lpr, available on
  18. a variety of Unix platforms. This vulnerability may allow local users to gain
  19. root privileges.
  20.  
  21. Exploit information involving this vulnerability has been publicly available
  22. for some time. Recently, the CERT/CC has received reports that the
  23. vulnerability is being actively exploited.
  24.  
  25. We recommend installing a vendor patch if one is available. Until you can do
  26. so, we recommend using the wrapper described in Section III.B.
  27.  
  28. We will update this advisory as we receive additional information.
  29. Please check our advisory files regularly for updates that relate to your
  30. site.
  31. - ----------------------------------------------------------------------------
  32.  
  33. I.  Description
  34.  
  35.     A vulnerability exists in the BSD-based lpr printing package found on many
  36.     Unix systems.
  37.  
  38.     Due to insufficient bounds checking on arguments that are supplied by
  39.     users, it is possible to overwrite the internal stack space of the lpr
  40.     program while it is executing. This can allow an intruder to cause lpr to
  41.     execute arbitrary commands by supplying a carefully designed argument to
  42.     lpr. These commands will be run with the privileges of the lpr program.
  43.     When lpr is installed setuid or setgid, it may allow intruders to gain
  44.     those privileges.
  45.  
  46.     When lpr is setuid root, it may allow intruders to run arbitrary commands
  47.     with root privileges.
  48.  
  49.     For information from vendors relating to this vulnerability, please check
  50.     Appendix A of this advisory. In addition to the products mentioned, be
  51.     aware that platforms using the BSD-based lpr systems, in which lpr is
  52.     installed setuid or setgid, may also be vulnerable.
  53.  
  54.     Note also that the vulnerability described in this advisory is not present
  55.     in the LPRng printing package.
  56.  
  57. II. Impact
  58.  
  59.     Local users may gain root privileges. It is necessary to have access to an
  60.     account on the system to exploit this vulnerability.
  61.  
  62. III. Solution
  63.  
  64.     The lpr printing package is available on many different systems. As vendor
  65.     patches are made available sites are encouraged to install them. Until
  66.     vendor patches are available, we recommend applying the workaround
  67.     referred to in III.B.
  68.  
  69.     A. Install vendor patches
  70.  
  71.        Specific vendor information has been placed in Appendix A. If the BSD-
  72.        based lpr printing software is used and your vendor is not listed in
  73.        Appendix A, please contact your vendor directly.
  74.  
  75.     B. Install lpr wrapper
  76.  
  77.        Until you can install a vendor patch, we encourage you install a
  78.        wrapper developed by AUSCERT to help prevent lpr being exploited using
  79.        this vulnerability. 
  80.  
  81.        The source for the wrapper, including installation instructions, can be
  82.        found at
  83.  
  84. ftp://ftp.auscert.org.au/pub/auscert/tools/overflow_wrapper/overflow_wrapper.c
  85.  
  86.        This wrapper replaces the lpr program and checks the length of the
  87.        command line arguments which are passed to it. If an argument exceeds a
  88.        certain predefined value (MAXARGLEN), the wrapper exits without
  89.        executing the lpr command. The wrapper program can also be configured
  90.        to syslog any failed attempts to execute lpr with arguments exceeding
  91.        MAXARGLEN. For further instructions on using this wrapper, please read
  92.        the comments at the top of overflow_wrapper.c.  
  93.  
  94.        When compiling overflow_wrapper.c for use with lpr, AUSCERT recommends
  95.        defining MAXARGLEN to be 32.  
  96.  
  97.        The MD5 checksum for the current version of overflow_wrapper.c can be
  98.        retrieved from
  99.  
  100.        ftp://ftp.auscert.org.au/pub/auscert/tools/overflow_wrapper/CHECKSUM
  101.        
  102.        The CHECKSUM file has been digitally signed using the AUSCERT PGP key.
  103.  
  104. ...........................................................................
  105. Appendix A  Vendor information
  106.  
  107. Below is a list of the vendors who have provided information. We will update
  108. this appendix as we receive additional information. If you do not see your
  109. vendor's name, please contact the vendor directly.
  110.  
  111. Berkeley Software Design, Inc. (BSDI)
  112. ======================================
  113.    BSD/OS 3.0 is not vulnerable to the problem.
  114.  
  115.    BSDI have issued a patch which addresses this vulnerability under
  116.    BSD/OS 2.1.  This patch is available from:
  117.  
  118.         ftp://ftp.bsdi.com/pub/bsdi/patches/patches-2.1/U210-028
  119.  
  120. Digital Equipment Corporation
  121. =============================
  122.    Digital Equipment Corporation                         
  123.    Software Security Response Team
  124.    Copyright (c) Digital Equipment Corporation 1997. All rights reserved.
  125.  
  126.     This reported problem is not present for Digital's ULTRIX or
  127.     Digital UNIX Operating Systems Software.
  128.    
  129.                         - DIGITAL EQUIPMENT CORPORATION  06/19/97
  130.  
  131. FreeBSD
  132. =======
  133.    This problem was fixed prior to the release of FreeBSD 2.1.6 and 2.2.
  134.    Users running older versions of the OS should review the security
  135.    advisory describing this vulnerability (SA-96.18) at:
  136.  
  137.         ftp://freebsd.org/pub/CERT/advisories/FreeBSD-SA-96:18.lpr.asc
  138.  
  139.    Patches can be found in the directory:
  140.  
  141.         ftp://freebsd.org/pub/CERT/patches/SA-96:18
  142.  
  143. IBM Corporation
  144. ===============
  145.    AIX is not vulnerable to the lpr buffer overflow.  The version of lpr
  146.    shipped with AIX is not installed with the setuid bit turned on.
  147.  
  148.    IBM and AIX are registered trademarks of International Business Machines
  149.    Corporation.
  150.  
  151. Linux
  152. =====
  153.    The Linux Emergency Response Team have released a Linux Security FAQ
  154.    Update which addresses this vulnerability.  This Update contains
  155.    information regarding various Linux distributions.  
  156.  
  157.    It is available from:
  158.  
  159.         ftp://bach.cis.temple.edu/pub/Linux/Security/FAQ/updates/
  160.                    Update-11-25-1996.vulnerability-lpr-0.06-v1.2
  161.  
  162. NeXT
  163. ====
  164.    The NeXT group has addressed the vulnerability described in this advisory
  165.    in release 4.2 of OpenStep/Mach.
  166.  
  167. The Santa Cruz Operation, Inc. (SCO)
  168. ====================================
  169.    SCO has determined that the following SCO operating systems
  170.    are not vulnerable:
  171.  
  172.    - SCO CMW+ 3.0
  173.    - SCO Open Desktop/Open Server 3.0, SCO UNIX 3.2v4
  174.    - SCO OpenServer 5.0
  175.    - SCO UnixWare 2.1
  176.  
  177. Sun Microsystems, Inc.
  178. =====================
  179.    All versions of Solaris are not affected. SunOS 4.1.3_U1 and SunOS 4.1.4
  180.    are vulnerable. Sun recommends that sites using SunOS 4.1.3_U1 and SunOS
  181.    4.1.4 apply the workaround provided in this advisory.
  182.  
  183. - ---------------------------------------------------------------------------
  184. The CERT Coordination Center staff thanks AUSCERT for permission to republish
  185. the information in their advisory AA-96.12. AUSCERT originally thanked
  186. Alexander O. Yuriev, the FreeBSD security team, IBM, and the CERT/CC for their
  187. assistance in the production of their advisory.
  188. - ---------------------------------------------------------------------------
  189.  
  190. If you believe that your system has been compromised, contact the CERT
  191. Coordination Center or your representative in the Forum of Incident Response
  192. and Security Teams (see http://www.first.org/team-info/).
  193.  
  194.  
  195. CERT/CC Contact Information
  196. - ----------------------------
  197. Email    cert@cert.org
  198.  
  199. Phone    +1 412-268-7090 (24-hour hotline)
  200.                 CERT personnel answer 8:30-5:00 p.m. EST(GMT-5) / EDT(GMT-4)
  201.                 and are on call for emergencies during other hours.
  202.  
  203. Fax      +1 412-268-6989
  204.  
  205. Postal address
  206.          CERT Coordination Center
  207.          Software Engineering Institute
  208.          Carnegie Mellon University
  209.          Pittsburgh PA 15213-3890
  210.          USA
  211.  
  212. Using encryption
  213.    We strongly urge you to encrypt sensitive information sent by email. We can
  214.    support a shared DES key or PGP. Contact the CERT/CC for more information.
  215.    Location of CERT PGP key
  216.          ftp://info.cert.org/pub/CERT_PGP.key
  217.  
  218. Getting security information
  219.    CERT publications and other security information are available from
  220.         http://www.cert.org/
  221.         ftp://info.cert.org/pub/
  222.  
  223.    CERT advisories and bulletins are also posted on the USENET newsgroup
  224.         comp.security.announce
  225.  
  226.    To be added to our mailing list for advisories and bulletins, send
  227.    email to
  228.         cert-advisory-request@cert.org
  229.  
  230.    In the subject line, type
  231.         SUBSCRIBE  your-email-address
  232.  
  233. - ---------------------------------------------------------------------------
  234. * Registered U.S. Patent and Trademark Office.
  235.  
  236. Copyright 1997 Carnegie Mellon University
  237. This material may be reproduced and distributed without permission provided
  238. it is used for noncommercial purposes and the copyright statement is
  239. included.
  240.  
  241. The CERT Coordination Center is part of the Software Engineering Institute
  242. (SEI). The SEI is sponsored by the U.S. Department of Defense.
  243. - ---------------------------------------------------------------------------
  244.  
  245. This file: ftp://info.cert.org/pub/cert_advisories/CA-97.19.bsdlp
  246.            http://www.cert.org
  247.                click on "CERT Advisories"
  248.  
  249.  
  250. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  251. Revision history
  252.  
  253. -----BEGIN PGP SIGNATURE-----
  254. Version: 2.6.2
  255.  
  256. iQCVAwUBM7EtenVP+x0t4w7BAQEVTQQAxgGLiaK6XRbtPPrcXvyio9WDswQUHJTG
  257. XpYksnonmdQ/LGiZL7AU0AQOtPRDSQlU22fZRMEPppFuANAkXcYVtr7rZxayJiMe
  258. xIWWCvmJd1TlYff/q1JLy3JnBTxq1rhjQ62PFkksP4giMZEh28jlOWcby04w1Kth
  259. i3jw7EfaBy4=
  260. =AqZf
  261. -----END PGP SIGNATURE-----
  262.  
  263.