mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-07 17:00:03 +01:00
Add LUKS2 uuid component in underlying dm-integrity device.
This commit is contained in:
committed by
Milan Broz
parent
59bed375d0
commit
249e6af3a6
@@ -2239,9 +2239,9 @@ static int _compare_device_types(struct crypt_device *cd,
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (isLUKS2(cd->type) && !src->uuid) {
|
||||
if (strncmp("INTEGRITY-", tgt->uuid, strlen("INTEGRITY-"))) {
|
||||
log_dbg(cd, "Unexpected uuid prefix %s in target integrity device.", tgt->uuid);
|
||||
if (isLUKS2(cd->type) && !strncmp("INTEGRITY-", tgt->uuid, strlen("INTEGRITY-"))) {
|
||||
if (crypt_uuid_cmp(tgt->uuid, src->uuid)) {
|
||||
log_dbg(cd, "LUKS UUID mismatch.");
|
||||
return -EINVAL;
|
||||
}
|
||||
} else if (isLUKS(cd->type)) {
|
||||
|
||||
Reference in New Issue
Block a user