#!/bin/sh configure_zsh() { # Stop if zsh is not present if [ ! -x /usr/bin/zsh ]; then return fi # Stop if user has opted out of zsh if echo "${LIVE_CONFIG_CMDLINE}" | grep -qs 'nozsh'; then return fi chsh --shell /usr/bin/zsh kali chsh --shell /usr/bin/zsh root } configure_usergroups() { # Ensure those groups exist addgroup --system kaboxer || true addgroup --system wireshark || true # adm - read access to log files # dialout - for serial port access # kaboxer - for kaboxer # vboxsf - shared folders for virtualbox guest # wireshark - capture sessions without being root kali_groups="adm dialout kaboxer vboxsf wireshark" for grp in $kali_groups; do getent group $grp >/dev/null || continue usermod -a -G $grp kali done } pkg_installed() { dpkg -s "$1" 2>/dev/null | grep -q "ok installed" } configure_terminal() { while read -r desktop terminal; do pkg_installed kali-desktop-$desktop || continue update-alternatives --verbose --set x-terminal-emulator /usr/bin/$terminal || true break done <