PHP Code:
1. Boot up live cd, and log into startx
2. apt-get update
3. apt-get instal hashalot lvm2
4. cryptsetup luksOpen /dev/[your logical partition] pvcrypt
5. Execute (in the SAME terminal):
a. mkdir /mnt/backtrack5
b. mount /dev/mapper/vg-root /mnt/backtrack5
c. mount /dev/sdb1 /mnt/backtrack5/boot
d. chroot /mnt/backtrack5
e. mount -t proc proc /proc
f. mount -t sysfs sys /sys
g. apt-get update
h. apt-get install hashalot lvm2
6. Navigate through file browser to “/mnt/backtrack5/etc/crypttab” and open in text editor
7. You are now editing a file. Add the following:
a. pvcrypt /dev/sdX2 none luks
b. /dev/sdX2 should be the encrypted partition
8. Quit vi (:wq) and execute:
a. Navigate in file browser to “/mnt/backtrack5/etc/fstab” and open in text editor
b. Change the line about the root partition (the only line with "/" in it. NOT /boot!), make it: "/dev/mapper/vg-root / ext4 defaults 0 1"
9. Execute:
a. cd ~
b. wget http://www.infosecramblings.com/cryptroot.patch
c. patch -u /usr/share/initramfs-tools/scripts/local-top/cryptroot ./cryptroot.patch
d. apt-get update
e. apt-get upgrade
f. apt-get dist-upgrade
g. chroot /mnt/backtrack5
h. update-initramfs -k all –u