Jump to content
nonno fabio

DX Integrator Syntax for Win7 Addon Makers

Recommended Posts

entries.ini commands supported by DXIntegrator

[sysPrepOC]

Component_Name=advpack.dll,LaunchINFSection,INF_FileName,SectionName

;or

Component_Name=setupapi.dll,InstallHinfSection,INF_FileName,SectionName

;;;example

[SysPrepOC]
Unlocker=advpack.dll,LaunchINFSection,Unlocker.inf,Unlocker
Silverlight=setupapi.dll,InstallHinfSection,MSSlight.inf,Silverlight

[General]

;;;example


[General]
BuildDate=2010-10-27T11:05:11Z
Description="Freeware tool which overcomes a Windows bug"
Language=English
Title=Unlocker
Version=1.9.0
WebSite=http://ccollomb.free.fr/unlocker/
processorArchitecture=x86 ; --> Warning: this key is used to force addon integration only in a certain system architecture; if present OS architecture is not the one defined in this key, DXIntegrator skips the AddOn
ForceLang=Italiano ; --> Warning: this key is used to force addon integration only in a certain system language; if present OS language is not the one defined in this key, DXIntegrator skips the AddOn
ReleaseType=True AddOn
Customizedby=OnePiece
Copyright=CEDRICK 'NITCH' COLLOMB
Company=CEDRICK 'NITCH' COLLOMB
InstallPackageName=Unlocker.inf
LastUpdateTime=2010-10-27T11:05:11Z

about Dirids:

http://msdn.microsoft.com/en-us/library/ff553598%28v=VS.85%29.aspx

about Security Descriptor Definition Language to be used in [securityRegistry*Integration] and in [securityFiles*Integration]:

http://msdn.microsoft.com/en-us/library/aa379567%28v=VS.85%29.aspx

http://msdn.microsoft.com/en-us/magazine/cc982153.aspx

http://blogs.technet.com/b/askds/archive/2008/04/18/the-security-descriptor-definition-language-of-love-part-1.aspx

http://technet.microsoft.com/en-us/library/cc512610.aspx

[securityRegistryBeforeIntegration]

;;;example

[SecurityRegistryBeforeIntegration]
"MACHINE\%KEY_SOFTWARE%\ProgramName",0,"D:P(A;CIOI;GR;;;BU)(A;CIOI;GA;;;BA)(A;CIOI;GA;;;SY)(A;CIOI;GA;;;CO)"

[securityRegistryAfterIntegration]

;;;example

[SecurityRegistryAfterIntegration]
"MACHINE\%KEY_SOFTWARE%\ProgramName",,"D:P(A;CIOI;GR;;;BU)(A;CIOI;GR;;;BA)(A;CIOI;GA;;;SY)(A;CIOI;GA;;;CO)"

DXIntegrator loads this HIVES as default, so like previous example if want to add reglines in HKLM\Software, you need to use MACHINE\%KEY_SOFTWARE%, if you want to add or delete reglines in HKLM\System instead, you need MACHINE\%KEY_SYSTEM%

"%MountDir%\Windows\System32\config\SOFTWARE" = %KEY_SOFTWARE%
"%MountDir%\Windows\System32\config\SYSTEM" = %KEY_SYSTEM%
"%MountDir%\Windows\System32\config\SECURITY" = %KEY_SECURITY%
"%MountDir%\Windows\System32\config\SAM" = %KEY_SAM%
"%MountDir%\Windows\System32\config\COMPONENTS" = %KEY_COMPONENTS%
"%MountDir%\Windows\System32\config\DEFAULT" = %KEY_DEFAULT%
"%MountDir%\Users\default\ntuser.dat" = %KEY_NTUSER%
"%MountDir%\Windows\system32\smi\store\Machine\schema.dat" = %KEY_SCHEMA%
"%MountDir%\WINDOWS\system32\config\systemprofile\NTUSER.DAT" = %KEY_NTUSER_SP%
"%MountDir%\WINDOWS\system32\config\systemprofile\AppData\Local\Microsoft\Windows\UsrClass.dat" = %KEY_USRCLASS_SP%
"%MountDir%\Windows\ServiceProfiles\LocalService\NTUSER.DAT" = %KEY_NTUSER_LS%
"%MountDir%\Windows\ServiceProfiles\LocalService\AppData\Local\Microsoft\Windows\UsrClass.dat" = %KEY_USRCLASS_LS%
"%MountDir%\Windows\ServiceProfiles\NetworkService\NTUSER.DAT" = %KEY_NTUSER_NS%
"%MountDir%\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\Windows\UsrClass.dat" = %KEY_USRCLASS_NS%
"%MountDir%\Users\Administrator\NTUSER.DAT" = %KEY_NTUSER_ADMIN%
"%MountDir%\Users\Administrator\AppData\Local\Microsoft\Windows\UsrClass.dat" = %KEY_USRCLASS_ADMIN%

[securityFilesBeforeIntegration]

;;;example

[SecurityFilesBeforeIntegration]
%11%\FileName.exe,0,"D:P(A;;GA;;;BA)(A;;GR;;;SY)(A;;GR;;;BU)"
%PROGRAMDATA%,0,"D:PAI(A;;0x1200a9;;;SY)(A;OICIIO;GXGR;;;SY)(A;;FA;;;BA)(A;OICIIO;GA;;;BA)(A;;0x1200a9;;;BU)(A;OICIIO;GXGR;;;BU)"
%10%\regedit.exe,0,"D:P(A;CI;GR;;;LS)(A;CI;GR;;;BU)(A;CI;GR;;;PU)(A;CI;GA;;;BA)(A;CI;GA;;;SY)(A;CI;GA;;;CO)"

[securityFilesAfterIntegration]

;;;example

[SecurityFilesAfterIntegration]
%11%\FileName.exe,0,"D:P(A;;GR;;;BA)(A;;GR;;;SY)(A;;GR;;;BU)"
%ALLUSERSPROFILE%,0,"D:P(A;CI;GR;;;BU)(A;CI;GA;;;BA)(A;CI;GA;;;SY)(A;CI;GA;;;CO)"
%16422%,0,"D:P(A;CI;GR;;;BU)(A;CI;GA;;;BA)(A;CI;GA;;;SY)(A;CI;GA;;;CO)"

[TweaksAddReg]

;;;example

[TweaksAddReg]
HKLM, "%KEY_SOFTWARE%\ProgramName", "Test", %REG_SZ%, "Test....."
HKLM, "Test\Test2", "Test2", %REG_SZ%, "Test2....." [color=green];;;see example in [ProcessesToRun*Integration] where RegHive has been loaded in HKLM\Test[/color]

[TweaksDelReg]

;;;example

[TweaksDelReg]
HKLM, "%KEY_SOFTWARE%\ProgramName"

SourceFiles = Directory where the addon has been extracted

MountDir = Directory where the image has been mounted Warning: %MountDir% is an optional variable, there's no need for it as MountDir is always DIRID 24 (Root directory of the system disk), so %24%\ is always mount directory destination

[ProcessesToRunBeforeIntegration]

;;;example

[ProcessesToRunBeforeIntegration]
reg load HKLM\Test "%Mountdir%\Windows\System32\config\RegHive"
"%SourceFiles%\ResHacker.exe" -delete "%16422%\Internet Explorer\iexplore.exe", "%16422%\Internet Explorer\iexplore.exe", Icon,,
"%SourceFiles%\ResHacker.exe" -addoverwrite "%16422%\Internet Explorer\iexplore.exe", "%16422%\Internet Explorer\iexplore.exe", "%SourceFiles%\Icon.res",,,
"%SourceFiles%\ResHacker.exe" -delete "%MountDir%\Program Files\Internet Explorer\iexplore.exe", "%MountDir%\Program Files\Internet Explorer\iexplore.exe", Bitmap,,
"%SourceFiles%\ResHacker.exe" -addoverwrite "%MountDir%\Program Files\Internet Explorer\iexplore.exe", "%MountDir%\Program Files\Internet Explorer\iexplore.exe", "%SourceFiles%\Bitmap.res",,,

[ProcessesToRunAfterIntegration]

;;;example

[ProcessesToRunAfterIntegration]
reg unload HKLM\Test
"%SourceFiles%\ResHacker.exe" -delete "%MountDir%\windows\system32\FileName.exe", "%MountDir%\windows\system32\FileName.exe", Bitmap,,
"%SourceFiles%\ResHacker.exe" -addoverwrite "%MountDir%\windows\system32\FileName.exe", "%MountDir%\windows\system32\FileName.exe", "%SourceFiles%\Bitmap.res",,,
"%SourceFiles%\ResHacker.exe" -delete "%11%\FileName.exe", "%11%\FileName.exe", Icon,,
"%SourceFiles%\ResHacker.exe" -addoverwrite "%11%\FileName.exe", "%11%\FileName.exe", "%SourceFiles%\Icon.res",,,

Warning, these sections do same job of [securityFiles*Integration] sections but in different ways; they've been added for they who find hard to understand microsoft guides about "Security Descriptor Definition Language", so you can use these too; anyway it is suggested to use [securityFiles*Integration] section, safer e also faster

1 = gives Admin permissions for a file or a directory

2 = when destination is a directory, gives Admin permission for all files and subdirectories of specified directory

3 = when destination is a directory, if it doesn't exist will be automatically created

[FilePermissionsBeforeIntegration]

;;;example

[b][FilePermissionsBeforeIntegration][/b]
%10%\regedit.exe,1
%COMMONPROGRAMFILES%,1
%16426%\Filename.exe,1

[FilePermissionsAfterIntegration]

;;;example

[FilePermissionsAfterIntegration]
%10%\test.exe,1
%PROGRAMFILES(X86)%,1
%16428%\Test,3

[AddProgram]

;;;example

[AddProgram]
Filerefox.exe
[color=Green];or[/color]
install_flash_player.exe -install -force
"SetUp XXX.exe" /S

[string]

;;;example

[Strings]
LANGNAME = "English"
LANGUAGE = "ENU"
MuiCultureDirectory = "en-US"
LangIdHex = "409"
Lang = "EN"
LCID = "0409"
UnlockerTip = "Freeware tool to overcome a Windows bug"

;or use multi local

about International INF Files http://msdn.microsoft.com/en-us/library/ff540208%28v=VS.85%29.aspx

[Strings.0409]
LANGNAME = "English"
LANGUAGE = "ENU"
MuiCultureDirectory = "en-US"
LangIdHex = "409"
Lang = "EN"
LCID = "0409"
UnlockerTip = "Freeware tool to overcome a Windows bug"

[Strings.0410]
LANGNAME = "Italiano"
LANGUAGE = "ITA"
MuiCultureDirectory = "it-IT"
LangIdHex = "410"
Lang = "IT"
LCID = "0410"
UnlockerTip = "Strumento freeware per superare un bug di Windows"

DXIntegrator adds as default these keys in Strings section

REG_SZ                                    = 0x00000000
REG_EXPAND_SZ = 0x00020000
REG_DWORD = 0x00010001
REG_QWORD = 0x000B0001
REG_BINARY = 0x00000001
REG_MULTI_SZ = 0x00010000
REG_NONE = 0x00020001
REG_KEYONLY = 0x00000010
REG_KEYONLY_COMMON = 0x00002000
REG_UNKNOWN = 0x00030001
REG_NOCLOBBER = 0x00000002
REG_DELVAL = 0x00000004
REG_OVERWRITEONLY = 0x00000020
REG_APPEND = 0x00000008 ;Append a given value to that of an existing named value entry. This flag is valid only if FLG_ADDREG_TYPE_MULTI_SZ is also set. The specified string value is not appended if it already exists.
REG_64BITKEY = 0x00001000
REG_32BITKEY = 0x00004000
REG_SZ_64BITKEY = 0x00001000
REG_SZ_32BITKEY = 0x00004000
REG_SZ_NOCLOBBER = 0x00000002
REG_SZ_NOCLOBBER_64BITKEY = 0x00001002
REG_SZ_NOCLOBBER_32BITKEY = 0x00004002
REG_SZ_DELVAL = 0x00000004
REG_SZ_DELVAL_64BITKEY = 0x00001004
REG_SZ_DELVAL_32BITKEY = 0x00004004
REG_SZ_OVERWRITEONLY = 0x00000020
REG_SZ_OVERWRITEONLY_64BITKEY = 0x00001020
REG_SZ_OVERWRITEONLY_32BITKEY = 0x00004020
REG_EXPAND_SZ_64BITKEY = 0x00021000
REG_EXPAND_SZ_32BITKEY = 0x00024000
REG_EXPAND_SZ_NOCLOBBER = 0x00020002
REG_EXPAND_SZ_NOCLOBBER_64BITKEY = 0x00021002
REG_EXPAND_SZ_NOCLOBBER_32BITKEY = 0x00024002
REG_EXPAND_SZ_DELVAL = 0x00020004
REG_EXPAND_SZ_DELVAL_64BITKEY = 0x00021004
REG_EXPAND_SZ_DELVAL_32BITKEY = 0x00024004
REG_EXPAND_SZ_OVERWRITEONLY = 0x00020020
REG_EXPAND_SZ_OVERWRITEONLY_64BITKEY = 0x00021020
REG_EXPAND_SZ_OVERWRITEONLY_32BITKEY = 0x00024020
REG_DWORD_64BITKEY = 0x00011001
REG_DWORD_32BITKEY = 0x00014001
REG_DWORD_NOCLOBBER = 0x00010003
REG_DWORD_NOCLOBBER_64BITKEY = 0x00011003
REG_DWORD_NOCLOBBER_32BITKEY = 0x00014003
REG_DWORD_DELVAL = 0x00010005
REG_DWORD_DELVAL_64BITKEY = 0x00011005
REG_DWORD_DELVAL_32BITKEY = 0x00014005
REG_DWORD_OVERWRITEONLY = 0x00010021
REG_DWORD_OVERWRITEONLY_64BITKEY = 0x00011021
REG_DWORD_OVERWRITEONLY_32BITKEY = 0x00014021
REG_QWORD_64BITKEY = 0x000B1001
REG_QWORD_32BITKEY = 0x000B4001
REG_QWORD_NOCLOBBER = 0x000B0003
REG_QWORD_NOCLOBBER_64BITKEY = 0x000B1003
REG_QWORD_NOCLOBBER_32BITKEY = 0x000B4003
REG_QWORD_DELVAL = 0x000B0005
REG_QWORD_DELVAL_64BITKEY = 0x000B1005
REG_QWORD_DELVAL_32BITKEY = 0x000B4005
REG_QWORD_OVERWRITEONLY = 0x000B0021
REG_QWORD_OVERWRITEONLY_64BITKEY = 0x000B1021
REG_QWORD_OVERWRITEONLY_32BITKEY = 0x000B4021
REG_BINARY_64BITKEY = 0x00001001
REG_BINARY_32BITKEY = 0x00004001
REG_BINARY_NOCLOBBER = 0x00000003
REG_BINARY_NOCLOBBER_64BITKEY = 0x00001003
REG_BINARY_NOCLOBBER_32BITKEY = 0x00004003
REG_BINARY_DELVAL = 0x00000005
REG_BINARY_DELVAL_64BITKEY = 0x00001005
REG_BINARY_DELVAL_32BITKEY = 0x00004005
REG_BINARY_OVERWRITEONLY = 0x00000021
REG_BINARY_OVERWRITEONLY_64BITKEY = 0x00001021
REG_BINARY_OVERWRITEONLY_32BITKEY = 0x00004021
REG_MULTI_SZ_64BITKEY = 0x00011000
REG_MULTI_SZ_32BITKEY = 0x00014000
REG_MULTI_SZ_APPEND = 0x00010008
REG_MULTI_SZ_APPEND_64BITKEY = 0x00011008
REG_MULTI_SZ_APPEND_32BITKEY = 0x00014008
REG_MULTI_SZ_NOCLOBBER = 0x00010002
REG_MULTI_SZ_NOCLOBBER_64BITKEY = 0x00011002
REG_MULTI_SZ_NOCLOBBER_32BITKEY = 0x00014002
REG_MULTI_SZ_DELVAL = 0x00010004
REG_MULTI_SZ_DELVAL_64BITKEY = 0x00011004
REG_MULTI_SZ_DELVAL_32BITKEY = 0x00014004
REG_MULTI_SZ_OVERWRITEONLY = 0x00010020
REG_MULTI_SZ_OVERWRITEONLY_64BITKEY = 0x00011020
REG_MULTI_SZ_OVERWRITEONLY_32BITKEY = 0x00014020
REG_NONE_64BITKEY = 0x00021001
REG_NONE_32BITKEY = 0x00022001
REG_NONE_NOCLOBBER = 0x00020003
REG_NONE_NOCLOBBER_64BITKEY = 0x00021003
REG_NONE_NOCLOBBER_32BITKEY = 0x00024003
REG_NONE_DELVAL = 0x00020005
REG_NONE_DELVAL_64BITKEY = 0x00021005
REG_NONE_DELVAL_32BITKEY = 0x00024005
REG_NONE_OVERWRITEONLY = 0x00020021
REG_NONE_OVERWRITEONLY_64BITKEY = 0x00021021
REG_NONE_OVERWRITEONLY_32BITKEY = 0x00024021
REG_KEYONLY_64BITKEY = 0x00001010
REG_KEYONLY_32BITKEY = 0x00004010
REG_KEYONLY_NOCLOBBER = 0x00000012
REG_KEYONLY_NOCLOBBER_64BITKEY = 0x00001012
REG_KEYONLY_NOCLOBBER_32BITKEY = 0x00004012
REG_KEYONLY_DELVAL = 0x00000015
REG_KEYONLY_DELVAL_64BITKEY = 0x00001015
REG_KEYONLY_DELVAL_32BITKEY = 0x00004015
REG_KEYONLY_OVERWRITEONLY = 0x00000030
REG_KEYONLY_OVERWRITEONLY_64BITKEY = 0x00001030
REG_KEYONLY_OVERWRITEONLY_32BITKEY = 0x00004030
REG_KEYONLY_COMMON_64BITKEY = 0x00003000
REG_KEYONLY_COMMON_32BITKEY = 0x00006000
REG_KEYONLY_COMMON_NOCLOBBER = 0x00002002
REG_KEYONLY_COMMON_NOCLOBBER_64BITKEY = 0x00003002
REG_KEYONLY_COMMON_NOCLOBBER_32BITKEY = 0x00006002
REG_KEYONLY_COMMON_DELVAL = 0x00002005
REG_KEYONLY_COMMON_DELVAL_64BITKEY = 0x00003005
REG_KEYONLY_COMMON_DELVAL_32BITKEY = 0x00006005
REG_KEYONLY_COMMON_OVERWRITEONLY = 0x00002020
REG_KEYONLY_COMMON_OVERWRITEONLY_64BITKEY = 0x00003020
REG_KEYONLY_COMMON_OVERWRITEONLY_32BITKEY = 0x00006020
REG_UNKNOWN_64BITKEY = 0x00031001
REG_UNKNOWN_32BITKEY = 0x00032001
REG_UNKNOWN_NOCLOBBER = 0x00030003
REG_UNKNOWN_NOCLOBBER_64BITKEY = 0x00031003
REG_UNKNOWN_NOCLOBBER_32BITKEY = 0x00034003
REG_UNKNOWN_DELVAL = 0x00030005
REG_UNKNOWN_DELVAL_64BITKEY = 0x00031005
REG_UNKNOWN_DELVAL_32BITKEY = 0x00034005
REG_UNKNOWN_OVERWRITEONLY = 0x00030021
REG_UNKNOWN_OVERWRITEONLY_64BITKEY = 0x00031021
REG_UNKNOWN_OVERWRITEONLY_32BITKEY = 0x00034021

; ServiceType values
SERVICE_KERNEL_DRIVER = 0x00000001
SERVICE_FILE_SYSTEM_DRIVER = 0x00000002
SERVICE_ADAPTER = 0x00000004
SERVICE_RECOGNIZER_DRIVER = 0x00000008
SERVICE_WIN32_OWN_PROCESS = 0x00000010
SERVICE_WIN32_SHARE_PROCESS = 0x00000020
SERVICE_INTERACTIVE_PROCESS = 0x00000100
SERVICE_INTERACTIVE_SHARE_PROCESS = 0x00000120

; StartType values
SERVICE_BOOT_START = 0x00000000
SERVICE_SYSTEM_START = 0x00000001
SERVICE_AUTO_START = 0x00000002
SERVICE_DEMAND_START = 0x00000003
SERVICE_DISABLED = 0x00000004

; ErrorControl values
SERVICE_ERROR_IGNORE = 0x00000000
SERVICE_ERROR_NORMAL = 0x00000001
SERVICE_ERROR_SEVERE = 0x00000002
SERVICE_ERROR_CRITICAL = 0x00000003

SPSVCINST_TAGTOFRONT = 0x00000001
SPSVCINST_ASSOCSERVICE = 0x00000002
SPSVCINST_DELETEEVENTLOGENTRY = 0x00000004
SPSVCINST_NOCLOBBER_DISPLAYNAME = 0x00000008
SPSVCINST_NOCLOBBER_STARTTYPE = 0x00000010
SPSVCINST_NOCLOBBER_ERRORCONTROL = 0x00000020
SPSVCINST_NOCLOBBER_LOADORDERGROUP = 0x00000040
SPSVCINST_NOCLOBBER_DEPENDENCIES = 0x00000080
SPSVCINST_NOCLOBBER_DESCRIPTION = 0x00000100

COPYFLG_WARN_IF_SKIP = 0x00000001
COPYFLG_NOSKIP = 0x00000002
COPYFLG_NOVERSIONCHECK = 0x00000004
COPYFLG_FORCE_FILE_IN_USE = 0x00000008
COPYFLG_NO_OVERWRITE = 0x00000010
COPYFLG_NO_VERSION_DIALOG = 0x00000020
COPYFLG_OVERWRITE_OLDER_ONLY = 0x00000040
COPYFLG_REPLACEONLY = 0x00000400
COPYFLG_REPLACE_BOOT_FILE = 0x00001000
COPYFLG_NOPRUNE = 0x00002000

this is the integration process executed by DXIntegrator

1 [FilePermissionsBeforeIntegration]

2 [securityFilesBeforeIntegration]

3 [ProcessesToRunBeforeIntegration]

4 [securityRegistryBeforeIntegration]

5 Offline Install Execution (installs addon AddOn)

6 [TweaksAddReg]

7 [TweaksDelReg]

8 [securityRegistryAfterIntegration]

9 [ProcessesToRunAfterIntegration]

10 [securityFilesBeforeIntegration]

11 [FilePermissionsAfterIntegration]

Share this post


Link to post
Share on other sites

DX Integrator INF file syntax

To create a Multiple Platforms and Operating Systems setup.inf file you can use in your addon inf file these sections:

http://www.wincert.net/forum/index.php?/forum/128-inf-discussion/

http://msdn.microsoft.com/en-us/library/ff548687%28v=VS.85%29.aspx

http://technet.microsoft.com/en-us/library/dd309538.aspx

http://www.ryston.com/x/INF_web/

http://www.osronline.com/ddkx/install/create-inf_4l47.htm

So the inf file of a True AddOn for Windows 2000/XP/2003/Vista/Seven must be as follows:


[color=green][b];section installing Optional Components in 2000/XP/2003[/b][/color]
[Optional Components]
SectionName

[color=green][b];Optional Components section for Windows 2000/XP/2003 in nLite & RVMi[/b][/color]
[SectionName]
....
....

[color=green][b];Optional Components section for Windows Vista/Seven in DXIntegrator[/b][/color]
[SectionName.nt]
....
....

In this case Sysoc doesn't read section with ".nt" etc., so you can use directly section name inside inf file to install the component both in Windows 2000/XP/2003 and in Windows Vista/Seven

so if AddOn will be integrated in Windows 2000/XP/2003 with nLite & RVMi, sysoc will install [sectionName] section during windows setup

If AddOn will integrated in Windows Vista/Seven withDXIntegrator instead, then DXIntegrator will read inf file according to microsoft rules about .inf file, meanging it will start to read sections in this way, first [sectionName.ntx86] or [sectionName.ntamd64]; if not found, then it will search for [sectionName.nt], then [sectionName], so in this case (Windows Vista/Seven) it wil find and install [sectionName.nt]; In this way [sectionName.nt] can be customized for a Windows Vista/Seven installation and [sectionName] for a Windows 2000/XP/2003 installation instead.

Multiple Platforms

For an inf file designed for a Multiple Platforms addon, you need these sections:


[color=green][b];Install component only in x32 systems (x86)[/b][/color]
[SectionName.ntx86]
....
....

[color=green][b];Install component only in x64 systems (amd64)[/b][/color]
[SectionName.ntamd64]
....
....

In this case DXIntegrator wil choose which section will install according to choosen OS

Multiple Operating Systems

For an inf file designed for a Multiple Operating Systems AddOn instead, you need these sections (Warning: microsoft doesn't support these options during Defaultinstall; They can be used only if you integrate them with DXIntegrator. Microsoft supports them in inf file in HW install only http://msdn.microsoft.com/en-us/library/ff550743%28v=VS.85%29.aspx

http://msdn.microsoft.com/en-us/library/ff539924%28v=VS.85%29.aspx

http://msdn.microsoft.com/en-us/library/ff550743%28v=VS.85%29.aspx

6.0 = Vista

6.1 = Windows 7


[color=green][b];Install component only in Windows Vista[/b][/color]
[SectionName.6.0]
....
....

[color=green][b];Install component only in Windows 7[/b][/color]
[SectionName.6.1]
....
....

Oppure


[color=green][b];Install component only in Windows Vista[/b][/color]
[SectionName.nt.6.0]
....

[color=green][b];Install component only in Windows 7[/b][/color]
[SectionName.nt.6.1]
....

;in case of Multiple Platforms

http://msdn.microsoft.com/en-us/library/ff539924%28v=VS.85%29.aspx


[color=green][b];Install component only in Windows Vista x32 (x86)[/b][/color]
[SectionName.ntx86.6.0]
....
....

[color=green][b];Install component only in Windows Vista x64 (amd64)[/b][/color]
[SectionName.ntamd64.6.0]
....
....


[color=green][b];Install component only in Windows 7 x32 (x86)[/b][/color]
[SectionName.ntx86.6.1]
....
....

[color=green][b];Install component only in Windows 7 x64 (amd64)[/b][/color]
[SectionName.ntamd64.6.1]
....
....

Edited by nonno fabio

Share this post


Link to post
Share on other sites

How to add/delete code in Windows 7 installation

First you must convert .reg file registry lines in INF file lines: for this you need n7Epsilon Reg2Inf tool

Here's is an example of windows 7 tweak reg file:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\PcaSvc]
"Start"=dword:00000004

[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\services\PcaSvc]
"Start"=dword:00000004

Export it with Notepad and send it to Reg2inf and you should get this:

[Version]
Signature="$Windows NT$"

[Optional Components]
MyRegTweaks

[DefaultInstall]
AddReg =REGEntries.AddReg
DelReg =REGEntries.DelReg

[MyRegTweaks]
OptionDesc ="Registry Entries"
Tip ="Registry Entries"
Modes =0,1,2,3
AddReg =REGEntries.AddReg
DelReg =REGEntries.DelReg

[REGEntries.AddReg]
; Reg2Inf v0.46 - http://tinyurl.com/fgqyf
HKLM,"SYSTEM\CurrentControlSet\services\PcaSvc","Start",0x10001,04,00,00,00
HKLM,"SYSTEM\ControlSet001\services\PcaSvc","Start",0x10001,04,00,00,00

[REGEntries.DelReg]
; Reg2Inf v0.46 - http://tinyurl.com/fgqyf

You can already directly use this inf file: if you name it Test.inf the entries.ini command will be:


[color=limegreen];This section contains entries that need to go into the [Components] section of the OCSysPrep.inf file. [/color]
[SysPrepOC]
Test=advpack.dll,LaunchINFSection,Test.inf,MyRegTweaks

[color=blue];for nLite RVMi in case you want to integrate the addon in Windows 2000/XP/2003 too[/color]
[color=limegreen];This section contains entries that need to go into the [Components] section of the Sysoc.inf file.[/color]
[sysoc]
Test = ocgen.dll,OcEntry,Test.inf,HIDE,7

If you want a more professional and/or customized inf file, the only lines needed are the ones under following sections:

REGEntries.AddReg and REGEntries.DelReg; got them and create an inf file compatible with both nLite/RVMi in Windows 2000/XP/2003 and DXIntegrator in Windows Vista/Seven: see more here (italian): http://www.eng2ita.net/forum/index.php/topic,7071.0.html

Here is a real example on how will must be your inf file in this case:

dscp1.png

dscp2.png

dscp3.png

dscp4.png

dscp5.png

[Version] - http://msdn.microsoft.com/en-us/library/ff547502%28v=VS.85%29.aspx

in a normal inf file normale you need only signature command under this section:


[Version]
signature="$Windows NT$"
[color=green]; or signature="$Chicago$"[/color]

Also these commands are default in the inf file structure, so they read and used by DXIntegrator too to take out info, etc.:

DriverVer=11/14/2010, %DSCP_ProductVersion%
Provider=Microsoft

These command instead:

Customizedby=Berserk - DMD
PackageDisplayName=%ProductName%
PackageReleaseType=True AddOn
PackageLanguage=%LANGNAME%
PackageDescription=%DSCPTip%

are optionals. They are read by DXIntegrator only, in general they're not mandatory because when DXIntegrator integrates an addon it reads entries.ini file and it writes them by itself if they're are missing.

[Optional Components], is the section read by SYSOC in Windows 2000/XP/2003 during Windows setup to install optional components. You can write here from one to more section name to install, in this example DSCP onlyDSCP


[Optional Components]
DSCP

[DSCP] is the section indicated by Optional Components section, so this is the one that SYSOC will install in Windows 2000/XP/2003 Setup

Following command are SYSOC defaults: this means, for example, that if Modes is missing so SYSOC don't installs this section in Windows Setup


OptionDesc ="%ProductName%"
Tip ="%DSCPTip%"
Modes = 0,1,2,3

About AddReg: http://msdn.microsoft.com/en-us/library/ff546320%28v=VS.85%29.aspx


AddReg = DSCP.Reg.Add.Values, DSCP.Add.Reg.ARP

This command can be used in every kind of inf file both from SetupAPI and Advpack etc., in this case it is used to install or add our regentries in system (in the example TWEAK doesn't consider regentries deletion so DelReg is not used)

[DSCP.nt] is the section read and prepared for Windows Vista/Seven Setup by DXIntegrator in this case


AddReg = DSCP.Reg.Add.Values, DSCP.Add.Reg.ARP
BackupReg = DSCP.Reg.Restore.Values

BackupReg is a command used in advanced INF options (when LaunchINFSectionEx is used: http://www.mdgx.com/INF_web/backup.htm). Now with DXIntegrator you can run it also from SetupApi or LaunchINFSection. In DXintegrator this command has same purpose: it saves the reg before installation and then restores it during Remove or Uninstall. The only difference in this case is that DXIntegrator backs up the reg in the same inf file, very useful in our case because reg rollback can be restored both in offline mode when DxIntegrator runs and in Online mode, for example when you want to unistall an addon from the Control Panel. The rollback section name is the same but with ".RollBack" at its end, for example the reg to be saved in DSCP.Reg.Backup section will be written by DXIntegrator lin DSCP.Reg.Backup.RollBack section (In this case it's not present because DSCP.Reg.Backup.RollBack will be created by DXIntegrator when the addon is installed in Offline Mode)

[DSCP.PerUser] is an optional section: Sometimes regentries are not added in a correct way or Windows setup overwrites them so better add it always after setup using peruserinstall. Peruserinstall run always before first desktop in Windows setup, after Runonce and RunonceEx, this means it is the latest configuration of system.

In this example is not needed but it is here to give you an example, to enable it you only need to add ".PerUser" in entries.ini section name like this:

[color=limegreen];This section contains entries that need to go into the [Components] section of the OCSysPrep.inf file. [/color]
[SysPrepOC]
DSCP=advpack.dll,LaunchINFSection,DSCP.inf,DSCP.PerUser

[DestinationDirs] - http://msdn.microsoft.com/en-us/library/ff547383%28v=VS.85%29.aspx

[DestinationDirs]
DefaultDestDir = 17

in this section you need to indicate directory destinations where to copy/delete/rename/etc. files. In the example is added to use "DefaultDestDir" command, and it shows where to copy inf file inf

[DSCP.Reg.Add.Values] is the section shown in AddReg command under "DSCP" and "DSCP.nt" sections (as always this regline works with both Windows XP and Windows 7)

[DSCP.Reg.Add.Values]
[color=limegreen]; Disables Program Compatibility Service[/color]
HKLM,"SYSTEM\CurrentControlSet\services\PcaSvc","Start",0x10001,04,00,00,00
HKLM,"SYSTEM\ControlSet001\services\PcaSvc","Start",0x10001,04,00,00,00

[DSCP.Add.Reg.ARP] is the section shown in AddReg command under "DSCP" and "DSCP.nt" sections: these regentries adds removal option in Control Panel

[DSCP.Add.Reg.ARP]
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","DisplayIcon", ,"%10%\regedit.exe"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","DisplayName", ,"%ProductName% %DSCP_ProductVersion%"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","DisplayVersion", ,"%DSCP_ProductVersion%"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","OnlineVersion", ,"%DSCP_ProductVersion%"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","Publisher", ,"DMD"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","UninstallString", ,"rundll32.exe advpack.dll,LaunchINFSection %17%\DSCP.inf,DefaultUninstall"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","URLInfoAbout", ,"http://www.eng2ita.net/forum/index.php/topic,6164.0.html"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","ParentKeyName", ,"OperatingSystem"
HKLM,"%KEY_WIN_CURVER%\Uninstall\DSCP","ParentDisplayName", ,"%PARENT_DISPLAY_NAME%"

[PerUserInst] is the section shown in PerUserInstall command under "DSCP.PerUser" section

[PerUserInst]
DisplayName=%ProductName%
Version=1.0.0000.0
IsInstalled=1
ComponentID=DSCP
GUID={x0020200-ecbd-11cf-8b85-00aa0050dscp}
Locale=en
StubPath=rundll32.exe advpack.dll,LaunchINFSection %17%\DSCP.inf,PerUser.Install,1,N

StubPath command shows the command to run: in the example it runs the command which installs "PerUser.Install" section

[PerUser.Install] is the section to be installed in PerUser Mode in StubPath command under "PerUserInst" section

[PerUser.Install]
AddReg = DSCP.Reg.Add.Values, DSCP.Add.Reg.ARP
DelReg = PerUser.CleanUp

[PerUser.CleanUp] is the section indicated in DelReg command under "PerUser.Install" section

[PerUser.CleanUp]
HKCU,"Software\Microsoft\Active Setup\Installed Components\>{x0020200-ecbd-11cf-8b85-00aa0050dscp}"
HKLM,"Software\Microsoft\Active Setup\Installed Components\>{x0020200-ecbd-11cf-8b85-00aa0050dscp}"
HKU,".DEFAULT\Software\Microsoft\Active Setup\Installed Components\>{x0020200-ecbd-11cf-8b85-00aa0050dscp}"
HKU,"S-1-5-18\Software\Microsoft\Active Setup\Installed Components\>{x0020200-ecbd-11cf-8b85-00aa0050dscp}"
HKU,"S-1-5-19\Software\Microsoft\Active Setup\Installed Components\>{x0020200-ecbd-11cf-8b85-00aa0050dscp}"
HKU,"S-1-5-20\Software\Microsoft\Active Setup\Installed Components\>{x0020200-ecbd-11cf-8b85-00aa0050dscp}"

this will remove all regentries used in peruser mode: better do this as peruser mode has been used only to execute a single command and nothing else but generally you can also not remove these lines, so everytime you add a new user account, with new configurations "rundll32.exe advpack.dll,LaunchINFSection %17%\DSCP.inf,PerUser.Install" will start again.

Warning: this is valid with DXIntegrator in Windows Vista/Seven only: in Windows 2000/XP/2003 nLite/RVMi won't work because SYSOC doesn't recognize PerUserInstall command. In Windows 2000/XP/2003 you must use a different way (see inside Onepiece's IE7/8 addon)

[DefaultUninstall] is the section indicated in "DSCP.Add.Reg.ARP" section, in other word the section executed when Control Panel uninstall is chosen

[DefaultUninstall]
BeginPrompt = BeginUnInsPrompt
AddReg = DSCP.Reg.Backup.RollBack
DelReg = DSCP.Add.Reg.ARP
UpdateInis = DSCP.OCSysPrep.CleanUp
EndPrompt = EndUnInsPrompt
CleanUp = 1

[DSCP.OCSysPrep.CleanUp] is the section indicated in UpdateInis command under "DefaultUninstall" section

[DSCP.OCSysPrep.CleanUp]
%17%\OCSysPrep.inf,Components,DSCP=*

This section removes the component from [Components] section in %WinDir%\inf\OCSysPrep.inf (as SYSOC does in Windows 2000/XP/2003)

[beginUnInsPrompt] is the section indicated in BeginPrompt command under "DefaultUninstall" section

[BeginUnInsPrompt]
Title = %ProductName% Uninstaller
Prompt = %UnInsPrompt%
ButtonType = YESNO ;<- YESNO or OKCANC

This opens a windows before removal starts, prompting if you want to proceed or not: if you click on YES removal starts, if you click on NO removal is aborted.

[EndUnInsPrompt] is the section indicated in EndPrompt command under "DefaultUninstall" section

[EndUnInsPrompt]
Prompt = %EndUnInsPrompt%

This opens a windows at the end of removal process, informing if removal has been successful or not, etc.

[DefaultInstall] is the section which starts when installation is manually run clicking on inf file.

[DefaultInstall]
BeginPrompt = BeginInstPrompt
CopyFiles = @DSCP.inf
AddReg = DSCP.Reg.Add.Values, DSCP.Add.Reg.ARP
UpdateInis = Update.Sysoc
EndPrompt = EndInstPrompt

About command CopyFiles http://msdn.microsoft.com/en-us/library/ff546346%28v=VS.85%29.aspx

Warning! According to inf file rules, if no section name has been indicated in installation command, DXIntegrator always search for DefaultInstall section, and if found customizes and installs it, for example if in entries.ini you use these lines

[SysPrepOC]
DSCP=advpack.dll,LaunchINFSection,DSCP.inf

then DXIntegrator search inside DSCP.inf file DefaultInstall section and customizes and installs it

[update.Sysoc] is the section indicated in UpdateInis command under "DefaultInstall" section

[Update.Sysoc]
%17%\OCSysPrep.inf,"Components",,"DSCP=advpack.dll,LaunchINFSection,DSCP.inf,DSCP"

This section adds the component in [Components] section in %WinDir%\inf\OCSysPrep.inf (as SYSOC does in Windows 2000/XP/2003)

[beginInstPrompt] is the section indicated in BeginPrompt command under "DefaultInstall" section

[BeginInstPrompt]
Title = %ProductName% Uninstaller
Prompt = %InstPrompt%
ButtonType = YESNO ;<- YESNO or OKCANC

This opens a windows before installation starts, prompting if you want to proceed or not: if you click on YES installation starts, if you click on NO installation is aborted.

[EndInstPrompt] is the section indicated in EndPrompt command under "DefaultInstall" section

[EndInstPrompt]
Prompt = %EndInstPrompt%

This opens a windows at the end of installation process, informing if installation has been successful or not, etc.

[strings] - http://msdn.microsoft.com/en-us/library/ff547485%28v=VS.85%29.aspx

is the section where you can place the variables used in your inf file

These are the main options but inf file have endless possibilities. For further information follow Microsoft Guides

INF Sections - http://msdn.microsoft.com/en-us/library/ff547465%28v=VS.85%29.aspx

INF commands - http://msdn.microsoft.com/en-us/library/ff547388%28v=VS.85%29.aspx

Adding an entries.ini file created as usual, now you can create with your inf file a .cab Addon using CabTool http://www.eng2ita.net/forum/index.php/topic,6628.0.htm

Here is a windows 7 registry tweaks collection http://www.eng2ita.net/forum/index.php/topic,6164.0.html (italian)

and here are some sample addons (italian):

DMD Windows 7 Raccolta Tweak di registro True AddOn

tabdownload.png Update (March 23-2011)

Hash MD5 F103C39522A8D64A29E8F5603AFE5210

Filesize: 6.77 KB (6942 bytes)

DMD Abilita visualizzazione .mkv in MediaCenter True AddOn

tabdownload.png Update (March 23-2011)

Hash MD5 ECF5893C528E3093857CCDF393F26554

Filesize: 4.00 KB (4102 bytes)

DMD Aggiungere comandi COPIA e SPOSTA True AddOn

tabdownload.png Update (March 23-2011)

Hash MD5 859956469C3C264698AD2E2FDC668EBD

Filesize: 3.07 KB (3144 bytes)

DMD Apertura Menu rapidi True AddOn

tabdownload.png Update (March 23-2011)

Hash MD5 5F60D1A500C7D87709EC2CF14D2BB477

Filesize: 2.89 KB (2964 bytes)

DMD Apparizione cestino in esplora risorse True AddOn

tabdownload.png Update (March 23-2011)

Hash MD5 FD20BEBC067AB9A15BB999BCA9A6EA3F

Filesize: 2.98 KB (3058 bytes)

DMD Disattiva il servizio compatibilità programmi True AddOn

tabdownload.png Update (March 23-2011)

Hash MD5 38AC0AD68FE1A029FF8B4C79750F56C6

Filesize: 2.93 KB (3002 bytes)

DMD Impostazioni dei Valori UAC True AddOn

tabdownload.png Update (March 23-2011)

Hash MD5 740D25D741A25A0B7AA1FEF2405BA169

Filesize: 3.25 KB (3330 bytes)

13679894.png

85633910.png

99169059.png

63015826.png

aaals.png

aaa2u.png

aaa3.png

20523994.png

Edited by nonno fabio

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...