Foros del Web » Administración de Sistemas » Unix / Linux »

Error acceso con servidor proxy Squid + Dansguardias + Clamav

Estas en el tema de Error acceso con servidor proxy Squid + Dansguardias + Clamav en el foro de Unix / Linux en Foros del Web. Buenas, estoy jugando con un servidor proxy bajo una máquina virtual con ubuntu 10.04, squid, dansguardian y clamav. El problema lo tengo a integrar el ...
  #1 (permalink)  
Antiguo 12/11/2010, 07:16
 
Fecha de Ingreso: septiembre-2007
Mensajes: 44
Antigüedad: 16 años, 7 meses
Puntos: 2
Error acceso con servidor proxy Squid + Dansguardias + Clamav

Buenas, estoy jugando con un servidor proxy bajo una máquina virtual con ubuntu 10.04, squid, dansguardian y clamav. El problema lo tengo a integrar el escaneo antivirus con dansguardian ya que squid y dansguardian funcionan ok.

El menaje que obtengo es el que se muestra más abajo desde una máquina cliente con XP, configurado el servidor proxy en el navegador web al intentar acceder a cualquier url.



Para integrar clamav con dansguardian he hecho lo siguiente.

Primero instalo clamav y su demonio (clamav clamav-daemon).

Edito el archivo de configuración que se encuentra en /etc/dansguardian/dansguardian.conf y descomento las siguientes lineas:

Código:
contentscanner = '/etc/dansguardian/contentscanners/clamav.conf'
contentscanner = '/etc/dansguardian/contentscanners/clamdscan.conf'
Edito /etc/dansguardian/contentscanners/clamdscan.conf y descomento esta linea clamdudsfile = '/var/run/clamav/clamd.ctl' para iniciar clamav en modo demonio.

El contenido de /etc/dansguardian/contentscanners/clamav.conf es:

Código:
# edit this to match the location of your ClamD UNIX domain socket
clamdudsfile = '/var/run/clamav/clamd.ctl'

# If this string is set, the text it contains shall be removed from the
# beginning of filenames when passing them to ClamD.
# Use it to - for example - support a ClamD running inside a chroot jail:
# if DG's filecachedir is set to "/var/clamdchroot/downloads/" and pathprefix
# is set to "/var/clamdchroot", then file names given to ClamD will be of the
# form "/downloads/tf*" instead of "/var/clamdchroot/downloads/tf*".
#pathprefix = '/var/clamdchroot'

exceptionvirusmimetypelist = '/etc/dansguardian/lists/contentscanners/exceptionvirusmimetypelist'
exceptionvirusextensionlist = '/etc/dansguardian/lists/contentscanners/exceptionvirusextensionlist'
exceptionvirussitelist = '/etc/dansguardian/lists/contentscanners/exceptionvirussitelist'
exceptionvirusurllist = '/etc/dansguardian/lists/contentscanners/exceptionvirusurllist'
Y /etc/dansguardian/contentscanners/clamav.conf tiene lo siguiente:

Código:
plugname = 'clamav'

# scanbuffmethod
#
# As of 2.9.4.0, DG uses libclamav's cl_scandesc method instead of
# cl_scanbuff when scanning memory buffers. Unfortunately, this means
# that memory contents must be written to a file before scanning even
# if the file is below maxcontentramcachescansize.
# This option specifies how temp files will be created:
#
#   file - create files in scanbuffdir
#
#   shm - use POSIX shared memory
#
scanbuffmethod = 'file'

# scanbuffdir - where to create temp files in scanbuffmethod 'file'.
# You can specify a ramfs/tmpfs partition to minimise performance
# impact.
# Defaults to the configured filecachedir.
#scanbuffdir = '/path/to/tmpfs'
# tempdir - temporary directory for internal use by clamav.
# When scanning archive files, clamav can create temporary files of
# its own; this allows you to specify where they will be created.
# Used regardless of scanbuffmethod.
# Defaults to the configured filecachedir.
#tempdir = '/path/to/tmpfs'
#maxfiles - The maximum number of files to scan from a single
# archive.  Like clamd.conf's MaxFiles.
maxfiles = 15000

#maxreclevel - The maximum recursion level when unpacking archives
# within archives.  Like clamd.conf's MaxRecursion.
maxreclevel = 10

#maxscansize - Upper limit on the amount of data that whill be
# scanned when unpacking an archive, in kilobytes. Like clamd.conf's
# MaxScanSize.
maxscansize = 100000

exceptionvirusmimetypelist = '/etc/dansguardian/lists/contentscanners/exceptionvirusmimetypelist'
exceptionvirusextensionlist = '/etc/dansguardian/lists/contentscanners/exceptionvirusextensionlist'
exceptionvirussitelist = '/etc/dansguardian/lists/contentscanners/exceptionvirussitelist'
exceptionvirusurllist = '/etc/dansguardian/lists/contentscanners/exceptionvirusurllist'
Por último el log /var/log/dansguardian/access.log muestra lo siguiente:
Código:
2010.11.12 13:31:18 - 192.168.1.2 http://www.google.es *INFECTED* *DENIED* /tmp/tffhBbBK: Access denied. ERROR GET 1215 0 Content scanning 1 403 text/html
Me da la impresión que me deniega cualquier acceso porque el pid de clamav no está comunicándose con dansguardian.

Saludos y gracias.

Etiquetas: proxy, squid, servidores
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 23:02.