Foros de discusión
ClamAV scanning
Jair Irwin, modificado hace 8 años.
ClamAV scanning
New Member Mensajes: 9 Fecha de incorporación: 28/11/14 Mensajes recientes
Hi all,
I have implemented ClamAV integration with liferay by adding the following to the portal-ext.properties file:
dl.store.antivirus.enabled=true
dl.store.antivirus.impl=com.liferay.portlet.documentlibrary.antivirus.ClamAntivirusScannerImpl
The scanning has been tested with the EICAR virus file and it works well. However, recently we manually updated our ClamAV virus DB (we are not able to do it automatically) and noticed that the DB files are quite large. This in turn has led to the uploading of content in liferay to take much longer than before (a small file takes about 20 seconds to scan and upload instead of the previous 3 seconds). I understand this may be more of a "ClamAV" question, but I'm wondering if anything could be done from a liferay perspective to speed things up? I know ClamAV has both "clamscan" and "clamdscan" - clamdscan is much faster than clamscan - not sure which one we invoke but wonder if it's possible to specify?
Thanks,
Jair.
I have implemented ClamAV integration with liferay by adding the following to the portal-ext.properties file:
dl.store.antivirus.enabled=true
dl.store.antivirus.impl=com.liferay.portlet.documentlibrary.antivirus.ClamAntivirusScannerImpl
The scanning has been tested with the EICAR virus file and it works well. However, recently we manually updated our ClamAV virus DB (we are not able to do it automatically) and noticed that the DB files are quite large. This in turn has led to the uploading of content in liferay to take much longer than before (a small file takes about 20 seconds to scan and upload instead of the previous 3 seconds). I understand this may be more of a "ClamAV" question, but I'm wondering if anything could be done from a liferay perspective to speed things up? I know ClamAV has both "clamscan" and "clamdscan" - clamdscan is much faster than clamscan - not sure which one we invoke but wonder if it's possible to specify?
Thanks,
Jair.
Dennis Ju, modificado hace 8 años.
RE: ClamAV scanning
Regular Member Mensajes: 228 Fecha de incorporación: 30/09/10 Mensajes recientes
It looks like Liferay's ClamAntivirusScannerImpl is hardcoded to run clamscan (and not clamdscan). The logic is pretty straightforward, so you can try rolling your own implementation calling clamdscan.
Jair Irwin, modificado hace 8 años.
RE: ClamAV scanning
New Member Mensajes: 9 Fecha de incorporación: 28/11/14 Mensajes recientes
Thanks Dennis!
That is very interesting. I am not a programmer myself so I may have to ask my developer for assistance.
Looking at that piece of code, would it likely simply be a matter of replacing "clamscan" with "clamdscan" and leaving all the rest the same?
Thanks again,
Jair.
That is very interesting. I am not a programmer myself so I may have to ask my developer for assistance.
Looking at that piece of code, would it likely simply be a matter of replacing "clamscan" with "clamdscan" and leaving all the rest the same?
Thanks again,
Jair.
Dennis Ju, modificado hace 8 años.