Home
last modified time | relevance | path

Searched refs:alg (Results 1 – 25 of 56) sorted by relevance

123

/onnv-gate/usr/src/uts/common/inet/ilb/
H A Dilb_alg_hash.c274 hash_t *alg = (hash_t *)alg_data; in hash_server_enable() local
277 mutex_enter(&alg->hash_lock); in hash_server_enable()
279 for (i = 0; i < alg->hash_servers; i++) { in hash_server_enable()
280 if (alg->hash_tbl[i].server == host) { in hash_server_enable()
281 if (alg->hash_tbl[i].enabled) { in hash_server_enable()
282 mutex_exit(&alg->hash_lock); in hash_server_enable()
289 if (i == alg->hash_servers) { in hash_server_enable()
290 mutex_exit(&alg->hash_lock); in hash_server_enable()
299 for (j = 0; j < alg->hash_enabled_servers; j++) { in hash_server_enable()
300 if (alg->hash_enabled_tbl[j].server == host) { in hash_server_enable()
[all …]
H A Dilb_alg_rr.c188 ilb_alg_data_t *alg; in ilb_alg_rr_init() local
191 if ((alg = kmem_alloc(sizeof (ilb_alg_data_t), KM_NOSLEEP)) == NULL) in ilb_alg_rr_init()
194 kmem_free(alg, sizeof (ilb_alg_data_t)); in ilb_alg_rr_init()
198 alg->ilb_alg_lb = rr_lb; in ilb_alg_rr_init()
199 alg->ilb_alg_server_del = rr_server_del; in ilb_alg_rr_init()
200 alg->ilb_alg_server_add = rr_server_add; in ilb_alg_rr_init()
201 alg->ilb_alg_server_enable = rr_server_enable; in ilb_alg_rr_init()
202 alg->ilb_alg_server_disable = rr_server_disable; in ilb_alg_rr_init()
203 alg->ilb_alg_fini = rr_fini; in ilb_alg_rr_init()
204 alg->ilb_alg_data = rr_alg; in ilb_alg_rr_init()
[all …]
/onnv-gate/usr/src/cmd/cmd-inet/usr.sbin/ipsecutils/
H A Dipsecalgs.c168 synch_emit_alg(struct ipsecalgent *alg) in synch_emit_alg() argument
173 EMIT(sync_req_attr, SPD_ATTR_ALG_ID, alg->a_alg_num); in synch_emit_alg()
174 EMIT(sync_req_attr, SPD_ATTR_ALG_PROTO, alg->a_proto_num); in synch_emit_alg()
175 EMIT(sync_req_attr, SPD_ATTR_ALG_INCRBITS, alg->a_key_increment); in synch_emit_alg()
177 nkey_sizes = num_sizes(alg->a_key_sizes); in synch_emit_alg()
180 EMIT(sync_req_attr, SPD_ATTR_ALG_KEYSIZE, alg->a_key_sizes[i]); in synch_emit_alg()
182 nblock_sizes = num_sizes(alg->a_block_sizes); in synch_emit_alg()
183 nparams = num_sizes(alg->a_mech_params); in synch_emit_alg()
187 alg->a_block_sizes[i]); in synch_emit_alg()
192 alg->a_mech_params[i]); in synch_emit_alg()
[all …]
/onnv-gate/usr/src/lib/libc/port/gen/
H A Dcrypt.c113 static void free_crypt_alg(struct crypt_alg_s *alg);
146 struct crypt_alg_s *alg; in crypt() local
181 alg = getalgbyname(algname, &found); in crypt()
182 if ((alg == NULL) || !found) { in crypt()
190 ciphertext = alg->a_genhash(ctbuffer, CRYPT_MAXCIPHERTEXTLEN, in crypt()
191 plaintext, salt, (const char **)alg->a_params); in crypt()
195 free_crypt_alg(alg); in crypt()
219 struct crypt_alg_s *alg = NULL; in crypt_gensalt() local
249 alg = getalgbyname(algname, &found); in crypt_gensalt()
250 if (alg == NULL || !found) { in crypt_gensalt()
[all …]
/onnv-gate/usr/src/common/openssl/crypto/engine/
H A Deng_fat.c97 static int int_def_cb(const char *alg, int len, void *arg) in int_def_cb() argument
100 if (!strncmp(alg, "ALL", len)) in int_def_cb()
102 else if (!strncmp(alg, "RSA", len)) in int_def_cb()
104 else if (!strncmp(alg, "DSA", len)) in int_def_cb()
106 else if (!strncmp(alg, "ECDH", len)) in int_def_cb()
108 else if (!strncmp(alg, "ECDSA", len)) in int_def_cb()
110 else if (!strncmp(alg, "DH", len)) in int_def_cb()
112 else if (!strncmp(alg, "RAND", len)) in int_def_cb()
114 else if (!strncmp(alg, "CIPHERS", len)) in int_def_cb()
116 else if (!strncmp(alg, "DIGESTS", len)) in int_def_cb()
/onnv-gate/usr/src/common/openssl/crypto/pkcs7/
H A Dpk7_attr.c114 X509_ALGOR *alg; in PKCS7_simple_smimecap() local
116 if(!(alg = X509_ALGOR_new())) { in PKCS7_simple_smimecap()
120 ASN1_OBJECT_free(alg->algorithm); in PKCS7_simple_smimecap()
121 alg->algorithm = OBJ_nid2obj (nid); in PKCS7_simple_smimecap()
124 if(!(alg->parameter = ASN1_TYPE_new())) { in PKCS7_simple_smimecap()
136 alg->parameter->value.integer = nbit; in PKCS7_simple_smimecap()
137 alg->parameter->type = V_ASN1_INTEGER; in PKCS7_simple_smimecap()
139 sk_X509_ALGOR_push (sk, alg); in PKCS7_simple_smimecap()
H A Dpk7_lib.c238 X509_ALGOR *alg; in PKCS7_add_signer() local
264 alg=sk_X509_ALGOR_value(md_sk,i); in PKCS7_add_signer()
265 if (OBJ_obj2nid(alg->algorithm) == nid) in PKCS7_add_signer()
273 if(!(alg=X509_ALGOR_new()) in PKCS7_add_signer()
274 || !(alg->parameter = ASN1_TYPE_new())) { in PKCS7_add_signer()
278 alg->algorithm=OBJ_nid2obj(nid); in PKCS7_add_signer()
279 alg->parameter->type = V_ASN1_NULL; in PKCS7_add_signer()
280 sk_X509_ALGOR_push(md_sk,alg); in PKCS7_add_signer()
/onnv-gate/usr/src/lib/libresolv2/common/dst/
H A Ddst_api.c77 static DST_KEY *dst_s_get_key_struct(const char *name, const int alg,
141 dst_check_algorithm(const int alg) in dst_check_algorithm() argument
143 return (dst_t_func[alg] != NULL); in dst_check_algorithm()
161 dst_s_get_key_struct(const char *name, const int alg, const int flags, in dst_s_get_key_struct() argument
166 if (dst_check_algorithm(alg)) /*%< make sure alg is available */ in dst_s_get_key_struct()
177 new_key->dk_alg = alg; in dst_s_get_key_struct()
182 new_key->dk_func = dst_t_func[alg]; in dst_s_get_key_struct()
465 int flags, proto, alg, len, dlen; in dst_s_read_public_key() local
534 if (fscanf(fp, "%d %d %d", &flags, &proto, &alg) != 3) { in dst_s_read_public_key()
571 return dst_buffer_to_key(in_name, alg, flags, proto, deckey, dlen); in dst_s_read_public_key()
[all …]
/onnv-gate/usr/src/lib/libipsecutil/common/
H A Dalgs.c125 alg_has_pkg(ipsec_proto_t *proto, struct ipsecalgent *alg) in alg_has_pkg() argument
133 if (proto->proto_algs_pkgs[i].alg_num == alg->a_alg_num) in alg_has_pkg()
189 struct ipsecalgent *alg; in write_new_algfile() local
249 alg = protos[i].proto_algs[j]; in write_new_algfile()
252 alg_pkg = alg_has_pkg(&protos[i], alg); in write_new_algfile()
260 alg->a_proto_num, alg->a_alg_num)); in write_new_algfile()
263 for (k = 0; alg->a_names[k] != NULL; k++) { in write_new_algfile()
264 FPRINTF_ERR(fprintf(f, "%s", alg->a_names[k])); in write_new_algfile()
265 if (alg->a_names[k+1] != NULL) in write_new_algfile()
270 FPRINTF_ERR(fprintf(f, "|%s|", alg->a_mech_name)); in write_new_algfile()
[all …]
/onnv-gate/usr/src/common/openssl/crypto/ocsp/
H A Docsp_lib.c105 X509_ALGOR *alg; in OCSP_cert_id_new() local
111 alg = cid->hashAlgorithm; in OCSP_cert_id_new()
112 if (alg->algorithm != NULL) ASN1_OBJECT_free(alg->algorithm); in OCSP_cert_id_new()
118 if (!(alg->algorithm=OBJ_nid2obj(nid))) goto err; in OCSP_cert_id_new()
119 if ((alg->parameter=ASN1_TYPE_new()) == NULL) goto err; in OCSP_cert_id_new()
120 alg->parameter->type=V_ASN1_NULL; in OCSP_cert_id_new()
/onnv-gate/usr/src/uts/common/inet/ip/
H A Dspdsock.c2349 ipsec_alginfo_t *alg = in spdsock_alglist() local
2351 uint_t minbits = alg->alg_minbits; in spdsock_alglist()
2352 uint_t maxbits = alg->alg_maxbits; in spdsock_alglist()
2353 uint_t defbits = alg->alg_default_bits; in spdsock_alglist()
2354 uint_t incr = alg->alg_increment; in spdsock_alglist()
2400 ipsec_alginfo_t *alg; in spdsock_dumpalgs() local
2427 alg = ipss->ipsec_alglists[algtype][algid]; in spdsock_dumpalgs()
2429 (ATTRPERALG + alg->alg_nkey_sizes + in spdsock_dumpalgs()
2430 alg->alg_nblock_sizes + alg->alg_nparams) + in spdsock_dumpalgs()
2491 alg = ipss->ipsec_alglists[algtype][algid]; in spdsock_dumpalgs()
[all …]
H A Dspd.c774 ipsec_alg_reg(ipsec_algtype_t algtype, ipsec_alginfo_t *alg, netstack_t *ns) in ipsec_alg_reg() argument
780 ASSERT(ipss->ipsec_alglists[algtype][alg->alg_id] == NULL); in ipsec_alg_reg()
781 ipsec_alg_fix_min_max(alg, algtype, ns); in ipsec_alg_reg()
782 ipss->ipsec_alglists[algtype][alg->alg_id] = alg; in ipsec_alg_reg()
785 alg_insert_sortlist(algtype, alg->alg_id, ns); in ipsec_alg_reg()
1265 #define SET_EXP_MINMAX(type, wild, alg, min, max, ipss) \ in ipsec_act_wildcard_expand() argument
1268 if (ipss->ipsec_alglists[type][alg] != NULL) \ in ipsec_act_wildcard_expand()
4695 ipsec_alg_fix_min_max(ipsec_alginfo_t *alg, ipsec_algtype_t alg_type, in ipsec_alg_fix_min_max() argument
4717 alg->alg_default_bits = alg->alg_key_sizes[0]; in ipsec_alg_fix_min_max()
4718 alg->alg_default = 0; in ipsec_alg_fix_min_max()
[all …]
/onnv-gate/usr/src/common/openssl/crypto/pkcs12/
H A Dp12_npas.c72 static int alg_get(X509_ALGOR *alg, int *pnid, int *piter, int *psaltlen);
204 static int alg_get(X509_ALGOR *alg, int *pnid, int *piter, int *psaltlen) in alg_get() argument
209 p = alg->parameter->value.sequence->data; in alg_get()
210 pbe = d2i_PBEPARAM(NULL, &p, alg->parameter->value.sequence->length); in alg_get()
211 *pnid = OBJ_obj2nid(alg->algorithm); in alg_get()
/onnv-gate/usr/src/uts/common/io/comstar/port/iscsit/
H A Discsit_auth.c290 uint64_t alg; in auth_chap_select_alg() local
299 rc = ddi_strtoull(alg_string, NULL, 0, (u_longlong_t *)&alg); in auth_chap_select_alg()
300 if (rc == 0 && alg == 5) { in auth_chap_select_alg()
310 alg = 0; in auth_chap_select_alg()
318 (uint32_t)alg); in auth_chap_select_alg()
323 if (alg == 0) { in auth_chap_select_alg()
473 uint32_t alg; in auth_chap_expect_r() local
477 &alg); in auth_chap_expect_r()
479 if (alg != 0) { in auth_chap_expect_r()
/onnv-gate/usr/src/cmd/cmd-inet/usr.lib/wpad/
H A Ddriver_wifi.c192 wpa_alg alg, unsigned char *addr, int key_idx, boolean_t set_tx, in wpa_driver_wifi_set_key() argument
201 if (alg == WPA_ALG_NONE) in wpa_driver_wifi_set_key()
204 switch (alg) { in wpa_driver_wifi_set_key()
219 " unknown/unsupported algorithm %d", alg); in wpa_driver_wifi_set_key()
H A Dwpa.c1003 int keyidx, tx, key_rsc_len = 0, alg; in wpa_supplicant_process_3_of_4_gtk() local
1036 alg = WPA_ALG_CCMP; in wpa_supplicant_process_3_of_4_gtk()
1045 alg = WPA_ALG_TKIP; in wpa_supplicant_process_3_of_4_gtk()
1053 alg = WPA_ALG_WEP; in wpa_supplicant_process_3_of_4_gtk()
1061 alg = WPA_ALG_WEP; in wpa_supplicant_process_3_of_4_gtk()
1082 if (wpa_s->driver->set_key(wpa_s->handle, wpa_s->linkid, alg, in wpa_supplicant_process_3_of_4_gtk()
1088 } else if (wpa_s->driver->set_key(wpa_s->handle, wpa_s->linkid, alg, in wpa_supplicant_process_3_of_4_gtk()
1249 int alg, keylen, rsclen; in wpa_supplicant_process_3_of_4() local
1253 alg = WPA_ALG_CCMP; in wpa_supplicant_process_3_of_4()
1258 alg = WPA_ALG_TKIP; in wpa_supplicant_process_3_of_4()
[all …]
/onnv-gate/usr/src/cmd/cvcd/sparc/sun4u/starcat/
H A Dcvcd.c398 cvcd_alg_t *alg; local
400 for (alg = algs; alg->arg_name != NULL && arg != NULL; alg++) {
401 if (strncmp(alg->arg_name, arg, strlen(alg->arg_name) + 1)
403 return (alg->alg_id);
/onnv-gate/usr/src/lib/libresolv2/common/nameser/
H A Dns_verify.c142 char name[MAXDNAME], alg[MAXDNAME]; in ns_verify() local
182 n = dn_expand(msg, eom, cp, alg, MAXDNAME); in ns_verify()
185 if (ns_samename(alg, NS_TSIG_ALG_HMAC_MD5) != 1) in ns_verify()
267 n = ns_name_pton(alg, buf2, sizeof(buf2)); in ns_verify()
348 char name[MAXDNAME], alg[MAXDNAME]; in ns_verify_tcp() local
409 n = dn_expand(msg, eom, cp, alg, MAXDNAME); in ns_verify_tcp()
412 if (ns_samename(alg, NS_TSIG_ALG_HMAC_MD5) != 1) in ns_verify_tcp()
/onnv-gate/usr/src/cmd/cmd-inet/usr.sbin/snoop/
H A Dsnoop_mip.c654 uint16_t alg, spi_hi, spi_low; in key_ext() local
661 (void) memcpy(&alg, p, sizeof (alg)); in key_ext()
662 alg = ntohs(alg); in key_ext()
663 switch (alg) { in key_ext()
678 "Algorithm = 0x%x: %s", alg, alg_string); in key_ext()
679 p += sizeof (alg); in key_ext()
680 this_ext_len -= sizeof (alg); in key_ext()
/onnv-gate/usr/src/common/openssl/ssl/
H A Ds3_lib.c1925 unsigned long alg,mask,emask; in ssl3_choose_cipher() local
1978 alg=c->algorithms&(SSL_MKEY_MASK|SSL_AUTH_MASK); in ssl3_choose_cipher()
1980 if (alg & SSL_KRB5) in ssl3_choose_cipher()
1988 ok=((alg & emask) == alg)?1:0; in ssl3_choose_cipher()
1990 printf("%d:[%08lX:%08lX]%p:%s (export)\n",ok,alg,emask, in ssl3_choose_cipher()
1996 ok=((alg & mask) == alg)?1:0; in ssl3_choose_cipher()
1998 printf("%d:[%08lX:%08lX]%p:%s\n",ok,alg,mask,c, in ssl3_choose_cipher()
2017 unsigned long alg; in ssl3_get_req_cert_type() local
2019 alg=s->s3->tmp.new_cipher->algorithms; in ssl3_get_req_cert_type()
2022 if (alg & (SSL_kDHr|SSL_kEDH)) in ssl3_get_req_cert_type()
[all …]
H A Dssl_ciph.c941 unsigned long alg,alg2,alg_s; in SSL_CIPHER_description() local
948 alg=cipher->algorithms; in SSL_CIPHER_description()
957 if (alg & SSL_SSLV2) in SSL_CIPHER_description()
959 else if (alg & SSL_SSLV3) in SSL_CIPHER_description()
964 switch (alg&SSL_MKEY_MASK) in SSL_CIPHER_description()
993 switch (alg&SSL_AUTH_MASK) in SSL_CIPHER_description()
1020 switch (alg&SSL_ENC_MASK) in SSL_CIPHER_description()
1058 switch (alg&SSL_MAC_MASK) in SSL_CIPHER_description()
1081 BIO_snprintf(buf,len,format,cipher->name,ver,kx,au,enc,mac,exp_str,alg); in SSL_CIPHER_description()
/onnv-gate/usr/src/common/openssl/crypto/asn1/
H A Dp5_pbe.c76 X509_ALGOR *PKCS5_pbe_set(int alg, int iter, unsigned char *salt,
117 al = OBJ_nid2obj(alg); /* never need to free al */
/onnv-gate/usr/src/common/openssl/crypto/objects/
H A Dobjects.txt216 SMIME 3 : id-smime-alg
276 id-smime-alg 1 : id-smime-alg-ESDHwith3DES
278 id-smime-alg 2 : id-smime-alg-ESDHwithRC2
280 id-smime-alg 3 : id-smime-alg-3DESwrap
282 id-smime-alg 4 : id-smime-alg-RC2wrap
283 id-smime-alg 5 : id-smime-alg-ESDH
284 id-smime-alg 6 : id-smime-alg-CMS3DESwrap
285 id-smime-alg 7 : id-smime-alg-CMSRC2wrap
401 id-pkix 6 : id-alg
505 id-alg 1 : id-alg-des40
[all …]
/onnv-gate/usr/src/lib/libpkg/common/
H A Dsecurity.c256 *get_fingerprint(X509 *cert, const EVP_MD *alg) in get_fingerprint() argument
264 if (!X509_digest(cert, alg, md, &n)) { in get_fingerprint()
/onnv-gate/usr/src/lib/pkcs11/pkcs11_tpm/common/
H A Dasn1.c839 CK_BYTE *alg = NULL; in ber_decode_PrivateKeyInfo() local
858 rc = ber_decode_SEQUENCE(buf + offset, &alg, &len, &field_len); in ber_decode_PrivateKeyInfo()
862 *algorithm = alg; in ber_decode_PrivateKeyInfo()
865 rc = ber_decode_OCTET_STRING(alg + len, priv_key, &buf_len, &field_len); in ber_decode_PrivateKeyInfo()
1073 CK_BYTE *alg = NULL; in ber_decode_RSAPrivateKey() local
1080 rc = ber_decode_PrivateKeyInfo(data, data_len, &alg, in ber_decode_RSAPrivateKey()
1085 if (memcmp(alg, ber_rsaEncryption, ber_rsaEncryptionLen) != 0) { in ber_decode_RSAPrivateKey()

123