****************************************************************************** ------ ----- ----- --- ----- | ----- ---- | | | | | |--- | | | | | | | | | |-- | | | | |-- | | | | | | | | \ | | ----- ---- ----- ----- | \ ----- A D V I S O R Y FA-98.03 ****************************************************************************** Topic: CGI Security Hole in EWS1.1 Source: CERT/CC Creation Date: Jan. 16, 1998 Last Updated: To aid in the wide distribution of essential security information, FedCIRC is forwarding the following information from CERT/CC Vendor Initiated Bulletin (VB-98.01). FedCIRC urges you to act on this information as soon as possible. If you have any questions, please contact FedCIRC: Telephone: +1 888 282 0870 Email: fedcirc@fedcirc.gov =======================FORWARDED TEXT STARTS HERE============================ -----BEGIN PGP SIGNED MESSAGE----- ============================================================================= CERT* Vendor-Initiated Bulletin VB-98.01 Jan. 16, 1998 Topic: CGI Security Hole in EWS1.1 Source: Excite, Inc. To aid in the wide distribution of essential security information, the CERT Coordination Center is forwarding the following information from Excite, Inc. Excite, Inc. urges you to act on this information as soon as possible. Excite, Inc. contact information is included in the forwarded text below; please contact them if you have any questions or need further information. =======================FORWARDED TEXT STARTS HERE============================ Topic: CGI Security Hole in EWS1.1 Source: Excite, Inc. 555 Broadway, Redwood City, CA 94063 http://www.excite.com Problem: Vulnerability in EWS1.1, Unix and Windows NT platforms I. Description Excite for Web Servers, version 1.1, for Unix and Windows NT platforms, contains a security hole that could allow a malicious user of the software to execute shell commands on the the host system on which EWS has been installed. In situations where the web server is running under a user-id with sufficient access privileges, a hacker could conceivably cause damage to the host system. EWS's search CGI is implemented in Perl and invokes a binary program to actually perform the search against the corpus. The function of the Perl CGI is to parse the results from the search engine and render them in HTML. This bug in no way affects Excite.com, anyone visiting or searching Excite.com, any search boxes (for example, those on the Netscape and Microsoft sites) that point to Excite.com, or sites that the Excite spider indexes. II. Impact Because a search entered by a user into the web page is passed as command line argument to the search binary, and because the command line is interpreted by the shell before the search binary is invoked, it is possible for a hacker with sufficient know-how to craft a search that could cause commands embedded in the search string to be invoked on the host system. III. Solution IMPORTANT: Please note that if you have obtained patches from Excite or a third party site prior to 1/16/98, you do not have the most recent version of the patch. Please visit the patches page referenced below to obtain the latest vresion of the patches, which have evaluated and tested internally, as well as by CERT (http://www.cert.org). The security hole can be corrected by replacing single Perl library file that is part of the EWS1.1 distribution. There are two new versions of this file available at http://www.excite.com/navigate/patches.html. One version is for Unix platforms, the other is for Windows NT platforms. Changes are confined to two subroutines within the architext_query.pl library file. The subroutines in question are 'MakeQuery' and 'MakeGather'. To apply the patch, simply replace the file architext_query.pl, which appears in the 'perllib' subdirectory of the EWS installation, with one of the files posted at the URL provided above. Note that comments at the top of the file indicate which operating system it is intended for, either Unix platforms, or Windows NT platforms. For Unix platforms, the changes made to these routines invoke the search binaries using Perl's 'exec', which calls C's execvp(3), thus bypassing any shell processing of the command. By avoiding shell processing of the command, the security hole is closed and prevents any attacks using shell-based hacking. It is not possible to use the same solution in the Windows NT implementation of Perl, so the patch for Windows NT takes a different approach, by defining a set of legal characters for a search string, and then 'sanitizing' the string by removing any characters that are not members of the set of legal characters. For more information, please visit http://www.excite.com/navigate. ========================FORWARDED TEXT ENDS HERE============================= If you believe that your system has been compromised, contact the CERT Coordination Center or your representative in the Forum of Incident Response and Security Teams (FIRST). See http://www.first.org/team-info/. We strongly urge you to encrypt any sensitive information you send by email. The CERT Coordination Center can support a shared DES key and PGP. Contact the CERT staff for more information. Location of CERT PGP key ftp://ftp.cert.org/pub/CERT_PGP.key CERT Contact Information - ------------------------ Email cert@cert.org Phone +1 412-268-7090 (24-hour hotline) CERT personnel answer 8:30-5:00 p.m. EST (GMT-5)/EDT(GMT-4), and are on call for emergencies during other hours. Fax +1 412-268-6989 Postal address CERT Coordination Center Software Engineering Institute Carnegie Mellon University Pittsburgh PA 15213-3890 USA CERT publications, information about FIRST representatives, and other security-related information are available from http://www.cert.org/ ftp://ftp.cert.org/pub/ CERT advisories and bulletins are also posted on the USENET newsgroup comp.security.announce To be added to our mailing list for CERT advisories and bulletins, send your email address to cert-advisory-request@cert.org In the subject line, type SUBSCRIBE your-email-address * Registered U.S. Patent and Trademark Office. The CERT Coordination Center is part of the Software Engineering Institute (SEI). The SEI is sponsored by the U. S. Department of Defense. This file: ftp://ftp.cert.org/pub/cert_bulletins/VB-98.01.excite -----BEGIN PGP SIGNATURE----- Version: 2.6.2 iQCVAwUBNL/VWXVP+x0t4w7BAQG2SgP6Ar0qbK3fbc07yAgm9Jk2FqaNEZxb07Io CIyW8yk4Tjwe7hRUJFFnZ48Y8clbgR+9qghsjhmbYj1rrxa6JfGqTmPEOG7dNuew Ckl+wSgDYuPV4EWbh29VfIVy5nfWyptciM2d0ufoZ70AG0X7Qxjqa6xWkeVkgmtk WaKYmcODGRU= =XtSJ -----END PGP SIGNATURE----- ========================FORWARDED TEXT ENDS HERE============================= The National Institute of Standards and Technology (NIST) has established a Federal Computer Incident response Capability (FedCIRC) to assist federal civilians agencies in their incident handling efforts by providing proactive and reactive computer security related services. FedCIRC is a partnership among NIST, the Computer Incident Advisory Capability (CIAC), and the CERT* Coordination Center (CERT/CC). If you believe that your system has been compromised, please contact FedCIRC: Telephone: +1 888 282 0870 Email: fedcirc@fedcirc.gov Web Server: http://www.fedcirc.gov/ * Registered in U.S. Patent and Trademark Office The CERT Coordination Center is part of the Software Engineering Institute. The Software Engineering Institute is sponsored by the U.S. Department of Defense. CIAC, the Computer Incident Advisory Capability, is the computer security incident response team for the U.S. Department of Energy (DOE) and the emergency backup response team for the National Institutes of Health (NIH). CIAC is located at the Lawrence Livermore National Laboratory in Livermore, California. CIAC is also a founding member of FIRST, the Forum of Incident Response and Security Teams, a global organization established to foster cooperation and coordination among computer security teams worldwide. This document was prepared as an account of work sponsored by an agency of the United States Government. Neither the United States Government nor the University of California nor any of their employees, makes any warranty, express or implied, or assumes any legal liability or responsibility for the accuracy, completeness, or usefulness of any information, apparatus, product, or process disclosed, or represents that its use would not infringe privately owned rights. Reference herein to any specific commercial products, process, or service by trade name, trademark, manufacturer, or otherwise, does not necessarily constitute or imply its endorsement, recommendation or favoring by the United States Government or the University of California. The views and opinions of authors expressed herein do not necessarily state or reflect those of the United States Government or the University of California, and shall not be used for advertising or product endorsement purposes.