Jump to content











Photo
- - - - -

Some questions regarding VistaPE scripts


  • Please log in to reply
5 replies to this topic

#1 zzz

zzz
  • Members
  • 1 posts
  •  
    Sweden

Posted 15 June 2008 - 06:25 PM

Hi all,

Although I'm used to BartPE I'm new to VistaPE and need help. I'm using WinBuilder 12 beta 2 and a Vista SP 1 image as source. See my questions below:

1) How do I add/change registry settings in a script? Please write an example.

2) Is the following all I need in order to associate a program added thrue a script to a file container? "associate_file,nfo".

3) I've created a plugin to BartPE that needs a filter driver added/loaded in order to function. That plugin has to be run as the last one during the building process to avoid other plugins to overwrite my plugin. I solved that by adding "ZZZZ" to the beginning of the plugin name. The question is how WinBuilder does this? Should I use the "Level" entry in the script and if that is true, which level is processed last?

4) WinBuilder created the below script lines for me but when I try to build it fails due to the very same script lines. What's up with that and how do I add the below to the Txtsetup.sif file?

[AddLine]
INIAddLine,Txtsetup.sif,SourceDisksFiles,prot_2k.sys=1,,,,,,3_,4,0,0,,1,4
INIAddLine,Txtsetup.sif,BusExtenders.Load,prot_2k=prot_2k.sys
INIAddLine,Txtsetup.sif,BusExtenders,prot_2k="Pointsec for PC Filter Driver",files.none,prot_2k

5) WinBuilder seems to not remember the source path I use. A mounted Vista image. Even though I've set the path once I have to set it again the last thing I do before I start to build. Am I doing something wrong or is this a bug?

WinBuilder looks very promising but if I can't get the above sorted I'll have to stick to BartPE. Thanks for your help!

#2 Nuno Brito

Nuno Brito

    Platinum Member

  • .script developer
  • 10545 posts
  • Location:boot.wim
  • Interests:I'm just a quiet simple person with a very quiet simple life living one day at a time..
  •  
    European Union

Posted 15 June 2008 - 09:09 PM

Hi all,


Hello, welcome!

:)



Although I'm used to BartPE I'm new to VistaPE and need help. I'm using WinBuilder 12 beta 2 and a Vista SP 1 image as source. See my questions below:


There is a small confusion here, I think you're using VistaPE version 12 beta 2

WinBuilder is a separate development and is going on version 75 beta 3 at this moment.

You can always grab the latest beta from this location: http://winbuilder.ne...load.php?list.4

Usually there is a forum topic where these changes are published for either VistaPE or WinBuilder




1) How do I add/change registry settings in a script? Please write an example.


You write them almost in the same manner but unlike bartPE, there is no predefined section for adding data onto hives.

Therefore, it is required to add instructions to load and unload the respective hive you wish to write on.

We use something called "API script" which allows to create a sort of cross portable code.

There is a simple getting started tutorial here:
http://www.boot-land...?showtopic=4424

In order to write registry keys, look on this example:
Hive_Load,HKCU

reg_add,0x3,"%reg%\Software\ORL\WinVNC3","Password",%vnc_key%

reg_add,0x3,"%reg%\Software\ORL\WinVNC3","PasswordViewOnly",%vnc_key%

hive_unload,HKCU


Hive_Load and Hive_Unload will prepare/unload the hive for your use, reg_add is responsible for adding the data.

Available hives to load:
[User,Default or HKCU],[Machine or HKU] and [System or HKLM]

You need to use one of the values between []. We use this implementation to resemble as close as possible the way how "real" windows work. For example, under XP PE environment there is a setupreg.hiv but this is not the case for Windows PE.

0x3 is the data type, beware that 0x4 numbers are here represented in decimal (opposed to hexadecimal from .INF)

"%reg%\" is a wrapper we use on app scripts, always the same value.

The rest is very much the same, there is a tool to convert your plugins - on wb click "Tools" --> "Convert"

---------------




2) Is the following all I need in order to associate a program added thrue a script to a file container? "associate_file,nfo".


For using this you will also have to provide more details like the location of the exe file for example.

Read the tutorial for creating an app script: http://www.boot-land...?showtopic=4424

Once you finish a simple app script, just add this line inside the [process] section.
associate_file,nfo



3) I've created a plugin to BartPE that needs a filter driver added/loaded in order to function. That plugin has to be run as the last one during the building process to avoid other plugins to overwrite my plugin. I solved that by adding "ZZZZ" to the beginning of the plugin name. The question is how WinBuilder does this? Should I use the "Level" entry in the script and if that is true, which level is processed last?


Level starts from 1 all the way to 10.

There are no fixed rules regarding the way how WinBuilder will see a script and it will run all scripts following this order:

Level number
Files first / Folders Last
Alphabetical order of the filename (script can have a custom title)


But when it comes to project organization, there are some rules in order to keep everything tidy and organized.


Each project author can define how each level is used. For example, the first level scripts (1..3) are usually used for copying the basic OS files and build the initial structure. While last level scripts (8..10) are used for post-processing (this is a bartPE term), tweaking the end image, creating the image and perhaps see the results on the emulator.

App scripts use level=5 (in the middle of the project)
Drivers go to Level=6

If you want to follow the ZZZ naming, then create a folder called ZZZ inside the Apps folder and place your app scripts there - it should surely be the last folder to be processed inside the Apps folder but beware that this might not be necessary at all under winbuilder - this world is a bit different.


4) WinBuilder created the below script lines for me but when I try to build it fails due to the very same script lines. What's up with that and how do I add the below to the Txtsetup.sif file?

[AddLine]
INIAddLine,Txtsetup.sif,SourceDisksFiles,prot_2k.sys=1,,,,,,3_,4,0,0,,1,4
INIAddLine,Txtsetup.sif,BusExtenders.Load,prot_2k=prot_2k.sys
INIAddLine,Txtsetup.sif,BusExtenders,prot_2k="Pointsec for PC Filter Driver",files.none,prot_2k


I'm not surprised at all - txtsetup.sif is a file that only exists on XP PE (BartPE, LiveXP, etc..).

Under Windows PE 2.x there is no such file.

If you want to add drivers then you should ask specific help on this matter at the VistaPE forum.

Each winbuilder project has their specific method (it's not cross platform like app scripts usually are)

Look here for some examples of script code for VistaPE drivers:
http://vistape.net/p...ivers-ms.script
http://vistape.net/p...vers-lan.script

(or look inside your VistaPE Drivers folder)



5) WinBuilder seems to not remember the source path I use. A mounted Vista image. Even though I've set the path once I have to set it again the last thing I do before I start to build. Am I doing something wrong or is this a bug?


Really strange, it works fine on the projects that I use.

Did your mounted Vista image had the same driver letter?

Sometimes when you reboot your computer, the emulated drive might get a different drive letter if other removable drives are inserted. (this is generic to windows)

In case this does happen with the same drive letter, please report it on the vistaPE forum to check if it's not a project specific bug and in case it's winbuilder.exe specific then I would appreciate if you could mention it on the winbuilder.exe bug tracker: http://www.boot-land...ocom=bugtracker


WinBuilder looks very promising but if I can't get the above sorted I'll have to stick to BartPE. Thanks for your help!


Well.. in true honesty I say that you can't ever expect the same results/work method as bartPE.

This sort of projects go far beyond what could be measured on bartPE but this will require understanding new rules and ways of work that change quite quickly sometimes as a project evolves.

In return you get the ultimate freedom in terms of boot disk customization, not just a good user interface but most important is that each project can be modified from head to toes by you or anyone else who wishes to make it better.

:)

#3 JonF

JonF

    Gold Member

  • .script developer
  • 1185 posts
  • Location:Boston, MA
  •  
    United States

Posted 16 June 2008 - 12:14 PM

5) WinBuilder seems to not remember the source path I use. A mounted Vista image. Even though I've set the path once I have to set it again the last thing I do before I start to build. Am I doing something wrong or is this a bug?

No need to mount an image. Copy the files into a directory and point WinBuilder to that directory. Same technique works for BartPE, and doesn't use up drive letters.

#4 powaking

powaking

    Frequent Member

  • Advanced user
  • 238 posts
  • Location:Fall River, MA
  •  
    United States

Posted 23 June 2008 - 08:56 PM

Would be interested in your PointSec script once you have it down. Please make it available once you do.

#5 powaking

powaking

    Frequent Member

  • Advanced user
  • 238 posts
  • Location:Fall River, MA
  •  
    United States

Posted 12 August 2008 - 01:39 PM

Would be interested in your PointSec script once you have it down. Please make it available once you do.


Sorry for the bump but wondering if you ever got the pointsec plugin working.

#6 marioval

marioval
  • Members
  • 2 posts
  •  
    United States

Posted 16 September 2008 - 01:30 PM

Sorry for the bump but wondering if you ever got the pointsec plugin working.


I would also be interested in the Pointsec script.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users