Skip to content

Improve LUKS partition detection logic

sasha0552 requested to merge sasha0552/live-boot:master into master

This MR modifies the logic for detecting LUKS partitions in the find_persistence_media function of 9990-misc-helpers.sh. The change allows the detection of already open LUKS partitions, which is particularly useful in scenarios where a LUKS-encrypted partition has a detached header and is opened by a user-provided component.

Previously, the function is_luks_partition failed to detect such LUKS partitions, leading to issues when the header was detached. The modified logic, now encapsulated in the new function is_luks_partition_or_active_mapping, considers both LUKS partitions and active LUKS mappings.

This enhancement ensures that LUKS-encrypted partitions opened by user-provided components are correctly identified and processed by the find_persistence_media function.

Merge request reports

Loading