kylefarris / clamscan

A robust ClamAV virus scanning library supporting scanning files, directories, and streams with local sockets, local/remote TCP, and local clamscan/clamdscan binaries (with failover).
MIT License
236 stars 69 forks source link

Could not connect to clamd on LocalSocket #25

Closed BradleyDHobbs closed 5 years ago

BradleyDHobbs commented 5 years ago

"ERROR: Could not connect to clamd on LocalSocket /var/run/clamd.scan/clamd.sock: Permission denied"

Running this from a directory in the home folder.

Any ideas?

kylefarris commented 5 years ago

Hey @BradleyDHobbs,

It likely has something to do with the permissions of your clamd config. This problem isn't really in the scope of this module, but I'll see if I can help you out anyways. What OS and OS version are you running on? What does your clamav config look like?

BradleyDHobbs commented 5 years ago

Yeah you were right. It was a permissions issue. I had to do some messing around with the virusgroup group. Got it working eventually.

On a side note, any way to use async await and/or promises with the methods?

kylefarris commented 5 years ago

Hey @BradleyDHobbs, I just released version 1.0.0 (big update) last week and it definitely supports Promises and Async/await now. So, please try it out and let me know if you have any issues. You will want to read the release notes for the release as there are some changes to the API (mostly to do with how you init the module).