Monday 16 December 2013

Boot HitManPro from Easy2Boot (or any grub4dos USB Flash drive)

HitManPro (Hitman Pro) can be booted from a grub4dos multiboot or Easy2Boot USB flash drive as follows:

The E2B USB drive must be of the 'Removable' type - it won't work if your E2B flash drive is of the Fixed-disk type (a USB HDD will not work either - Hitman will not auto-run when you boot to Windows).

Note: See the end of this post for an easy way to add the boot code to any Flash drive without reformatting it!

1. If your multiboot USB Flash drive already contains files, you will need to back these up by copying the entire contents of the USB Flash drive to an empty temporary folder on your hard disk.

2. Run the HitManPro USB utility and install HitManPro to the USB Flash drive. This will reformat the entire drive and you will lose all previous contents of the USB Flash drive!

Note: This 'format' process also writes data to some sectors (55 I think) at the very end of the drive. This is why it has to be the same drive that you are going to use for your multiboot drive.

3. Unplug and re-insert the USB Flash drive (it will be dismounted by the HitManPro installation program).

4. Copy the KickStarter.exe, HitManPro.exe and HitManPro_x64.exe files from the USB Flash drive to a temporary folder on your hard drive.

5. Use RMPrepUSB (or your favourite USB format utility) to prepare the USB Flash drive as if you were preparing it as a fresh drive. If you use Easy2Boot, just follow the Easy2Boot drive preparation instructions. It is safest to reduce the size of the last partition on the drive by 10MB to avoid overwriting the last 60 or so sectors that are used by HitManPro. In practice though, these are probably fairly safe (if you use the 'Boot as HDD' option then the last 63 sectors are protected anyway).

6. Install grub4dos to the USB Flash drive (MBR or PBR or both) in your usual way (grubinst.exe, bootice or RMPrepUSB, etc.).

7. Copy back the original files that you backed-up in Step 1 and Step 4.

8. Download KickStartSidekick.iso from the HitManPro website and copy it to the root of your USB Flash drive (the menu file will assume it is in the root but it can be in a different folder if you wish). If you have an E2B drive, copy the file to the \_ISO\MAINMENU folder.

9. To your grub4dos menu.lst menu file add the following entry (not required for E2B drives):

title HitManPro \n Choose option 3 for a Windows XP system
map /KickstartSidekick.ISO (0xff)
map --hook
root (0xff)
chainloader (0xff)


Your Flash drive will now contain (at least) these files:

\grldr
\Kickstarter.exe
\HitmanPro.exe
\HitmanPro_x64.exe
\KickstartSidekick.ISO (or in \_ISO\MAINMENU folder for E2B)
\menu.lst

That's it.

If you want to make another, different multiboot USB Flash drive, you must repeat these steps on the new drive so that the special sectors are written by HitManPro to the end of the USB Flash drive.

As very few utilities write to the extreme end of the drive, the special HitManPro sectors are likely to survive any subsequent formatting.

HitManPro seems to work by introducing code to Windows which runs when Windows boots. This code is continuously looking for the special sectors at the end of a Flash drive. If you prepare a USB Flash drive as above but omit step 2, then the KickstartSidekick.iso will still introduce this code into Windows when it boots to the Windows Desktop. If you then insert ANY USB Flash drive which contains these special sectors at the end of the drive, it will automatically run HitManPro.exe (if it is also on the USB Flash drive). Presumably this is to allow Windows enough time to mount all the USB Flash drives once it has booted and reached the Desktop.

HitManPro will not install onto a USB Hard drive or a USB Flash drive that is of the 'Fixed-disk' type (appears as 'Local Disk' in Windows Explorer).

If you want to add HitManPro to your Easy2Boot USB Flash drive, simply copy the KickstartSidekick.ISO file to \_ISO\MAINMENU and follow the instructions above or add a .mnu file containing the same menu as detailed above (e.g. \_ISO\MAINMENU\HitMan.mnu). If you wish, you can change the location of the KickstartSidekick.ISO file and edit the menu to match the new location.

Adding HitManPro without needing to re-format you E2B drive

If you wish you can add the special HitManPro sectors to the end of your USB Flash 'removable' drive using RMPrepUSB v2.1.716 or later as follows (note v2.1.714 has a bug so don't use it for this!).

The E2B USB drive must be of the 'Removable' type - it won't work if your E2B flash drive is of the Fixed-disk type (a USB HDD will not work either - Hitman will not auto-run when you boot to Windows).

1. Use the HitManPro utility to create a working USB HitManPro drive on a spare drive.

2. In RMPrepUSB v2.1.716 or later use the Drive Info button and enter 0 for the start sector - get the last sector of the HitManPro USB drive from the listing in Notepad - e.g.:
Reported size 8,011,120,640 bytes (7.4609GiB)  Last LBA 15,646,719

3. Use the Drive->File button in RMPrepUSB, filename=Hitman.bin, Start sector = (Last_LBA + 1 - 60), Length=0, FileStart=0 - this will make a file containing the last 60 sectors of the drive (e.g. Start sector = 15646719 + 1 = 15646720 - 60 = 15646660SEC).

4. Insert your target grub4dos multiboot or Easy2Boot drive and use the Drive Info button to get the Last_LBA sector of your multiboot drive (e.g. Last LBA 16,203,775)

5. Use the File->Drive button in RMPrepUSB, filename=Hitman.bin, StartofFile=0, USBStart=(Last_LBA + 1 - 60), length=0 to write the sectors to the end of your multiboot USB Flash drive (e.g. Start sector = 16203775 + 1 - 60 = 16203716SEC)

Note that this will corrupt the last 60 sectors on your multiboot USB Flash drive which may or may not affect the data or partitions on your drive (probably not though - the risk is very small!).

Note: In Easy2Boot v1.64, you can run the HitmanXfer.g4b batch file to transfer the sectors to your E2B USB drive - just get to the grub4dos console in E2B and type HitmanXfer to start the batch file.
You must use a real system for this, VMs don't seem to work very well (unless you use VBox+VMUB)!


See blog post here for more details about the use of this batch file.

No comments:

Post a Comment