Loading crypto/asymmetric_keys/asymmetric_type.c +2 −2 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ EXPORT_SYMBOL_GPL(asymmetric_keyid_match); * "id:<id>" - request a key matching the ID * "<subtype>:<id>" - request a key of a subtype */ static int asymmetric_key_cmp(const struct key *key, static bool asymmetric_key_cmp(const struct key *key, const struct key_match_data *match_data) { const struct asymmetric_key_subtype *subtype = asymmetric_key_subtype(key); Loading include/linux/key-type.h +6 −4 Original line number Diff line number Diff line Loading @@ -56,9 +56,11 @@ typedef int (*request_key_actor_t)(struct key_construction *key, * Preparsed matching criterion. */ struct key_match_data { /* Comparison function, defaults to type->match, but can be replaced by * type->match_preparse(). */ int (*cmp)(const struct key *key, /* Comparison function, defaults to exact description match, but can be * overridden by type->match_preparse(). Should return true if a match * is found and false if not. */ bool (*cmp)(const struct key *key, const struct key_match_data *match_data); const void *raw_data; /* Raw match data */ Loading net/dns_resolver/dns_key.c +2 −2 Original line number Diff line number Diff line Loading @@ -176,7 +176,7 @@ static void dns_resolver_free_preparse(struct key_preparsed_payload *prep) * The domain name may be a simple name or an absolute domain name (which * should end with a period). The domain name is case-independent. */ static int dns_resolver_cmp(const struct key *key, static bool dns_resolver_cmp(const struct key *key, const struct key_match_data *match_data) { int slen, dlen, ret = 0; Loading security/keys/internal.h +4 −4 Original line number Diff line number Diff line Loading @@ -127,7 +127,7 @@ struct keyring_search_context { struct timespec now; }; extern int key_default_cmp(const struct key *key, extern bool key_default_cmp(const struct key *key, const struct key_match_data *match_data); extern key_ref_t keyring_search_aux(key_ref_t keyring_ref, struct keyring_search_context *ctx); Loading @@ -150,7 +150,7 @@ extern struct key *request_key_and_link(struct key_type *type, struct key *dest_keyring, unsigned long flags); extern int lookup_user_key_possessed(const struct key *key, extern bool lookup_user_key_possessed(const struct key *key, const struct key_match_data *match_data); extern key_ref_t lookup_user_key(key_serial_t id, unsigned long flags, key_perm_t perm); Loading security/keys/keyring.c +2 −2 Original line number Diff line number Diff line Loading @@ -513,7 +513,7 @@ EXPORT_SYMBOL(keyring_alloc); /* * By default, we keys found by getting an exact match on their descriptions. */ int key_default_cmp(const struct key *key, bool key_default_cmp(const struct key *key, const struct key_match_data *match_data) { return strcmp(key->description, match_data->raw_data) == 0; Loading Loading
crypto/asymmetric_keys/asymmetric_type.c +2 −2 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ EXPORT_SYMBOL_GPL(asymmetric_keyid_match); * "id:<id>" - request a key matching the ID * "<subtype>:<id>" - request a key of a subtype */ static int asymmetric_key_cmp(const struct key *key, static bool asymmetric_key_cmp(const struct key *key, const struct key_match_data *match_data) { const struct asymmetric_key_subtype *subtype = asymmetric_key_subtype(key); Loading
include/linux/key-type.h +6 −4 Original line number Diff line number Diff line Loading @@ -56,9 +56,11 @@ typedef int (*request_key_actor_t)(struct key_construction *key, * Preparsed matching criterion. */ struct key_match_data { /* Comparison function, defaults to type->match, but can be replaced by * type->match_preparse(). */ int (*cmp)(const struct key *key, /* Comparison function, defaults to exact description match, but can be * overridden by type->match_preparse(). Should return true if a match * is found and false if not. */ bool (*cmp)(const struct key *key, const struct key_match_data *match_data); const void *raw_data; /* Raw match data */ Loading
net/dns_resolver/dns_key.c +2 −2 Original line number Diff line number Diff line Loading @@ -176,7 +176,7 @@ static void dns_resolver_free_preparse(struct key_preparsed_payload *prep) * The domain name may be a simple name or an absolute domain name (which * should end with a period). The domain name is case-independent. */ static int dns_resolver_cmp(const struct key *key, static bool dns_resolver_cmp(const struct key *key, const struct key_match_data *match_data) { int slen, dlen, ret = 0; Loading
security/keys/internal.h +4 −4 Original line number Diff line number Diff line Loading @@ -127,7 +127,7 @@ struct keyring_search_context { struct timespec now; }; extern int key_default_cmp(const struct key *key, extern bool key_default_cmp(const struct key *key, const struct key_match_data *match_data); extern key_ref_t keyring_search_aux(key_ref_t keyring_ref, struct keyring_search_context *ctx); Loading @@ -150,7 +150,7 @@ extern struct key *request_key_and_link(struct key_type *type, struct key *dest_keyring, unsigned long flags); extern int lookup_user_key_possessed(const struct key *key, extern bool lookup_user_key_possessed(const struct key *key, const struct key_match_data *match_data); extern key_ref_t lookup_user_key(key_serial_t id, unsigned long flags, key_perm_t perm); Loading
security/keys/keyring.c +2 −2 Original line number Diff line number Diff line Loading @@ -513,7 +513,7 @@ EXPORT_SYMBOL(keyring_alloc); /* * By default, we keys found by getting an exact match on their descriptions. */ int key_default_cmp(const struct key *key, bool key_default_cmp(const struct key *key, const struct key_match_data *match_data) { return strcmp(key->description, match_data->raw_data) == 0; Loading