Help creating Custom Copy of a Fixlet

(imported topic written by SystemAdmin)

Hello,

I’m very new to authoring/modifiying fixlets and could use all the help I can get!

Was testing fixlet ID 8091033 for Adobe Reader 9.3.3 security update and noticed it was changing some registry values located in HKEY_LOCAL_MACHINE\SOFTWARE\Classes\AcroExch.Document7\shell\open\command to point to Adobe Acrobat 5. Ideally I would like to copy the exsisting fixlet and add registry settings back to what they should be at the end of the fixlet.

Desired Settings:

HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Open\command

Default

= “C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe” “%1”

HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Print\command

Default

= “C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe” /p /h “%1”

HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Printto\command

Default

= “C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe” /t “%1” “%2” “%3” “%4”

If it’s easier, I exported the desired settings into a .reg that could be applied at the end, just not sure how and where it would look/be in the code of the copied and modified fixlet.

Any help would be greatly appreciated!

(imported comment written by SystemAdmin)

I didnt look through the Fixlet yet but you could create a custom copy of the Fixlet and add or replace the lines below

if 
{not x64 of operating system
} regset 
"[HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Open\command]" @ = 
"C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe" 
"%1" regset 
"[HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Print\command]" @ = 
"C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe" /p /h 
"%1" regset 
"[HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Printto\command]" @ = 
"C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe" /t 
"%1" 
"%2" 
"%3" 
"%4" endif 

if 
{x64 of operating system
} regset64 
"[HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Open\command]" @ = 
"C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe" 
"%1" regset64 
"[HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Print\command]" @ = 
"C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe" /p /h 
"%1" regset64 
"[HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Printto\command]" @ = 
"C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe" /t 
"%1" 
"%2" 
"%3" 
"%4" endif

(imported comment written by SystemAdmin)

Thanks for the reply!

I’m not sure I’m putting the code in the right place, as the settings are not taking. Target PCs are Windows XP SP3 machines.

here is the entire code, with your changes:

download http://ardownload.adobe.com/pub/adobe/reader/win/9.x/9.3.3/misc/AdbeRdrUpd933_all_incr.msp

continue if {(size of it = 8040960 AND sha1 of it = “0bc1c01fcf1e5c872c31b3f633428007438bd05e”) of file “AdbeRdrUpd933_all_incr.msp” of folder “__Download”}

waithidden msiexec.exe /p “__Download\AdbeRdrUpd933_all_incr.msp” REINSTALL=ALL REINSTALLMODE=omu /qn

delete __appendfile

appendfile REGEDIT4

appendfile

http://HKEY_LOCAL_MACHINE\SOFTWARE\Adobe\Acrobat Reader\9.0\AdobeViewer

appendfile “EULA”=dword:00000001

appendfile “Launched”=dword:00000001

appendfile

delete temp.reg

move __appendfile temp.reg

wait regedit -s temp.reg

// Disable the updater

// First, create an updater preferences file

delete __appendfile

appendfile <?xml version="1.0" encoding="UTF-8" ?>

appendfile

appendfile %temp%\Adobe\Updater6\aum.log

appendfile 2

appendfile 0

appendfile

appendfile 0

appendfile 0

appendfile 2008-07-01

appendfile 0

appendfile %temp%\Adobe\Updater6

appendfile 0

appendfile 0

appendfile 0

appendfile 1

appendfile

appendfile 0

appendfile

appendfile

delete AdobeUpdaterPrefs.dat

copy __appendfile AdobeUpdaterPrefs.dat

// Now create a batch file that will put this in all users’ application data folders

delete __appendfile

appendfile @ECHO OFF

appendfile for /f “tokens=* delims=,” %%a in (‘dir %systemdrive%\docume~1 /b /ad’) do call :process “%%a”

appendfile goto :eof

appendfile :process

appendfile if

%1

== goto :eof

appendfile if

%1

== goto :eof

appendfile if

%1

== goto :eof

appendfile xcopy AdobeUpdaterPrefs.dat “%systemdrive%\Documents and Settings%~1\Local Settings\Application Data\Adobe\Updater6” /Y/I

delete AdobeUpdaterPrefs.bat

copy __appendfile AdobeUpdaterPrefs.bat

// Run the batch file

waithidden AdobeUpdaterPrefs.bat

//modify the registry to fit appropriate settings

if {not x64 of operating system}

regset

http://HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Open\command

@ = “C:\Program Files\Adobe\Reader 9.0\Reader\AcroRd32.exe” “%1”

regset

http://HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Print\command

@ = “C:\Program Files\Adobe\Reader 9.0\Reader\AcroRd32.exe” /p /h “%1”

regset

http://HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Printto\command

@ = “C:\Program Files\Adobe\Reader 9.0\Reader\AcroRd32.exe” /t “%1” “%2” “%3” “%4”

endif

if {x64 of operating system}

regset64

http://HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Open\command

@ = “C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe” “%1”

regset64

http://HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Print\command

@ = “C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe” /p /h “%1”

regset64

http://HKLM\SOFTWARE\Classes\AcroExch.Document.7\shell\Printto\command

@ = “C:\Program Files (x86)\Adobe\Reader 9.0\Reader\AcroRd32.exe” /t “%1” “%2” “%3” “%4”

endif

action may require restart “0bc1c01fcf1e5c872c31b3f633428007438bd05e”

thanks in advance!

EDIT: Would it be easier to export the desired registry settings to a .reg file and have the fixlet run the .reg file at the end? If so, how would I do that? -thanks

(imported comment written by SystemAdmin)

Where you put my code looks fine

Download the Fixlet Debugger and choose “New Action Tab” paste your code in and run it

http://software.bigfix.com/download/bes/72/FixletDebugger-7.5.0.933.zip

The code I gave you sets the registry entrys and was tested in the Fixlet Dubugger…

I dont have any relevant systems for that fixlet

Try running it through the Debugger and see if you get the desired results