cregit-Linux how code gets into the kernel

Release 4.15 security/keys/encrypted-keys/encrypted.h

/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __ENCRYPTED_KEY_H

#define __ENCRYPTED_KEY_H


#define ENCRYPTED_DEBUG 0
#if defined(CONFIG_TRUSTED_KEYS) || \
  (defined(CONFIG_TRUSTED_KEYS_MODULE) && defined(CONFIG_ENCRYPTED_KEYS_MODULE))
extern struct key *request_trusted_key(const char *trusted_desc,
				       const u8 **master_key, size_t *master_keylen);
#else

static inline struct key *request_trusted_key(const char *trusted_desc, const u8 **master_key, size_t *master_keylen) { return ERR_PTR(-EOPNOTSUPP); }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar3096.77%150.00%
David Howells13.23%150.00%
Total31100.00%2100.00%

#endif #if ENCRYPTED_DEBUG
static inline void dump_master_key(const u8 *master_key, size_t master_keylen) { print_hex_dump(KERN_ERR, "master key: ", DUMP_PREFIX_NONE, 32, 1, master_key, master_keylen, 0); }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar34100.00%2100.00%
Total34100.00%2100.00%


static inline void dump_decrypted_data(struct encrypted_key_payload *epayload) { print_hex_dump(KERN_ERR, "decrypted data: ", DUMP_PREFIX_NONE, 32, 1, epayload->decrypted_data, epayload->decrypted_datalen, 0); }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar35100.00%1100.00%
Total35100.00%1100.00%


static inline void dump_encrypted_data(struct encrypted_key_payload *epayload, unsigned int encrypted_datalen) { print_hex_dump(KERN_ERR, "encrypted data: ", DUMP_PREFIX_NONE, 32, 1, epayload->encrypted_data, encrypted_datalen, 0); }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar37100.00%1100.00%
Total37100.00%1100.00%


static inline void dump_hmac(const char *str, const u8 *digest, unsigned int hmac_size) { if (str) pr_info("encrypted_key: %s", str); print_hex_dump(KERN_ERR, "hmac: ", DUMP_PREFIX_NONE, 32, 1, digest, hmac_size, 0); }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar51100.00%1100.00%
Total51100.00%1100.00%

#else
static inline void dump_master_key(const u8 *master_key, size_t master_keylen) { }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar14100.00%2100.00%
Total14100.00%2100.00%


static inline void dump_decrypted_data(struct encrypted_key_payload *epayload) { }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar11100.00%1100.00%
Total11100.00%1100.00%


static inline void dump_encrypted_data(struct encrypted_key_payload *epayload, unsigned int encrypted_datalen) { }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar15100.00%1100.00%
Total15100.00%1100.00%


static inline void dump_hmac(const char *str, const u8 *digest, unsigned int hmac_size) { }

Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar20100.00%1100.00%
Total20100.00%1100.00%

#endif #endif

Overall Contributors

PersonTokensPropCommitsCommitProp
Mimi Zohar31099.04%466.67%
David Howells20.64%116.67%
Greg Kroah-Hartman10.32%116.67%
Total313100.00%6100.00%
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.
Created with cregit.