Bug 12162 - clamav-0.100.1-1 on CentOS 5 i386 can't read virus databases
clamav-0.100.1-1 on CentOS 5 i386 can't read virus databases
Status: RESOLVED WONTFIX
Product: ClamAV
Classification: ClamAV
Component: All
stable
x86 GNU/Linux
: P3 normal
: 0.101.0
Assigned To: ClamAV team
:
: 12160 12169 12185 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2018-07-13 09:00 EDT by CTAC
Modified: 2020-02-13 12:14 EST (History)
4 users (show)

See Also:
QA Contact:


Attachments
spec file used to build package (26.15 KB, application/octet-stream)
2018-07-13 09:00 EDT, CTAC
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description CTAC 2018-07-13 09:00:19 EDT
Created attachment 7457 [details]
spec file used to build package

Hi
I've build clamav-0.100.1-1.i386.rpm from source RPM clamav-0.100.1-1.el6.src.rpm (extract SPEC, create SRPM with rpmbuild -bs clamav.spec, rpmbuild --rebuild clamav-0.100.1-1.src.rpm)


$ sudo rpm -Uhv clamd-0.100.1-1.i386.rpm clamav-0.100.1-1.i386.rpm clamav-milter-0.100.1-1.i386.rpm
Preparing...                ########################################### [100%]
   1:clamav                 warning: /etc/freshclam.conf created as /etc/freshclam.conf.rpmnew
########################################### [ 33%]
   2:clamd                  ########################################### [ 67%]
   3:clamav-milter          ########################################### [100%]

$ ls -al /var/lib/clamav/
total 162592
drwxr-xr-x  2 clam clam      4096 Jul 13 18:22 .
drwxr-xr-x 34 root root      4096 Nov 17  2015 ..
-rw-r--r--  1 clam clam    185246 Jul 11 08:37 bytecode.cvd
-rw-r--r--  1 clam clam  48392890 Jul 11 08:37 daily.cvd
-rw-r--r--  1 clam clam 117892267 Jan  9  2018 main.cvd

$ clamscan -V
ClamAV 0.100.1/24741/Wed Jul 11 03:52:06 2018

$ clamscan -v *
LibClamAV Error: cli_cvdload: Corrupted CVD header
LibClamAV Error: Can't load /var/lib/clamav/daily.cvd: Malformed database
ERROR: Malformed database

----------- SCAN SUMMARY -----------
Known viruses: 0
Engine version: 0.100.1
Scanned directories: 0
Scanned files: 0
Infected files: 0
Data scanned: 0.00 MB
Data read: 0.00 MB (ratio 0.00:1)
Time: 0.112 sec (0 m 0 s)

$ freshclam -V
ClamAV 0.100.1/24741/Wed Jul 11 03:52:06 2018

$ sudo freshclam
ClamAV update process started at Fri Jul 13 19:57:16 2018
main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Downloading daily-24742.cdiff [100%]
Downloading daily-24743.cdiff [100%]
Downloading daily-24744.cdiff [100%]
Downloading daily-24745.cdiff [100%]
Downloading daily-24746.cdiff [100%]
Downloading daily-24747.cdiff [100%]
Downloading daily-24748.cdiff [100%]
daily.cld updated (version: 24748, sigs: 2012279, f-level: 63, builder: neo)
bytecode.cvd is up to date (version: 324, sigs: 89, f-level: 63, builder: neo)
WARNING: [LibClamAV] cli_cvdload: Corrupted CVD header
ERROR: Corrupted database file /var/lib/clamav/bytecode.cvd: Malformed database
Corrupted database file renamed to /var/lib/clamav/bytecode.cvd.broken
WARNING: [LibClamAV] cli_cvdload: Corrupted CVD header
ERROR: Corrupted database file /var/lib/clamav/main.cvd: Malformed database
Corrupted database file renamed to /var/lib/clamav/main.cvd.broken
Trying again in 5 secs...
Update process terminated
Comment 1 Micah Snyder 2018-07-13 10:47:41 EDT
ClamAV 0.100 has You should be able to alleviate this issue by upgrading zlib to a recent version: http://zlib.net/

https://github.com/Cisco-Talos/clamav-devel/blob/dev/0.100/NEWS.md#known-issues

I will make a point to add something to our configuration script to require a newer version of zlib.
Comment 2 Micah Snyder 2018-07-13 10:48:42 EDT
*** Bug 12160 has been marked as a duplicate of this bug. ***
Comment 3 Micah Snyder 2018-07-26 09:09:12 EDT
*** Bug 12169 has been marked as a duplicate of this bug. ***
Comment 4 Sergio Basto 2018-08-31 08:12:34 EDT
in epel6 /centos6 we fix it with "Bundle zlib 1.2.7-17.el7 to avoid malformed database errors (#1600458)" [1]

https://src.fedoraproject.org/rpms/clamav/c/e83b89fce61b2db2b174ee06f82c7c2b852a6cd8?branch=el6
Comment 5 Micah Snyder 2018-08-31 12:49:12 EDT
This is interesting.  I created a patch to force users to use a newer version of zlib, but refrained from applying it to ClamAV 0.101 because I didn't think it was possible for RedHat or Centos 5/6 to use anything newer than 1.2.3 and I didn't want to impact the 64bit Centos 5/6 users.
Comment 6 Mickey Sola 2018-09-05 11:50:14 EDT
*** Bug 12185 has been marked as a duplicate of this bug. ***
Comment 7 Micah Snyder 2020-02-13 12:14:29 EST
We don't intend to fix this compatibility issue as there are workarounds for older distributions.