从/etc/clamav/clamd.conf或/etc/clamd.conf中找不到clamd Unix套接字

时间:2018-12-26 06:11:02

标签: python

当我使用pyclamd时,链接服务器安装的CLAMAV时间的CLAMAV时间错误。

import pyclamd

# Create object for using unix socket
cd = pyclamd.ClamdUnixSocket()
# cd = pyclamd.ClamdAgnostic()
try:
    # test if server is reachable
    cd.ping()
except pyclamd.ConnectionError:
    # if failed, test for network socket
    cd = pyclamd.ClamdNetworkSocket()
    try:
        cd.ping()
    except pyclamd.ConnectionError:
        raise (ValueError, "could not connect to clamd server either by unix or network socket")

错误:

enter image description here

0 个答案:

没有答案