History

Merge tag 'for-next-keys-7.2-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/jarkko/linux-tpmdd

Pull keys update from Jarkko Sakkinen: "This contains only bug fixes" * tag 'for-next-keys-7.2-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/jarkko/linux-tpmdd: keys: keyctl_pkey: replace BUG with return -EOPNOTSUPP keys: request_key: replace BUG with return -EINVAL keys: Pin request_key_auth payload in instantiate paths keys: prevent slab cache merging for key_jar keys: Replace strcpy(derived_buf, "AUTH_KEY") with strscpy(..., HASH_SIZE) KEYS: Use acquire when reading state in keyring search keys/trusted_keys: mark 'migratable' as __ro_after_init keys: use kmalloc_flex in user_preparse KEYS: trusted: Debugging as a feature KEYS: encrypted: Remove unnecessary selection of CRYPTO_RNG KEYS: fix overflow in keyctl_pkey_params_get_2()

Linus Torvalds committed 4 months ago

Commit e2c05952 parents 0798268 1b9524217 files · +158 −49Browse files

Showing the changes to include (2 of 17 files). Show all

Unified · Split

2 files
  1. include/keys/request_key_auth-type.h +2 −0
  2. include/keys/trusted-type.h +12 −9
include/keys/request_key_auth-type.h+2−0
@@ -9,12 +9,14 @@ · 8 unmodified lines
99 #define _KEYS_REQUEST_KEY_AUTH_TYPE_H
1010
1111 #include <linux/key.h>
12+#include <linux/refcount.h>
1213
1314 /*
1415 * Authorisation record for request_key().
1516 */
1617 struct request_key_auth {
1718 struct rcu_head rcu;
19+ refcount_t usage;
1820 struct key *target_key;
1921 struct key *dest_keyring;
2022 const struct cred *cred;
include/keys/trusted-type.h+12−9
@@ -83,18 +83,21 @@ struct trusted_key_source { · 82 unmodified lines
8383
8484 extern struct key_type key_type_trusted;
8585
86−#define TRUSTED_DEBUG 0
86+#ifdef CONFIG_TRUSTED_KEYS_DEBUG
87+extern bool trusted_debug;
8788
88−#if TRUSTED_DEBUG
8989 static inline void dump_payload(struct trusted_key_payload *p)
9090 {
91− pr_info("key_len %d\n", p->key_len);
92− print_hex_dump(KERN_INFO, "key ", DUMP_PREFIX_NONE,
93− 16, 1, p->key, p->key_len, 0);
94− pr_info("bloblen %d\n", p->blob_len);
95− print_hex_dump(KERN_INFO, "blob ", DUMP_PREFIX_NONE,
96− 16, 1, p->blob, p->blob_len, 0);
97− pr_info("migratable %d\n", p->migratable);
91+ if (!trusted_debug)
92+ return;
93+
94+ pr_debug("key_len %d\n", p->key_len);
95+ print_hex_dump_debug("key ", DUMP_PREFIX_NONE,
96+ 16, 1, p->key, p->key_len, 0);
97+ pr_debug("bloblen %d\n", p->blob_len);
98+ print_hex_dump_debug("blob ", DUMP_PREFIX_NONE,
99+ 16, 1, p->blob, p->blob_len, 0);
100+ pr_debug("migratable %d\n", p->migratable);
98101 }
99102 #else
100103 static inline void dump_payload(struct trusted_key_payload *p)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t