From: David Howells Date: Tue, 2 Sep 2014 12:52:10 +0000 (+0100) Subject: KEYS: Fix public_key asymmetric key subtype name X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=876c6e3e028d1b326c81f6f134a4804b92f67dc7;p=linux-beck.git KEYS: Fix public_key asymmetric key subtype name The length of the name of an asymmetric key subtype must be stored in struct asymmetric_key_subtype::name_len so that it can be matched by a search for ":". Fix the public_key subtype to have name_len set. Signed-off-by: David Howells Signed-off-by: James Morris --- diff --git a/crypto/asymmetric_keys/public_key.c b/crypto/asymmetric_keys/public_key.c index 97eb001960b9..2f6e4fb1a1ea 100644 --- a/crypto/asymmetric_keys/public_key.c +++ b/crypto/asymmetric_keys/public_key.c @@ -121,6 +121,7 @@ static int public_key_verify_signature_2(const struct key *key, struct asymmetric_key_subtype public_key_subtype = { .owner = THIS_MODULE, .name = "public_key", + .name_len = sizeof("public_key") - 1, .describe = public_key_describe, .destroy = public_key_destroy, .verify_signature = public_key_verify_signature_2,