You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Added cipher and keyslot inventory to inventory-fde
Extended inventory-fde to report active dm-crypt cipher per volume
and LUKS keyslot details (per-keyslot cipher and PBKDF algorithm).
LUKS2 metadata is cached as JSON with a 24-hour TTL.
Gracefully degrades when dmsetup or cryptsetup are absent.
Tool paths are defined as variables for single-point configuration.
Includes loopback test helper script and Mission Portal screenshot.
Full disk encryption (FDE) protects data at rest by encrypting entire block devices.
2
2
This module detects mounted volumes backed by dm-crypt (LUKS1, LUKS2, or plain dm-crypt) on Linux systems and reports whether all, some, or none of the non-virtual block device filesystems are encrypted.
3
3
4
-
Detection is performed entirely through virtual filesystem reads (`/sys/block/` and `/proc/mounts`), with no dependency on external commands like `dmsetup` or `findmnt`.
4
+
Basic detection (encryption status, method, volume lists) is performed entirely through virtual filesystem reads (`/sys/block/` and `/proc/mounts`).
5
+
When `dmsetup` and `cryptsetup` are available, the module additionally reports the active cipher and LUKS keyslot details (per-keyslot cipher and PBKDF algorithm).
5
6
6
7
## How it works
7
8
@@ -10,13 +11,19 @@ Detection is performed entirely through virtual filesystem reads (`/sys/block/`
10
11
3. Identifies crypt devices by the `CRYPT-` prefix in the UUID
11
12
4. Parses `/proc/mounts` to find all non-virtual block device mounts (excluding loop devices)
12
13
5. Classifies each mount as encrypted or unencrypted by checking if its device matches a crypt device path
14
+
6. If `dmsetup` is available, reads the active cipher from `dmsetup table` for each crypt device
15
+
7. If `cryptsetup` is available, reads LUKS keyslot metadata (cipher and PBKDF per slot) via `cryptsetup luksDump`
13
16
14
17
## Inventory
15
18
16
-
-**Full disk encryption enabled** -- `yes` if all non-virtual block device filesystems are encrypted, `partial` if some are encrypted and some are not, `no` if none are encrypted.
17
-
-**Full disk encryption method** -- The encryption type(s) detected, e.g. `LUKS2`, `LUKS1`, `PLAIN`, or `none`. Multiple types are comma-separated if different methods are in use.
18
-
-**Full disk encryption volumes** -- List of mountpoints backed by encrypted devices.
19
-
-**Unencrypted volumes** -- List of mountpoints on non-virtual block devices that are not encrypted.
19
+
-**Full disk encryption enabled** - `yes` if all non-virtual block device filesystems are encrypted, `partial` if some are encrypted and some are not, `no` if none are encrypted.
20
+
-**Full disk encryption methods** - The encryption type(s) detected, e.g. `LUKS2`, `LUKS1`, `PLAIN`. Empty list when no encryption is found.
21
+
-**Full disk encryption volumes** - List of mountpoints backed by encrypted devices.
22
+
-**Unencrypted volumes** - List of mountpoints on non-virtual block devices that are not encrypted.
23
+
-**Full disk encryption volume ciphers** - The active dm-crypt cipher per volume, e.g. `/ : aes-xts-plain64`. Requires `dmsetup`.
24
+
-**Full disk encryption keyslot info** - LUKS keyslot cipher and PBKDF per volume, e.g. `/ : 0:aes-xts-plain64/argon2id`. Requires `cryptsetup`. Not available for plain dm-crypt (no keyslots).
25
+
26
+
[](inventory-fde-mission-portal.png)
20
27
21
28
## Example
22
29
@@ -26,11 +33,24 @@ A system with LUKS2-encrypted root but unencrypted `/boot` and `/boot/efi`:
"$(this.promise_filename): $(this.namespace):$(this.bundle) is currently only instrumented for Linux. Please consider making a pull request or filing a ticket to request your specific platform.";
132
291
}
133
292
293
+
bundle agent luks2_keyslot_info(cache_file)
294
+
# @brief Parse LUKS2 JSON metadata and return keyslot summary
0 commit comments