From ea4a19fcc67a3f865c459260ee60c98eac8a7544 Mon Sep 17 00:00:00 2001 From: Developer Date: Fri, 20 Mar 2026 17:34:14 -0400 Subject: [PATCH] BUG FIX: ImunifyAV scanner using invalid 'scan' command ISSUE: ImunifyAV on-demand scanner was using invalid command syntax: imunify-antivirus malware on-demand scan --path=$path ERROR: 'scan' is not a valid choice Available commands: check-detached, list, queue, start, status, stop FIX: Changed to use correct 'queue put' command with positional path argument: imunify-antivirus malware on-demand queue put "$path" IMPACT: - ImunifyAV scans were failing with exit code 2 - Script was reporting 'complete' despite errors - New scanner generation will now use correct command TESTING: - Verified with: imunify-antivirus malware on-demand queue put --help - 'queue put' is the correct current API - Command now executes successfully (exit code 0) --- modules/security/malware-scanner.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/security/malware-scanner.sh b/modules/security/malware-scanner.sh index 4760dc8..8256805 100755 --- a/modules/security/malware-scanner.sh +++ b/modules/security/malware-scanner.sh @@ -982,8 +982,8 @@ for scanner in "${AVAILABLE_SCANNERS[@]}"; do echo " Scanning: $path" # Run scan with timeout to prevent hanging on status checks - # ImunifyAV scan - output to log file - timeout 7200 imunify-antivirus malware on-demand scan --path="$path" &>> "$LOG_DIR/imunify.log" & + # ImunifyAV scan - use 'queue put' command with path as positional argument + timeout 7200 imunify-antivirus malware on-demand queue put "$path" &>> "$LOG_DIR/imunify.log" & IMUNIFY_PID=$! # Monitor with simple timeout (don't try to parse imunify status which hangs)