Ola Marcos,

Vc precisa de dois arquivos: um .netrc, para baixar os DATs, e o outro 
um script (atualiza.sh) que instala as novas versoes.
Estou lhe enviando um exemplo (retirado da propria documentacao do 
VirusScan), qquer duvida, entre em contato.


###### Inicio .netrc ############
#Atualizacao DATs VirusScan
machine ftp.nai.com
login anonymous
password [EMAIL PROTECTED]
macdef init
cd pub/antivirus/datfiles/4.x
bin
prompt
mget dat-*.tar
close
bye
###### Fim .netrc ###############

###### Inicio atualiza.sh #######
#!/bin/sh

# Assume uvscan is installed in the same directory
# as this script.

install_directory=`dirname $0`

# Create a download directory

mkdir /tmp/dat-updates

cd /tmp/dat-updates

# Get the version of the currently installed .DATs
# from the info given by the --version switch

current_version=`
$install_directory/uvscan --version | grep "Virus data file" | awk '{ 
print substr($4,2,4) }'`

# Get the new .DATs.
# The entry in your .netrc file should take care
# of the downloading.

ftp ftp.nai.com

# Get the version of the new .DATs from the filename.

new_version=`echo dat-*.tar | awk '{ print substr($1,5,4) }'`

# If they are the same age or older than the current ones,
# do not install them

if [ "$current_version" -ge "$new_version" ]
then
        echo "No new .DATs available at this time"
        echo "Currently installed version: $current_version"
        echo "Version on FTP site: $new_version"
else
        tar -xf dat-*.tar

# Move them to the install directory, making sure
# the filename is lower case.

        for file in `tar -tf dat-*.tar`
        do
                newfile=`echo $file | tr [A-Z] [a-z]`
                mv ./$file $install_directory/$newfile
        done

# Get the current version again and make sure
# the new .DATs installed correctly.

        current_version=`
        $install_directory/uvscan --version | grep "Virus data file" | 
awk '{ print substr($4,2,4) }'`
        if [ ! "$current_version" -eq "$new_version" ]
        then
                echo "DAT file updates did not work correctly."
                echo "Please try manually."
        fi
fi

# Delete the directory that you created.

cd /
rm -fr /tmp/dat-updates

###### Fim atualiza.sh ###########

-----Original Message-----
From:   Marcos_linux
Sent:   Sat 3/9/2002 06:09
To:     [EMAIL PROTECTED]
Cc:    
Subject:        Script para atualizar os DATs do uvscan. Onde encontrar ?
Oi

Alguem pode me enviar um script (ou uma dica de onde encontrar) para 
atualiza��o dos arquivos .DAT do amavis+uvscan
Procurei no historico, achei um, mas n�o consegui fazer funcionar.

O script qwue eu encontrei foi enviado por "applein 
<[EMAIL PROTECTED]>",
Mas como eu n�o entendo nada de script, t� mais perdido que cego em 
tiroteio.


Obrigado
[]�s
Marcos M. de Souza.
S�o Paulo - Brasil







Assinantes em 11/03/2002: 2232
Mensagens recebidas desde 07/01/1999: 157747
Historico e [des]cadastramento: http://linux-br.conectiva.com.br
Assuntos administrativos e problemas com a lista:
            mailto:[EMAIL PROTECTED]

Responder a