ClamWin Free Antivirus
Support and Discussion Forums
 problem with --move switch with clamscan
ih8gates

 Joined: 04 Feb 2006 Posts: 5
 Posted: Sat Feb 04, 2006 7:42 pm
when using the --move swithc, clamscan appears to simply wrap a "move" command around a file it finds, passing it the file that is infected. it appears, though, that clamscan sends it the entire filename with path as the 2nd argument (the "to" location). so it tries to do, essentially:

move "c:\test\infected.txt" "c:\quarantine\c:\test\infected.txt"

which of course, doesn't work. i get errors like:

i've tried different options for defining the --move directory, but none have worked:

c:\quarantine
c:\quarantine\
c:/quarantine

has anyone had success with this?
alch

 Joined: 27 Nov 2005 Posts: 1748
 Posted: Sun Feb 05, 2006 5:41 am
Clamwin uses --move switch successfully:
--move="/cygdrive/c/quarantine"
ih8gates

 Joined: 04 Feb 2006 Posts: 5
 Posted: Sun Feb 05, 2006 2:42 pm
is that to say that clamscan isn't supported as part of the clamwin project?

i'm using clamscan since in this case i need a CLI. does clamwin support a command line interface?
alch

 Joined: 27 Nov 2005 Posts: 1748
 Posted: Mon Feb 06, 2006 12:44 am
 Quote: is that to say that clamscan isn't supported as part of the clamwin project? i'm using clamscan since in this case i need a CLI. does clamwin support a command line interface?

No, what I am saying that clamwin calls clamscan.exe with this parameter successfully. Try to use the quotation marks and /cygdrive/c notation.
--move="/cygdrive/c/quarantine"
ih8gates

 Joined: 04 Feb 2006 Posts: 5
 Posted: Mon Feb 06, 2006 2:21 pm
hhmm. strange. i still get the same error. i'm using the following in my batch file:

"C:\Program Files\ClamWin\bin\clamscan.exe" --infected --no-summary --bell --move="c:\quarantine" --database="c:\Documents and Settings\All Users\.clamwin\db" %1

i was just trying to get clamscan to work with the download statusbar plugin in firefox but will, as recommended in your other recent post, switch over to using 'firefox glue' instead.
alch

 Joined: 27 Nov 2005 Posts: 1748
 Posted: Mon Feb 06, 2006 2:52 pm
"C:\Program Files\ClamWin\bin\clamscan.exe" --infected --no-summary --bell --move="/cygdrive/c/quarantine" --database="/cygdrive/c/Documents and Settings/All Users/.clamwin/db" %1

However clamwin glue for firefox will display a messagebox which is better then a beep.

ih8gates

 Joined: 04 Feb 2006 Posts: 5
 Posted: Tue Feb 07, 2006 9:04 pm

yikes! thanks for the tip.

i guess that's inherent in the way that FF passes info from it's download manager?
alch