clevis: auto-enable feature for bound LUKS devices#56
Open
romenskiy2012 wants to merge 3 commits intoosboot:masterfrom
Open
clevis: auto-enable feature for bound LUKS devices#56romenskiy2012 wants to merge 3 commits intoosboot:masterfrom
romenskiy2012 wants to merge 3 commits intoosboot:masterfrom
Conversation
legionus
reviewed
Apr 2, 2026
features/clevis/guess/device
Outdated
| dev="$(readlink -ef "$dev" 2>/dev/null || true)" | ||
|
|
||
| [ -b "$dev" ] || exit 0 | ||
| command -v clevis >/dev/null 2>&1 || exit 0 |
Collaborator
There was a problem hiding this comment.
@romenskiy2012 Maybe we should move this check up earlier?
Just after [ -d "$SYSFS_PATH$1"/dm ] || exit 0 ?
because none of the other steps are necessary if this utility isn't available.
legionus
reviewed
Apr 2, 2026
features/luks/guess/device
Outdated
| # CRYPT-LUKS1-00000000000000000000000000000000-name | ||
| # CRYPT-LUKS2-00000000000000000000000000000000-name | ||
| ======= | ||
| >>>>>>> 9f9d7d14 (clevis: auto-enable feature for bound LUKS devices) |
Collaborator
There was a problem hiding this comment.
Oops. You forgot to check the difference.
Add a new clevis feature that installs the tools and files required for TPM2-backed LUKS unlock in initrd. The feature is optional and is enabled explicitly through FEATURES. Signed-off-by: Arseniy Romenskiy <romenskiy@altlinux.org>
When no keyfile is available and the volume is not activated, try clevis-based unlock before falling back to interactive passphrase entry. If clevis is unavailable or unlock fails, keep the existing password prompt logic unchanged. Signed-off-by: Arseniy Romenskiy <romenskiy@altlinux.org>
Add a guess/device script for the clevis feature. The script checks dm-crypt devices, resolves the underlying LUKS device and enables the clevis feature automatically when a Clevis binding is present. Signed-off-by: Arseniy Romenskiy <romenskiy@altlinux.org>
Contributor
Author
|
I made a critical mistake with rebase, and corrupted the story. |
Collaborator
|
You're still having trouble with the rebase. On github and locally, I see 3 commits. The first two add a feature that you've already submitted in another PR. Please rebase onto master. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a guess/device script for the clevis feature.
The script checks dm-crypt devices, resolves the underlying LUKS device and enables the clevis feature automatically when a Clevis binding is present.