7 EEJOH GFSaJaUFOF UP UIF JbF 4D XJUI B Q4 Fc b82 5IF 1FSTJTUFODF FBUVSFc

7 eejoh gfsajaufof up uif jbf 4d xjui b q4 fc b82 5if

This preview shows page 266 - 269 out of 344 pages.

</7/ "EEJOH GFSaJaUFO[F UP UIF -JbF >4D XJUI B Q4# ,Fc b/8/2/ 5IF 1FSTJTUFODF 'FBUVSFc hYQMBOBUJPOT Next, we will discuss the steps required to add persistence to a Kali USB key. The nature of a live system is to be ephemeral. All data stored on the live system and all the changes made are lost when you reboot. To remedy this, you can use a feature of live-boot called persistence, which is enabled when the boot parameters include the QFSTJTUFODF keyword. 36b $IBQUFS b ن "EWBODFE 7TBHF
Image of page 266
Since modifying the boot menu is a non-trivial task, Kali includes two menu entries by default that enable persistence: Live USB Persistence and Live USB Encrypted Persistence, as shown in Figure 9.1, “Persistence Menu Entries” [page 240]. 'JHVSF </2 1FSTJTUFODF KFOV &OUSJFT When this feature is enabled, live-boot will scan all partitions looking for file systems labeled QFSTJTUFODF (which can be overridden with the QFSTJTUFODF?MBCFMe WBMVF boot parameter) and the installer will set up persistence of the directories which are listed in the persistence.conf file found in that partition (one directory per line). The special value “ ^tVOJPO ” enables full persistence of all directories with a union mount , an overlay that stores only the changes when compared to the underlying file system. The data of the persisted directories are stored in the file system that contains the corresponding persistence.conf file. 38_ ,BMJ -JOVY 4FWFBMFE
Image of page 267
b/8/3/ 9FࡻJOH 7Q 7OFODSZQUFE 1FSTJTUFODF PO B 79# ,FZ In this section, we assume that you have prepared a Kali Live USB Key by following the instructions at section 2.1.4, “Copying the Image on a DVD-ROM or USB Key” [page 19] and that you have used a USB key big enough to hold the ISO image (roughly 3 GB) and the data of the directories that you want to persist. We also assume that the USB key is recognized by Linux as ^EFW^TEC and that it only contains the two partitions that are part of the default ISO image ( ^EFW^TEC2 and ^EFW^TEC3 ). Be very careful when performing this procedure. You can easily destroy important data if you re-partition the wrong drive. To add a new partition, you must know the size of the image that you copied so that you can make the new partition start after the live image. Then use parted to actually create the partition. The commands below analyze the ISO image named kali-linux-2016.1-amd64.iso , which is assumed to be present on the USB key as well: # parted /dev/sdb print Model: SanDisk Cruzer Edge (scsi) Disk /dev/sdb: 32,0GB Sector size (logical/physical): 512B/512B Partition Table: msdos Disk Flags: Number Start End Size Type File system Flags 1 32,8kB 2852MB 2852MB primary boot, hidden 2 2852MB 2945MB 93,4MB primary # start=$(du --block-size=1MB kali-linux-2016.1-amd64.iso | awk ’{print $1}’) # echo ”Size of image is $start MB” Size of image is 2946 MB # parted -a optimal /dev/sdb mkpart primary ”${start}MB” 100% Information: You may need to update /etc/fstab.
Image of page 268
Image of page 269

You've reached the end of your free preview.

Want to read all 344 pages?

  • Summer '17
  • Annette Limeaux

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern

Stuck? We have tutors online 24/7 who can help you get unstuck.
A+ icon
Ask Expert Tutors You can ask You can ask You can ask (will expire )
Answers in as fast as 15 minutes