Mailing List Archive

[clamav-users] clamscan vs clamdscan
Hi altogether,

I´ve got a question regarding *clamscan* vs *clamdscan*.

My system is Linux/BodhiLinux 5.1.0 in a VM.
As antivirus-software I installed *clamav*:

/sudo apt-get install clamav clamav-freshclam/

Scanning procedure is good although a bit slow. So in addition to that I
installed the service *clamd*:

/sudo apt-get install clamav-daemon/

Scanning is much faster now.

My question is: Is it alright to have  *clamav* and *clamav-daemon*
installed alongside each other?
So that I can run  either "clamscan somefile"  or  "clamdscan somefile"?

Thanks a lot in advance.

Greetings.
Rosika
Re: [clamav-users] clamscan vs clamdscan [ In reply to ]
Hi there,

On Sat, 9 May 2020, Christian wrote:

> ... Is it alright to have? *clamav* and *clamav-daemon*
> installed alongside each other?
> So that I can run? either "clamscan somefile"? or? "clamdscan somefile"?

You should really have asked that question on a mailing list for your
Linux distribution, not on this list, because if you install ClamAV
from a distribution it's done differently from how it's done if you
install from the original sources. But if you read for example

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

I think it will tell you what you want to know.

See also

http://www.clamav.net/documents/

and for example

http://www.catb.org/~esr/faqs/smart-questions.html

--

73,
Ged.

_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
Dear Christian,

It's normal that scanning with clamdscan takes a shorter time than
clamscan because the virus databases is already loaded (since it's a
daemon) and ready for action. For testing purposes(debugging, etc) you
can use clamscan for all other purposes use clamdscan where you don't
need to wait to load the virus database on each run.

---
Best regards,
Iulian

On 2020-05-09 18:43, Christian wrote:

> Hi altogether,
>
> I´ve got a question regarding clamscan vs clamdscan.
>
> My system is Linux/BodhiLinux 5.1.0 in a VM.
> As antivirus-software I installed clamav:
>
> _sudo apt-get install clamav clamav-freshclam_
>
> Scanning procedure is good although a bit slow. So in addition to that I installed the service clamd:
>
> _sudo apt-get install clamav-daemon_
>
> Scanning is much faster now.
>
> My question is: Is it alright to have clamav and clamav-daemon installed alongside each other?
> So that I can run either "clamscan somefile" or "clamdscan somefile"?
>
> Thanks a lot in advance.
>
> Greetings.
> Rosika
>
> _______________________________________________
>
> 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] clamscan vs clamdscan [ In reply to ]
On our mailserver, we run clamdscan, since mail arrives frequently (!).

On my workstation, I have switched to just using clamscan. Clamdscan
now uses so much resident memory (~ 1 GB), that even on my 32 GB
workstation I found it unreasonable to permanently tie up that much RAM
when I only scan things a couple of times per day. I'd rather wait the
extra few (10?) seconds.

This makes room for my many Firefox windows, each with many tabs, which
altogether eat much more RAM (about 6.5 GB resident, 46 GB virtual).
But I use them far more often, and need their rapid response.


On Sat, 09 May 2020 21:15:35 +0300
iulian stan via clamav-users <clamav-users@lists.clamav.net> wrote:

> Dear Christian,
>
> It's normal that scanning with clamdscan takes a shorter time than
> clamscan because the virus databases is already loaded (since it's a
> daemon) and ready for action. For testing purposes(debugging, etc) you
> can use clamscan for all other purposes use clamdscan where you don't
> need to wait to load the virus database on each run.
>
> ---
> Best regards,
> Iulian
>
> On 2020-05-09 18:43, Christian wrote:
>
> > Hi altogether,
> >
> > I´ve got a question regarding clamscan vs clamdscan.
> >
> > My system is Linux/BodhiLinux 5.1.0 in a VM.
> > As antivirus-software I installed clamav:
> >
> > _sudo apt-get install clamav clamav-freshclam_
> >
> > Scanning procedure is good although a bit slow. So in addition to that I installed the service clamd:
> >
> > _sudo apt-get install clamav-daemon_
> >
> > Scanning is much faster now.
> >
> > My question is: Is it alright to have clamav and clamav-daemon installed alongside each other?
> > So that I can run either "clamscan somefile" or "clamdscan somefile"?
> >
> > Thanks a lot in advance.
> >
> > Greetings.
> > Rosika


_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
Hi there,

On Sat, 9 May 2020, Paul Kosinski via clamav-users wrote:

> On our mailserver, we run clamdscan, since mail arrives frequently (!).

On a mail server most people would use a milter, e.g. clamav-milter,
which is part of the ClamAV package.

The use of milters offers many benefits. It enables a mail server to
inspect a message during the SMTP conversation, allowing the server
(for example) to reject unwanted mail at the earliest possible time,
before accepting the message. This can avoid wasting resources, and
leaks of information to the sender such as the fact that a recipient
address actually exists and accepts mail (valuable information to the
typical spammer, because it is saleable).

--

73,
Ged.

_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
Citeren "G.W. Haywood via clamav-users" <clamav-users@lists.clamav.net>:

> Hi there,
>
> On Sat, 9 May 2020, Paul Kosinski via clamav-users wrote:
>
>> On our mailserver, we run clamdscan, since mail arrives frequently (!).
>
> On a mail server most people would use a milter, e.g. clamav-milter,
> which is part of the ClamAV package.

It depends. There are other ways to filter before accepting messages.
I use the proxy filter in Postfix to scan messages with Amavisd (which
will scan for both viruses and spam). No milter involved.

> The use of milters offers many benefits. It enables a mail server to
> inspect a message during the SMTP conversation, allowing the server
> (for example) to reject unwanted mail at the earliest possible time,
> before accepting the message. This can avoid wasting resources, and
> leaks of information to the sender such as the fact that a recipient
> address actually exists and accepts mail (valuable information to the
> typical spammer, because it is saleable).




_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
Hi there,

On Sat, 9 May 2020, iulian stan via clamav-users wrote:

> It's normal that scanning with clamdscan takes a shorter time than
> clamscan because the virus databases is already loaded (since it's a
> daemon) and ready for action. For testing purposes(debugging, etc) you
> can use clamscan for all other purposes use clamdscan where you don't
> need to wait to load the virus database on each run.

Do be aware that the configurations used by clamscan and clamdscan
will in most cases be different, as will the permissions. Refer to
the full documentation for configuration details and make sure that
you understand the implications of the user and group permissions
for the real and effective uids and gids of the scanning processes.

--

73,
Ged.

_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
Dear Iulian ,


thanks a lot for your answer.

That sounds good. So I take it that I can have clamav and clamav-daemon
installed at the same time and use
either of them.
That´s really cool.

Thank you again for your confirmation and explanation.

There´s just one question remaining which concerns the EICAR-test-file.
For that I post a separate e-mail.

Greetings.
Rosika and Christian

Am 09.05.20 um 20:15 schrieb iulian stan:
> Dear Christian,
> It's normal that scanning with clamdscan takes a shorter time than
> clamscan because the virus databases is already loaded (since it's a
> daemon) and ready for action. For testing purposes(debugging, etc) you
> can use clamscan for all other purposes use clamdscan where you don't
> need to wait to load the virus database on each run.
>
> ---
> Best regards,
> Iulian



_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
>On Sat, 9 May 2020, Paul Kosinski via clamav-users wrote:
>>On our mailserver, we run clamdscan, since mail arrives frequently (!).

On 10.05.20 09:33, G.W. Haywood via clamav-users wrote:
>On a mail server most people would use a milter, e.g. clamav-milter,
>which is part of the ClamAV package.

however, clamav-milter uses clamd so it needs clamd running just as
clamdscan. amavis does the same.

>The use of milters offers many benefits. It enables a mail server to
>inspect a message during the SMTP conversation, allowing the server
>(for example) to reject unwanted mail at the earliest possible time,
>before accepting the message. This can avoid wasting resources, and
>leaks of information to the sender such as the fact that a recipient
>address actually exists and accepts mail (valuable information to the
>typical spammer, because it is saleable).

--
Matus UHLAR - fantomas, uhlar@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Silvester Stallone: Father of the RISC concept.

_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
>>On Sat, 9 May 2020, Paul Kosinski via clamav-users wrote:
>>>On our mailserver, we run clamdscan, since mail arrives frequently (!).

>Citeren "G.W. Haywood via clamav-users" <clamav-users@lists.clamav.net>:
>>On a mail server most people would use a milter, e.g. clamav-milter,
>>which is part of the ClamAV package.

On 10.05.20 10:51, Arjen de Korte via clamav-users wrote:
>It depends. There are other ways to filter before accepting messages.
>I use the proxy filter in Postfix to scan messages with Amavisd (which
>will scan for both viruses and spam). No milter involved.

I prever to use amavisd-milter, e.g. because it can be combined with other
milters, while smtpd proxy has problems combining.

And, also, milter only adds one Received: header and makes looking through
logs easier.

--
Matus UHLAR - fantomas, uhlar@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
I drive way too fast to worry about cholesterol.

_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
On milters:

Our email handling is a two stage mechanism. Our rented server at our
public IP address is a small, cheap VM (with no ports blocked, of
course) which runs Postfix and Apache. There is not enough RAM to also
run clamd, so we simply use Postfix's builtin filter mechanisms, like
SMTP protocol checking, sending domain vs sending IP matching, rate
limiting etc., to reject *lots* of obvious spam.

Any email that is actually received by this Postfix is *immediately*
forwarded, via an encrypted tunnel, to our second Postfix, which is on
our LAN. This second Postfix immediately "delivers" the email to our local
Dovecot, which is set up for local IMAP access. On the way, the email
is filtered via clamd and our Bayesian spam checker. We also make
extensive use of Postfix's 'valias' feature to allow the us to create
multiple email names for a given real user. This is handy when setting
up Website logins etc. (This posting from <clamav-users@iment.com> is
an example of that.)

Only email to valid user names is delivered, the rest is discarded
right away. (You might be surprised how much email to made-up user
names arrives. These are mapped by valias's catch-all to "nobody" and
then flushed.) Email that is deemed to be spam is actually delivered
to a second instance of Dovecot, where it is sorted by year and month
and only then by the ultimate real user. This allows us to keep for
review email that only appears to be spam.

The IMAP access is completely local to our LAN, so our email (as a
whole) is not permanently stored on any physically public servers.
Also, any purely intra-domain email never leaves our LAN.

A final feature in our email handling is that any mail we send out has
its destination address automatically recorded in a local database and
any reply from that email address never gets routed to the spam bucket,
but simply has a header added indicating it's a Reply. (This database
also has a local Web interface to explicitly Query, Forget, Allow or
Block an email address.)

P.S. G.W Haywood ought to consider something like our email reply
database. When I replied to an email he sent me from what seemed to be
his private email address (i.e., not his clamav address), it was held
for a few days at his MTA, "timed out" and was then bounced -- twice.



On Sun, 10 May 2020 09:33:11 +0100 (BST)
"G.W. Haywood via clamav-users" <clamav-users@lists.clamav.net> wrote:

> Hi there,
>
> On Sat, 9 May 2020, Paul Kosinski via clamav-users wrote:
>
> > On our mailserver, we run clamdscan, since mail arrives frequently (!).
>
> On a mail server most people would use a milter, e.g. clamav-milter,
> which is part of the ClamAV package.
>
> The use of milters offers many benefits. It enables a mail server to
> inspect a message during the SMTP conversation, allowing the server
> (for example) to reject unwanted mail at the earliest possible time,
> before accepting the message. This can avoid wasting resources, and
> leaks of information to the sender such as the fact that a recipient
> address actually exists and accepts mail (valuable information to the
> typical spammer, because it is saleable).
>

_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
Hi there,

On Sun, 10 May 2020, Paul Kosinski via clamav-users wrote:

> Our email handling is [...snip...]

Mail system design isn't really the topic for this list, so I won't
comment further on your setup.

> (You might be surprised how much email to made-up user names ...

Back in the 1980s I might have been surprised, but now about the only
thing that surprises me with emails is when one arrives which should
have been rejected by my filters. It happens very rarely, and when it
does I shout abuse at my screen.

> P.S. G.W Haywood ought to consider something like our email reply
> database.

You asked for help. I provided the help, and I explained that you can
contact me via this list. Please try to keep to the list topics.

> When I replied to an email he sent me from what seemed to be
> his private email address (i.e., not his clamav address), it was held
> for a few days at his MTA, "timed out"

No, if mail is delayed it's held on the sender's server, not on mine.
That's the whole point - upping the ante for spammers. Evidently my
take on email is different from what you'd like it to be, in that you
seem to think I should be trying harder to accept mail, whereas I'm
always trying to find more ways to reject it. My use of ClamAV, to
stay on topic, isn't about protection from viruses but about rejecting
the unwanted mail. To that end some of the third party databases kick
serious butt and at your request I've sent you privately a list of the
databases that I use. The official databases don't do much by way of
rejecting junk mail, but that's not really why they exist so it isn't
a criticism of them.

As I've already explained to you, aside from the fact that your IPs
are on a blacklist, _all_ Level3 IPs are blacklisted here. Given the
history of Level3 and CenturyLink (who bought Level3 in 2017, and who
are also blacklisted here), that is unlikely to change anytime soon.
If you're offended that my servers won't accept your private mail then
please be assured that it isn't personal. I'm just blocking garbage,
and as I've explained there may unfortunately be collateral damage in
some cases - such as if you're in one of over a hundred blacklisted
countries, and/or you use IPs from one of a few named ASN owners, or
one of a few dozen specific ASNs. Regrettably AS3356 is one of those.

> and was then bounced -- twice.

Again no, my servers never bounce mail. Either it's accepted, or it's
rejected, or the sending server gives up. Until one of those results
appears there is the possibility of greylisting TEMPFAILs, but the way
that SMTP works means that the _sending_ server retains responsibility
for the message during the greylisting period. Something like 30% of
the IPs on the planet are firewalled here, so they can't even make a
TCP connection. The firewalling is dynamic, driven by a milter which
uses a custom database of things like ASNs, countries, and some other
things that I don't want to talk about in public. If a firewalled IP
tries to send mail it will get a "connection refused". The Internet
is infested by criminals, many of whom are sponsored by governments
and have vastly greater resources than we do, so I make no apologies
for that.

You still seem to me to be worrying about the wrong things.

--

73,
Ged.

_______________________________________________

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] clamscan vs clamdscan [ In reply to ]
On Monday 11 May 2020 10:04:34 G.W. Haywood via clamav-users wrote:

> Hi there,
>
> On Sun, 10 May 2020, Paul Kosinski via clamav-users wrote:
> > Our email handling is [...snip...]
>
> Mail system design isn't really the topic for this list, so I won't
> comment further on your setup.
>
> > (You might be surprised how much email to made-up user names ...
>
> Back in the 1980s I might have been surprised, but now about the only
> thing that surprises me with emails is when one arrives which should
> have been rejected by my filters. It happens very rarely, and when it
> does I shout abuse at my screen.
>
> > P.S. G.W Haywood ought to consider something like our email reply
> > database.
>
> You asked for help. I provided the help, and I explained that you can
> contact me via this list. Please try to keep to the list topics.
>
> > When I replied to an email he sent me from what seemed to be
> > his private email address (i.e., not his clamav address), it was
> > held for a few days at his MTA, "timed out"
>
> No, if mail is delayed it's held on the sender's server, not on mine.
> That's the whole point - upping the ante for spammers. Evidently my
> take on email is different from what you'd like it to be, in that you
> seem to think I should be trying harder to accept mail, whereas I'm
> always trying to find more ways to reject it. My use of ClamAV, to
> stay on topic, isn't about protection from viruses but about rejecting
> the unwanted mail. To that end some of the third party databases kick
> serious butt and at your request I've sent you privately a list of the
> databases that I use. The official databases don't do much by way of
> rejecting junk mail, but that's not really why they exist so it isn't
> a criticism of them.
>
> As I've already explained to you, aside from the fact that your IPs
> are on a blacklist, _all_ Level3 IPs are blacklisted here. Given the
> history of Level3 and CenturyLink (who bought Level3 in 2017, and who
> are also blacklisted here), that is unlikely to change anytime soon.
> If you're offended that my servers won't accept your private mail then
> please be assured that it isn't personal. I'm just blocking garbage,
> and as I've explained there may unfortunately be collateral damage in
> some cases - such as if you're in one of over a hundred blacklisted
> countries, and/or you use IPs from one of a few named ASN owners, or
> one of a few dozen specific ASNs. Regrettably AS3356 is one of those.
>
> > and was then bounced -- twice.
>
> Again no, my servers never bounce mail. Either it's accepted, or it's
> rejected, or the sending server gives up. Until one of those results
> appears there is the possibility of greylisting TEMPFAILs, but the way
> that SMTP works means that the _sending_ server retains responsibility
> for the message during the greylisting period. Something like 30% of
> the IPs on the planet are firewalled here, so they can't even make a
> TCP connection. The firewalling is dynamic, driven by a milter which
> uses a custom database of things like ASNs, countries, and some other
> things that I don't want to talk about in public. If a firewalled IP
> tries to send mail it will get a "connection refused". The Internet
> is infested by criminals, many of whom are sponsored by governments
> and have vastly greater resources than we do, so I make no apologies
> for that.
>
> You still seem to me to be worrying about the wrong things.

Somebody who says what needs to be said. Luv it, sic 'em GW

Cheers, Gene Heskett
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
- Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>

_______________________________________________

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