/u-boot/include/ |
H A D | rc4.h | 16 * @key: 16-byte key to use 18 void rc4_encode(unsigned char *buf, unsigned int len, const unsigned char key[16]);
|
H A D | tegra-kbc.h | 11 #define KEY_IS_MODIFIER(key) ((key) >= KEY_FIRST_MODIFIER)
|
/u-boot/lib/rsa/ |
H A D | rsa-mod-exp.c | 41 * @key: Key containing modulus to subtract 44 static void subtract_modulus(const struct rsa_public_key *key, uint32_t num[]) argument 49 for (i = 0; i < key->len; i++) { 50 acc += (uint64_t)num[i] - key->modulus[i]; 59 * @key: Key containing modulus to check 63 static int greater_equal_modulus(const struct rsa_public_key *key, argument 68 for (i = (int)key->len - 1; i >= 0; i--) { 69 if (num[i] < key->modulus[i]) 71 if (num[i] > key->modulus[i]) 83 * @key 88 montgomery_mul_add_step(const struct rsa_public_key *key, uint32_t result[], const uint32_t a, const uint32_t b[]) argument 123 montgomery_mul(const struct rsa_public_key *key, uint32_t result[], uint32_t a[], const uint32_t b[]) argument 140 num_public_exponent_bits(const struct rsa_public_key *key, int *num_bits) argument 170 is_public_exponent_bit_set(const struct rsa_public_key *key, int pos) argument 182 pow_mod(const struct rsa_public_key *key, uint32_t *inout) argument 260 struct rsa_public_key key; local 327 struct rsa_public_key *key; local [all...] |
/u-boot/lib/crypto/ |
H A D | rsa_helper.c | 3 * RSA key extract helper 27 struct rsa_key *key = context; local 33 /* invalid key provided */ 44 /* In FIPS mode only allow key size 2K and higher */ 46 pr_err("RSA: key size not allowed in FIPS mode\n"); 52 key->n = value; 53 key->n_sz = vlen; 61 struct rsa_key *key = context; local 63 /* invalid key provided */ 64 if (!value || !key 76 struct rsa_key *key = context; local 91 struct rsa_key *key = context; local 106 struct rsa_key *key = context; local 121 struct rsa_key *key = context; local 136 struct rsa_key *key = context; local 151 struct rsa_key *key = context; local 174 rsa_parse_pub_key(struct rsa_key *rsa_key, const void *key, unsigned int key_len) argument 194 rsa_parse_priv_key(struct rsa_key *rsa_key, const void *key, unsigned int key_len) argument [all...] |
H A D | asymmetric_type.c | 2 /* Asymmetric public-key cryptography key type 44 [VERIFYING_KEY_SIGNATURE] = "key sig", 45 [VERIFYING_KEY_SELF_SIGNATURE] = "key self sig", 54 * find_asymmetric_key - Find a key by ID. 60 * Find a key in the given keyring by identifier. The preferred identifier is 64 struct key *find_asymmetric_key(struct key *keyring, 69 struct key *key; local 267 asymmetric_key_cmp(const struct key *key, const struct key_match_data *match_data) argument 280 asymmetric_key_cmp_partial(const struct key *key, const struct key_match_data *match_data) argument 350 asymmetric_key_describe(const struct key *key, struct seq_file *m) argument 454 asymmetric_key_destroy(struct key *key) argument 474 asymmetric_restriction_alloc( key_restrict_link_func_t check, struct key *key) argument 520 struct key *key; local 562 struct key *key = params->key; local [all...] |
H A D | public_key.c | 2 /* In-software asymmetric public-key crypto subtype 36 MODULE_DESCRIPTION("In-software asymmetric public-key subtype"); 42 * Provide a part of a description of the key for /proc/keys. 44 static void public_key_describe(const struct key *asymmetric_key, 47 struct public_key *key = asymmetric_key->payload.data[asym_crypto]; local 49 if (key) 50 seq_printf(m, "%s.%s", key->id_type, key->pkey_algo); 55 * Destroy a public key algorithm key 57 public_key_free(struct public_key *key) argument 205 u8 *key, *ptr; local 268 char *key, *ptr; local 354 char *key, *ptr; local 420 public_key_verify_signature_2(const struct key *key, const struct public_key_signature *sig) argument [all...] |
/u-boot/lib/libavb/ |
H A D | avb_rsa.c | 7 * key for computation. The code extends libmincrypt RSA verification code to 8 * support multiple RSA key lengths and hash digest algorithms. 26 IAvbKey* key = NULL; local 34 avb_error("Invalid key.\n"); 40 avb_error("Unexpected key length.\n"); 53 /* Store n and rr following the key header so we only have to do one 56 key = (IAvbKey*)(avb_malloc(sizeof(IAvbKey) + 2 * h.key_num_bits / 8)); 57 if (key == NULL) { 61 key->len = h.key_num_bits / 32; 62 key 83 iavb_free_parsed_key(IAvbKey* key) argument 88 subM(const IAvbKey* key, uint32_t* a) argument 99 geM(const IAvbKey* key, uint32_t* a) argument 114 montMulAdd(const IAvbKey* key, uint32_t* c, const uint32_t a, const uint32_t* b) argument 139 montMul(const IAvbKey* key, uint32_t* c, uint32_t* a, uint32_t* b) argument 152 modpowF4(const IAvbKey* key, uint8_t* inout) argument 208 avb_rsa_verify(const uint8_t* key, size_t key_num_bytes, const uint8_t* sig, size_t sig_num_bytes, const uint8_t* hash, size_t hash_num_bytes, const uint8_t* padding, size_t padding_num_bytes) argument [all...] |
H A D | avb_property_descriptor.c | 27 /* Check that key and value are fully contained. */ 43 const char* key; member in struct:__anon1425 67 avb_error("No terminating NUL byte in key.\n"); 73 data->key, 90 const char* key, 96 key_size = avb_strlen(key); 99 data.key = key; 118 const char* key, 127 value = avb_property_lookup(image_data, image_size, key, key_siz 88 avb_property_lookup(const uint8_t* image_data, size_t image_size, const char* key, size_t key_size, size_t* out_value_size) argument 116 avb_property_lookup_uint64(const uint8_t* image_data, size_t image_size, const char* key, size_t key_size, uint64_t* out_value) argument [all...] |
H A D | avb_property_descriptor.h | 19 /* A descriptor for properties (free-form key/value pairs). 21 * Following this struct are |key_num_bytes| bytes of key data, 42 * name |key| in a vbmeta image. If |key_size| is 0, |key| must be 62 * known good public key. 66 const char* key, 79 const char* key,
|
/u-boot/test/env/ |
H A D | hashtable.c | 24 char key[20]; local 27 sprintf(key, "%d", (int)i); 29 item.data = key; 31 item.key = key; 44 char key[20]; local 47 sprintf(key, "%d", (int)i); 50 item.data = key; 51 item.key = key; 67 char key[20]; local [all...] |
/u-boot/tools/ |
H A D | fdt_host.h | 34 * @key: Key FDT blob to check against 38 int fit_check_sign(const void *fit, const void *key,
|
H A D | key2dtsi.py | 4 # Public key to dtsi converter. 20 ap = ArgumentParser(description='Public key to dtsi converter') 23 help='hash to be used with key (default: sha256)') 25 help='mark key required for configuration') 27 help='mark key required for image') 29 help='mark key for usage in SPL') 31 help='key file (formats: X.509, PKCS#1, OpenSSH)') 40 key = RSA.importKey(key_data) variable 42 r_squared = (2**key.size_in_bits())**2 % key [all...] |
/u-boot/arch/arm/include/asm/arch-tegra/ |
H A D | crypto.h | 25 * \param key AES128 encryption key 27 int sign_enc_data_block(u8 *source, unsigned int length, u8 *signature, u8 *key); 34 * \param key AES128 encryption key 36 int encrypt_data_block(u8 *source, unsigned int length, u8 *key); 43 * \param key AES128 encryption key 45 int decrypt_data_block(u8 *source, unsigned int length, u8 *key);
|
/u-boot/fs/ubifs/ |
H A D | key.h | 12 * This header contains various key-related definitions and helper function. 13 * UBIFS allows several key schemes, so we access key fields only via these 14 * helpers. At the moment only one key scheme is supported. 16 * Simple key scheme 20 * in case of direntry key). Next 3 bits are node type. The last 29 bits are 79 * ino_key_init - initialize inode key. 81 * @key: key to initialize 85 union ubifs_key *key, ino_ 84 ino_key_init(const struct ubifs_info *c, union ubifs_key *key, ino_t inum) argument 100 union ubifs_key *key = k; local 113 lowest_ino_key(const struct ubifs_info *c, union ubifs_key *key, ino_t inum) argument 126 highest_ino_key(const struct ubifs_info *c, union ubifs_key *key, ino_t inum) argument 140 dent_key_init(const struct ubifs_info *c, union ubifs_key *key, ino_t inum, const struct qstr *nm) argument 159 dent_key_init_hash(const struct ubifs_info *c, union ubifs_key *key, ino_t inum, uint32_t hash) argument 178 union ubifs_key *key = k; local 194 lowest_dent_key(const struct ubifs_info *c, union ubifs_key *key, ino_t inum) argument 208 xent_key_init(const struct ubifs_info *c, union ubifs_key *key, ino_t inum, const struct qstr *nm) argument 229 union ubifs_key *key = k; local 245 lowest_xent_key(const struct ubifs_info *c, union ubifs_key *key, ino_t inum) argument 259 data_key_init(const struct ubifs_info *c, union ubifs_key *key, ino_t inum, unsigned int block) argument 274 highest_data_key(const struct ubifs_info *c, union ubifs_key *key, ino_t inum) argument 289 trun_key_init(const struct ubifs_info *c, union ubifs_key *key, ino_t inum) argument 303 invalid_key_init(const struct ubifs_info *c, union ubifs_key *key) argument 315 key_type(const struct ubifs_info *c, const union ubifs_key *key) argument 328 const union ubifs_key *key = k; local 340 const union ubifs_key *key = k; local 352 const union ubifs_key *key = k; local 362 key_hash(const struct ubifs_info *c, const union ubifs_key *key) argument 375 const union ubifs_key *key = k; local 385 key_block(const struct ubifs_info *c, const union ubifs_key *key) argument 399 const union ubifs_key *key = k; local 514 is_hash_key(const struct ubifs_info *c, const union ubifs_key *key) argument [all...] |
/u-boot/lib/ecdsa/ |
H A D | ecdsa-verify.c | 16 * Derive size of an ECDSA key from the curve name 18 * While it's possible to extract the key size by using string manipulation, 29 static int fdt_get_key(struct ecdsa_public_key *key, const void *fdt, int node) argument 33 key->curve_name = fdt_getprop(fdt, node, "ecdsa,curve", NULL); 34 if (!key->curve_name) { 35 debug("Error: ecdsa cannot get 'ecdsa,curve' property from key. Likely not an ecdsa key.\n"); 39 key->size_bits = ecdsa_key_size(key->curve_name); 40 if (key 66 struct ecdsa_public_key key; local [all...] |
/u-boot/arch/arm/mach-stm32mp/ |
H A D | cmd_stm32key.c | 25 /* PKH is the first element of the key list */ 59 /* index of current selected key in stm32key list, 0 = PKH by default */ 100 static void read_key_value(const struct stm32key *key, u32 addr) argument 104 for (i = 0; i < key->size; i++) { 105 printf("%s OTP %i: [%08x] %08x\n", key->name, key->start + i, 111 static int read_key_otp(struct udevice *dev, const struct stm32key *key, bool print, bool *locked) argument 118 for (i = 0, word = key->start; i < key->size; i++, word++) { 126 printf("%s OTP %i: %08x lock : %08x\n", key 189 fuse_key_value(struct udevice *dev, const struct stm32key *key, u32 addr, bool print) argument 230 display_key_info(const struct stm32key *key) argument 248 const struct stm32key *key; local 274 const struct stm32key *key; local 322 const struct stm32key *key = get_key(stm32key_index); local 372 const struct stm32key *key; local [all...] |
/u-boot/include/crypto/ |
H A D | public_key.h | 2 /* Asymmetric public-key algorithm definitions 21 * Cryptographic data for the public-key subtype of the asymmetric key type. 23 * Note that this may include private part of the key as well as the public 27 void *key; member in struct:public_key 37 extern void public_key_free(struct public_key *key); 40 * Public key cryptography signature data 58 struct key; 62 extern int restrict_link_by_signature(struct key *dest_keyring, 65 struct key *trust_keyrin [all...] |
H A D | pkcs7.h | 16 struct key; 42 struct key *trust_keyring);
|
/u-boot/include/keys/ |
H A D | asymmetric-type.h | 2 /* Asymmetric Public-key cryptography key type interface 14 #include <linux/key-type.h> 20 * The key payload is four words. The asymmetric-type key uses them as 24 asym_crypto, /* The data representing the key */ 27 asym_auth /* The key's authorisation (signature, parent key ID) */ 32 * Identifiers for an asymmetric key ID. We have three ways of looking up a 33 * key derive 73 asymmetric_key_ids(const struct key *key) argument [all...] |
/u-boot/common/ |
H A D | menu.c | 28 char *key; member in struct:menu_item 83 * Otherwise, print the key of the item. 90 puts(item->key); 101 * key. 107 if (item->key) 108 free(item->key); 132 * Check if an item's key matches a provided string, pointed to by extra. If 133 * extra is NULL, an item with a NULL key will match. Otherwise, the item's 134 * key has to match according to strcmp. 137 * the key matche 215 char *key = m->item_choice(m->item_choice_data); local 433 enum bootmenu_key key = BKEY_NONE; local 488 enum bootmenu_key key; local 529 enum bootmenu_key key; local [all...] |
/u-boot/fs/btrfs/ |
H A D | subvolume.c | 21 struct btrfs_key key; local 37 key.objectid = cur; 38 key.type = BTRFS_INODE_REF_KEY; 39 key.offset = (u64)-1; 41 ret = btrfs_search_slot(NULL, root, &key, &path, 0, 0); 69 btrfs_item_key_to_cpu(path.nodes[0], &key, path.slots[0]); 70 cur = key.offset; 83 struct btrfs_key key; local 100 key.objectid = cur; 101 key 163 struct btrfs_key key; local [all...] |
H A D | inode.c | 25 struct btrfs_key key; local 29 key.objectid = ino; 30 key.type = BTRFS_EXTENT_DATA_KEY; 31 key.offset = 0; 34 ret = btrfs_search_slot(NULL, root, &key, &path, 0, 0); 77 struct btrfs_key key; local 81 key.objectid = rootid; 82 key.type = BTRFS_ROOT_BACKREF_KEY; 83 key.offset = (u64)-1; 85 ret = btrfs_search_slot(NULL, root, &key, 124 struct btrfs_key key; local 250 struct btrfs_key key; local 426 struct btrfs_key key; local 537 struct btrfs_key key; local 666 struct btrfs_key key; local [all...] |
H A D | dir-item.c | 86 struct btrfs_key key; local 92 key.objectid = dir; 93 key.type = BTRFS_DIR_ITEM_KEY; 95 key.offset = btrfs_name_hash(name, name_len); 97 ret = btrfs_search_slot(trans, root, &key, path, ins_len, cow); 111 found_key.offset != key.offset) 121 struct btrfs_key key; local 125 key.objectid = ino; 126 key.type = BTRFS_DIR_INDEX_KEY; 127 key [all...] |
/u-boot/scripts/kconfig/lxdialog/ |
H A D | yesno.c | 31 int i, x, y, key = 0, button = 0; local 65 while (key != KEY_ESC) { 66 key = wgetch(dialog); 67 switch (key) { 80 button = ((key == KEY_LEFT ? --button : ++button) < 0) ? 1 : (button > 1 ? 0 : button); 90 key = on_key_esc(dialog); 100 return key; /* ESC pressed */
|
/u-boot/include/crypto/internal/ |
H A D | rsa.h | 13 * rsa_key - RSA key structure 50 int rsa_parse_pub_key(struct rsa_key *rsa_key, const void *key, 53 int rsa_parse_priv_key(struct rsa_key *rsa_key, const void *key,
|