Here is another alternative using the superdat files. I put the superdat files in the export directory on the PDC so that it is available at all domain controllers.

code:

:VARDEC
Global $HKLM_S, $netlog
$HKLM_S="$HKLM\SOFTWARE\"
$netlog=Substr(@LDRIVE,1,Len(@LDRIVE)-1)
;
; $OS is set in another subroutine. It will either be:
; "Win9x" or "Windows NT"
;
; I can supply that subroutine if anyone is interested.
Return
;
;****************************************************************************************
:VIRUSUPD
; Description:
; This subroutine will first check to see if Network Associates' McAfee Virus Scan has
; been installed on this system. If it has, it will compare the installed virus definition
; version to that on the server. If the server version is newer, it will install it.
; The macro @LDRIVE reports a letter and a colon on Win9x computers and a UNC on NT.
;
; Input:
; $HKLM_S, $netlog, $OS
;
; Output:
; None
;****************************************************************************************
; Modification History
; Date Initials Description
; 10 Sep 99 bvv Wrote first cut.
; 14 Sep 99 bvv Adjusted script to accomodate @ldrive macro.
;****************************************************************************************
;
Dim $key, $avversion, $newversion, $versiondif, $newvernum, $virfile
$key=$HKLM_S+"McAfee\VirusScan"
If ExistKey("$key")=0
$avversion=ReadValue("$key","szVirDefVer")
If @ERROR=0
$avversion=Val(Substr($avversion,Len($avversion)-3,4))
If @ERROR=0
If $OS="Win9x"
$virfile="$netlog:\sdat*.exe"
Else
$virfile="$netlog\sdat*.exe"
Endif
; In case someone leaves old virus definition files around, will take advantage
; of the fact that McAfee uses 4 digits in its file names which gets incremented
; by one with each new version.
$newverion=Dir("$verfile")
While $newversion<> "" and @ERROR=0
$savename=$newversion
$newversion=Dir()
Loop
$newversion=$savename
; The above loop will find all the virus definitions in the netlogon share. By
; virtue of the fact that the filenames have 4 digits in them and that they are
; incremented by one with each new version, the last name found will be the newest.
; Each time through the loop, save the found name. The last time through the
; loop, $newversion="". So, set it to the last saved name.
$newvernum=Val(Substr($newversion,5,4))
$versiondif=$newvernum-$avversion
If $versiondif>0
If $OS="Win9x"
Copy "$netlog:\$newversion" %TEMP%
Else
Copy "$netlog\$newversion" %TEMP%
Endif
? "Updating virus definitions. The version being installed is: $newversion."
$selection=Messagebox("The virus definitions on your computer are being updated. As a result, your system may reboot itself. If it does, just login again.", "Important Notice",4160,7)
Shell "$comd $newversion /logfile %TEMP%\mcafeedat.txt /silent /reboot"
; The system may reboot here.
Else
? "The virus definitions are up to date. Currently installed version is:"
? "$avversion. And the new version is: $newvernum."
Endif
Else
? "There was an error reading the new virus definition file."
? "The error is: "+@SERROR
? "Netlog is: "+$netlog
Endif
Else
? "Could not read the version of the virus defenition files."
? "Error is: "+@SERROR
Endif
Else
? "McAfee is not installed on this system!"
Endif
Return
;
;****************************************************************************************