clamd.conf(5)
Hey bestie π welcome to clamd.conf(5), aka the Clam AntiVirus daemon config manual β the whole thing, section 5, no skips, no shortcuts. This is the file that tells clamd(8) how to live its life. Grab a snack, we're going through every single directive. π
β¨ NAME β¨
clamd.conf β the configuration file for the Clam AntiVirus Daemon. That's it, that's the name, short and iconic. π
π DESCRIPTION π
clamd.conf is the file that configures the Clam AntiVirus daemon, clamd(8). She's the one in charge. Periodt.
π FILE FORMAT π
The file is made of two things: comments, and options with arguments. Simple as.
Any line that starts with a hash (#) symbol? The parser literally ignores it. Not even looking at it. π
Options and their arguments are case sensitive, and they're shaped like Option Argument.
The arguments come in these types, so let's do a little type tour π¦:
BOOLβ a boolean value. You can write it asyes/no, ortrue/false, or1/0. Pick your fighter.STRINGβ a string with no blank characters in it. No spaces, bestie, she's picky.SIZEβ a size in bytes. You can useMormfor megabytes, andKorkfor kilobytes. Want it in plain bytes? Just don't use any modifier. Easy.NUMBERβ an unsigned integer.
π DIRECTIVES π
Okay so here's the vibe: when some option is not used β meaning it's commented out, or just straight up not in the config file at all β clamd takes a default action. So if you say nothing, she still has opinions. π
Exampleβ if this option is set,clamdwill not run.
πΈ Logging & daemon basics πΈ
LogFile STRINGβ save all reports to a log file.- Default:
disabled
- Default:
LogFileUnlock BOOLβ by default the log file is locked for writing, and only a single daemon process can write to it. This option disables that lock.- Default:
no
- Default:
LogFileMaxSize SIZEβ the maximum size of the log file. A value of0disables the limit entirely.- Default:
1048576
- Default:
LogTime BOOLβ log the time for each message.- Default:
no
- Default:
LogClean BOOLβ log all clean files too. Super useful for debugging, but it drastically increases the log size, so watch out.- Default:
no
- Default:
LogSyslog BOOLβ use the system logger. (She can work together withLogFile, they're not jealous.)- Default:
no
- Default:
LogFacility STRINGβ the type of syslog messages. Please refer toman syslogfor facility names, iykyk.- Default:
LOG_LOCAL6
- Default:
LogVerbose BOOLβ enable verbose logging. Chatty era.- Default:
no
- Default:
LogRotate BOOLβ rotate the log file. Requires theLogFileMaxSizeoption to be set prior to this option, so order matters bestie.- Default:
no
- Default:
ExtendedDetectionInfo BOOLβ log additional info about the infected file β like its size and hash β right alongside the virus name. Extra details, extra slay.- Default:
no
- Default:
PidFile STRINGβ write the daemon's pid to the specified file.- Default:
disabled
- Default:
π¦ Directories & databases π¦
TemporaryDirectory STRINGβ this option lets you change the default temporary directory.- Default: system specific (usually
/tmpor/var/tmp).
- Default: system specific (usually
DatabaseDirectory STRINGβ this option lets you change the default database directory. If you enable it, please make sure it points to the same directory in bothclamdandfreshclam. Teamwork, fr fr.- Default: defined at configuration (
/usr/local/share/clamav)
- Default: defined at configuration (
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, be an absolute path, and be readable byfreshclam,clamd,clamscan, andsigtool.- Default:
/etc/clamav/certs
- Default:
FIPSCryptoHashLimits BOOLβ enforce FIPS-like limits on using hash algorithms for cryptographic purposes. Will disable MD5 & SHA1 FP sigs, and will require.signfiles to verify CVD authenticity.- Default:
no
- Default:
OfficialDatabaseOnly BOOLβ only load the official signatures published by the ClamAV project. Nothing unofficial gets in. π«- Default:
no
- Default:
FailIfCvdOlderThan NUMBERβ return with a nonzero error code if the virus database is older than the specified number of days.- Default:
-1
- Default:
π«Ά Sockets & listening π«Ά
LocalSocket STRINGβ path to a local (Unix) socket the daemon will listen on.- Default:
disabled
- Default:
LocalSocketGroup STRINGβ sets the group ownership on the unix socket.- Default: the primary group of the user running
clamd
- Default: the primary group of the user running
LocalSocketMode STRINGβ sets the permissions on the unix socket to the specified mode.- Default: socket is world readable and writable
FixStaleSocket BOOLβ remove stale socket after an unclean shutdown. Cleanup queen. π§Ή- Default:
yes
- Default:
TCPSocket NUMBERβ TCP port number the daemon will listen on.- Default:
disabled
- Default:
TCPAddr STRINGβ by defaultclamdbinds toINADDR_ANY. This option lets you restrict the TCP address and gives you some degree of protection from the outside world. This option can be specified multiple times in order to listen on multiple IPs. IPv6 is now supported. β¨- Default:
disabled
- Default:
π Protocol commands π
EnableShutdownCommand BOOLβ enables theSHUTDOWNcommand. Setting this tonoprevents a client from stoppingclamdvia the protocol. When disabled,clamdresponds to this command withCOMMAND UNAVAILABLE.- Default:
yes
- Default:
EnableReloadCommand BOOLβ enables theRELOADcommand. Setting this tonoprevents a client from reloading the database. When disabled,clamdresponds to this command withCOMMAND UNAVAILABLE.- Default:
yes
- Default:
EnableVersionCommand BOOLβ enables theVERSIONcommand. Setting this tonoprevents a client from querying version information. When disabled,clamdresponds to this command withCOMMAND UNAVAILABLE.- Default:
yes
- Default:
EnableStatsCommand BOOLβ enables theSTATScommand. Setting this tonoprevents a client from querying statistics. When disabled,clamdresponds to this command withCOMMAND UNAVAILABLE.- Default:
yes
- Default:
MaxConnectionQueueLength NUMBERβ the maximum length the queue of pending connections may grow to.- Default:
200
- Default:
π₯ Streaming, threads & timeouts π₯
StreamMaxLength SIZEβ close theSTREAMsession when the data size limit is exceeded. The value should match your MTA's limit for the maximum attachment size.- Default:
100M
- Default:
StreamMinPort NUMBERβ theSTREAMcommand uses an FTP-like protocol. This option sets the lower boundary for the port range.- Default:
1024
- Default:
StreamMaxPort NUMBERβ this option sets the upper boundary for the port range.- Default:
2048
- Default:
MaxThreads NUMBERβ maximum number of threads running at the same time.- Default:
10
- Default:
ReadTimeout NUMBERβ this option specifies the time (in seconds) after whichclamdshould timeout if a client doesn't provide any data.- Default:
120
- Default:
CommandReadTimeout NUMBERβ this option specifies the time (in seconds) after whichclamdshould timeout if a client doesn't provide any initial command after connecting. The default is set to30to avoid timeouts with TCP sockets when processing large messages. If using a Unix socket, the value can be changed to5. Note: the timeout for subsequent commands, and/or data chunks, is specified byReadTimeout.- Default:
30
- Default:
SendBufTimeout NUMBERβ this option specifies how long to wait (in milliseconds) if the send buffer is full. Keep this value low to preventclamdhanging.- Default:
500
- Default:
MaxQueue NUMBERβ maximum number of queued items (including those being processed byMaxThreadsthreads). It's recommended to have this value at least twiceMaxThreadsif possible.
WARNING: you shouldn't increase this too much, to avoid running out of file descriptors. The following condition should hold:text MaxThreads*MaxRecursion + MaxQueue - MaxThreads + 6 < RLIMIT_NOFILERLIMIT_NOFILEis the maximum number of open file descriptors (usually1024), set byulimit -n.
- Default:
100
IdleTimeout NUMBERβ this option specifies how long (in seconds) the process should wait for a new job.- Default:
30
- Default:
π§ Scanning behavior π§
ExcludePath REGEXβ don't scan files and directories matchingREGEX. This directive can be used multiple times.- Default:
disabled
- Default:
MaxDirectoryRecursion NUMBERβ maximum depth directories are scanned at.- Default:
15
- Default:
FollowDirectorySymlinks BOOLβ follow directory symlinks.- Default:
no
- Default:
CrossFilesystems BOOLβ scan files and directories on other filesystems.- Default:
yes
- Default:
FollowFileSymlinks BOOLβ follow regular file symlinks.- Default:
no
- Default:
SelfCheck NUMBERβ this option specifies the time intervals (in seconds) in whichclamdshould perform a database check.- Default:
600
- Default:
ConcurrentDatabaseReload BOOLβ enable non-blocking (multi-threaded/concurrent) database reloads. This feature will temporarily load a second scanning engine while scanning continues using the first engine. Once loaded, the new engine takes over. The old engine is removed as soon as all scans using the old engine have completed. This feature requires more RAM, so this option is provided in case users are willing to block scans during reload in exchange for lower RAM requirements.- Default:
yes
- Default:
π Events & daemon lifecycle π
VirusEvent COMMANDβ execute a command when a virus is found. Use the following environment variables to identify the file and virus names:$CLAM_VIRUSEVENT_FILENAME,$CLAM_VIRUSEVENT_VIRUSNAME. In the command string,'%v'will also be replaced with the virus name.
Note: the'%f'filename format character has been disabled and will no longer be replaced with the file name, due to command injection security concerns. Use the'CLAM_VIRUSEVENT_FILENAME'environment variable instead. For the same reason, you should NOT use the environment variables in the command directly, but should use it carefully from your executed script.
- Default:
disabled
ExitOnOOM BOOLβ stop the daemon whenlibclamavreports an out of memory condition.- Default:
no
- Default:
AllowAllMatchScan BOOLβ permit use of theALLMATCHSCANcommand.- Default:
yes
- Default:
Foreground BOOLβ don't fork into background. Stay right here, main character energy. β¨- Default:
no
- Default:
Debug BOOLβ enable debug messages fromlibclamav.- Default:
no
- Default:
LeaveTemporaryFiles BOOLβ do not remove temporary files (for debugging purpose).- Default:
no
- Default:
GenerateMetadataJsonBOOL β bestie, this one records metadata all about the file being scanned π. Scan metadata is lowkey essential for file analysis and for debugging why a scan is behaving the way it is. The JSON metadata gets printed out after the scan is complete ifDebugis enabled. And ametadata.jsonfile gets written to the scan temp directory ifLeaveTemporaryFilesis enabled. Default:noJsonStoreHTMLURIsBOOL β stores the URIs it finds in HTML files into the json metadata β¨. They go in an array under the tagURIs. Heads up:GenerateMetadataJsonis required for this feature to do literally anything. Default:yes(ifGenerateMetadataJsonis used)JsonStorePDFURIsBOOL β same vibe, but for URIs found in PDF files π¦. They land in an array taggedURIs. And again:GenerateMetadataJsonis required for this feature. Default:yes(ifGenerateMetadataJsonis used)JsonStoreExtraHashesBOOL β calculatesMD5andSHA1hashes (on top ofSHA2-256, not instead of) and stores them in the json metadata π . You guessed it:GenerateMetadataJsonis required for this feature. Default:noUserSTRING β run the daemon as a specified user. Important: the process must be started byrootfor this to work at all. Default:disabledBytecodeBOOL β with this turned on, ClamAV loads bytecode from the database. Highly recommended you keep this on β otherwise you may miss detections for a whole bunch of new viruses π. Default:yesBytecodeSecuritySTRING β sets the bytecode security level π.
Possible values:
TrustSignedβ trust bytecode loaded from signed.c[lv]dfiles, and insert runtime safety checks for bytecode loaded from other sourcesParanoidβ don't trust any bytecode, insert runtime checks for all of it
Recommended: TrustSigned, because bytecode inside .cvd files already has these checks. Default: TrustSigned
BytecodeTimeoutNUMBER β sets the bytecode timeout, measured in milliseconds β±οΈ. Default:10000BytecodeUnsignedBOOL β allows loading bytecode from outside digitally signed.c[lv]dfiles.
Caution: you should NEVER run bytecode signatures from untrusted sources. Doing so may result in arbitrary code execution π. Like, actual "someone else runs code on your machine" energy. Do not play with this.
Default: no
BytecodeModeSTRING β sets the bytecode execution mode ποΈ.
Possible values:
Autoβ automatically choose JIT if possible, fallback to interpreterForceJITβ always choose JIT, fail if that's not possibleForceInterpreterβ always choose interpreterTestβ run with both JIT and interpreter and compare the results. Makes all failures fatal.
Default: Auto
DetectPUABOOL β detect Possibly Unwanted Applications π. Default:NoExcludePUACATEGORY β excludes one specific PUA category. You can use this directive multiple times, stack 'em up π . The complete list of PUA categories lives athttps://docs.clamav.net/faq/faq-pua.html. Default:disabledIncludePUACATEGORY β only includes one specific PUA category. Also usable multiple times, no cap. Same list of categories athttps://docs.clamav.net/faq/faq-pua.html. Default:disabledHeuristicAlertsBOOL β in some cases (like complex malware, exploits hiding in graphic files, and other cursed situations), ClamAV busts out special algorithms for accurate detection π΅οΈ. This option is what controls that algorithmic detection. Default:yesHeuristicScanPrecedenceBOOL β lets a heuristic match take precedence π. When it's enabled, if a heuristic scan (likephishingScan) detects a possible virus/phishing, scanning stops immediately. Recommended β it saves CPU scan-time. When it's disabled, viruses/phishing caught by heuristic scans get reported only at the end of the scan. So if an archive holds both a heuristically detected virus/phishing and real malware, the real malware is what gets reported. Keep this disabled if you intend to handle"*.Heuristics.*"viruses differently from "real" malware. Oh, and heads up: if a non-heuristically-detected virus (signature-based) is found first, the scan is interrupted immediately regardless of this config option. Default:noScanPEBOOL β PE means Portable Executable, the executable file format used across all 32 and 64-bit versions of Windows π. This option lets ClamAV do a deeper analysis of executable files, and it's also required for decompressing popular executable packers like UPX. Turn it off and the original files still get scanned, just without the extra processing. Default:yesScanELFBOOL β Executable and Linking Format is the standard format for UN*X executables π§. This option controls whether ELF files get scanned. Turn it off and the original files still get scanned, just without additional processing. Default:yesScanMailBOOL β enables scanning of mail files π§. Turn it off and the original files still get scanned, just without parsing individual messages/attachments. Default:yesScanPartialMessagesBOOL β scans RFC1341 messages that got split across many emails π΅. You'll need to periodically clean up the$TemporaryDirectory/clamav-partialdirectory.
WARNING: this option may open your system to a DoS attack. Never use it on loaded servers. Fr fr, just don't.
Default: no
PhishingSignaturesBOOL β enables email signature-based phishing detection π£. Default:yesPhishingScanURLsBOOL β enables URL signature-based phishing detection (Heuristics.Phishing.Email.*) π. Default:yesStructuredDataDetectionBOOL β enables the DLP module π. Default:noStructuredMinCreditCardCountNUMBER β sets the lowest number of credit card numbers that must be found in a file before a detect is generated π³. Default:3StructuredCCOnlyBOOL β with this on, the DLP module searches for valid credit card numbers only. Debit and Private Label cards won't be searched. Default:NoStructuredMinSSNCountNUMBER β sets the lowest number of Social Security Numbers that must be found in a file before a detect is generated πͺͺ. Default:3StructuredSSNFormatNormalBOOL β with this on, the DLP module searches for valid SSNs formatted asxxx-yy-zzzz. Default:YesStructuredSSNFormatStrippedBOOL β with this on, the DLP module searches for valid SSNs formatted asxxxyyzzzz. Default:NoScanHTMLBOOL β performs HTML/JavaScript/ScriptEncoder normalisation and decryption π. Turn it off and the original files still get scanned, just without additional processing. Default:yesScanOLE2BOOL β enables scanning of OLE2 files, like Microsoft Office documents and.msifiles π. Turn it off and the original files still get scanned, just without additional processing. Default:yesScanPDFBOOL β enables scanning within PDF files π. Turn it off and the original files still get scanned, just without additional processing. Default:yesScanSWFBOOL β enables scanning within SWF files π§. Turn it off and the original files still get scanned, just without decoding and additional processing. Default:yesScanXMLDOCSBOOL β enables scanning of xml-based document files supported by libclamav π. Turn it off and the original files still get scanned, just without additional processing. Default:yesScanHWP3BOOL β enables scanning of HWP3 files π°π·. Turn it off and the original files still get scanned, just without additional processing. Default:yesScanOneNoteBOOL β enables scanning of OneNote files π. Turn it off and the original files still get scanned, just without additional processing. Default:yesScanArchiveBOOL β scans within archives and compressed files ποΈ. Turn it off and the original files still get scanned, just without unpacking and additional processing. Default:yesScanImageBOOL β enables scanning of image (graphics) files πΌοΈ. Turn it off and the original files still get scanned, just without unpacking and additional processing. Default:yesScanImageFuzzyHashBOOL β enables detection by calculating a fuzzy hash of image (graphics) files β¨. Signatures using image fuzzy hashes typically match files and documents by identifying images embedded in or attached to those files. Turn this off and some files may no longer be detected, which is giving "why is nothing firing" π. Default:yesAlertBrokenExecutablesBOOL β alerts on broken executable files (PE & ELF) π. Default:noAlertBrokenMediaBOOL β alerts on broken graphics files (JPEG, TIFF, PNG, GIF) π. Default:noAlertEncryptedBOOL β alerts on encrypted archives and documents (encrypted.zip,.7zip,.rar,.pdf) π. Default:noAlertEncryptedArchiveBOOL β alerts on encrypted archives (encrypted.zip,.7zip,.rar) ποΈ. Default:noAlertEncryptedDocBOOL β alerts on encrypted documents (encrypted.pdf) π. Default:noAlertOLE2MacrosBOOL β alerts on OLE2 files containing VBA macros (Heuristics.OLE2.ContainsMacros) π¦ . Default:noAlertExceedsMaxBOOL β when this is set, files that exceed theMaxFileSize,MaxScanSize, orMaxRecursionlimit get flagged with a virus name starting with"Heuristics.Limits.Exceeded"π¨. Default:noAlertPhishingSSLMismatchBOOL β alerts on emails containing SSL mismatches in URLs. Careful though β this might lead to false positives! π Default:no
okay bestie we're still deep in the directives list and now we're hitting the scan-limit and on-access zone, so grab a snack π, this part is a whole journey but I promise it's worth it π
AlertPhishingCloakBOOLβ turns on alerts for emails that are hiding cloaked URLs in them (heads up, this one might throw a few false positives, it's just like that sometimes π). Default:noAlertPartitionIntersectionBOOLβ alerts when raw DMG image files have partition intersections going on. Default:noDisableCacheβ lets you turn off the engine's caching feature entirely. By default the engine keeps an MD5 in a cache for any file that didn't get flagged as a virus, or that hit its limit checks. > Warning: turning the cache off is gonna hurt performance on large scans, no cap, it's a real tradeoff π. Default:noCacheSizeβ sets how many entries the cache can hold. Bestie, the value should be a square number, otherwise it gets rounded up to the nearest square number (the math said so, not me β¨). Default:65536ForceToDiskβ makes memory or nested map scans dump their content to disk. Flip this on and more data gets written to disk, and it's available when theleave-tempsoption is enabled β but at the cost of more disk writes. Pick your battles π . Default:noMaxScanTimeSIZEβ the max amount of time a scan is allowed to take before it's done. The value is in milliseconds. Setting it to0disables the limit. > WARNING: disabling this limit or setting it too high may result in scanning of certain files locking up the scanning process/threads, which is literally a Denial of Service. That's not the vibe. Default:120000MaxScanSizeSIZEβ the maximum amount of data scanned for each input file. Archives and other containers get recursively extracted and scanned up to this value. The size of the archive plus the sum of the sizes of all the files inside it both count toward the scan size. Like, a1Muncompressed archive containing a single1Minner file counts as2Mtoward the max scan size β it's giving "everything counts" energy fr fr. > Warning: disabling this limit or setting it too high may result in severe damage to the system. Default:400MMaxFileSizeSIZEβ files bigger than this limit just don't get scanned, periodt. This affects the input file itself and any files contained inside it (when the input file is an archive, a document, or some other kind of container). > Warning: disabling this limit or setting it too high may result in severe damage to the system. Also, technical design limitations prevent ClamAV from scanning files greater than2 GBat this time. Default:100MMaxRecursionNUMBERβ nested archives get scanned recursively, so like if a Zip archive contains a RAR file, all the files within it get scanned too. This option says how deep the process should keep going. > Warning: setting this limit too high may result in severe damage to the system. Default:17MaxFilesNUMBERβ how many files get scanned inside an archive, a document, or any other kind of container. > Warning: disabling this limit or setting it too high may result in severe damage to the system. Default:10000MaxEmbeddedPESIZEβ the max size of a file to check for embedded PE. Files bigger than this value skip that extra analysis step. Negative values are not allowed. Default:40MMaxHTMLNormalizeSIZEβ the max size of an HTML file to normalize. HTML files bigger than this value don't get normalized or scanned. Negative values are not allowed. Default:40MMaxHTMLNoTagsSIZEβ the max size of a normalized HTML file to scan. HTML files bigger than this value after normalization don't get scanned. Negative values are not allowed. Default:8MMaxScriptNormalizeSIZEβ the max size of a script file to normalize. Script content bigger than this value doesn't get normalized or scanned. Negative values are not allowed. Default:20MMaxZipTypeRcgSIZEβ the max size of a ZIP file for reanalyzing type recognition. ZIP files bigger than this value skip the step that could potentially reanalyze them as PE. Negative values are not allowed. > WARNING: setting this limit too high may result in severe damage or impact performance. Default:1MMaxPartitionsSIZEβ the maximum number of partitions of a raw disk image that get scanned. Raw disk images with more partitions than this value will have up to that many partitions scanned. Negative values are not allowed. > WARNING: setting this limit too high may result in severe damage or impact performance. Default:50MaxIconsPESIZEβ the maximum number of icons within a PE that get scanned. PE files with more icons than this value will have up to that many icons scanned. Negative values are not allowed. > WARNING: setting this limit too high may result in severe damage or impact performance. Default:100MaxRecHWP3NUMBERβ the maximum number of recursive calls to the HWP3 parsing function. HWP3 files using more than this limit get terminated and the user gets alerted. Scans will be unable to scan any HWP3 attachments if the recursive limit is reached. Negative values are not allowed. > WARNING: setting this limit too high may result in severe damage or impact performance. Default:16PCREMatchLimitNUMBERβ the maximum calls to the PCRE match function during an instance of regex matching. Instances using more than this limit get terminated and the user gets alerted, but the scan keeps going (iconic, honestly). For more info on match_limit, go look at the PCRE documentation. Negative values are not allowed. > WARNING: setting this limit too high may severely impact performance. Default:10000PCRERecMatchLimitNUMBERβ the maximum recursive calls to the PCRE match function during an instance of regex matching. Instances using more than this limit get terminated and the user gets alerted, but the scan keeps going. For more info on match_limit_recursion, see the PCRE documentation. Negative values are not allowed, and values greater thanPCREMatchLimitare superfluous (like why would you π). > WARNING: setting this limit too high may severely impact performance. Default:2000PCREMaxFileSizeSIZEβ the maximum filesize for which PCRE subsigs will be executed. Files exceeding this limit won't have PCRE subsigs executed, unless a subsig is encompassed to a smaller buffer. Negative values are not allowed. Setting this value tozerodisables the limit. > WARNING: setting this limit too high or disabling it may severely impact performance. Default:100MOnAccessIncludePathSTRINGβ specifies a directory (including all the files and directories inside it) that should be scanned on access. This option can be used multiple times. Default:disabledOnAccessExcludePathSTRINGβ lets you exclude directories from on-access scanning. It can be used multiple times. Default:disabledOnAccessExcludeRootUIDBOOLβ with this you can exclude the root UID (0). Processes running under root will be able to access all files without triggering scans or permission denied events. But bestie, note this: ifclamdcan't check the uid of the process that generated an on-access scan event (e.g., becauseOnAccessPreventionwas not enabled, and the process already exited),clamdwill perform a scan. So settingOnAccessExcludeRootUIDis not guaranteed to prevent every access by the root user from triggering a scan (unlessOnAccessPreventionis enabled). Default:noOnAccessExcludeUIDNUMBERβ lets you exclude specific UIDs. Processes with these UIDs will be able to access all files without triggering scans or permission denied events. This option can be used multiple times (one per line). Note: using a value of0on any line will disable this option entirely β so if you wanna exclude the root UID (0), please enable theOnAccessExcludeRootUIDoption instead. Also note: ifclamdcan't check the uid of the process that generated an on-access scan event (e.g., becauseOnAccessPreventionwas not enabled, and the process already exited),clamdwill perform a scan. Thus, settingOnAccessExcludeUIDis not guaranteed to prevent every access by the specified uid from triggering a scan (unlessOnAccessPreventionis enabled). Default:disabledOnAccessExcludeUnameSTRINGβ lets you do exclusions via user names when using the on-access scanning client. It can be used multiple times, and it has the same potential race condition limitations as theOnAccessExcludeUIDoption (yeah, that whole thing again π). Default:disabledOnAccessMaxFileSizeSIZEβ files larger than this value won't be scanned in on access. Default:5MOnAccessMaxThreadsNUMBERβ max number of scanning threads to allocate to the OnAccess thread pool at startup. These threads are the ones responsible for creating a connection with the daemon and kicking off scanning after an event has been processed. To keepclamonaccfrom consuming all ofclamd's resources, keep this lower thanclamd's max threads. Default:5OnAccessCurlTimeoutNUMBERβ max amount of time (in milliseconds) that the OnAccess client should spend for every connect, send, and receive attempt when communicating withclamdvia curl. Default:5000(5 seconds)OnAccessMountPathSTRINGβ specifies a mount point (including all the files and directories under it) that should be scanned on access. This option can be used multiple times. Default:disabledOnAccessDisableDDDBOOL β turns OFF the dynamic directory determination system, aka the thing that lets clamd watch include paths recursively. If you kill DDD, no more recursive watch, bestie. Default:noOnAccessPreventionBOOL β switches on fanotify blocking, so when malicious files get caught, access gets blocked for real. Default:disabledOnAccessRetryAttemptsNUMBER β how many times the OnAccess client will retry a scan that failed because of connection problems (or, like, other issues). Default:0OnAccessDenyOnErrorBOOL β when you're using prevention, flipping this on means any error during scanning = the event attempt gets denied. Which sounds slay until you realize it can cause unwanted system behaviour with certain configurations π so the client defaults it to off and would rather just allow access events if there's a scan or connection error. Default:noOnAccessExtraScanningBOOL β toggles extra scanning and notifications for when a file or directory is created or moved β¨. Heads up though: it requires the DDD system to kick off those extra scans. Default:noDisableCertCheckBOOL β disables authenticode certificate chain verification in PE files. Default:no
π NOTES π
Okay so real talk for a sec π«Ά β every option that expresses a size is capped at a max of 4GB. If you feed it values in excess of that, they get reset to the maximum. No negotiating, that's just the law.
π FILES π
/etc/clamav/clamd.conf
π AUTHORS π
The masterminds behind all this, giving main character energy fr fr:
- Tomasz Kojm
<tkojm@clamav.net> - Kevin Lin
<klin@sourcefire.com>
π¦ SEE ALSO π¦
Go read these next, bestie, they're all in the same universe iykyk:
And that's the whole page, no cap π ClamAV 1.5.4 dropped this one back on December 4, 2013, and that's the version and date you'd find sitting in the footer. Obsessed with you for reading the whole thing, mwah ππ
π¦ where this page comes from
- arch rolling: clamav 1.5.4-1 Β· GPL-2.0-only
- ubuntu jammy: clamav-daemon 1.5.4+dfsg-0ubuntu0.22.04.1 Β· GPL-2.0-only
- ubuntu noble: clamav-daemon 1.5.4+dfsg-0ubuntu0.24.04.1 Β· GPL-2.0-only
- ubuntu resolute: clamav-daemon 1.5.4+dfsg-0ubuntu0.26.04.1 Β· GPL-2.0-only
- ubuntu stonking: clamav-daemon 1.5.4+dfsg-0ubuntu1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms