mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-05 16:00:05 +01:00
Print better error message for unsupported LUKS2 AEAD device resize.
Fixes: #804
This commit is contained in:
@@ -3709,6 +3709,11 @@ int crypt_resize(struct crypt_device *cd, const char *name, uint64_t new_size)
|
|||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (isLUKS2(cd->type) && crypt_get_integrity_tag_size(cd)) {
|
||||||
|
log_err(cd, _("Resize of LUKS2 device with integrity protection is not supported."));
|
||||||
|
return -ENOTSUP;
|
||||||
|
}
|
||||||
|
|
||||||
if (new_size)
|
if (new_size)
|
||||||
log_dbg(cd, "Resizing device %s to %" PRIu64 " sectors.", name, new_size);
|
log_dbg(cd, "Resizing device %s to %" PRIu64 " sectors.", name, new_size);
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user