freshclam.conf(5)

πŸ’– freshclam.conf(5) πŸ’–

okay bestie, gather round, because we're about to read the config file for freshclam.conf β€” that's the Configuration file for Clam AntiVirus database update tool, aka the little file that tells freshclam(1) how to go get your virus databases. she's not the star of the show, she's the manager of the star of the show, and honestly? manager energy is main character energy. πŸŽ€


✨ DESCRIPTION ✨

so. the file freshclam.conf configures the Clam AntiVirus Database Updater, which is freshclam(1). that's it. that's the whole vibe. she configures, she updates, she slays. πŸ’…


🌸 FILE FORMAT 🌸

the file is literally just comments and options with arguments, no cap. every line that starts with a hash (#) gets ignored by the parser β€” so go ahead and yap in the comments, nobody's reading them but you. 🫢

options and arguments are case sensitive and look like this: Option Argument.

the arguments come in these types:

  • BOOL β€” a boolean value. you can write yes/no or true/false or 1/0. pick your fighter. ✨
  • STRING β€” a string without blank characters. no spaces, bestie, she will not tolerate them.
  • SIZE β€” size in bytes. you can use M or m for megabytes and K or k for kilobytes. the lowercase ones are just as valid, she's not picky like that. πŸ’–
  • NUMBER β€” an unsigned integer. no negatives, we're staying positive in this household.

πŸ‘‘ DIRECTIVES πŸ‘‘

when an option is not used β€” meaning it's hashed out, or it just straight-up doesn't exist in the config file β€” freshclam takes a default action. so if you don't say anything, she's still gonna do something. iconique.


  • Example β€” if this option is set, freshclam will not run. that's it. that's the whole thing. she's a little troll like that. πŸ’€
  • LogFileMaxSize SIZE β€” limits the size of the log file. the logger gets automatically disabled if the file is greater than SIZE. a value of 0 disables the limit entirely (yolo mode). Default: 1M
  • LogTime BOOL β€” log the time with each message. timestamps, bestie, they're giving accountability. Default: no
  • LogSyslog BOOL β€” enable logging to Syslog. may be used in combination with UpdateLogFile. Default: disabled.
  • LogFacility STRING β€” specify the type of syslog messages β€” please refer to man syslog for facility names. Default: LOG_LOCAL6
  • LogVerbose BOOL β€” enable verbose logging. she will tell you everything. 😭 Default: disabled
  • LogRotate BOOL β€” rotate log file. requires the LogFileMaxSize option to be set prior to this option. Default: no
  • PidFile STRING β€” write the daemon's pid to the specified file. Default: disabled
  • DatabaseDirectory STRING β€” path to a directory containing database files. this directory must already exist, must be an absolute path, must be writeable by freshclam and readable by clamd/clamscan. all four, no exceptions, she's checking. πŸ”₯ Default: /var/lib/clamav
  • CVDCertsDirectory STRING β€” path to a directory containing ClamAV CA certificate files used to verify signed database archives (e.g. CVD files). this directory must already exist, must be an absolute path, and must be readable by freshclam, clamd, clamscan, and sigtool. Default: /etc/clamav/certs
  • FIPSCryptoHashLimits BOOL β€” enforce FIPS-like limits on using hash algorithms for cryptographic purposes. this will disable MD5 & SHA1 FP sigs and will require .sign files to verify CVD authenticity. she's locking it down. πŸ”’ Default: no
  • Foreground BOOL β€” don't fork into background. she stays right here with you. 🫢 Default: no
  • Debug BOOL β€” enable debug messages in libclamav. Default: no
  • UpdateLogFile STRING β€” enable logging to a specified file. highly recommended β€” like, genuinely, bestie, do this one. Default: disabled.
  • DatabaseOwner STRING β€” when started by root, drop privileges to a specified user. humble queen behavior. Default: clamav
  • Checks NUMBER β€” number of database checks per day. Default: 12
  • DNSDatabaseInfo STRING β€” use DNS to verify the virus database version. FreshClam uses DNS TXT records to verify the versions of the database and software itself. with this directive you can change the database verification domain.
⚠️ WARNING: please don't change it unless you're configuring freshclam to use your own database verification domain.

Default: enabled, pointing to current.cvd.clamav.net

  • DatabaseMirror STRING β€” DatabaseMirror specifies to which mirror(s) freshclam should connect. you should have at least one entries: database.clamav.net. now that CloudFlare is being used as our Content Delivery Network (CDN), this one domain name works world-wide to direct freshclam to the closest geographic endpoint. one domain, whole planet, she ate. 🌍 Default: database.clamav.net
  • PrivateMirror STR β€” this option allows you to easily point freshclam to private mirrors. if PrivateMirror is set, freshclam does not attempt to use DNS to determine whether its databases are out-of-date; instead it will use the If-Modified-Since request or directly check the headers of the remote database files. for each database, freshclam first attempts to download the CLD file. if that fails, it tries to download the CVD file. this option overrides DatabaseMirror, DNSDatabaseInfo and ScriptedUpdates. it can be used multiple times to provide fall-back mirrors. Default: disabled
  • MaxAttempts NUMBER β€” how many attempts (per mirror) to make before giving up. she's persistent but she's not that persistent. Default: 3 (per mirror)
  • ScriptedUpdates BOOL β€” with this option you can control scripted updates. it's highly recommended to keep it enabled. Default: yes
  • TestDatabases BOOL β€” with this option enabled, freshclam will attempt to load new databases into memory to make sure they are properly handled by libclamav before replacing the old ones. vibe check before commitment, love that for her. ✨ Default: enabled
  • CompressLocalDatabase BOOL β€” by default freshclam will keep the local databases (.cld) uncompressed to make their handling faster. with this option you can enable the compression; the change will take effect with the next database update. Default: no
  • ExtraDatabase STRING β€” download an additional 3rd party signature database distributed through the ClamAV mirrors. this option can be used multiple times. Default: disabled
  • ExcludeDatabase STRING β€” exclude a standard signature database (opt-out). this option can be used multiple times. Default: disabled
  • DatabaseCustomURL STRING β€” with this option you can provide custom sources for database files. this option can be used multiple times. support for: http(s)://, ftp(s)://, or file://. example usage:
DatabaseCustomURL https://myserver.com:4567/allow_list.wdb

Default: disabled

  • HTTPProxyServer STR, HTTPProxyPort NUMBER β€” use given proxy server and TCP port for database downloads. the HTTPProxyServer may be prefixed with [scheme]:// to specify which kind of proxy is used.
    • http:// β€” HTTP Proxy. Default when no scheme or proxy type is specified.
    • https:// β€” HTTPS Proxy. (Added in 7.52.0 for OpenSSL, GnuTLS and NSS)
    • socks4:// β€” SOCKS4 Proxy.
    • socks4a:// β€” SOCKS4a Proxy. Proxy resolves URL hostname.
    • socks5:// β€” SOCKS5 Proxy.
    • socks5h:// β€” SOCKS5 Proxy. Proxy resolves URL hostname.
  • HTTPProxyUsername STR, HTTPProxyPassword STRING β€” proxy usage is authenticated through given username and password. Default: disabled
  • HTTPUserAgent STRING β€” if your servers are behind a firewall/proxy which applies User-Agent filtering, you can use this option to force the use of a different User-Agent header. as of ClamAV 0.103.3, this setting may not be used when updating from the clamav.net CDN and can only be used when updating from a private mirror. Default: clamav/version_number
  • NotifyClamd STRING β€” notify a running clamd(8) to reload its database after a download has occurred. the path for clamd.conf file must be provided. Default: the default is to not notify clamd. see clamd.conf(5)'s option SelfCheck for how clamd(8) handles database updates in this case.
  • OnUpdateExecute STRING β€” execute this command after the database has been successfully updated. πŸŽ‰ Default: disabled
  • OnErrorExecute STRING β€” execute this command after a database update has failed. 😭 Default: disabled
  • OnOutdatedExecute STRING β€” execute this command when freshclam reports outdated version. in the command string %v will be replaced by the new version number. Default: disabled
  • LocalIPAddress IP β€” use IP as client address for downloading databases. useful for multi homed systems. Default: use OS'es default outgoing IP address.
  • ConnectTimeout NUMBER β€” timeout in seconds when connecting to database server. Default: 10
  • ReceiveTimeout NUMBER β€” maximum time in seconds for each download operation. 0 means no timeout. Default: 0
  • Bytecode BOOL β€” this option enables downloading of bytecode.cvd, which includes additional detection mechanisms and improvements to the ClamAV engine. Default: yes

πŸŽ€ FILES πŸŽ€

  • /etc/clamav/freshclam.conf

πŸ’œ AUTHOR πŸ’œ

  • Thomas Lamy <thomas.lamy@netwake.de>
  • Tomasz Kojm <tkojm@clamav.net>
  • Kevin Lin <klin@sourcefire.com>

the trio, the icons, the legends. πŸ‘‘


πŸ¦‹ SEE ALSO πŸ¦‹


okay and that's the whole page, bestie!! πŸ’– this one's from ClamAV 1.5.4, dated December 4, 2013 β€” yeah she's an elder but she still ate, fr fr. go configure your databases and stay safe out there, mwah 🫢✨🌸