V8.00.000.2025.06.17
All checks were successful
🔁 Render Graphviz Diagrams. / 🔁 Render Graphviz Diagrams. (push) Successful in 32s
🛡️ Shell Script Linting / 🛡️ Shell Script Linting (push) Successful in 47s

Signed-off-by: Marc S. Weidner <msw@coresecret.dev>
This commit is contained in:
2025-07-24 18:28:35 +02:00
parent e9681e87c5
commit 0a2d983c7d
64 changed files with 525 additions and 1423 deletions

View File

@@ -13,7 +13,7 @@
### Definition of MUST set early Variables
# shellcheck disable=SC2155
declare -agx ARY_PARAM_ARRAY=("$@")
declare -ag ARY_PARAM_ARRAY=("$@")
declare -grx VAR_PARAM_COUNT="$#"
declare -grx VAR_PARAM_STRNG="$*"
declare -grx VAR_CONTACT="security@coresecret.eu"
@@ -24,5 +24,5 @@ declare -gx VAR_AUTO_INSTALL="false"
declare -gx VAR_DEBUG_TRACE="false"
declare -gx VAR_DEBUG_TRAP="false"
declare -gx VAR_IN_DIALOG_WR="false"
umask 0022
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh

View File

@@ -34,7 +34,7 @@ declare -girx ERR_BTRFS_INITPH=236 # The btrfs subvolume could not be initi
declare -girx ERR_BTRFS_SUBVOL=235 # The btrfs subvolume could not be created.
declare -girx ERR_BTRFS_OPTION=234 # Compression options algo:level not valid btrfs pairs.
declare -girx ERR_MOUNTING_DEV=233 # The Device could not be mounted.
declare -girx ERR_MOUNTING_ROOT=232 # The / Volume could not be mounted.
declare -girx ERR_MOUNTING_ROOT=232 # The '/' Volume could not be mounted.
declare -girx ERR_MOUNTING_LUKS=231 # The LUKS Volume could not be mounted.
declare -girx ERR_UNKNOWN_DEV=230 # Unknown Device Path.
declare -girx ERR_DEBOOTSTRAP=229 # Failure occurred on debootstrap.
@@ -42,9 +42,10 @@ declare -girx ERR_CHRT_MOUNTS=228 # Failure occurred while mounting system
declare -girx ERR_CHRT_COMMAND=227 # Failure occurred while executing chroot environment command.
declare -girx ERR_GRUB_EFI_FORCE=226 # Invalid combination of Partition Table and grub_force_efi.
declare -girx ERR_GRUB_BACKGROUND=225 # Failure occurred on setting up the GRUB-background.
declare -girx ERR_PATH_NOT_VALID=224 # Specific path is not existing.
declare -girx ERR_READ_NUKE_FILE=223 # Error reading Luks Nuke password file.
declare -girx ERR_READ_GRUB_FILE=222 # Error reading Grub password file.
declare -girx ERR_GRUB_ARCHITECTURE=224 # Architecture is not supported by Grub.
declare -girx ERR_PATH_NOT_VALID=223 # Specific path is not existing.
declare -girx ERR_READ_NUKE_FILE=222 # Error reading Luks Nuke password file.
declare -girx ERR_READ_GRUB_FILE=221 # Error reading Grub password file.
### Definition of error trap vars
declare -gx ERRCODE="" # = $? = $1 = ERRCODE

View File

@@ -17,7 +17,6 @@ declare -grx VAR_KERNEL_INF="$(mktemp --tmpdir --mode=0600 /tmp/var_kernel_inf.X
declare -grx VAR_KERNEL_TMP="$(mktemp --tmpdir --mode=0600 /tmp/var_kernel_tmp.XXXXXXXX)"
declare -grx VAR_KERNEL_SRT="$(mktemp --tmpdir --mode=0600 /tmp/var_kernel_srt.XXXXXXXX)"
declare -grx VAR_NOTES="$(mktemp --tmpdir --mode=0600 /tmp/var_notes.XXXXXXXX)"
declare -grx LOG_ERROR="/tmp/ciss_debian_installer_$$_error.log"
declare -grx VAR_SETUP_CONF="preseed.yaml"
declare -grx VAR_SETUP_PART="partitioning.yaml"
declare -grx VAR_SETUP_FILE="${0##*/}" # 'setup.sh'
@@ -47,87 +46,6 @@ declare -grx RECOVERY="/recovery"
declare -grx VAR_SAFE_MNT_BASE="/run/ciss/bootstrap"
### Default log level.
declare -gx DEFAULT_LOG_LEVEL="info"
declare -gx VAR_DEFAULT_LOG_LEVEL="info"
### 1081_helper_grub.sh:
### Variable to finish GRUB CMDLINE strings.
declare -grx VAR_H='"'
### 1250_yaml_parser.sh:
### Indexed Arrays for 'Debian Packages' to install and 'NTPSec Server' to use.
#declare -ag ARY_BOOTPARAM=()
#declare -ag ARY_PACKAGES=()
#declare -ag ARY_NTPSRVR=()
### 1251_yaml_reader.sh:
### Variable for highest device count e.g., /dev/sdf = "f"
declare -gx VAR_RECIPE_DEV_COUNTER=""
### Variable for firmware ("UEFI" || "BIOS")
declare -gx VAR_RECIPE_FIRMWARE=""
### Variable for active recipe (e.g., "gben0afx256")
declare -gx VAR_RECIPE_STRING=""
### Variable partition table ("gpt" || "mbr")
declare -gx VAR_RECIPE_TABLE=""
### Assoziative Array (HashMap) for devices and accompanying partitions
declare -Ag HMP_RECIPE_DEV_PARTITIONS
### 3200_partitioning.sh
### Assoziative Array (HashMap) to store UUIDs for each partition
### HMP_UUID_PARTITION["UUID_${var_dev}${var_part}"]="${var_uuid}"
declare -Ag HMP_UUID_PARTITION
### 3220_partition_encryption.sh
### Assoziative Array (HashMap) to store Ephemeral Device for each Mount Path
### HMP_EPHEMERAL_DEV["${var_mount_path}"]="/dev/${var_dev}${var_part}"
declare -Ag HMP_EPHEMERAL_DEV
### Assoziative Array (HashMap) to store Ephemeral Device Encryption Label for each Mount Path
### HMP_EPHEMERAL_ENCLABEL["${var_mount_path}"]="${var_encryption_label}"
declare -Ag HMP_EPHEMERAL_ENCLABEL
### Assoziative Array (HashMap) to store UUID for each Encryption Label
### HMP_ENCRYPTIONLABEL_UUID["${var_encryption_label}"]="${var_uuid}"
declare -Ag HMP_ENCRYPTIONLABEL_UUID
### Assoziative Array (HashMap) to store Encryption Label for each Mount Path
### HMP_MOUNTPATH_ENCRYPTIONLABEL["${var_mount_path}"]="${var_encryption_label}"
declare -Ag HMP_MOUNTPATH_ENCRYPTIONLABEL
### 3260_setup_filesystem.sh
### Assoziative Array (HashMap) to store Crypt Mapper OR Device for each Mount Path
### HMP_MOUNTPATH_DEV["${var_mount_path}"]="/dev/mapper/${var_encryption_label}"
### HMP_MOUNTPATH_DEV["${var_mount_path}"]="/dev/${var_dev}${var_part}"
declare -Ag HMP_MOUNTPATH_DEV
### TODO
# [3_5_1_functions_installation_partition_encryption()] Create a hashmap to store the device path for each ephemeral partition
# MAP_EPHEMERAL_DEV["${MOUNT_PATH}"]="/dev/${DEV}${PARTITION}"
declare -g -A MAP_EPHEMERAL_DEV=()
# [3_5_1_functions_installation_partition_encryption()] Create a hashmap to store the encryption label for each ephemeral partition
# MAP_EPHEMERAL_ENCLABEL["${MOUNT_PATH}"]="${ENCRYPTION_LABEL}"
declare -g -A MAP_EPHEMERAL_ENCLABEL=()
# [3_5_1_functions_installation_partition_encryption()] Create a hashmap to store UUIDs for each encrypted partition
# MAP_UUID_CRYPT["${ENCRYPTION_LABEL}"]="${UUID}"
declare -g -A MAP_UUID_CRYPT=()
# [3_5_1_functions_installation_partition_encryption()] Create a hashmap to store the device path for each encrypted partition
# MAP_PATH_CRYPT["${MOUNT_PATH}"]="${ENCRYPTION_LABEL}"
declare -g -A MAP_PATH_CRYPT=()
# [3_6_0_functions_installation_setup_filesystem()] Create a hashmap to store the mount paths of each partition
declare -g -A MAP_MOUNTPATH_DEV=()
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh

View File

@@ -16,4 +16,4 @@ declare -gix COLS=$(tput cols)
declare -gix ROWS_USE=$(($(tput lines) - 8))
declare -gix COLS_USE=$(($(tput cols) - 8))
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh:
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh