August 26, 2015

Kali 2 as a long term everyday Linux #2: download and verify Kali ISO, build a bootable pendrive in three easy steps


Step #1: download Kali.

First, get the updated download link here https://www.kali.org/downloads/

If you already use a Linux box it's more educational to start using the command line ;-)

$ cd && cd Downloads
$ wget -c http://cdimage.kali.org/kali-2.0/kali-linux-2.0-amd64.iso



Step #2: verify it's genuine and intact.


Copy the sha1 hash from the Kali download page:
$ echo "aaeb89a78f155377282f81a785aa1b38ee5f8ba0 kali-linux-2.0-amd64.iso" > kali-linux-2.0-amd64.iso.sha1sum
$ sha1sum -c kali-linux-2.0-amd64.iso.sha1sum 

WARNING: don't trust the torrent download and always check the sha1 hash. My torrent client downloaded the iso without errors, but it was corrupt!

Step #3: build a bootable pendrive.

Find your pendrive device, usually it's /dev/sdb (or /dev/mmcblk0 if you use a SD card instead of an USB pendrive).
$ sudo fdisk -l

If it is already mounted, unmount it before overwriting:
$ mount | grep /dev/
$ sudo umount /dev/<your-mounted-pendrive-here>

Copy the downloaded ISO over the pendrive device.
WARNING: make sure you copy over the device (i.e. /dev/sdb), not the partition (i.e. /dev/sdb1).

http://www.google.it/url?sa=i&rct=j&q=&esrc=s&source=images&cd=&cad=rja&uact=8&ved=0CAQQjBxqFQoTCKaG5aaFxMcCFcM_FAodWWMDnw&url=http%3A%2F%2Fi286.photobucket.com%2Falbums%2Fll82%2Fshemaro91%2Fcrying-baby.jpg&ei=lkXcVabjNMP_UNnGjfgJ&psig=AFQjCNHLd-SG9RGLNVQCi1Fk-9FlDJ7CYQ&ust=1440585492918353
Yes my dear, it wasn't /dev/sda

If you have pv you can show the progress bar:
$ pv kali-linux-2.0-amd64.iso | sudo dd of=/dev/sdb bs=16M

If you don't have pv (pipe-view), use only dd:
$ sudo dd if=kali-linux-2.0-amd64.iso of=/dev/sdb bs=16M

If you are using Windows or Mac, use your preferred tool or UniversalUSBinstaller to burn the pendrive.

You can follow this tutorial series with this tag: kali-everyday