Mailing List Archive

[clamav-users] MS Windows Explorer Context Menu sendto (clamscan.exe) - how to keep cmd box open to view results?
BACKGROUND:
MS Windows 7 SP1 x64 Pro and Home Premium. Also intending MS Windows 10,
Pro.

I used ClamWin for a few years as adjunct to Windows Defender mainly to
scan one or two isolated downloads but also in case Defender got
temporarily munged. But around February this year the signature updates
stopped. Someone posted a workaround with some substitute program files
at the ClamWin forum* but I decided I would try ClamAV's own official MS
Windows port (no GUI) so I installed "Traditional executable installer
that will install ClamAV in the "c:\Program Files\ directory", x64. I
am not using clamd.
* http://forums.clamwin.com/

THE QUESTION:
I don't want scan on access, just clamscan.exe to be invoked against
specified files via selecting them in Windows Explorer or similar e.g.
FreeCommander XE and then using Explorer context menu's sendto to direct
them to clamscan.exe. This works, but the cmd box which opens does not
stay open / static after the last message is printed to screen by
clamscan.exe. User may watch the output in real time and check if "OK"
comes up against specific files but I would prefer to do unattended
momentarily especially if more than a couple of files.

Are there any settings to tweak somewhere to accomplish this? I see there
are:
freshclam.conf
and
clamd.conf
but seemingly no *.conf for the executable clamscan.exe. Nothing in
folder conf_examples

(As for freshclam.exe I have created a Desktop icon to run it as
Administrator which works and one can monitor its progress in the cmd box
that opens, but again that closes on program termination - it's worked
every time over the last 3 months since installation so I have not
explored the logging capabilities, but ideally the cmd box should remain
open until dismissed by user).


I briefly investigated whether this is an MS Windows cmd box setting but I
can't find one offhand. There is cmd /k for MS Windows batch files but I'm
not using a batch file because it gets complicated if more than one file
is ot be selected and scanned (and seemingly parameters/arguments are
limited to nine: %1 to %9. In the 1990s days "DOS lets batch files
examine up to nine options typed after a batch file name at the DOS
prompt.") I've assumed modern cmd likewise.

There are probably more complexities with batch files which I don't want
to investigate at this time. I had tried the setting change for cmd in
Registry as per "Leonard" comment here

https://www.itechtics.com/3-ways-to-prevent-command-prompt-from-closing-after-running-commands/#comments

without changing the first line regarding batch files, but it made no
difference; the box just closed on program termination. (The Registry
value fwiw was changed to /k "%1" %* which I've changed back to default
of same ie. omitting /k).

How is this retention of open cmd box accomplished? Is there a
clamscan.conf which can be created to achieve this? (None I see in the
distribution). I haven't yet looked into logging options but it would be
inconvenient to use it routinely to check for positives; it's more
efficient to see the output of clamscan.exe and if toxic, discard the
scanned file and seek another source.

Or one for the developer list?

Regards,



Robert Jones











THIS E-MAIL AND ANY ATTACHED FILES ARE CONFIDENTIAL AND MAY BE LEGALLY
PRIVILEGED. If you are not the addressee, any disclosure,
reproduction, copying, distribution or other dissemination or use of
this communication is strictly prohibited. If you have received this
transmission in error please notify the sender immediately and then
delete this e-mail. All liability for viruses is excluded.

rwj@SDF.org
SDF Public Access UNIX System - http://SDF.org

_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml
Re: [clamav-users] MS Windows Explorer Context Menu sendto (clamscan.exe) - how to keep cmd box open to view results? [ In reply to ]
Hi there,

Disclaimer: I don't generally use Windows, and my experience of it is
more or less limited to fixing problems that clients have had with it.
That said, they've had a lot of problems over the years, and I know a
lot more about it than most Windows users, but I don't by any means
consider myself a "Windows expert"...

On Sun, 20 Jun 2021, RW Jones via clamav-users wrote:

> BACKGROUND:
> MS Windows 7 SP1 x64 Pro and Home Premium. Also intending MS Windows 10, Pro.

As I'm sure you know, Windows 7 reached its End Of Life 18 months ago.
You really shouldn't be using it any more, *especially* if you need to
ask questions like the questions you're asking here.

> I used ClamWin for a few years as adjunct to Windows Defender mainly to scan
> one or two isolated downloads but also in case Defender got temporarily
> munged. But around February this year the signature updates stopped.

IMHO ClamWin sucks. The version of ClamAV on which it is based was
stuck at 0.99 for years, even when ClamAV was at 0.103. It appears
ClamWin was finally updated after version 0.103.2 was released, but it
was a fraud - it was version 0.103.1, hacked to claim it is 0.103.2.
See the archives of this list for more information:

https://marc.info/?l=clamav-users&m=162298199126248&w=2

In case it isn't clear, given the obviously unsatisfactory history I
wouldn't touch ClamWin with a ten foot pole.

> I decided I would try ClamAV's own official MS Windows port (no GUI) ...

Good plan.

> THE QUESTION:
> I don't want scan on access, just clamscan.exe to be invoked against
> specified files via selecting them in Windows Explorer or similar e.g.
> FreeCommander XE and then using Explorer context menu's sendto to direct them
> to clamscan.exe. This works, but the cmd box which opens does not stay open
> / static after the last message is printed to screen by clamscan.exe. User
> may watch the output in real time and check if "OK" comes up against specific
> files but I would prefer to do unattended momentarily especially if more than
> a couple of files.
>
> Are there any settings to tweak somewhere to accomplish this?

I don't know about settings, but I'd guess you could do it easily with
a batch file. For example the batch file would call clamscan and then
call something which pauses until a key is pressed. You know the kind
of thing: "Press any key to continue." Having said that there must be
better ways - please read on.

> I see there
> are:
> freshclam.conf
> and
> clamd.conf
> but seemingly no *.conf for the executable clamscan.exe.

It's not the sort of thing that's appropriate for clamscan itself.

> (As for freshclam.exe I have created a Desktop icon to run it as
> Administrator which works and one can monitor its progress in the cmd box
> that opens, but again that closes on program termination - it's worked every
> time over the last 3 months since installation so I have not explored the
> logging capabilities, but ideally the cmd box should remain open until
> dismissed by user).

It's more usual to run freshclam unattended, on a schedule, and get it
to send its output to a log somewhere so that you can view the log at
your leisure. Once you have it working, it's rare to hit problems.

> I briefly investigated whether this is an MS Windows cmd box setting but I
> can't find one offhand. There is cmd /k for MS Windows batch files but I'm
> not using a batch file because it gets complicated if more than one file is
> ot be selected and scanned (and seemingly parameters/arguments are limited to
> nine: %1 to %9. In the 1990s days "DOS lets batch files examine up to nine
> options typed after a batch file name at the DOS prompt.") I've assumed
> modern cmd likewise.

There's a --file-list option to clamscan which makes it very easy to
scan multiple files. Just create a file containing the path list, one
path per line in the list. The 'path' means include (for Windows, the
drive letter if necessary and) all the parent directories, for example

C:/Users/Downloads/dodgy\ file.exe

Caveat: I can't remember that last time I did this on Windows, so you
might need to experiment with the directory separator character '/'; I
*think* '/' will work, but Windows of course uses '\' and you may need
to use '\\' instead. (The rest of the world uses a single backslash
as the 'escape' character to quote any 'special characters' used - and
the 'space' character is one of those, which is why I've quoted it in
my example filename with a space in it).

> How is this retention of open cmd box accomplished? Is there a clamscan.conf
> which can be created to achieve this?

As I said it isn't appropriate, but you might look here for example:

https://superuser.com/questions/306167/how-to-prevent-the-command-prompt-from-closing-after-execution

> I haven't yet looked into logging options but it would be inconvenient ...

Why don't you use the batch file idea, with the --log-file command
line option to clamscan, followed by running your favourite pager to
view the log file after the scan completes? Then you won't have to
wait for anything, you can do something else while the scan runs, and
you won't need to worry about boxes closing because the pager will
hold it open until you quit it.

Alternatively start a terminal window (or whatever it's called in
Windows thesedays) and just type "clamscan filename". That's what I'd
do, if forced (probably it would be at gunpoint) to use Windows.

> Or one for the developer list?

Nope.

One last thing. Well, almost last.

My impression is that you're downloading dodgy things from the Internet
and using ClamAV to scan them for threats before using the dodgy things
on your Windows box. This can only end in tears. You need to be aware
that no virus scanner is 100% effective. Over the years I've posted a
few estimates for ClamAV's success rate on this list. The most recent:

https://marc.info/?l=clamav-users&m=162379914711853&w=2

Another disclaimer is needed here. I only use ClamAV to scan mail, and
the characteristics of threats in the incoming mail here might be very
different from the characteristics of the threats in the dodgy things
that you're downloading. So you can't really read a lot into the actual
numbers in that post but you *can* and *should* take away that *nothing*
can detect each and every threat.

--

73,
Ged.

> THIS E-MAIL AND ANY ATTACHED FILES ARE CONFIDENTIAL AND MAY BE LEGALLY
> PRIVILEGED. If you are ...

Utter rubbish. :)

_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml
Re: [clamav-users] MS Windows Explorer Context Menu sendto (clamscan.exe) - how to keep cmd box open to view results? [ In reply to ]
Hi Robert,

You're correct that there is no config file for clamscan.exe. There also isn't any config option to have the command-line applications stay open if you're double-clicking them. ClamAV wasn't designed to be double-clicked. The problem you're facing is not really specific to ClamAV but really is for any command line application. But I think I can help...

I too initially stumbled on the "cmd /k" trick but you're right that multiple arguments get too complicated. It is instead pretty easy to do with PowerShell. Here are some scripts that should work for you for freshclam and clamscan. The "Pause" at the end will keep the window open until you press "Enter". These scripts should handle any number of arguments, and you can hardcode in some arguments like I have in ClamScan.ps1.

FreshClam.ps1:

param(
[Parameter(ValueFromRemainingArguments=$true)][String[]]$ScanArgs
)

$MyProgram = "C:\Program Files\ClamAV\freshclam.exe"
$Arguments = "$ScanArgs" # <-- feel free to add extra args if you want.

Write-Output "Running: $MyProgram $Arguments"
Start-Process $MyProgram -Wait -NoNewWindow -ArgumentList $Arguments
Pause


ClamScan.ps1:

param(
[Parameter(ValueFromRemainingArguments=$true)][String[]]$ScanArgs
)

$MyProgram = "C:\Program Files\ClamAV\clamscan.exe"
$Arguments = "--max-filesize=2000M --max-scansize=4000M $ScanArgs"

Write-Output "Running: $MyProgram $Arguments"
Start-Process $MyProgram -Wait -NoNewWindow -ArgumentList $Arguments
Pause


Please let me know how this works for you.

Cheers,
Micah


> -----Original Message-----
> From: clamav-users <clamav-users-bounces@lists.clamav.net> On Behalf Of RW
> Jones via clamav-users
> Sent: Sunday, June 20, 2021 7:00 AM
> To: clamav-users@lists.clamav.net
> Cc: RW Jones <rwj@SDF.ORG>
> Subject: [clamav-users] MS Windows Explorer Context Menu sendto
> (clamscan.exe) - how to keep cmd box open to view results?
>
>
> BACKGROUND:
> MS Windows 7 SP1 x64 Pro and Home Premium. Also intending MS Windows
> 10, Pro.
>
> I used ClamWin for a few years as adjunct to Windows Defender mainly to scan
> one or two isolated downloads but also in case Defender got temporarily
> munged. But around February this year the signature updates stopped.
> Someone posted a workaround with some substitute program files at the
> ClamWin forum* but I decided I would try ClamAV's own official MS Windows
> port (no GUI) so I installed "Traditional executable installer that will install
> ClamAV in the "c:\Program Files\ directory", x64. I am not using clamd.
> * http://forums.clamwin.com/
>
> THE QUESTION:
> I don't want scan on access, just clamscan.exe to be invoked against specified
> files via selecting them in Windows Explorer or similar e.g.
> FreeCommander XE and then using Explorer context menu's sendto to direct
> them to clamscan.exe. This works, but the cmd box which opens does not stay
> open / static after the last message is printed to screen by clamscan.exe. User
> may watch the output in real time and check if "OK"
> comes up against specific files but I would prefer to do unattended
> momentarily especially if more than a couple of files.
>
> Are there any settings to tweak somewhere to accomplish this? I see there
> are:
> freshclam.conf
> and
> clamd.conf
> but seemingly no *.conf for the executable clamscan.exe. Nothing in
> folder conf_examples
>
> (As for freshclam.exe I have created a Desktop icon to run it as Administrator
> which works and one can monitor its progress in the cmd box that opens, but
> again that closes on program termination - it's worked every time over the last
> 3 months since installation so I have not explored the logging capabilities, but
> ideally the cmd box should remain open until dismissed by user).
>
>
> I briefly investigated whether this is an MS Windows cmd box setting but I can't
> find one offhand. There is cmd /k for MS Windows batch files but I'm not using
> a batch file because it gets complicated if more than one file is ot be selected
> and scanned (and seemingly parameters/arguments are limited to nine: %1 to
> %9. In the 1990s days "DOS lets batch files examine up to nine options typed
> after a batch file name at the DOS
> prompt.") I've assumed modern cmd likewise.
>
> There are probably more complexities with batch files which I don't want to
> investigate at this time. I had tried the setting change for cmd in Registry as
> per "Leonard" comment here
>
> https://www.itechtics.com/3-ways-to-prevent-command-prompt-from-closing-
> after-running-commands/#comments
>
> without changing the first line regarding batch files, but it made no difference;
> the box just closed on program termination. (The Registry value fwiw was
> changed to /k "%1" %* which I've changed back to default of same ie. omitting
> /k).
>
> How is this retention of open cmd box accomplished? Is there a clamscan.conf
> which can be created to achieve this? (None I see in the distribution). I haven't
> yet looked into logging options but it would be inconvenient to use it routinely
> to check for positives; it's more efficient to see the output of clamscan.exe and
> if toxic, discard the scanned file and seek another source.
>
> Or one for the developer list?
>
> Regards,
>
>
>
> Robert Jones
>
>
>
>
>
>
>
>
>
>
>
> THIS E-MAIL AND ANY ATTACHED FILES ARE CONFIDENTIAL AND MAY BE
> LEGALLY PRIVILEGED. If you are not the addressee, any disclosure, reproduction,
> copying, distribution or other dissemination or use of this communication is
> strictly prohibited. If you have received this transmission in error please notify
> the sender immediately and then delete this e-mail. All liability for viruses is
> excluded.
>
> rwj@SDF.org
> SDF Public Access UNIX System - http://SDF.org
>
> _______________________________________________
>
> clamav-users mailing list
> clamav-users@lists.clamav.net
> https://lists.clamav.net/mailman/listinfo/clamav-users
>
>
> Help us build a comprehensive ClamAV guide:
> https://github.com/vrtadmin/clamav-faq
>
> http://www.clamav.net/contact.html#ml

_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml
Re: [clamav-users] MS Windows Explorer Context Menu sendto (clamscan.exe) - how to keep cmd box open to view results? [ In reply to ]
Two more things...

In the scripts, "Pause" is supposed to be on a new line, not on the same line as "Start-Process".

Also I forgot to mention that there is a new version of ClamWin released June 7th that should work okay: https://clamwin.com/content/view/251/1/

Regards,
Micah


> -----Original Message-----
> From: clamav-users <clamav-users-bounces@lists.clamav.net> On Behalf Of
> Micah Snyder (micasnyd) via clamav-users
> Sent: Sunday, June 20, 2021 12:29 PM
> To: ClamAV users ML <clamav-users@lists.clamav.net>
> Cc: Micah Snyder (micasnyd) <micasnyd@cisco.com>
> Subject: Re: [clamav-users] MS Windows Explorer Context Menu sendto
> (clamscan.exe) - how to keep cmd box open to view results?
>
> Hi Robert,
>
> You're correct that there is no config file for clamscan.exe. There also isn't any
> config option to have the command-line applications stay open if you're
> double-clicking them. ClamAV wasn't designed to be double-clicked. The
> problem you're facing is not really specific to ClamAV but really is for any
> command line application. But I think I can help...
>
> I too initially stumbled on the "cmd /k" trick but you're right that multiple
> arguments get too complicated. It is instead pretty easy to do with PowerShell.
> Here are some scripts that should work for you for freshclam and clamscan.
> The "Pause" at the end will keep the window open until you press "Enter".
> These scripts should handle any number of arguments, and you can hardcode in
> some arguments like I have in ClamScan.ps1.
>
> FreshClam.ps1:
>
> param(
> [Parameter(ValueFromRemainingArguments=$true)][String[]]$ScanArgs
> )
>
> $MyProgram = "C:\Program Files\ClamAV\freshclam.exe"
> $Arguments = "$ScanArgs" # <-- feel free to add extra args if you want.
>
> Write-Output "Running: $MyProgram $Arguments"
> Start-Process $MyProgram -Wait -NoNewWindow -ArgumentList $Arguments
> Pause
>
>
> ClamScan.ps1:
>
> param(
> [Parameter(ValueFromRemainingArguments=$true)][String[]]$ScanArgs
> )
>
> $MyProgram = "C:\Program Files\ClamAV\clamscan.exe"
> $Arguments = "--max-filesize=2000M --max-scansize=4000M $ScanArgs"
>
> Write-Output "Running: $MyProgram $Arguments"
> Start-Process $MyProgram -Wait -NoNewWindow -ArgumentList $Arguments
> Pause
>
>
> Please let me know how this works for you.
>
> Cheers,
> Micah
>
>
> > -----Original Message-----
> > From: clamav-users <clamav-users-bounces@lists.clamav.net> On Behalf
> > Of RW Jones via clamav-users
> > Sent: Sunday, June 20, 2021 7:00 AM
> > To: clamav-users@lists.clamav.net
> > Cc: RW Jones <rwj@SDF.ORG>
> > Subject: [clamav-users] MS Windows Explorer Context Menu sendto
> > (clamscan.exe) - how to keep cmd box open to view results?
> >
> >
> > BACKGROUND:
> > MS Windows 7 SP1 x64 Pro and Home Premium. Also intending MS Windows
> > 10, Pro.
> >
> > I used ClamWin for a few years as adjunct to Windows Defender mainly
> > to scan one or two isolated downloads but also in case Defender got
> > temporarily munged. But around February this year the signature updates
> stopped.
> > Someone posted a workaround with some substitute program files at the
> > ClamWin forum* but I decided I would try ClamAV's own official MS
> > Windows port (no GUI) so I installed "Traditional executable installer
> > that will install ClamAV in the "c:\Program Files\ directory", x64. I am not
> using clamd.
> > * http://forums.clamwin.com/
> >
> > THE QUESTION:
> > I don't want scan on access, just clamscan.exe to be invoked against
> > specified files via selecting them in Windows Explorer or similar e.g.
> > FreeCommander XE and then using Explorer context menu's sendto to
> > direct them to clamscan.exe. This works, but the cmd box which opens
> > does not stay open / static after the last message is printed to
> > screen by clamscan.exe. User may watch the output in real time and check if
> "OK"
> > comes up against specific files but I would prefer to do unattended
> > momentarily especially if more than a couple of files.
> >
> > Are there any settings to tweak somewhere to accomplish this? I see
> > there
> > are:
> > freshclam.conf
> > and
> > clamd.conf
> > but seemingly no *.conf for the executable clamscan.exe. Nothing in
> > folder conf_examples
> >
> > (As for freshclam.exe I have created a Desktop icon to run it as
> > Administrator which works and one can monitor its progress in the cmd
> > box that opens, but again that closes on program termination - it's
> > worked every time over the last
> > 3 months since installation so I have not explored the logging
> > capabilities, but ideally the cmd box should remain open until dismissed by
> user).
> >
> >
> > I briefly investigated whether this is an MS Windows cmd box setting
> > but I can't find one offhand. There is cmd /k for MS Windows batch
> > files but I'm not using a batch file because it gets complicated if
> > more than one file is ot be selected and scanned (and seemingly
> > parameters/arguments are limited to nine: %1 to %9. In the 1990s days
> > "DOS lets batch files examine up to nine options typed after a batch
> > file name at the DOS
> > prompt.") I've assumed modern cmd likewise.
> >
> > There are probably more complexities with batch files which I don't
> > want to investigate at this time. I had tried the setting change for
> > cmd in Registry as per "Leonard" comment here
> >
> > https://www.itechtics.com/3-ways-to-prevent-command-prompt-from-closin
> > g-
> > after-running-commands/#comments
> >
> > without changing the first line regarding batch files, but it made no
> > difference; the box just closed on program termination. (The Registry
> > value fwiw was changed to /k "%1" %* which I've changed back to
> > default of same ie. omitting /k).
> >
> > How is this retention of open cmd box accomplished? Is there a
> > clamscan.conf which can be created to achieve this? (None I see in
> > the distribution). I haven't yet looked into logging options but it
> > would be inconvenient to use it routinely to check for positives; it's
> > more efficient to see the output of clamscan.exe and if toxic, discard the
> scanned file and seek another source.
> >
> > Or one for the developer list?
> >
> > Regards,
> >
> >
> >
> > Robert Jones
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > THIS E-MAIL AND ANY ATTACHED FILES ARE CONFIDENTIAL AND MAY BE
> LEGALLY
> > PRIVILEGED. If you are not the addressee, any disclosure,
> > reproduction, copying, distribution or other dissemination or use of
> > this communication is strictly prohibited. If you have received this
> > transmission in error please notify the sender immediately and then
> > delete this e-mail. All liability for viruses is excluded.
> >
> > rwj@SDF.org
> > SDF Public Access UNIX System - http://SDF.org
> >
> > _______________________________________________
> >
> > clamav-users mailing list
> > clamav-users@lists.clamav.net
> > https://lists.clamav.net/mailman/listinfo/clamav-users
> >
> >
> > Help us build a comprehensive ClamAV guide:
> > https://github.com/vrtadmin/clamav-faq
> >
> > http://www.clamav.net/contact.html#ml
>
> _______________________________________________
>
> clamav-users mailing list
> clamav-users@lists.clamav.net
> https://lists.clamav.net/mailman/listinfo/clamav-users
>
>
> Help us build a comprehensive ClamAV guide:
> https://github.com/vrtadmin/clamav-faq
>
> http://www.clamav.net/contact.html#ml

_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml
Re: [clamav-users] MS Windows Explorer Context Menu sendto (clamscan.exe) - how to keep cmd box open to view results? [ In reply to ]
Thanks for the input and in particular the heads-up on logfiles which imo
is the key to a simple, elegant solution which avoids batch files and
tiresome cmd box typing. I did some more research after the replies to my
post but it's been interrupted by other stuff; so as the following works
for me, I'll go with the following as one possible solution.


(In neither case will the cmd box stay open by using the settings in (A)
and (B) below but the ***objective of seeing program output*** is in each
case secured by viewing the log file in the chosen location, while in the
case of clamscan.exe also preserving the convenience of selecting
multiple, even non-contiguous, operand files in Explorer and sending them
to clamscan.exe via its Context Menu's sendto). I've assumed Administrator
privileges are required to do all the following whether or not that is
actually so. Adjust filenames/locations to taste; also the following
assumes a default ClamAV installation.


~~~

(A) freshclam.exe desktop icon settings:

Create a desktop icon for freshclam.exe using one or other of the various
means available.
Right click the desktop icon and set Properties as:

"C:\Program Files\ClamAV\freshclam.exe" --log=c:\[some-folder]\freshclam.log

Start in: "C:\Program Files\ClamAV"

After running via clicking the desktop icon, freshclam's log of operations
is found in your 'favourite' / convenient directory which you specified as
per the above. Likewise the results of scanning files by clamscan.exe are
logged in the location chosen as per the below.


(B) clamscan.exe and Explorer/ Context Menu sendto settings:

Add clamscan.exe to the sendto list in Explorer's Context Menu using one
or other of the various means available.

Navigate to view:

C:\Users\[admin]\AppData\Roaming\Microsoft\Windows\SendTo\clamscan.exe.lnk

Right click clamscan.exe.lnk and set Properties as:

"C:\Program Files\ClamAV\clamscan.exe" --log=c:\[some-folder]\clamscan.log

Start in: "C:\Program Files\ClamAV\"

~~~

Freshclam alerted me to new ClamAV version 0.103.3 so I've also updated to
that.

Interesting to read concerning ClamWin's creative versioning; I'd just
decided to go with ClamAV's own MS Windows version as closer to source so
to speak.

The Windows 7 machines were of course hardened using a couple of programs
designed for the purpose as well as utilising modiified HOSTS etc etc.;
the plan having been to upgrade to a dual-boot with the next Debian major
release, stable/Xfce/nonfree when it emerges in July or August. (The i386
/ w32 version of current runs pretty well on a travelling laptop with only
a celeron 1197.030 MHz processor and 2GB RAM). Maybe I'll consider devuan
but offhand I don't know what its release timing will be following on the
new Debian major version.

ClamAV is also going on the Windows 10 laptop.


Regards,


Robert Jones



On Sun, 20 Jun 2021, G.W. Haywood via clamav-users wrote:

> Date: Sun, 20 Jun 2021 16:29:41 +0100 (BST)
> From: G.W. Haywood via clamav-users <clamav-users@lists.clamav.net>
> To: RW Jones via clamav-users <clamav-users@lists.clamav.net>
> Cc: G.W. Haywood <clamav@jubileegroup.co.uk>
> Subject: Re: [clamav-users] MS Windows Explorer Context Menu sendto
> (clamscan.exe) - how to keep cmd box open to view results?
>
> Hi there,
>
> Disclaimer: I don't generally use Windows, and my experience of it is
> more or less limited to fixing problems that clients have had with it.
> That said, they've had a lot of problems over the years, and I know a
> lot more about it than most Windows users, but I don't by any means
> consider myself a "Windows expert"...
>
> On Sun, 20 Jun 2021, RW Jones via clamav-users wrote:
>
>> BACKGROUND:
>> MS Windows 7 SP1 x64 Pro and Home Premium. Also intending MS Windows 10,
>> Pro.
[snip]








THIS E-MAIL AND ANY ATTACHED FILES ARE CONFIDENTIAL AND MAY BE LEGALLY
PRIVILEGED. If you are not the addressee, any disclosure,
reproduction, copying, distribution or other dissemination or use of
this communication is strictly prohibited. If you have received this
transmission in error please notify the sender immediately and then
delete this e-mail. All liability for viruses is excluded.

rwj@SDF.org
SDF Public Access UNIX System - http://SDF.org

_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml
Re: [clamav-users] MS Windows Explorer Context Menu sendto (clamscan.exe) - how to keep cmd box open to view results? [ In reply to ]
Thanks very much for the input.

I did examine (for starters) the .ps1 clamscan script file but owing to my
pretty much total ignorance of Powershell syntax and time being
exceptionally tight over the last couple of days I haven't yet got to
grips with it because it seems I will have to research script privilege
change and some other stuff; plus I couldn't see, absent comments to the
code, what the operand file/s were. (That's probably just me being
incoherent btw).

Anyway I now have what is for me a neat and workable solution based on
simple use of the two programs' logs and avoiding batch files and cmd line
typing (doubtless just one among many potentials I could explore, time
permitting) - please see my reply to G.W. Haywood's response to my initial
posting.

I will probably stick with ClamAV now, especially given the remarks re:
versioning of ClamWin that were earlier referenced by you in your quoted
post here:

https://marc.info/?l=clamav-users&m=162298199126248&w=2


Regards,




Robert Jones



On Sun, 20 Jun 2021, Micah Snyder (micasnyd) via clamav-users wrote:

> Date: Sun, 20 Jun 2021 21:55:09 +0000
> From: "Micah Snyder (micasnyd) via clamav-users"
> <clamav-users@lists.clamav.net>
> To: ClamAV users ML <clamav-users@lists.clamav.net>
> Cc: "Micah Snyder (micasnyd)" <micasnyd@cisco.com>
> Subject: Re: [clamav-users] MS Windows Explorer Context Menu sendto
> (clamscan.exe) - how to keep cmd box open to view results?
>
> Two more things...
>
> In the scripts, "Pause" is supposed to be on a new line, not on the same
> line as "Start-Process".
>
> Also I forgot to mention that there is a new version of ClamWin released
> June 7th that should work okay: https://clamwin.com/content/view/251/1/
>
> Regards,
> Micah
>
>
>> -----Original Message-----
>> From: clamav-users <clamav-users-bounces@lists.clamav.net> On Behalf Of
>> Micah Snyder (micasnyd) via clamav-users
>> Sent: Sunday, June 20, 2021 12:29 PM
>> To: ClamAV users ML <clamav-users@lists.clamav.net>
>> Cc: Micah Snyder (micasnyd) <micasnyd@cisco.com>
>> Subject: Re: [clamav-users] MS Windows Explorer Context Menu sendto
>> (clamscan.exe) - how to keep cmd box open to view results?
>>
>> Hi Robert,
>>
>> You're correct that there is no config file for clamscan.exe. There also isn't any
>> config option to have the command-line applications stay open if you're
>> double-clicking them. ClamAV wasn't designed to be double-clicked. The
>> problem you're facing is not really specific to ClamAV but really is for any
>> command line application. But I think I can help...
>>
[snip]











THIS E-MAIL AND ANY ATTACHED FILES ARE CONFIDENTIAL AND MAY BE LEGALLY
PRIVILEGED. If you are not the addressee, any disclosure,
reproduction, copying, distribution or other dissemination or use of
this communication is strictly prohibited. If you have received this
transmission in error please notify the sender immediately and then
delete this e-mail. All liability for viruses is excluded.

rwj@SDF.org
SDF Public Access UNIX System - http://SDF.org

_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml