[Pkg-clamav-devel] Bug#799808: clamav: dpkg-configure of clamav fails in finnish locale

Antti Järvinen antti.jarvinen at katiska.org
Tue Sep 22 21:26:52 UTC 2015

Package: clamav
Version: 0.98.7+dfsg-3
Severity: normal

Dear Maintainer,

when updating clamav to newer version using apt-get the configure-stage 
fails if LANG is set to fi_FI.UTF-8. Setting LANG to C fixes the problem. 

In following output LANG is initially set to fi_FI.UTF-8 so there is 
some output in finnish, translations follow:

# nice apt-get -f dist-upgrade
Luetaan pakettiluetteloita... Valmis
Muodostetaan riippuvuussuhteiden puu       
Luetaan tilatiedot... Valmis        
Käsitellään päivitystä ... Valmis
Nämä paketit on jätetty odottamaan:
  gstreamer0.10-plugins-good gstreamer1.0-plugins-good tellico
0 päivitetty, 0 uutta asennusta, 0 poistettavaa ja 3 päivittämätöntä.
2 ei asennettu kokonaan tai poistettiin.
Toiminnon jälkeen käytetään 0  t lisää levytilaa.
Haluatko jatkaa? [K/e] k
Setting up clamav-freshclam (0.98.7+dfsg-3) ...
/var/lib/dpkg/info/clamav-freshclam.config: 136: export: Binääritiedosto: bad variable name
dpkg: error processing package clamav-freshclam (--configure):
 subprocess installed post-installation script returned error exit status 2
dpkg: dependency problems prevent configuration of clamav:
 clamav depends on clamav-freshclam (>= 0.98.7+dfsg) | clamav-data; however:
  Package clamav-freshclam is not configured yet.
  Package clamav-data is not installed.
  Package clamav-freshclam which provides clamav-data is not configured yet.

dpkg: error processing package clamav (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
E: Sub-process /usr/bin/dpkg returned an error code (1)
# export LANG=C
# nice apt-get -f dist-upgrade
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  gstreamer0.10-plugins-good gstreamer1.0-plugins-good tellico
0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up clamav-freshclam (0.98.7+dfsg-3) ...
Replacing config file /etc/logrotate.d/clamav-freshclam with new version
Replacing config file /etc/clamav/freshclam.conf with new version
Setting up clamav (0.98.7+dfsg-3) ...

So in the error message the word "Binääritiedosto" translates to 
"Binary file" - maybe configure script expects some specific word
or chokes on accented characters? ..quite possibly as the line 136
there reads 
        export "$variable"="true"
and bash might dislike environment variables with non-ascii names? 

The string seems to originate from variable CLAMAVCONF that in turn
is propably content of file /etc/clamav/freshclam.conf but in there
I don't see any accented characters, nor word "Binääritiedosto", it
is all english and .. judging by the file timestamp, it just got
overwritten by the upgrade process so I don't even have the original 
offending content any more. 

Antti Järvinen

-- Package-specific info:
--- configuration ---
#Automatically Generated by clamav-base postinst
#To reconfigure clamd run #dpkg-reconfigure clamav-base
#Please read /usr/share/doc/clamav-base/README.Debian.gz for details
LocalSocket /var/run/clamav/clamd.ctl
FixStaleSocket true
LocalSocketGroup clamav
LocalSocketMode 666
# TemporaryDirectory is not set to its default /tmp here to make overriding
# the default with environment variables TMPDIR/TMP/TEMP possible
User clamav
AllowSupplementaryGroups true
ScanMail true
ScanArchive true
ArchiveBlockEncrypted false
MaxDirectoryRecursion 15
FollowDirectorySymlinks false
FollowFileSymlinks false
ReadTimeout 180
MaxThreads 12
MaxConnectionQueueLength 15
LogSyslog false
LogRotate true
LogFacility LOG_LOCAL6
LogClean false
LogVerbose false
PidFile /var/run/clamav/clamd.pid
DatabaseDirectory /var/lib/clamav
SelfCheck 3600
Foreground false
Debug false
ScanPE true
MaxEmbeddedPE 10M
ScanOLE2 true
ScanHTML true
MaxHTMLNormalize 10M
MaxHTMLNoTags 2M
MaxScriptNormalize 5M
MaxZipTypeRcg 1M
ScanSWF true
DetectBrokenExecutables false
ExitOnOOM false
LeaveTemporaryFiles false
AlgorithmicDetection true
ScanELF true
IdleTimeout 30
PhishingSignatures true
PhishingScanURLs true
PhishingAlwaysBlockSSLMismatch false
PhishingAlwaysBlockCloak false
DetectPUA false
ScanPartialMessages false
HeuristicScanPrecedence false
StructuredDataDetection false
CommandReadTimeout 5
SendBufTimeout 200
MaxQueue 100
ExtendedDetectionInfo true
OLE2BlockMacros false
ScanOnAccess false
AllowAllMatchScan true
ForceToDisk false
DisableCertCheck false
StreamMaxLength 25M
LogFile /var/log/clamav/clamav.log
LogTime true
LogFileUnlock false
LogFileMaxSize 0
Bytecode true
BytecodeSecurity TrustSigned
BytecodeTimeout 60000
OfficialDatabaseOnly false
CrossFilesystems true
# Automatically created by the clamav-freshclam postinst
# Comments will get lost when you reconfigure the clamav-freshclam package

DatabaseOwner clamav
UpdateLogFile /var/log/clamav/freshclam.log
LogVerbose false
LogSyslog false
LogFacility LOG_LOCAL6
LogFileMaxSize 0
LogRotate true
LogTime true
Foreground false
Debug false
MaxAttempts 5
DatabaseDirectory /var/lib/clamav
DNSDatabaseInfo current.cvd.clamav.net
AllowSupplementaryGroups false
ConnectTimeout 30
ReceiveTimeout 30
TestDatabases yes
ScriptedUpdates yes
CompressLocalDatabase no
SafeBrowsing false
Bytecode true
# Check for new database 24 times a day
Checks 24
DatabaseMirror db.local.clamav.net
DatabaseMirror database.clamav.net
# Proxy: http://0�:/
HTTPProxyServer 0�

--- data dir ---
total 290072
-rw-r--r-- 1 clamav clamav    399872 Jun 18 22:01 bytecode.cld
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-3824a89e358512ff826f058cc43c6f23
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-3bc33e578f70df4e86363c248fb2225b
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-3eacc9d8bed66bdec4793c43811672ef
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-5ac0347670568f9e26113de2e3dfe70c
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-7782d396e781b0645fd2a1c9cbd6b48f
drwxr-xr-x 2 clamav clamav      4096 Jul  4 18:28 clamav-9a76c543cf030acd8fe996b5f6977295.tmp
drwxr-xr-x 3 clamav clamav      4096 Jul  8 17:44 clamav-b7558548b9094482f7d09bd276417c14.tmp
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-c3aa0972bdf17fb243774ac916b826af
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-c537b7c8aa981aff5e150076ac0e6dc9
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-e82db1c1213c04bd5e405a0a50a1b926
drwx------ 2 clamav clamav      4096 Jan  3  2014 clamav-f1ed525fb7142341da677cbaff7d91bc
-rw-r--r-- 1 clamav clamav  91893248 Jun 21 20:48 daily.cld
-rw-r--r-- 1 clamav clamav  40909312 Jan  2  2014 daily.cld.broken
-rw-r--r-- 1 clamav clamav 163468288 Sep 18  2013 main.cld
-rw------- 1 clamav clamav      1872 Jun 21 22:48 mirrors.dat

-- System Information:
Debian Release: stretch/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.1.0-2-amd64 (SMP w/2 CPU cores)
Locale: LANG=fi_FI.UTF-8, LC_CTYPE=fi_FI.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages clamav depends on:
ii  clamav-freshclam [clamav-data]  0.98.7+dfsg-3
ii  libc6                           2.19-20
ii  libclamav6                      0.98.7+dfsg-3
ii  libcurl3                        7.44.0-2
ii  libssl1.0.0                     1.0.2d-1
ii  zlib1g                          1:1.2.8.dfsg-2+b1

Versions of packages clamav recommends:
ii  clamav-base  0.98.7+dfsg-3

Versions of packages clamav suggests:
pn  clamav-docs  <none>

-- no debconf information

More information about the Pkg-clamav-devel mailing list