Table of ContentsClose
Coder for Life

Win 7 Boot Updater: Extras

During the development of the Windows 7 Boot Updater many smaller projects / programs were made. Some of these programs are released below, and many include their source.

  • BS7 File Format: the format used for the Windows 7 boot skin files
  • video2png: converts video files to many PNG files
  • mng2png: converts a MNG file to many PNG files
  • bmzip: bootmgr decompressor / compressor
  • BootRes: breaks up or puts together the activity.bmp file in bootres.dll
  • reCAPTCHA.NET: a reCAPTCHA control for desktop .NET programs (not ASP.NET)
  • signer: tool to work with custom certificates and self-signing programs
  • xml-compact: compacts an XML file by removing unnecessary white-space
  • TestsigningOff: turns TESTSIGNING off for all BCD entries with it on
  • OpenHiddenSystemDrive: opens the Windows 7/8 small 'hidden' partition in Windows Explorer
  • VolumeInfo: lists detailed information about all volumes (hard drives, CD drives, ...) on the computer
  • DriveInfo: lists detailed information about all drives and partitions on the computer, either MBR or GPT
  • boot-info: lists basic information about the current Windows install, boot files, and boot configuration
  • MsgTableEditor: easily edit extracted message tables from PE files

In addition to these, code from programs that I previously published into the public domain were used: BatchResourceUpdater, PEChecksum, xdel, and security.



BS7 File Format

This is the file format used by the Windows 7 Boot Updater program. It is published so that others may make editors or automated solutions or whatever.

With v0 Beta 1 (v0.0.1.1) a new file format was introduced (although the program is still able to read boot skins made before with v0 Alpha 11 (v0.0.0.11) and earlier). The new format takes the XML file that used to be the entire file and wraps it in a multipart/related file so that the images can be included in plain binary instead of encoding them into base64 (which causes a 33% gain in file size).

BS7 XML Schema and multipart/related information (5.31 KB, updated 2012-11-08)

Example Boot Skin (1.3 KB, updated 2012-11-08)



video2png

Converts any video file to many PNG files. It primarily uses the open-source ffmpeg to do the conversion, so any video file it supports can be converted. I have added a batch simplify the conversion, which forces the output to match that of the Windows 7 boot animation: 200x200 frames, 15 fps, 105 frames. Simply download and extract the zip file then drag a video file onto the video2png.bat file.

viedo2png (32-bit) (5.97 MB, updated 2012-11-08)

viedo2png (64-bit) (6.31 MB, updated 2012-11-08)



mng2png

Converts a MNG file to many PNG files. This was not produced by me. It primarily is uses the open-source advmng, which is part of AdvanceCOMP by AdvanceMAME. Simply extract the ZIP file and drag a MNG file onto the mng2png.bat file.

mng2png (209.64 KB, updated 2012-11-08)



bmzip

If you have ever looked at the bootmgr in Windows 7 (C:\Windows\Boot\PCAT\bootmgr) you would be totally confused. The file actually has 3 parts: the 16-bit boot stub which can be loaded directly by the BIOS and two PE (EXE) Files. The two PE files can be found by searching for "MZ\x90\0". The first only contains a single version resource in a 'corrupted' resource table*. The second is compressed and is the program that does most of the work.

To be able to study or change the compressed PE image you need to expand it. I have figured out how the compression works and I provide a utility to (un)compress it below. The program can either take an entire bootmgr file or just the extracted compressed program (including the three bytes before the "MZ")

The utility can re-compress the file as well. The recompressed file is ~20 bytes larger than the original compressed file (not bad for figuring this all out on my own!). Currently there is no system for rebuilding the complete bootmgr file, however this is fairly easy with a hex editor.

Released under the Windows 7 Boot EULA. It may not be used for commercial purposes.

Updates:

  • 5/8/2011:
    • Improved compressor:
      • Improved speed (4x as fast)
      • Improved compression ratio (only ~20 bytes worse than original instead of ~1.5 KB)
    • Can now take a complete bootmgr file instead of needing it extracted first

bmzip (32-bit) (17.5 KB, updated 2012-11-08)

bmzip (64-bit) (20.5 KB, updated 2012-11-08)

Command Line:

  1. bmzip compressed_file decompressed_file (decompresses the file)
  2. bmzip /c uncompresed_file compressed_file (compresses the file)

Tested by ensuring that the checksum and digital certificate of the decompressed file work and that if you decompress the re-compressed file it results in an identical file.

* It isn't really corrupted, it is just that every program in existence has 3 levels deep of directories (for type, name, and language) and so every program that can read resources (including Windows Explorer) assumes that it will be 3 levels deep. Well, this program uses only one level (for type) and nothing else. The specification of resources tables does not mandate 3 levels deep, so it is technically allowed.



BootRes

Allows you to easily take the activity.bmp file and break it apart or to take a folder of 105 frames and create an activity.bmp file. Written in C++/CLR (.NET). It is run from the command line. Run the program without any parameters for more information.

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

BootRes (40 KB, updated 2012-11-08)

BootRes Source (6.81 KB, updated 2012-11-08)



reCAPTCHA.NET

A user control that implements the image and audio of reCAPTCHA for desktop applications. It is written in C# and comes with a demo program. It handles the challenges but your application must implement the user input and the buttons for help, reload, and switching challenge type. The control exposes methods to easily access these functions. It also does not handle the verification, you must have a server-side script for that.

Released under the MIT License since all the other reCAPTCHA plugins / libraries are released under that license.

reCAPTCHA (107 KB, updated 2012-11-08)

reCAPTCHA Source (99.3 KB, updated 2012-11-08)

Updated to no longer require the NAudio library and instead uses the built-in mciSendString function.



signer

A tool to work with custom certificates and self-signing. It has five commands:

  • /list lists available certificates that can be used for signing on your computer
  • /create creates a custom certificate authority and code-signing certificate
  • /sign signs a program, automatically creating a CA/certificate if necessary
  • /export exports a certificate so it can be installed on another computer
  • /install installs a certificate into an off-line registry hive, such as ones in boot.wim/install.wim

Run the program without any commands to see how to use it. It is written in C.

This program can also sign driver packages but you first must create a security catalog for the driver package using inf2cat. You can then sign the resulting .cat file.

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

signer (32-bit) (28 KB, updated 2012-11-08)

signer (64-bit) (31 KB, updated 2012-11-08)

signer Source (15.17 KB, updated 2012-11-08)

signer example script to work with a mounted WIM (604 bytes, updated 2012-11-08)



xml-compact

Compacts an XML file by removing all unnecessary white-space. This allows you to nicely include XML/XSD files in executables that are 20-30% smaller than the nice to read and edit forms. Written in C#.

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

xml-compact (6 KB, updated 2012-11-08)

xml-compact Source (3.87 KB, updated 2012-11-08)



TestsigningOff

Finds which (if any) BCD entries have TESTSIGNING on (including {bootmgr}) and turns TESTSIGNING off for them. It is a nice example of using the BCD / WMI from managed (.NET) source. Written in C++ / CLI.

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

TestsigningOff (32-bit) (69 KB, updated 2012-11-08)

TestsigningOff (64-bit) (77.5 KB, updated 2012-11-08)

TestsigningOff Source (23.8 KB, updated 2012-11-08)



OpenHiddenSystemDrive

Opens the small 'hidden' system partition named "System Reserved" in some Windows 7/8 installs. Not all installs have this partition. Once the folder opens, it may look empty, but it is just because everything is well hidden on it. You must show hidden and protected system files to see them.

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

Updated on 1/9/2012 to find partitions up to 500 MB (instead of 150 MB) since Windows 8 uses 350 MB instead of 100 or 150 MB.

OpenHiddenSystemDrive (32-bit) (28 KB, updated 2012-11-08)

OpenHiddenSystemDrive (64-bit) (31.5 KB, updated 2012-11-08)

OpenHiddenSystemDrive Source (9.3 KB, updated 2012-11-08)



VolumeInfo

Lists detailed information about all volumes on the computer. Volumes include hard drives, CD/DVD/Blu-Ray drives, thumb drives, external hard drives, flash card readers, and floppy disks. It even includes some drives that are hidden. It lists information like serial number, format, features, how to access, and much more!

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

VolumeInfo (32-bit) (10.5 KB, updated 2012-11-08)

VolumeInfo (64-bit) (17.5 KB, updated 2012-11-08)

VolumeInfo Source (3.91 KB, updated 2012-11-08)



DriveInfo

Lists detailed information about all drives and partitions on the computer. It includes MBR and GPT disks.

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

DriveInfo (32-bit) (22.5 KB, updated 2012-11-08)

DriveInfo (64-bit) (28.5 KB, updated 2012-11-08)

DriveInfo Source (9.47 KB, updated 2012-11-08)



boot-info

Lists basic version information about the current Windows installation, boot files (bootmgr, winload.exe, and winresume.exe), and boot configuration. Useful for diagnosing issues and finding out about changes due to Windows Update. Allows you to copy and save the information easily.

Released under the Windows 7 Boot EULA. It may not be used for commercial purposes.

boot-info (32-bit) (54.5 KB, updated 2012-11-08)

boot-info (64-bit) (57 KB, updated 2012-11-08)



MsgTableEditor

Allows you to easily edit message tables extracted from PE Files (EXE, DLL, MUI, ...). Note that this is not complete, however the code to decompile and recompile the message table from a data structure is all provided, so you would just need to add some code to modify the data structure. It is written in C. The message tables can be extracted using 7-zip or resource editors. The program runs as an interactive terminal. It can optionally take the name of a file to open as an argument.

Released under the GPLv3 License. It is free to use for personal and open-source software but may not be used commercially.

MsgTableEditor (32-bit) (15.5 KB, updated 2012-11-08)

MsgTableEditor (64-bit) (21.5 KB, updated 2012-11-08)

MsgTableEditor Source (9.46 KB, updated 2012-11-08)



Windows is a registered trademark of Microsoft Corporation in the United States and other countries.

Comments

0 Responses to 'Win 7 Boot Updater: Extras' Feed for this Entry

There are currently no comments.


Leave a Reply >
Note: If you are having a problem with Windows 7 Boot Updater read the troubleshooting list first!.
If your question has already been answered there or in the comments it will be deleted.
Automatically creates links and paragraphs.
Many HTML tags are supported.
Use <code language=""></code> for code.
Language can be dos, java, php, c, ...
(not published)