Function clamav_client::scan_buffer_socket
source · pub fn scan_buffer_socket<P: AsRef<Path>>(
buffer: &[u8],
socket_path: P,
chunk_size: Option<usize>
) -> IoResultExpand description
Scans a data buffer for viruses using a Unix socket connection
This function streams the provided buffer data to a ClamAV server through
a Unix socket connection for scanning.
Arguments
buffer: The data to be scannedsocket_path: The path to the Unix socket for the ClamAV serverchunk_size: An optional chunk size for reading data. IfNone, a default chunk size is used
Returns
An IoResult containing the server’s response as a vector of bytes