=====Kali on USB Armory=====
{{::usbarmory.jpg?direct&600|}}
**Note:** this is an unencrypted install!
====Install Kali on the SDcard====
* Download the [[https://www.offensive-security.com/kali-linux-arm-images/|latest image]]
* Verify the download:$ sha256sum kali-2017.01-usbarmory.img.xz
2b2b1d42c255fbb34e6ea24d35dc33639f6b52f05d9378a3e3ccaea793d824ee kali-2017.01-usbarmory.img.xz
* Write the image to the SDcard:# lsblk # /dev/sdc is my SDcard device
# xzcat kali-2017.01-usbarmory.img.xz | dd of=/dev/sdc bs=1M status=progress
* Plug in the device. When the USB Armory has booted up, you should have a new USB network interface on your host machine, for example ''enp0s20f0u1i1''.
* Configure the USB network interface:
nmcli con mod 'Wired connection 1' connection.id usbarmory
nmcli con mod usbarmory ipv4.addresses 10.0.0.2/24
nmcli con mod usbarmory ipv4.method manual
nmcli con up usbarmory
* Log in with user root/toor:ssh root@10.0.0.1
====Forward traffic from USB Armory====
* Configure forwarding:
echo "net.ipv4.conf.eno1.forwarding = 1" >> /etc/sysctl.d/50-forwarding.conf
sysctl -p
* Add direct rules to firewalld. The ''%%--%%permanent'' option to keep these rules across restarts. Interface ''eno1'' is the interface connected to the rest of the network.
firewall-cmd --permanent --direct --add-rule ipv4 nat POSTROUTING 0 -o eno1 -j MASQUERADE
firewall-cmd --permanent --direct --add-rule ipv4 filter FORWARD 0 -i enp0s20f0u1 -o eno1 -j ACCEPT
firewall-cmd --permanent --direct --add-rule ipv4 filter FORWARD 0 -i eno1 -o enp0s20f0u1 -m state --state RELATED,ESTABLISHED -j ACCEPT
firewall-cmd --reload
====Fix: does not boot after apt-get update====
* Mount the SDcard and add the following modules to ''/etc/modules'':ledtrig_heartbeat # comment this line if you don't want that intense blinking LED.
ci_hdrc_imx
#g_mass_storage
g_ether
====Expand root filesystem====
* Connect the SCcard to the host machine.
* Modify partition:# parted /dev/mmcblk0
print
rm 1
mkpart primary ext2 5243kB 100%
print
quit
* Reboot:reboot
* Login and resize filesystem:resize2fs /dev/mmcblk0p1
{{tag>[linux kali usb armory]}}