ClamAV broken version check

Wednesday, September 3. 2008

If you've just built and installed the new version 0.94 of ClamAV (because it reminded you that your current version was out of date), and you're using the experimental features, it exposes a rather dumb bug that results in these messages in your freshclam log:
@4000000048be74fd0687f57c Software version from DNS: 0.94 @4000000048be74fd0688245c WARNING: Your ClamAV installation is OUTDATED! @4000000048be74fd06883014 WARNING: Local version: 0.94-exp Recommended version: 0.94
Apparently ClamAV's version comparison is not terribly clever, and the 'new feature' of marking experimental versions with '-exp' has tripped it up. I'm sure there are multiple workarounds, but I changed this in shared/misc.c:
#ifdef CL_EXPERIMENTAL /*#define EXP_VER "-exp"*/ #define EXP_VER #else #define EXP_VER #endif
as the EXP_VER string is what gets appended to the version number (apparently only for display purposes, but it does the trick). I then rebuilt it and now my log says:
@4000000048be848926da098c Software version from DNS: 0.94
Yay - no error!

Trackbacks


Trackback specific URI for this entry
    No Trackbacks

Comments


    No comments

Add Comment

You can use [geshi lang=lang_name [,ln={y|n}]][/geshi] tags to embed source code snippets.

To prevent automated Bots from commentspamming, please enter the string you see in the image below in the appropriate input box. Your comment will only be submitted if the strings match. Please ensure that your browser supports and accepts cookies, or your comment cannot be verified correctly.
CAPTCHA

    Submitted comments will be subject to moderation before being displayed.