From 723ad6afdf96b68f7f44b0c708fc839601ebec52 Mon Sep 17 00:00:00 2001 From: Ondrej Kozina Date: Fri, 9 May 2025 10:45:31 +0200 Subject: [PATCH] Print error message in cryptetup cli. Prints "Volume key does not match the volume" when passed VK's digest does match the stored one. --- src/cryptsetup.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/cryptsetup.c b/src/cryptsetup.c index 097c24cb..12e70aec 100644 --- a/src/cryptsetup.c +++ b/src/cryptsetup.c @@ -1911,6 +1911,8 @@ static int action_open_luks(void) goto out; r = crypt_activate_by_keyslot_context(cd, activated_name, CRYPT_ANY_SLOT, kc1, CRYPT_ANY_SLOT, kc2, activate_flags); } + if (r == -EPERM) + log_err(_("Volume key does not match the volume.")); if (r) goto out; } else {