summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ubifs-utils/mkfs.ubifs/fscrypt.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ubifs-utils/mkfs.ubifs/fscrypt.c b/ubifs-utils/mkfs.ubifs/fscrypt.c
index 6d1fa4b..02132e2 100644
--- a/ubifs-utils/mkfs.ubifs/fscrypt.c
+++ b/ubifs-utils/mkfs.ubifs/fscrypt.c
@@ -165,6 +165,9 @@ static int parse_key_descriptor(const char *desc, __u8 *dst)
{
int i, hi, lo;
+ if (desc[0] == '0' && (desc[1] == 'x' || desc[1] == 'X'))
+ desc += 2;
+
for (i = 0; i < FS_KEY_DESCRIPTOR_SIZE; ++i) {
if (!desc[i * 2] || !desc[i * 2 + 1]) {
err_msg("key descriptor '%s' is too short", desc);