FreshClam: use the configured outdated hook in daemon mode (#1770)

FreshClam's non-daemon update path passes OnOutdatedExecute to the database update helper when the outdated-version hook is enabled. The daemon update loop checked the OnOutdatedExecute option but accidentally passed the OnUpdateExecute command string instead.

This could cause daemon-mode outdated-version events to run the update hook, or to run no hook when only OnOutdatedExecute was configured. Pass the OnOutdatedExecute command string in the daemon path so both update modes use the same hook selection.

Credit: Nir Yehoshua, Cipher Security Labs

CLAM-3025
This commit is contained in:
Val S.
2026-08-19 19:07:31 -04:00
committed by GitHub
parent 6698cd2c05
commit f7f5d96816
+1 -1
View File
@@ -2092,7 +2092,7 @@ int main(int argc, char **argv)
bPrivate ? 0 : optget(opts, "ScriptedUpdates")->enabled,
bPrune,
optget(opts, "OnUpdateExecute")->enabled ? optget(opts, "OnUpdateExecute")->strarg : NULL,
optget(opts, "OnOutdatedExecute")->enabled ? optget(opts, "OnUpdateExecute")->strarg : NULL,
optget(opts, "OnOutdatedExecute")->enabled ? optget(opts, "OnOutdatedExecute")->strarg : NULL,
optget(opts, "daemon")->enabled,
optget(opts, "NotifyClamd")->active ? optget(opts, "NotifyClamd")->strarg : NULL,
&fc_context);