Remote pine Denial of Service From: Linus Sj
Remote pine Denial of Service From: Linus Sjöberg <lsjoberg@aland.net> (Ålcom) To: bugtraq@securityfocus.com Date: Thu, 7 Nov 2002 15:16:13 +0200 (EET) Security Advisory 23rd October 2002 Remote pine version 4.44 denial of service Name: Pine version 4.44 Arch: Redhat 7.2 i386 Severity: Medium Vendor URL: http://www.washington.edu/pine/ Author: Linus Sjöberg (lsjoberg@aland.net) Vendor notified: 14:th October 2002 Vendor response: 14:th October 2002 Vendor fix: ?????? Impact: An attacker can send a fully legal email message with a crafted From-header and thus forcing pine to core dump on startup. The only way to launch pine is manually removing the bad message either directly from the spool, or from another MUA. Until the message has been removed or edited there is no way of accessing the INBOX using pine. Description *********** When pine detects an email with a From-header looking like From: "\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\""@host.fubar it will die with a segmentation fault. Note that the address is fully legal, even if quite unusable. When i reproduced the problem with a pine running within gdb I got the following backtrack: #0 0x401ea490 in chunk_free (ar_ptr=0x4029e300, p=0x83b65d8) at malloc.c:3231 #1 0x401ea3f4 in __libc_free (mem=0x83b65e0) at malloc.c:3154 #2 0x081ef8e2 in fs_give (block=0xbfffb9b8) at fs_unix.c:60 #3 0x080feb4f in set_index_addr (idata=0xbfffc8c0, field=0x83012d8 "From", addr=0x83b6160, prefix=0x0, width=18, s=0xbfffbd11 "\"\\\"\\\"\\\"\\\"\\\"\\\"\\\"\\\"\\\b`´:\bX½^?¿ïø\036\b") at mailindx.c:4508 #4 0x080fb397 in format_index_line (idata=0xbfffc8c0) at mailindx.c:3376 #5 0x080f9ec4 in build_header_line (state=0x839f260, stream=0x83aba88, msgmap=0x83a17b0, msgno=40) at mailindx.c:2761 #6 0x080f71e3 in update_index (state=0x839f260, screen=0xbfffcb90) at mailindx.c:1264 #7 0x080f576c in index_lister (state=0x839f260, cntxt=0x83a8d28, folder=0x839f325 "INBOX", stream=0x83aba88, msgmap=0x83a17b0) at mailindx.c:603 #8 0x080f5347 in mail_index_screen (state=0x839f260) at mailindx.c:452 #9 0x081588e6 in main (argc=1, argv=0xbfffddc4) at pine.c:1122 #10 0x40185657 in __libc_start_main (main=0x8156974 <main>, argc=1, ubp_av=0xbfffddc4, init=0x804ab28 <_init>, fini=0x8225c70 <_fini>, rtld_fini=0x4000dcd4 <_dl_fini>, stack_end=0xbfffddbc) at ../sysdeps/generic/libc-start.c:129 Since pine dumped core it might be possible to execute code on the victims machine, but since I am not into those kind of games I leave that part for others to find out. The possibility of locking somebody out from his email is important enough for an advisory+update IMHO. Fix Information *************** Washington University replied to my posting within a few hours and reported that the issue was to be fixed in version 4.50. They have not yet made such a version publicly available after 1½ month, so I have chosen to go public with this advisory even if there is no patch yet available.
raker: 4.50 was released yesterday, the new version has the fix for this security bug. I took a look at the previous ebuilds and I noticed that were lots of patches applied to the package. I think you have more knownlege of the pine ebuild so I wonder if you could bump this?
I'll sort out the diffs and let you know soon.
pine-4.50 has been added to portage. Please test and let me know if everything is alright. Also need to give the option to add debugging support back in. I'll add that soon or create a -r1.
I have added support for DEBUG and fixed the ssl certs path. ( /etc/ssl/certs to match with the forthcoming openssl-0.9.6g-r1 or later openssl ebuilds instead of the current /usr/lib/ssl/certs which isn't handled properly anyway... ) I also cleaned out the the patches I had commented out from the ebuild. AFAIK, all known bugs are dealt with in this ebuild.
Also, pine-4.50-r1 has been added to portage which includes all previous fixes and maildir support. This needs testing but everything looks good so far. :)
SuSE Security Announcement: pine (SuSE-SA:2002:046) From: Thomas Biege <thomas@suse.de> To: <bugtraq@securityfocus.com> Date: Mon, 25 Nov 2002 12:05:38 +0100 (CET) Message was signed with unknown key 0x3D25D3D9. The validity of the signature can't be verified. ______________________________________________________________________________ SuSE Security Announcement Package: pine Announcement-ID: SuSE-SA:2002:046 Date: Monday, Nov 25th 2002 10:30 MEST Affected products: 7.1, 7.2, 7.3, 8.0, 8.1 SuSE Linux Database Server SuSE eMail Server 3.1 SuSE eMail Server III SuSE Firewall Adminhost VPN SuSE Linux Admin-CD for Firewall SuSE Firewall on CD 2 - VPN SuSE Firewall on CD 2 SuSE Linux Enterprise Server for S/390 SuSE Linux Connectivity Server SuSE Linux Enterprise Server 7 for IA32 SuSE Linux Office Server Vulnerability Type: remote denial-of-service Severity (1-10): 4 SuSE default package: yes (7.1 - 8.0) no (8.1) Cross References: none Content of this advisory: 1) security vulnerability resolved: - heap buffer overflow while parsing mail address problem description, discussion, solution and upgrade information 2) pending vulnerabilities, solutions, workarounds: - sparc distribution - WindowMaker 3) standard appendix (further information) ______________________________________________________________________________ 1) problem description, brief discussion, solution, upgrade information Pine, Program for Internet News and Email, is a well known and widely used eMail client. While parsing and escaping characters of eMail addresses pine does not allocate enough memory for storing the escaped mailbox part of an address. This results in a buffer overflow on the heap that will make pine crash. The offending eMail can just be deleted manually or by using another mail user agent. A possible temporary workaround is to filter the respective header lines by a mail delivery agent (such as procmail). Please download the update package for your distribution and verify its integrity by the methods listed in section 3) of this announcement. Then, install the package using the command "rpm -Fhv file.rpm" to apply the update. Our maintenance customers are being notified individually. The packages are being offered to install from the maintenance web. Intel i386 Platform: SuSE-8.1: ftp://ftp.suse.com/pub/suse/i386/update/8.1/rpm/i586/pine-4.44-224.i586.rpm 8c32d5571d7488e31f693a884dedb81e patch rpm(s): ftp://ftp.suse.com/pub/suse/i386/update/8.1/rpm/i586/pine-4.44-224.i586.patch.rpm 467b8b318958b0ead3f30fa7b1f5a9a0 source rpm(s): ftp://ftp.suse.com/pub/suse/i386/update/8.1/rpm/src/pine-4.44-224.src.rpm 9b1ff436719cf9752cda3ddd711e80a7 SuSE-8.0: ftp://ftp.suse.com/pub/suse/i386/update/8.0/n1/pine-4.44-222.i386.rpm 01d9e82164a5ce4037b84be1b2ed4228 patch rpm(s): ftp://ftp.suse.com/pub/suse/i386/update/8.0/n1/pine-4.44-222.i386.patch.rpm 162c4265909af7805f7aeaf3e12e8763 source rpm(s): ftp://ftp.suse.com/pub/suse/i386/update/8.0/zq1/pine-4.44-222.src.rpm d724e02b1ea3783e5bfb01ae9728d7cf SuSE-7.3: ftp://ftp.suse.com/pub/suse/i386/update/7.3/n1/pine-4.33-266.i386.rpm 140c58adf7d0b2113d5bbbbb20de67e2 source rpm(s): ftp://ftp.suse.com/pub/suse/i386/update/7.3/zq1/pine-4.33-266.src.rpm 100c86e88ce357b0efacf7dfe2ab592c SuSE-7.2: ftp://ftp.suse.com/pub/suse/i386/update/7.2/n1/pine-4.33-266.i386.rpm bd44232250b3def07cab81064dad11f2 source rpm(s): ftp://ftp.suse.com/pub/suse/i386/update/7.2/zq1/pine-4.33-266.src.rpm e28daa1f2d66135fcf5951c9b2dc19be SuSE-7.1: ftp://ftp.suse.com/pub/suse/i386/update/7.1/n1/pine-4.33-263.i386.rpm 9bdd3394336a786b0711b8e98ab4a268 source rpm(s): ftp://ftp.suse.com/pub/suse/i386/update/7.1/zq1/pine-4.33-263.src.rpm 630478b751a24e86c52fe645be9365c4 Sparc Platform: SuSE-7.3: ftp://ftp.suse.com/pub/suse/sparc/update/7.3/n1/pine-4.33-97.sparc.rpm 5187b311c27f043178a12ae186d228a6 source rpm(s): ftp://ftp.suse.com/pub/suse/sparc/update/7.3/zq1/pine-4.33-97.src.rpm 9616303edadfd899785f3ac12d2dc02a AXP Alpha Platform: SuSE-7.1: ftp://ftp.suse.com/pub/suse/axp/update/7.1/n1/pine-4.33-85.alpha.rpm f5155d79236e3ec15c463f586f731c17 source rpm(s): ftp://ftp.suse.com/pub/suse/axp/update/7.1/zq1/pine-4.33-85.src.rpm 75365b21b97c8a2f722d95491f62d305 PPC Power PC Platform: SuSE-7.3: ftp://ftp.suse.com/pub/suse/ppc/update/7.3/n1/pine-4.33-143.ppc.rpm 98955d956701d7c6c3e0522468377044 source rpm(s): ftp://ftp.suse.com/pub/suse/ppc/update/7.3/zq1/pine-4.33-143.src.rpm d4cdfbf180711ae6e9bab31b87cbb3bd SuSE-7.1: ftp://ftp.suse.com/pub/suse/ppc/update/7.1/n1/pine-4.33-141.ppc.rpm 0b0512af4bdffc654bbd1774c2c8f8a9 source rpm(s): ftp://ftp.suse.com/pub/suse/ppc/update/7.1/zq1/pine-4.33-141.src.rpm 0ee371a8935abe58aa53221606960bbe ______________________________________________________________________________ 2) Pending vulnerabilities in SuSE Distributions and Workarounds: - sparc distribution We have moved the update directories for the SuSE SPARC distributions 7.0 and 7.1 as well as the distribution directory for 7.1 to the discontinued/ tree on ftp.suse.com. We urge all of the sparc users to upgrade to the SuSE-7.3-sparc distribution, the latest in the row for the sparc platform. Resource limitations keep us from timely providing update packages for the older sparc distribution. - WindowMaker A bug was found in the image processing code of windowmaker. It could allow attackers to execute arbitrary code as the user running windowmaker by tricking the user into viewing special crafted malicious image files. New packages are currently being built and will be available soon. ______________________________________________________________________________ 3) standard appendix: authenticity verification, additional information - Package authenticity verification: SuSE update packages are available on many mirror ftp servers all over the world. While this service is being considered valuable and important to the free and open source software community, many users wish to be sure about the origin of the package and its content before installing the package. There are two verification methods that can be used independently from each other to prove the authenticity of a downloaded file or rpm package: 1) md5sums as provided in the (cryptographically signed) announcement. 2) using the internal gpg signatures of the rpm package. 1) execute the command md5sum <name-of-the-file.rpm> after you downloaded the file from a SuSE ftp server or its mirrors. Then, compare the resulting md5sum with the one that is listed in the announcement. Since the announcement containing the checksums is cryptographically signed (usually using the key security@suse.de), the checksums show proof of the authenticity of the package. We disrecommend to subscribe to security lists which cause the email message containing the announcement to be modified so that the signature does not match after transport through the mailing list software. Downsides: You must be able to verify the authenticity of the announcement in the first place. If RPM packages are being rebuilt and a new version of a package is published on the ftp server, all md5 sums for the files are useless. 2) rpm package signatures provide an easy way to verify the authenticity of an rpm package. Use the command rpm -v --checksig <file.rpm> to verify the signature of the package, where <file.rpm> is the filename of the rpm package that you have downloaded. Of course, package authenticity verification can only target an un-installed rpm package file. Prerequisites: a) gpg is installed b) The package is signed using a certain key. The public part of this key must be installed by the gpg program in the directory ~/.gnupg/ under the user's home directory who performs the signature verification (usually root). You can import the key that is used by SuSE in rpm packages for SuSE Linux by saving this announcement to a file ("announcement.txt") and running the command (do "su -" to be root): gpg --batch; gpg < announcement.txt | gpg --import SuSE Linux distributions version 7.1 and thereafter install the key "build@suse.de" upon installation or upgrade, provided that the package gpg is installed. The file containing the public key is placed at the top-level directory of the first CD (pubring.gpg) and at ftp://ftp.suse.com/pub/suse/pubring.gpg-build.suse.de . - SuSE runs two security mailing lists to which any interested party may subscribe: suse-security@suse.com - general/linux/SuSE security discussion. All SuSE security announcements are sent to this list. To subscribe, send an email to <suse-security-subscribe@suse.com>. suse-security-announce@suse.com - SuSE's announce-only mailing list. Only SuSE's security announcements are sent to this list. To subscribe, send an email to <suse-security-announce-subscribe@suse.com>. For general information or the frequently asked questions (faq) send mail to: <suse-security-info@suse.com> or <suse-security-faq@suse.com> respectively. ===================================================================== SuSE's security contact is <security@suse.com> or <security@suse.de>. The <security@suse.de> public key is listed below. ===================================================================== ______________________________________________________________________________ The information in this advisory may be distributed or reproduced, provided that the advisory is not modified in any way. In particular, it is desired that the clear-text signature shows proof of the authenticity of the text. SuSE Linux AG makes no warranties of any kind whatsoever with respect to the information contained in this security advisory. Type Bits/KeyID Date User ID pub 2048R/3D25D3D9 1999-03-06 SuSE Security Team <security@suse.de> pub 1024D/9C800ACA 2000-10-19 SuSE Package Signing Key <build@suse.de> -----BEGIN PGP PUBLIC KEY BLOCK----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: For info see http://www.gnupg.org mQGiBDnu9IERBACT8Y35+2vv4MGVKiLEMOl9GdST6MCkYS3yEKeueNWc+z/0Kvff 4JctBsgs47tjmiI9sl0eHjm3gTR8rItXMN6sJEUHWzDP+Y0PFPboMvKx0FXl/A0d M+HFrruCgBlWt6FA+okRySQiliuI5phwqkXefl9AhkwR8xocQSVCFxcwvwCglVcO QliHu8jwRQHxlRE0tkwQQI0D+wfQwKdvhDplxHJ5nf7U8c/yE/vdvpN6lF0tmFrK XBUX+K7u4ifrZlQvj/81M4INjtXreqDiJtr99Rs6xa0ScZqIT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 whaQN/7O/JIVAQEB+QP/cYblSAmPXxSFiaHWB+MiUNw8B6ozBLK0QcMQ2YcL6+Vl D+nSZP20+Ja2nfiKjnibCv5ss83yXoHkYk2Rsa8foz6Y7tHwuPiccvqnIC/c9Cvz dbIsdxpfsi0qWPfvX/jLMpXqqnPjdIZErgxpwujas1n9016PuXA8K3MJwVjCqSKI RgQQEQIABgUCOhpCpAAKCRDHUqoysN/3gCt7AJ9adNQMbmA1iSYcbhtgvx9ByLPI DgCfZ5Wj+f7cnYpFZI6GkAyyczG09sE= =LRKC -----END PGP PUBLIC KEY BLOCK----- End of signed message Bye, Thomas -- Thomas Biege <thomas@suse.de> SuSE Linux AG,Deutschherrnstr. 15-19,90429 Nuernberg Function: Security Support & Auditing "lynx -source http://www.suse.de/~thomas/contact/thomas.asc | pgp -fka" Key fingerprint = 51 AD B9 C7 34 FC F2 54 01 4A 1C D4 66 64 09 83 -- Over thinking, Over analyzing, seperates the body from the mind. - Maynard James Keenan