Page 1 of 1 1
Topic Options
#76454 - 2003-08-20 11:16 PM Checking for RPC Patch
plazaai Offline
Fresh Scripter

Registered: 2003-07-25
Posts: 8
I copied a script from one of the posts here and changed it a little. I want it to look for the reg key and the display a message whether it’s been installed or not. If the patch is not installed I have it call an exe (autoit) that will tell the user that the patch is missing and to cll the helpdesk. On a W2K PC with out the patch it call the exe twice. Any help here is the script

? "Please Wait... Checking if Microsoft RPC Security Patch is Installed"

$KBPATH="netlogon"

SELECT

CASE @ProductType='Windows NT Workstation'

$KBFile='Q823980i.EXE'

$KBRequired=KeyExist('HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Q823980')

IF $KBRequired

; Patch already installed

ELSE

Shell '%comspec% /c '+@LSERVER+'\'+$KBPath+'\'+$KBFile+' /u /q /z'

ENDIF

CASE @ProductType='Windows 2000 Professional'

$KBFile='Windows2000-KB823980.exe'

$KBRequired=KeyExist('HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Updates\Windows 2000\SP5\KB823980')

If $KBRequired

? "Patch Already Installed"

Else

Shell @LSERVER+'\'+$KBPath+'\'+$KBFile

ENDIF

Case @PRODUCTTYPE='Windows XP Professional'

$KBFile='WindowsXP-KB823980.exe'

IF @CSD = 'Service Pack 1'

$KBRequired=KeyExist("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Updates\Windows XP\SP2\KB823980\Filelist")

If $KBRequired

? "Patch Already Installed"

Else


Shell @LSERVER+'\'+$KBPath+'\'+$KBFile

ENDIF

ELSE

$KBFile='WindowsXP-KB823980.exe'

$KBRequired=KeyExist("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Updates\Windows XP\SP1\KB823980\Filelist")

If $KBRequired

? "Patch Already Installed"

Else

Shell @LSERVER+'\'+$KBPath+'\'+$KBFile



EndIF

ENDIF

Top
#76455 - 2003-08-20 11:24 PM Re: Checking for RPC Patch
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
Please repost your code within [CODE] tags and with proper indentation!

Why do you want to use AUTOIT for a user notification? [Confused]
_________________________
There are two types of vessels, submarines and targets.

Top
Page 1 of 1 1


Moderator:  Glenn Barnas, NTDOC, Arend_, Jochen, Radimus, Allen, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
1 registered (mole) and 1300 anonymous users online.
Newest Members
Viginette, ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder
17888 Registered Users

Generated in 0.05 seconds in which 0.024 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org