From owner-freebsd-ports-bugs@FreeBSD.ORG Sun Sep 12 21:20:21 2004 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 34F1216A4CE for ; Sun, 12 Sep 2004 21:20:20 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id A752243D5C for ; Sun, 12 Sep 2004 21:20:20 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) i8CLKKIm035254 for ; Sun, 12 Sep 2004 21:20:20 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.11/8.12.11/Submit) id i8CLKKFi035253; Sun, 12 Sep 2004 21:20:20 GMT (envelope-from gnats) Resent-Date: Sun, 12 Sep 2004 21:20:20 GMT Resent-Message-Id: <200409122120.i8CLKKFi035253@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Mark Martinec Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B588416A4CE for ; Sun, 12 Sep 2004 21:12:05 +0000 (GMT) Received: from www.freebsd.org (www.freebsd.org [216.136.204.117]) by mx1.FreeBSD.org (Postfix) with ESMTP id 953B643D41 for ; Sun, 12 Sep 2004 21:12:05 +0000 (GMT) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.12.11/8.12.11) with ESMTP id i8CLC5RB024594 for ; Sun, 12 Sep 2004 21:12:05 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.12.11/8.12.11/Submit) id i8CLC5Ht024593; Sun, 12 Sep 2004 21:12:05 GMT (envelope-from nobody) Message-Id: <200409122112.i8CLC5Ht024593@www.freebsd.org> Date: Sun, 12 Sep 2004 21:12:05 GMT From: Mark Martinec To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-2.3 Subject: ports/71686: rar and unrar Segmentation fault on password-prot. archive with -p- X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Sep 2004 21:20:21 -0000 >Number: 71686 >Category: ports >Synopsis: rar and unrar Segmentation fault on password-prot. archive with -p- >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Sep 12 21:20:20 GMT 2004 >Closed-Date: >Last-Modified: >Originator: Mark Martinec >Release: 5.2-CURRENT >Organization: "J. Stefan" Institute >Environment: FreeBSD sleepy.ijs.si 5.2-CURRENT FreeBSD 5.2-CURRENT #2: Wed Aug 25 12:58:04 CEST 2004 mark@sleepy.ijs.si:/usr/obj/usr/src/sys/SLEEPY i386 >Description: Both the rar and unrar with any command (x, t, v, l) segfaults on certain (not all) password-protected (or broken?) archives when password is not given or is incorrect. Here is an example RAR that triggers the problem: http://www.ijs.si/people/mark/frt45q.rar (caution with that file, might contain a virus) While this may be a minor annoyance for interactive use, it can be a showstopper in anti-virus software (clamav, amavisd-new, ...) which calls unrar or rar to unpack RAR archives. Here is a backtrace after 'unrar t -p-' fault: Program received signal SIGSEGV, Segmentation fault. 0x28211e80 in _ftello () from /lib/libc.so.5 (gdb) bt #0 0x28211e80 in _ftello () from /lib/libc.so.5 #1 0x28211e05 in ftello () from /lib/libc.so.5 #2 0x0804d06e in File::Tell() (this=0xbfbea890) at file.cpp:449 #3 0x0804c2b5 in SaveFilePos (this=0xbfbea420, SaveFile=@0xbfbea890) at savepos.cpp:6 #4 0x0804d26a in File::FileLength() (this=0xbfbea890) at file.cpp:582 #5 0x0805e8ab in CmdExtract::ExtractArchiveInit(CommandData*, Archive&) (this=0xbfbf5760, Cmd=0xbfbf8d64, Arc=@0xbfbea890) at extract.cpp:56 #6 0x0805eb3c in CmdExtract::ExtractArchive(CommandData*) (this=0xbfbf5760, Cmd=0xbfbf8d64) at extract.cpp:107 #7 0x0805e774 in CmdExtract::DoExtract(CommandData*) (this=0xbfbf5760, Cmd=0xbfbf8d64) at extract.cpp:30 #8 0x0806d8fe in CommandData::ProcessCommand() (this=0xbfbf8d64) at cmddata.cpp:977 #9 0x08049b57 in main (argc=9, argv=0xbfbfe894) at rar.cpp:101 #10 0x08049826 in _start () Program versions from ports distinfo (most recent): (unrarsrc-3.3.5.tar.gz) (rarbsd-3.3.0.tar.gz) >How-To-Repeat: $ rar t -inul -p- frt45q.rar Segmentation fault $ unrar t -inul -p- frt45q.rar Segmentation fault $ rar t frt45q.rar RAR 3.30 Copyright (c) 1993-2004 Eugene Roshal 22 Jan 2004 Shareware version Type RAR -? for help Enter password (will not be echoed) for frt45q.rar: Encrypted file: CRC failed in frt45q.rar (password incorrect ?)Segmentation fault >Fix: >Release-Note: >Audit-Trail: >Unformatted: