-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 2/26/13 12:07 AM, ZEMEN Dragana wrote:

> 
> I am using clamd as a deamon in a network mode and connecting to
> it over a Socket Connection from my Client written in Java. At the 
> initial phase I am making a connection pool to the clamav and 
> subsequently taking one connection after another and sending files 
> to be scanned. However, I want to be able to reuse the connections 
> from the connection pool. For example I take one connection, send
> a file to the clam using it, getting a result from clam and
> putting this connection back to the connection pool. As the second
> request I get a new file from the database, and then the same
> (already used) connection from the connection pool and send the new
> file over this connection to clamd. This does not work because
> clamd closes the connection after accepting and processing one
> request from a client:
> 
> Log file: ... Tue Feb 19 14:18:07 2013 -> 
> instream(192.168.35.51@55453): Eicar-Test-Signature FOUND Tue Feb 
> 19 14:18:07 2013 -> Finished scanthread Tue Feb 19 14:18:07 2013
> -> Scanthread: connection shut down (FD 12) ....
> 
> Is there a property which I could use to avoid this closing of the 
> connection after the processing of one request?
> 

Take a look at the clamd man page for the IDSESSION command.  This
will allow you to hold the session open for longer, however not all
commands are compatible with sessions.


Tom

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (Darwin)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJRLExeAAoJEEJSM9yB4iIWYLIH/RgpRQHN+clChUHfI1FhxecB
95gjkcrvOtXcmFPnz81cTSCPb46Vr5cpI/f+7vlB5AcxCW1ZlWG+pvUcoEB2CK4z
nJsfLxljGDgVx2G8CSegtfx3hs1QxPLIX9lvJUKsrtQzsOOLbstaqmJ8lAc/75j/
6r04rdAZb+r0RqZh73yVRbvY8+0+DAgppER21NktR5dfoFnzkwHk906WTZA1NZMZ
f2MJqY/GcVoOhdydOKWUD25NlCpoxGAodLNQa/udkxFNaOGle8hgvPAlLTdr2HB3
0xM2XQfIu8mxZeALJ00UCQOWjt+7XXmbhKq4zX890+o9YB68Iuk6Z9WY87DSPOA=
=Lulx
-----END PGP SIGNATURE-----
_______________________________________________
Help us build a comprehensive ClamAV guide: visit http://wiki.clamav.net
http://www.clamav.net/support/ml

Reply via email to