clamav icon indicating copy to clipboard operation
clamav copied to clipboard

Freshclam generating spurious warnings for content not modified HTTP 304

Open akissa opened this issue 2 years ago • 3 comments

Describe the bug

Commit https://github.com/Cisco-Talos/clamav/commit/5a343f6448945bcc4883ed4894493a4f8779d733 introduced logging of HTTP codes, this is generating spurious warnings when downloading custom signatures and the signature has not changed.

The offending code is this https://github.com/Cisco-Talos/clamav/blob/5c413cefb546579eeca5599d8b0f509e01402342/libfreshclam/libfreshclam_internal.c#L1303

How to reproduce the problem

Run freshclam on the just release 1.0.3. The following will be logged to standard error and to file.

Aug 29 13:33:36 myhost freshclam[14596]: ******* RESULT 304, SIZE: 0 *******

Attachments

N/A

akissa avatar Aug 29 '23 12:08 akissa

@akissa freshclam update is working as expected and should give http_code 304 in case of "no database change".

We will work on removing this logger in the upcoming release. Will update you on this.

rsundriyal avatar Sep 01 '23 17:09 rsundriyal

@rsundriyal That is not the issue, the issue is it is logging what is a non error to stderr. When run under cron, because there is output on stderr you get an email for each run containing this bogus log messages.

akissa avatar Sep 02 '23 04:09 akissa

I also have this warnings, after update from 1.0.0 to 1.0.2, no change on configuration.

dddns avatar Sep 03 '23 19:09 dddns