Hi,

A get a segmentation fault in clamscan on FreeBSD. Clamav is built from the ports, and I only added -g for debugging. This is what's happening:

# uname -a
FreeBSD mars.altus-escon.com 7.2-PRERELEASE FreeBSD 7.2-PRERELEASE #1: Wed Apr 29 18:51:19 CEST 2009 r...@mars.altus-escon.com:/usr/obj/ usr/src/sys/MARS amd64

# clamscan -V
ClamAV 0.95.2/9742/Wed Aug 26 09:09:45 2009

# gdb clamscan
GNU gdb 6.1.1 [FreeBSD]
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "amd64-marcel-freebsd"...(no debugging symbols found)...
(gdb) run *
Starting program: /usr/local/bin/clamscan *
[New LWP 101064]
[New Thread 0x800e020b0 (LWP 101064)]
Attic/disk3,v: OK
Attic/disk2,v: OK
Attic/about.frm,v: OK
Attic/info-32.$$$,v: OK
Attic/test.txt,v: OK
Attic/info-32.log,v: OK
Attic/about.frx,v: OK
Attic/disk1,v: OK
Attic/disk4,v: OK
Attic/info-32.vbp,v: OK
Attic/lane-mt.ldb,v: OK
Attic/lanecomm.ldb,v: OK
Attic/options.frm,v: OK
HINSTALL.EXE,v: OK
HINSTALL.HLP,v: OK
about00.frm,v: OK
about00.frx,v: OK
brake.frm,v: OK
brake.frx,v: OK
brakeform.frm,v: OK
brakeform.frx,v: OK
brakegra.frm,v: OK
clamscan.core: OK
customer.frm,v: OK
customer.frx,v: OK
database.bas,v: OK
db.bas,v: OK
deployreport.txt,v: OK
dist/SETUP.LST,v: OK
dist/laneco4.CAB,v: OK
dist/setup.exe,v: OK

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x800e020b0 (LWP 101064)]
0x00000008006e432b in mszip_make_decode_table (nsyms=288, nbits=9,
length=0x800ed3058 "\a\b\t\a\b\b\t\n\b\t\n\b\a\t\b\a\b\t\t\n\t\t\t \v\b", table=0x800ed3198) at mspack.c:239
239           table[leaf] = sym;
(gdb) where
#0  0x00000008006e432b in mszip_make_decode_table (nsyms=288, nbits=9,
length=0x800ed3058 "\a\b\t\a\b\b\t\n\b\t\n\b\a\t\b\a\b\t\t\n\t\t\t \v\b", table=0x800ed3198) at mspack.c:239 #1 0x00000008006e51a5 in mszip_inflate (zip=0x800ed3000) at mspack.c: 463 #2 0x00000008006e5da5 in mszip_decompress (zip=0x800ed3000, out_bytes=135767) at mspack.c:669
#3  0x00000008006ef094 in cab_extract (file=0x800e161c0,
name=0x800e2b180 "/var/tmp//clamav- b9776d8c756100d30ec866088caf83de") at cab.c:679 #4 0x0000000800678884 in cli_scanmscab (desc=4, ctx=0x7fffffffda80, sfx_offset=202) at scanners.c:730 #5 0x000000080067b845 in cli_scanraw (desc=4, ctx=0x7fffffffda80, type=CL_TYPE_CABSFX, typercg=1 '\001',
    dettype=0x7fffffffda30) at scanners.c:1769
#6 0x000000080067cb2b in cli_magic_scandesc (desc=4, ctx=0x7fffffffda80) at scanners.c:2101 #7 0x000000080067ccfe in cl_scandesc (desc=4, virname=0x7fffffffdb08, scanned=0x516fb0, engine=0x800e180c0,
    scanoptions=25143) at scanners.c:2153
#8  0x0000000000407f8c in ?? ()
#9  0x0000000000408393 in ?? ()
... etc

Looks like a problem inside the CAB decoder. Anybody seen this before?

Kind regards,
Ben

_______________________________________________
Help us build a comprehensive ClamAV guide: visit http://wiki.clamav.net
http://www.clamav.net/support/ml

Reply via email to