Add a debug message before running keyslot PBKDF.

This is useful for debugging if the process is killed by OOM.
This commit is contained in:
Milan Broz
2021-10-15 19:17:45 +02:00
parent ca30d3cda9
commit 083cdb9310

View File

@@ -248,6 +248,7 @@ static int luks2_keyslot_set_key(struct crypt_device *cd,
/*
* Calculate keyslot content, split and store it to keyslot area.
*/
log_dbg(cd, "Running keyslot key derivation.");
r = crypt_pbkdf(pbkdf.type, pbkdf.hash, password, passwordLen,
salt, LUKS_SALTSIZE,
derived_key->key, derived_key->keylength,
@@ -350,6 +351,7 @@ static int luks2_keyslot_get_key(struct crypt_device *cd,
/*
* Calculate derived key, decrypt keyslot content and merge it.
*/
log_dbg(cd, "Running keyslot key derivation.");
r = crypt_pbkdf(pbkdf.type, pbkdf.hash, password, passwordLen,
salt, LUKS_SALTSIZE,
derived_key->key, derived_key->keylength,