View Issue Details

IDProjectCategoryView StatusLast Update
0005983Kali LinuxKali Websites & Docspublic2020-01-14 11:59
ReporterEnceledusGoofOff Assigned Tog0tmi1k  
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version2019.4 
Summary0005983: Kali ISO of Doom instructions need to be updated
Description

Hello,

I'm seeing an issue where files such as an openvpn config that are within includes.chroot aren't making their way to the generated ISO file.

I have an ISO builder, made following the Kali ISO of Doom Too instructions. That ISO builder is fully up-to-date and contains three files I include on ISOs. Those files are included in the kali-linux-rolling-amd64.log chroot_includes section (see keepopenVPN, client.conf, and every_5_mins, below):

[2020-01-07 18:42:38] lb chroot_includes 
P: Begin copying chroot includes...
P: Creating a tarball with files from includes.chroot...
P: Extracting the tarball in the chroot...
./
./usr/
./usr/lib/
./usr/lib/live/
./usr/lib/live/config/
./usr/lib/live/config/0031-kali-password
./usr/lib/live/config/1165-fix-openssh-server
./usr/bin/
./usr/local/
./usr/local/sbin/
./usr/local/sbin/keepopenVPN
./etc/
./etc/openvpn/
./etc/openvpn/client.conf
./etc/cron.d/
./etc/cron.d/every_5_min

However, those files are not on the ISO when I boot it.

Steps To Reproduce

Build a Kali ISO of Doom Too imager according to these instructions:
https://www.offensive-security.com/kali-linux/kali-rolling-iso-of-doom/

build folder is located in /opt

Edit /opt/build/kali-config/common/includes.chroot/etc/openvpn/client.conf

Add directories and files (I tested with the actual script and with placeholders, no difference):

/opt/build/kali-config/common/includes.chroot/usr/local/sbin/keepopenVPN
/opt/build/kali-config/common/includes.chroot/etc/cron.d/every_5_min

Boot the generated ISO and allow to build

Login and check files exist

root@kali:~# ls /etc/openvpn
client  server  update-resolv-conf
root@kali:~# ls /etc/cron.d
e2scrub_all  john  php  sysstat
root@kali:~# ls /usr/local/sbin
root@kali:~#
Attached Files

Activities

rhertzog

rhertzog

2020-01-08 18:14

administrator   ~0011838

Are those files in /opt/build/chroot/ after a build ?

What is the path of the iso image that you are testing ?

How are you booting the live iso image ?

EnceledusGoofOff

EnceledusGoofOff

2020-01-08 18:24

reporter   ~0011839

Yes, the files remain in /opt/build/kali-config/common/includes.chroot/* after a build.
The path to the iso was the same place I got the log file entries above: /opt/build/images. the ISO name was kali-rolling-iso-amd64.iso, I believe.
I'm booting the ISO by using SCP to copy out of the Kali ISO maker and then building a VM with the ISO as a base. I tried building a VM on both Win with Hyper-v and ESX with VMware with the same results.

rhertzog

rhertzog

2020-01-08 20:13

administrator   ~0011840

So the files are part of the live system available in the ISO and you see them if you "boot" the live system.

However for a few weeks now, the installer no longer copies the live system in the installed system, instead it starts from scratch with debootstrap and installs all the packages. So if you want to modify the installed system, you will have to find another solution: for example changing the debian installer preseeding to run some custom commands, see https://www.debian.org/releases/stable/i386/apbs05.en.html#preseed-hooks

So there's no bug here, and I'm going to close this ticket.

rhertzog

rhertzog

2020-01-08 20:21

administrator   ~0011841

Actually I'll reframe this bug into a request to update the "kali iso of doom" blog post... because the instructions in that post are now inaccurate as you experienced.

EnceledusGoofOff

EnceledusGoofOff

2020-01-08 22:05

reporter   ~0011842

That's fair, rhertzog. Thanks for your time.

noahbirnel

noahbirnel

2020-01-09 19:27

reporter   ~0011848

rhertzog, which commit made this change?

This breaks our automatic build process. I'd like to make a PR to make it optional / configurable.

rhertzog

rhertzog

2020-01-10 07:53

administrator   ~0011859

It's 45dfa51b334a8b9d5a89c71cc7b5ec578831bf3a that changed the type of installer (although we made further changes to the value passed to --debian-installer afterwards).

rhertzog

rhertzog

2020-01-13 15:54

administrator   ~0011912

Here's the change that you want to document in the updated blog post.

--- a/auto/config
+++ b/auto/config
@@ -72,10 +72,10 @@ fi

Define options that vary across architectures

case "$arch" in
amd64)

  • lb_opts="$lb_opts --debian-installer cdrom"
  • lb_opts="$lb_opts --debian-installer live"
    ;;
    i386)
  • lb_opts="$lb_opts --debian-installer cdrom --linux-flavours 686-pae"
  • lb_opts="$lb_opts --debian-installer live --linux-flavours 686-pae"
    ;;
    armel|armhf)
    lb_opts="$lb_opts --binary-images hdd --binary-filesystem ext4 --chroot-filesystem none"
patch (574 bytes)   
diff --git a/auto/config b/auto/config
index c0d2f14..a6f6905 100755
--- a/auto/config
+++ b/auto/config
@@ -72,10 +72,10 @@ fi
 # Define options that vary across architectures
 case "$arch" in
     amd64)
-	lb_opts="$lb_opts --debian-installer cdrom"
+	lb_opts="$lb_opts --debian-installer live"
     ;;
     i386)
-	lb_opts="$lb_opts --debian-installer cdrom --linux-flavours 686-pae"
+	lb_opts="$lb_opts --debian-installer live --linux-flavours 686-pae"
     ;;
     armel|armhf)
 	lb_opts="$lb_opts --binary-images hdd --binary-filesystem ext4 --chroot-filesystem none"
patch (574 bytes)   
g0tmi1k

g0tmi1k

2020-01-14 11:59

administrator   ~0011922

Updated ~ https://www.offensive-security.com/kali-linux/kali-rolling-iso-of-doom/

Issue History

Date Modified Username Field Change
2020-01-08 16:53 EnceledusGoofOff New Issue
2020-01-08 18:14 rhertzog Note Added: 0011838
2020-01-08 18:24 EnceledusGoofOff Note Added: 0011839
2020-01-08 20:13 rhertzog Note Added: 0011840
2020-01-08 20:13 rhertzog Assigned To => rhertzog
2020-01-08 20:13 rhertzog Status new => closed
2020-01-08 20:13 rhertzog Resolution open => no change required
2020-01-08 20:21 rhertzog Assigned To rhertzog =>
2020-01-08 20:21 rhertzog Severity block => major
2020-01-08 20:21 rhertzog Status closed => confirmed
2020-01-08 20:21 rhertzog Resolution no change required => open
2020-01-08 20:21 rhertzog Category General Bug => Kali Websites & Docs
2020-01-08 20:21 rhertzog Summary Kali ISO of Doom not including files from includes.chroot? => Kali ISO of Doom instructions need to be updated
2020-01-08 20:21 rhertzog Note Added: 0011841
2020-01-08 22:05 EnceledusGoofOff Note Added: 0011842
2020-01-09 19:27 noahbirnel Note Added: 0011848
2020-01-10 07:53 rhertzog Note Added: 0011859
2020-01-13 15:54 rhertzog File Added: patch
2020-01-13 15:54 rhertzog Note Added: 0011912
2020-01-14 11:59 g0tmi1k Assigned To => g0tmi1k
2020-01-14 11:59 g0tmi1k Status confirmed => resolved
2020-01-14 11:59 g0tmi1k Resolution open => fixed
2020-01-14 11:59 g0tmi1k Note Added: 0011922