ClearFoundation Tracker - ClearOS
View Issue Details
0019401ClearOSapp-file-scan - Antimalware File Scanpublic2018-03-21 05:242019-11-23 05:02
NickH 
NickH 
normaltweakalways
closedsuspended 
7.4.0 
 
0019401: Add option to exclude file types from daily scan
Currently the file scanner app scans all files and folders within the selected locations. Many file types are considered harmless such as jpg's and could be excluded from daily scans. As an example my IP security camera produces some 3800 jpg's yesterday and I keep a few days of history. A full scan including these takes over 2h.

It would be trivial to read in parameters exclude= and exclude-dir= from /etc/clearos/file_scan.conf by adding these lines to /use/sbin/file_scan:

            elseif ($param == 'exclude')
                $clam_scan_options .= " --$param=$value";
            elseif ($param == 'exclude-dir')
                $clam_scan_options .= " --$param=$value";

after the lines:

            elseif ($param == 'max-scansize')
                $clam_scan_options .= " --$param=$value";

This can be documented in the help text as the max-scansize and max-filesize are at the moment.

Longer term this could be the precursor to adding the parameters to the Webconfig.

Note that clamscan allows these parameters to be repeated multiple times, but we don't necessarily need to to start with as a regex such as --exclude="\.(jpg|jpeg|png|gif|mkv)$" can cover multiple file types.
No tags attached.
Issue History
2018-03-21 05:24NickHNew Issue
2018-03-21 08:01user2Statusnew => confirmed
2019-11-23 05:02NickHNote Added: 0012401
2019-11-23 05:02NickHStatusconfirmed => closed
2019-11-23 05:02NickHAssigned To => NickH
2019-11-23 05:02NickHResolutionopen => suspended

Notes
(0012401)
NickH   
2019-11-23 05:01   
Migrated to https://gitlab.com/clearos/clearfoundation/app-file-scan/issues/1 [^]