Home
last modified time | relevance | path

Searched refs:key (Results 1 – 25 of 1548) sorted by relevance

12345678910>>...62

/dragonfly/crypto/libressl/crypto/gost/
HDgost2814789.c72 const GOST2814789_KEY *key) in Gost2814789_encrypt() argument
80 n2 ^= f(key, n1 + key->key[0]); n1 ^= f(key, n2 + key->key[1]); in Gost2814789_encrypt()
81 n2 ^= f(key, n1 + key->key[2]); n1 ^= f(key, n2 + key->key[3]); in Gost2814789_encrypt()
82 n2 ^= f(key, n1 + key->key[4]); n1 ^= f(key, n2 + key->key[5]); in Gost2814789_encrypt()
83 n2 ^= f(key, n1 + key->key[6]); n1 ^= f(key, n2 + key->key[7]); in Gost2814789_encrypt()
85 n2 ^= f(key, n1 + key->key[0]); n1 ^= f(key, n2 + key->key[1]); in Gost2814789_encrypt()
86 n2 ^= f(key, n1 + key->key[2]); n1 ^= f(key, n2 + key->key[3]); in Gost2814789_encrypt()
87 n2 ^= f(key, n1 + key->key[4]); n1 ^= f(key, n2 + key->key[5]); in Gost2814789_encrypt()
88 n2 ^= f(key, n1 + key->key[6]); n1 ^= f(key, n2 + key->key[7]); in Gost2814789_encrypt()
90 n2 ^= f(key, n1 + key->key[0]); n1 ^= f(key, n2 + key->key[1]); in Gost2814789_encrypt()
[all …]
HDgostr341001_key.c112 GOST_KEY_check_key(const GOST_KEY *key) in GOST_KEY_check_key() argument
119 if (key == NULL || key->group == NULL || key->pub_key == NULL) { in GOST_KEY_check_key()
123 if (EC_POINT_is_at_infinity(key->group, key->pub_key) != 0) { in GOST_KEY_check_key()
129 if ((point = EC_POINT_new(key->group)) == NULL) in GOST_KEY_check_key()
133 if (EC_POINT_is_on_curve(key->group, key->pub_key, ctx) == 0) { in GOST_KEY_check_key()
140 if (EC_GROUP_get_order(key->group, order, ctx) == 0) { in GOST_KEY_check_key()
144 if (EC_POINT_mul(key->group, point, NULL, key->pub_key, order, in GOST_KEY_check_key()
149 if (EC_POINT_is_at_infinity(key->group, point) == 0) { in GOST_KEY_check_key()
157 if (key->priv_key != NULL) { in GOST_KEY_check_key()
158 if (BN_cmp(key->priv_key, order) >= 0) { in GOST_KEY_check_key()
[all …]
/dragonfly/usr.sbin/bthcid/
HDparser.y50 static void free_key (link_key_p key);
61 static link_key_p key = NULL; variable
79 key = (link_key_p) malloc(sizeof(*key));
80 if (key == NULL) {
86 memset(key, 0, sizeof(*key));
90 if (get_key(&key->bdaddr, 1) != NULL) {
93 bt_ntoa(&key->bdaddr, NULL));
94 free_key(key);
96 LIST_INSERT_HEAD(&link_keys, key, next);
98 key = NULL;
[all …]
HDconfig.c57 link_key_p key = NULL; in lookup_key() local
63 if ((key = get_key(raddr, 0)) != NULL) { in lookup_key()
66 bt_ntoa(&key->bdaddr, NULL), in lookup_key()
67 (key->name != NULL)? key->name : "No name", in lookup_key()
68 (key->key != NULL)? "exists" : "doesn't exist"); in lookup_key()
69 return key->key; in lookup_key()
85 link_key_p key = NULL; in lookup_pin_conf() local
91 if ((key = get_key(raddr, 0)) != NULL) { in lookup_pin_conf()
94 bt_ntoa(&key->bdaddr, NULL), in lookup_pin_conf()
95 (key->name != NULL)? key->name : "No name", in lookup_pin_conf()
[all …]
/dragonfly/contrib/wpa_supplicant/src/tls/
HDrsa.c64 struct crypto_rsa_key *key; in crypto_rsa_import_public_key() local
68 key = os_zalloc(sizeof(*key)); in crypto_rsa_import_public_key()
69 if (key == NULL) in crypto_rsa_import_public_key()
72 key->n = bignum_init(); in crypto_rsa_import_public_key()
73 key->e = bignum_init(); in crypto_rsa_import_public_key()
74 if (key->n == NULL || key->e == NULL) { in crypto_rsa_import_public_key()
75 crypto_rsa_free(key); in crypto_rsa_import_public_key()
98 pos = crypto_rsa_parse_integer(pos, end, key->n); in crypto_rsa_import_public_key()
99 pos = crypto_rsa_parse_integer(pos, end, key->e); in crypto_rsa_import_public_key()
111 return key; in crypto_rsa_import_public_key()
[all …]
/dragonfly/crypto/libressl/crypto/evp/
HDe_rc4_hmac_md5.c76 void rc4_md5_enc (RC4_KEY *key, const void *in0, void *out,
85 EVP_RC4_HMAC_MD5 *key = data(ctx); in rc4_hmac_md5_init_key() local
87 RC4_set_key(&key->ks, EVP_CIPHER_CTX_key_length(ctx), inkey); in rc4_hmac_md5_init_key()
89 MD5_Init(&key->head); /* handy when benchmarking */ in rc4_hmac_md5_init_key()
90 key->tail = key->head; in rc4_hmac_md5_init_key()
91 key->md = key->head; in rc4_hmac_md5_init_key()
93 key->payload_length = NO_PAYLOAD_LENGTH; in rc4_hmac_md5_init_key()
116 EVP_RC4_HMAC_MD5 *key = data(ctx); in rc4_hmac_md5_cipher() local
118 size_t rc4_off = 32-1-(key->ks.x&(32-1)), /* 32 is $MOD from rc4_md5-x86_64.pl */ in rc4_hmac_md5_cipher()
119 md5_off = MD5_CBLOCK - key->md.num, in rc4_hmac_md5_cipher()
[all …]
HDe_aes_cbc_hmac_sha1.c91 int aesni_set_encrypt_key(const unsigned char *userKey, int bits, AES_KEY *key);
92 int aesni_set_decrypt_key(const unsigned char *userKey, int bits, AES_KEY *key);
95 size_t length, const AES_KEY *key, unsigned char *ivec, int enc);
98 const AES_KEY *key, unsigned char iv[16], SHA_CTX *ctx, const void *in0);
106 EVP_AES_HMAC_SHA1 *key = data(ctx); in aesni_cbc_hmac_sha1_init_key() local
110 ret = aesni_set_encrypt_key(inkey, ctx->key_len * 8, &key->ks); in aesni_cbc_hmac_sha1_init_key()
112 ret = aesni_set_decrypt_key(inkey, ctx->key_len * 8, &key->ks); in aesni_cbc_hmac_sha1_init_key()
114 SHA1_Init(&key->head); /* handy when benchmarking */ in aesni_cbc_hmac_sha1_init_key()
115 key->tail = key->head; in aesni_cbc_hmac_sha1_init_key()
116 key->md = key->head; in aesni_cbc_hmac_sha1_init_key()
[all …]
/dragonfly/contrib/gdb-7/readline/
HDvi_mode.c165 _rl_vi_set_last (key, repeat, sign) in _rl_vi_set_last() argument
166 int key, repeat, sign; in _rl_vi_set_last()
168 _rl_vi_last_command = key;
176 rl_vi_start_inserting (key, repeat, sign) in rl_vi_start_inserting() argument
177 int key, repeat, sign; in rl_vi_start_inserting()
179 _rl_vi_set_last (key, repeat, sign);
180 rl_vi_insertion_mode (1, key);
263 rl_vi_undo (count, key) in rl_vi_undo() argument
264 int count, key; in rl_vi_undo()
266 return (rl_undo_command (count, key));
[all …]
HDtext.c260 rl_forward_byte (count, key) in rl_forward_byte() argument
261 int count, key; in rl_forward_byte()
264 return (rl_backward_byte (-count, key));
320 rl_forward_char (count, key) in rl_forward_char() argument
321 int count, key; in rl_forward_char()
326 return (rl_forward_byte (count, key));
329 return (rl_backward_char (-count, key));
351 rl_forward_char (count, key) in rl_forward_char() argument
352 int count, key; in rl_forward_char()
354 return (rl_forward_byte (count, key));
[all …]
/dragonfly/usr.sbin/ypserv/
HDyp_dblookup.c74 char *key; member
196 DBT key = { NULL, 0 }, data = { NULL, 0 }; in yp_setflags() local
199 key.data = inter_string; in yp_setflags()
200 key.size = inter_sz; in yp_setflags()
202 if (!(dbp->get)(dbp, &key, &data, 0)) in yp_setflags()
205 key.data = secure_string; in yp_setflags()
206 key.size = secure_sz; in yp_setflags()
208 if (!(dbp->get)(dbp, &key, &data, 0)) in yp_setflags()
274 qptr->dbptr->key = NULL; in yp_cache_db()
311 yp_find_db(const char *name, const char *key, const int size) in yp_find_db() argument
[all …]
/dragonfly/contrib/gcc-4.7/libgcc/config/
HDvxlib-tls.c126 #define KEY_VALID_P(key) !(tls_keys.generation[key] & 1) argument
156 __gthread_key_t key; in tls_delete_hook() local
174 for (key = 0; key < MAX_KEYS; key++) in tls_delete_hook()
176 if (data->generation[key] == tls_keys.generation[key]) in tls_delete_hook()
178 tls_dtor dtor = tls_keys.dtor[key]; in tls_delete_hook()
181 dtor (data->values[key]); in tls_delete_hook()
233 __gthread_key_t key; in __gthread_key_create() local
240 for (key = 0; key < MAX_KEYS; key++) in __gthread_key_create()
241 if (!KEY_VALID_P (key)) in __gthread_key_create()
249 tls_keys.generation[key]++; /* making it even */ in __gthread_key_create()
[all …]
/dragonfly/sys/netproto/802_11/wlan/
HDieee80211_crypto.c103 cipher_detach(struct ieee80211_key *key) in cipher_detach() argument
105 key->wk_cipher->ic_detach(key); in cipher_detach()
109 cipher_attach(struct ieee80211vap *vap, struct ieee80211_key *key) in cipher_attach() argument
111 return key->wk_cipher->ic_attach(vap, key); in cipher_attach()
119 struct ieee80211_key *key, in dev_key_alloc() argument
122 return vap->iv_key_alloc(vap, key, keyix, rxkeyix); in dev_key_alloc()
127 const struct ieee80211_key *key) in dev_key_delete() argument
129 return vap->iv_key_delete(vap, key); in dev_key_delete()
133 dev_key_set(struct ieee80211vap *vap, const struct ieee80211_key *key) in dev_key_set() argument
135 return vap->iv_key_set(vap, key); in dev_key_set()
[all …]
/dragonfly/usr.bin/top/
HDhash.c124 string_hash(hash_table *ht, char *key) in string_hash() argument
131 while ((ch = (unsigned char)*key++) != '\0') in string_hash()
323 hash_add_uint(hash_table *ht, unsigned int key, void *value) in hash_add_uint() argument
339 hi->key = key; in hash_add_uint()
343 bucket = &(ht->buckets[(key % ht->num_buckets)]); in hash_add_uint()
351 k1 = h->key; in hash_add_uint()
352 if (key == k1) in hash_add_uint()
386 hash_replace_uint(hash_table *ht, unsigned int key, void *value) in hash_replace_uint() argument
397 bucket = &(ht->buckets[(key % ht->num_buckets)]); in hash_replace_uint()
405 k1 = hi->key; in hash_replace_uint()
[all …]
HDhash.h83 unsigned int key; member
87 void *hash_add_uint(hash_table *ht, unsigned int key, void *value);
88 void *hash_replace_uint(hash_table *ht, unsigned int key, void *value);
89 void *hash_lookup_uint(hash_table *ht, unsigned int key);
90 void *hash_remove_uint(hash_table *ht, unsigned int key);
97 pid_t key; member
101 void *hash_add_pid(hash_table *ht, pid_t key, void *value);
102 void *hash_replace_pid(hash_table *ht, pid_t key, void *value);
103 void *hash_lookup_pid(hash_table *ht, pid_t key);
104 void *hash_remove_pid(hash_table *ht, pid_t key);
[all …]
/dragonfly/crypto/libressl/crypto/ec/
HDec_key.c379 EC_KEY_set_public_key_affine_coordinates(EC_KEY * key, BIGNUM * x, BIGNUM * y) in EC_KEY_set_public_key_affine_coordinates() argument
386 if (!key || !key->group || !x || !y) { in EC_KEY_set_public_key_affine_coordinates()
394 point = EC_POINT_new(key->group); in EC_KEY_set_public_key_affine_coordinates()
404 if (!EC_POINT_set_affine_coordinates(key->group, point, x, y, ctx)) in EC_KEY_set_public_key_affine_coordinates()
406 if (!EC_POINT_get_affine_coordinates(key->group, point, tx, ty, ctx)) in EC_KEY_set_public_key_affine_coordinates()
416 if (!EC_KEY_set_public_key(key, point)) in EC_KEY_set_public_key_affine_coordinates()
419 if (EC_KEY_check_key(key) == 0) in EC_KEY_set_public_key_affine_coordinates()
432 EC_KEY_get0_group(const EC_KEY * key) in EC_KEY_get0_group() argument
434 return key->group; in EC_KEY_get0_group()
438 EC_KEY_set_group(EC_KEY * key, const EC_GROUP * group) in EC_KEY_set_group() argument
[all …]
/dragonfly/lib/libthread_xu/thread/
HDthr_spec.c47 _pthread_key_create(pthread_key_t *key, void (*destructor) (void *)) in _pthread_key_create() argument
67 *key = i; in _pthread_key_create()
78 _pthread_key_delete(pthread_key_t key) in _pthread_key_delete() argument
83 if ((unsigned int)key < PTHREAD_KEYS_MAX) { in _pthread_key_delete()
87 if (_thread_keytable[key].allocated) in _pthread_key_delete()
88 _thread_keytable[key].allocated = 0; in _pthread_key_delete()
105 int key; in _thread_cleanupspecific() local
115 for (key = 0; (key < PTHREAD_KEYS_MAX) && in _thread_cleanupspecific()
116 (curthread->specific_data_count > 0); key++) { in _thread_cleanupspecific()
119 if (_thread_keytable[key].allocated && in _thread_cleanupspecific()
[all …]
/dragonfly/crypto/openssh/
HDssh-xmss.c69 ssh_xmss_serialize_public(const struct sshkey *key, struct sshbuf *b, in ssh_xmss_serialize_public() argument
74 if (key->xmss_name == NULL || key->xmss_pk == NULL || in ssh_xmss_serialize_public()
75 sshkey_xmss_pklen(key) == 0) in ssh_xmss_serialize_public()
77 if ((r = sshbuf_put_cstring(b, key->xmss_name)) != 0 || in ssh_xmss_serialize_public()
78 (r = sshbuf_put_string(b, key->xmss_pk, in ssh_xmss_serialize_public()
79 sshkey_xmss_pklen(key))) != 0 || in ssh_xmss_serialize_public()
80 (r = sshkey_xmss_serialize_pk_info(key, b, opts)) != 0) in ssh_xmss_serialize_public()
87 ssh_xmss_serialize_private(const struct sshkey *key, struct sshbuf *b, in ssh_xmss_serialize_private() argument
92 if (key->xmss_name == NULL) in ssh_xmss_serialize_private()
95 if ((r = sshbuf_put_cstring(b, key->xmss_name)) != 0 || in ssh_xmss_serialize_private()
[all …]
HDssh-ecdsa.c49 ssh_ecdsa_size(const struct sshkey *key) in ssh_ecdsa_size() argument
51 switch (key->ecdsa_nid) { in ssh_ecdsa_size()
95 ssh_ecdsa_serialize_public(const struct sshkey *key, struct sshbuf *b, in ssh_ecdsa_serialize_public() argument
100 if (key->ecdsa == NULL) in ssh_ecdsa_serialize_public()
103 sshkey_curve_nid_to_name(key->ecdsa_nid))) != 0 || in ssh_ecdsa_serialize_public()
104 (r = sshbuf_put_eckey(b, key->ecdsa)) != 0) in ssh_ecdsa_serialize_public()
111 ssh_ecdsa_serialize_private(const struct sshkey *key, struct sshbuf *b, in ssh_ecdsa_serialize_private() argument
116 if (!sshkey_is_cert(key)) { in ssh_ecdsa_serialize_private()
117 if ((r = ssh_ecdsa_serialize_public(key, b, opts)) != 0) in ssh_ecdsa_serialize_private()
121 EC_KEY_get0_private_key(key->ecdsa))) != 0) in ssh_ecdsa_serialize_private()
[all …]
/dragonfly/lib/libc/db/test/btree.tests/
HDmain.c265 DBT key, data; in append() local
273 key.data = argv[1]; in append()
274 key.size = sizeof(recno_t); in append()
277 status = (db->put)(db, &key, &data, R_APPEND); in append()
293 DBT data, key; in cursor() local
296 key.data = argv[1]; in cursor()
298 key.size = sizeof(recno_t); in cursor()
300 key.size = strlen(argv[1]) + 1; in cursor()
301 status = (*db->seq)(db, &key, &data, R_CURSOR); in cursor()
310 keydata(&key, &data); in cursor()
[all …]
/dragonfly/sys/crypto/twofish/
HDtwofish.c284 static u_int32_t h_fun(twofish_ctx *ctx, const u_int32_t x, const u_int32_t key[]) in h_fun() argument
292 case 4: b0 = q(1, (u_int8_t) b0) ^ extract_byte(key[3],0); in h_fun()
293 b1 = q(0, (u_int8_t) b1) ^ extract_byte(key[3],1); in h_fun()
294 b2 = q(0, (u_int8_t) b2) ^ extract_byte(key[3],2); in h_fun()
295 b3 = q(1, (u_int8_t) b3) ^ extract_byte(key[3],3); in h_fun()
296 case 3: b0 = q(1, (u_int8_t) b0) ^ extract_byte(key[2],0); in h_fun()
297 b1 = q(1, (u_int8_t) b1) ^ extract_byte(key[2],1); in h_fun()
298 b2 = q(0, (u_int8_t) b2) ^ extract_byte(key[2],2); in h_fun()
299 b3 = q(0, (u_int8_t) b3) ^ extract_byte(key[2],3); in h_fun()
300 …case 2: b0 = q(0, (u_int8_t) (q(0, (u_int8_t) b0) ^ extract_byte(key[1],0))) ^ extract_byte(key[0]… in h_fun()
[all …]
/dragonfly/usr.sbin/installer/libaura/
HDdict.c48 void aura_dict_locate_hash(struct aura_dict *d, const void *key, size_t key_size,
50 void aura_dict_locate_list(struct aura_dict *d, const void *key, size_t key_size,
54 static void aura_dict_fetch_hash(struct aura_dict *d, const void *key, size_t key_size,
56 static void aura_dict_store_hash(struct aura_dict *d, const void *key, size_t key_size,
58 static void aura_dict_fetch_list(struct aura_dict *d, const void *key, size_t key_size,
60 static void aura_dict_store_list(struct aura_dict *d, const void *key, size_t key_size,
62 static void aura_dict_store_list_sorted(struct aura_dict *d, const void *key, size_t key_si…
118 if (b->key != NULL) in aura_bucket_free()
119 free(b->key); in aura_bucket_free()
150 hashpjw(const void *key, size_t key_size, size_t table_size) { in hashpjw() argument
[all …]
/dragonfly/crypto/libressl/crypto/rsa/
HDrsa_chk.c59 RSA_check_key(const RSA *key) in RSA_check_key() argument
66 if (!key->p || !key->q || !key->n || !key->e || !key->d) { in RSA_check_key()
84 if (BN_is_one(key->e)) { in RSA_check_key()
88 if (!BN_is_odd(key->e)) { in RSA_check_key()
94 r = BN_is_prime_ex(key->p, BN_prime_checks, NULL, NULL); in RSA_check_key()
103 r = BN_is_prime_ex(key->q, BN_prime_checks, NULL, NULL); in RSA_check_key()
112 r = BN_mul(i, key->p, key->q, ctx); in RSA_check_key()
118 if (BN_cmp(i, key->n) != 0) { in RSA_check_key()
125 r = BN_sub(i, key->p, BN_value_one()); in RSA_check_key()
130 r = BN_sub(j, key->q, BN_value_one()); in RSA_check_key()
[all …]
/dragonfly/sys/opencrypto/
HDxform.c453 null_encrypt(caddr_t key, u_int8_t *blk, u_int8_t *iv) in null_encrypt() argument
458 null_decrypt(caddr_t key, u_int8_t *blk, u_int8_t *iv) in null_decrypt() argument
463 null_setkey(void *sched, u_int8_t *key, int len) in null_setkey() argument
469 des1_encrypt(caddr_t key, u_int8_t *blk, u_int8_t *iv) in des1_encrypt() argument
472 des_key_schedule *p = (des_key_schedule *) key; in des1_encrypt()
478 des1_decrypt(caddr_t key, u_int8_t *blk, u_int8_t *iv) in des1_decrypt() argument
481 des_key_schedule *p = (des_key_schedule *) key; in des1_decrypt()
487 des1_setkey(void *sched, u_int8_t *key, int len) in des1_setkey() argument
489 return des_set_key((des_cblock *)key, sched); in des1_setkey()
493 des3_encrypt(caddr_t key, u_int8_t *blk, u_int8_t *iv) in des3_encrypt() argument
[all …]
/dragonfly/sys/dev/drm/
HDdrm_hashtab.c59 void drm_ht_verbose_list(struct drm_open_hash *ht, unsigned long key) in drm_ht_verbose_list() argument
66 hashed_key = hash_long(key, ht->order); in drm_ht_verbose_list()
67 DRM_DEBUG("Key is 0x%08lx, Hashed key is 0x%08x\n", key, hashed_key); in drm_ht_verbose_list()
70 DRM_DEBUG("count %d, key: 0x%08lx\n", count++, entry->key); in drm_ht_verbose_list()
74 unsigned long key) in drm_ht_find_key() argument
80 hashed_key = hash_long(key, ht->order); in drm_ht_find_key()
83 if (entry->key == key) in drm_ht_find_key()
85 if (entry->key > key) in drm_ht_find_key()
92 unsigned long key) in drm_ht_find_key_rcu() argument
98 hashed_key = hash_long(key, ht->order); in drm_ht_find_key_rcu()
[all …]
/dragonfly/contrib/cvs-1.12/src/
HDmyndbm.c69 fputs (node->key, fp); in write_item()
99 mydbm_fetch (DBM *db, datum key) in mydbm_fetch() argument
106 s = xmalloc (key.dsize + 1); in mydbm_fetch()
107 (void) strncpy (s, key.dptr, key.dsize); in mydbm_fetch()
108 s[key.dsize] = '\0'; in mydbm_fetch()
131 datum key; in mydbm_firstkey() local
137 key.dptr = p->key; in mydbm_firstkey()
138 key.dsize = strlen (p->key); in mydbm_firstkey()
142 key.dptr = NULL; in mydbm_firstkey()
143 key.dsize = 0; in mydbm_firstkey()
[all …]

12345678910>>...62