Created attachment 18793 [details] Patch to fix virusfilter with clamav unix socket Tried to use the latest version 4.23.4 and found out that the vfs virusfilter was not working properly. The error that was logged was the following: virusfilter_clamav_scan_init: clamd: Connecting to socket failed: /var/run/clamd/clamd.socket: Protocol not supported where /var/run/clamd/clamd.socket is the path to the socket where clamd is listening for connections. I tried to debug the problem and I traced the problem to this exact change: https://github.com/samba-team/samba/commit/6934c7ae402ee7ef593b613022f0330303766287#diff-271c747e500fb0a06d2b8aaefc76308ed1189abcf8821dcb158c89ce8af0af02R543 The above change was made to add a protocol parameter to some socket functions, and that commit sets the protocol parameter explicitly to IPPROTO_TCP Unfortunately open_socket_out is called from virusfilter_io_connectpath and attempts to connect to a UNIX socket. So, when attempting to connect to a UNIX socket and the protocol is explicitly set to IPPROTO_TCP, the socket call fails with error EPROTONOSUPPORT. That specific protocol parameter should be left 0 (use default protocol), in order to work properly I attach a small patch for version 4.23.4 that fixes the issue.