How to create your own plugin

How to create your own plugin.

 

                                  

 

This is one way of the possible way’s to create a plugin. We are going to create a plugin using different tools available, and free of any charges.

 

Just keep one thing in mind; using these tools, doesn’t automatically mean, the plugin is working 100% correctly from the first time on. Some applications could well need some additional steps, such as starting from a cmd prompt, because for instance the application needs write access to do it’s job, and therefore it might be necessary to have the plugin copied to the ram drive before starting it.

One of the important issues, is try to find out what registry entry and/or modifications are done, when a program is installed. The program I use is InstallRite 2.5 .

This program takes snapshots of your system, (registry + installed files + ini files), before and after an installation of a program.

We are going to start InstallRite, by clicking on "install new software and create an InstallKit", do a first snapshot, start the setup from within InstallRite of our application we want to build, (after the installation, I usually start the application itself, because some of them create ini files, with the settings etc). After that, we continue with InstallRite to do a second snapshot, and save the changes viewed. (Just follow the wizard)

 

 

In the review of the installation, we can see, which files, ini-files and registry modifications are done.

Also you can export the changes which toke place in the registry before and after installation.

This exported registry file can be prepared for the plugin, by using Convert Reg File to PEBuilder 3 Inf File created by Paraglider .

Once the inf file is created by the converter to be used in your plugin, some additional steps are still needed, such as correcting the application paths entered in this inf file.

example:

0x1, "blablabla............App Path","C:\Program Files\application name"

Needs to be modyfied to

 0x1, "blablabla............App Path","%SystemDrive%\Programs\your plugin name"

Or

0x1,"blablabla..............................dll","C:\Windows\System32\blabla.dll"

would need to be modified to

0x1,"blablabla..............................dll","%SystemDrive%\i386\System32\blabla.dll"

both redirecting to the location on your CD.

Also, with InstallRite 2.5 you can see, when additional files are installed in other folders, then the installation folder, such as dll files in the system32 folder, and are needed for a correct running of the application. If needed, you have to copy them to the plugin folder, and modify the inf file, so these files are also copied during the build of your ISO file.

For creating the plugin itself, we are going to use the PluginBuilder 3.5.1  created by PapaTomTom by clicking on Plugin - Create Plugin... - Create normal plugin

Note: Plugin-Builder is also able to export registry files needed for your plugin.

You can perfectly combine the registry data from the inf file created with Convert Reg File to PEBuilder inf File, with the inf file created with PluginBuilder.

 

 Note: For all possibilities of Plugin-Builder, have a look at the Plugin-Builder help file  (a Dutch translation of the Plugin-Builder help (Pluginbuilder_help.doc) can be found here )

 

If additional files are needed, such as dll files which are located in your system32 folder, you also will have to copy them to your plugin, as well as add the entries to your plugin.inf file.

Here is a list of the (most used) directories ID's:

ID Directory Remark
30000 [root] PE Builder output root
1 \ SystemRoot (on CD this is the \i386 folder, on hd this is the \minint folder)
2 system32
3 system32\config
4 system32\drivers
5 system
7 system32\ras
9 system32\spool
10 system32\spool\drivers
11 system32\spool\drivers\w32x86\3
12 system32\spool\prtprocs
13 system32\spool\prtprocs\w32x86
14 system32\wins
15 system32\dhcp
16 repair
17 system32\drivers\etc
18 system32\spool\drivers\w32x86
19 system32\drivers\disdn
20 inf
21 Help
22 Fonts
24 msagent\intl
25 Cursors
26 Media
27 java
28 java\classes
29 java\trustlib
30 system32\ShellExt
31 Web
32 system32\Setup
33 Web\printers
34 system32\spool\drivers\color
35 system32\wbem
36 system32\wbem\Repository
37 addins
38 "Connection Wizard"
39 "Driver Cache\i386"
40 security
41 security\templates
42 system32\npp
43 system32\ias
44 system32\dllcache
45 Temp
46 Web\printers\images
47 system32\export
48 system32\wbem\mof\good
49 system32\wbem\mof\bad
50 twain_32
51 msapps\msinfo
52 msagent
53 msagent\chars
54 security\logs
55 system32\icsxml
57 system32\mui
58 %MUI_PRIMARY_LANG_ID_DIR%
59 system32\mui\dispspec
60 AppPatch
61 Debug
62 Debug\UserMode
63 system32\oobe
67 Help\Tours
68 Resources\Themes\Luna
69 Resources\Themes\Luna\Shell\NormalColor
70 system32\oobe\html\ispsgnup
71 system32\oobe\html\mouse
72 system32\oobe\html\oemcust
73 system32\oobe\html\oemhw
74 system32\oobe\html\oemreg
75 system32\oobe\images
76 system32\oobe\setup
77 system32\oobe\sample
78 Resources\Themes\Luna\Shell\Metallic
79 Resources\Themes\Luna\Shell\Homestead
91 Help\Tours\mmTour
92 Help\Tours\htmlTour
100 system32\1025
101 system32\1028
102 system32\1031
103 system32\1033
104 system32\1037
105 system32\1041
106 system32\1042
107 system32\1054
108 system32\2052
109 system32\3076
110 system32\wbem\xml
111 system32\usmt
112 system32\inetsrv
123 mui
124 WinSxS
125 WinSxS\Manifests
126 WinSxS\InstallTemp
127 ime
129 Resources\Themes
130 ime
132 ime\imejp
133 System32\IME\PINTLGNT
134 System32\IME\CINTLGNT
135 System32\IME\TINTLGNT
136 IME\CHTIME\Applets
137 ime\imejp98
138 ime\imejp\applets
180 system32\3com_dmi
252 WinSxS\Policies

For more specific settings, you should take a look a the pluginhelp.htm which comes with the PEBuilder installation files.

The last step is building your ISO file using PEBuilder and burn it on a CD/CDRW to test, or use a Virtual PC Program.

Good Luck!

Other tips are:
How to Slipstream Windows XP Service Pack

How to create a Bootable CD (after slipstreaming)
How to create an ISO file with Bart's PEBuilder
How to extract Windows PE from Longhorn
How to change the Bootscreen of Windows XP

 

Any remarks or suggestions, just let me know

Top

Disclaimer