Home
last modified time | relevance | path

Searched refs:enc (Results 1 – 25 of 199) sorted by relevance

12345678

/openssl/crypto/asn1/
H A Dtasn_utl.c142 enc->enc = NULL; in ossl_asn1_enc_init()
143 enc->len = 0; in ossl_asn1_enc_init()
153 OPENSSL_free(enc->enc); in ossl_asn1_enc_free()
154 enc->enc = NULL; in ossl_asn1_enc_free()
155 enc->len = 0; in ossl_asn1_enc_free()
165 if (enc == NULL) in ossl_asn1_enc_save()
168 OPENSSL_free(enc->enc); in ossl_asn1_enc_save()
171 if ((enc->enc = OPENSSL_malloc(inlen)) == NULL) { in ossl_asn1_enc_save()
175 memcpy(enc->enc, in, inlen); in ossl_asn1_enc_save()
187 if (enc == NULL || enc->modified) in ossl_asn1_enc_restore()
[all …]
/openssl/test/
H A Dpkcs12_format_test.c361 sprintf(fname, "1key_ciph-%s_iter-%d.p12", OBJ_nid2sn(enc->nid), enc->iter); in test_single_key()
392 PKCS12_ENC enc; in test_single_key_enc_alg() local
398 enc.pass = enc_default.pass; in test_single_key_enc_alg()
406 PKCS12_ENC enc; in test_single_key_enc_pass() local
408 enc.nid = enc_default.nid; in test_single_key_enc_pass()
409 enc.pass = passwords[z]; in test_single_key_enc_pass()
417 PKCS12_ENC enc; in test_single_key_enc_iter() local
419 enc.nid = enc_default.nid; in test_single_key_enc_iter()
421 enc.iter = iters[z]; in test_single_key_enc_iter()
620 sprintf(fname, "1secret_ciph-%s_iter-%d.p12", OBJ_nid2sn(enc->nid), enc->iter); in test_single_secret()
[all …]
H A Dbad_dtls_test.c289 unsigned char *enc; in send_record() local
301 enc = OPENSSL_malloc(len + SHA_DIGEST_LENGTH + 1 + pad); in send_record()
302 if (enc == NULL) in send_record()
306 memcpy(enc, msg, len); in send_record()
323 || !EVP_MAC_update(ctx, enc, len) /* Finally the data itself */ in send_record()
324 || !EVP_MAC_final(ctx, enc + len, NULL, SHA_DIGEST_LENGTH)) in send_record()
330 enc[len++] = pad; in send_record()
338 || !TEST_int_ge(EVP_Cipher(enc_ctx, enc, enc, len), 0)) in send_record()
351 BIO_write(rbio, enc, len); in send_record()
357 OPENSSL_free(enc); in send_record()
/openssl/crypto/pem/
H A Dpem_pk8.c22 int nid, const EVP_CIPHER *enc,
29 int nid, const EVP_CIPHER *enc,
52 return do_pk8pkey(bp, x, 0, -1, enc, kstr, klen, cb, u, NULL); in PEM_write_bio_PKCS8PrivateKey()
59 return do_pk8pkey(bp, x, 1, -1, enc, kstr, klen, cb, u, NULL); in i2d_PKCS8PrivateKey_bio()
70 const EVP_CIPHER *enc, const char *kstr, int klen, in do_pk8pkey() argument
104 if (enc != NULL) { in do_pk8pkey()
136 if (enc || (nid != -1)) { in do_pk8pkey()
146 p8 = PKCS8_encrypt(nid, enc, kstr, klen, NULL, 0, 0, p8inf); in do_pk8pkey()
212 return do_pk8pkey_fp(fp, x, 1, -1, enc, kstr, klen, cb, u, NULL); in i2d_PKCS8PrivateKey_fp()
233 return do_pk8pkey_fp(fp, x, 0, -1, enc, kstr, klen, cb, u, NULL); in PEM_write_PKCS8PrivateKey()
[all …]
/openssl/crypto/cms/
H A Dcms_enc.c39 int enc, keep_key = 0; in ossl_cms_EncryptedContent_init_bio() local
43 enc = ec->cipher ? 1 : 0; in ossl_cms_EncryptedContent_init_bio()
54 if (enc) { in ossl_cms_EncryptedContent_init_bio()
82 if (enc) { in ossl_cms_EncryptedContent_init_bio()
117 if (!enc || !ec->key) { in ossl_cms_EncryptedContent_init_bio()
131 if (enc) in ossl_cms_EncryptedContent_init_bio()
145 if (enc || ec->debug) { in ossl_cms_EncryptedContent_init_bio()
163 if (enc) { in ossl_cms_EncryptedContent_init_bio()
249 CMS_EncryptedData *enc = cms->d.encryptedData; in ossl_cms_EncryptedData_init_bio() local
250 if (enc->encryptedContentInfo->cipher && enc->unprotectedAttrs) in ossl_cms_EncryptedData_init_bio()
[all …]
/openssl/crypto/aes/
H A Daes_cfb.c27 unsigned char *ivec, int *num, const int enc) in AES_cfb128_encrypt() argument
30 CRYPTO_cfb128_encrypt(in, out, length, key, ivec, num, enc, in AES_cfb128_encrypt()
37 unsigned char *ivec, int *num, const int enc) in AES_cfb1_encrypt() argument
39 CRYPTO_cfb128_1_encrypt(in, out, length, key, ivec, num, enc, in AES_cfb1_encrypt()
45 unsigned char *ivec, int *num, const int enc) in AES_cfb8_encrypt() argument
47 CRYPTO_cfb128_8_encrypt(in, out, length, key, ivec, num, enc, in AES_cfb8_encrypt()
H A Daes_ecb.c22 const AES_KEY *key, const int enc) in AES_ecb_encrypt() argument
26 assert((AES_ENCRYPT == enc) || (AES_DECRYPT == enc)); in AES_ecb_encrypt()
28 if (AES_ENCRYPT == enc) in AES_ecb_encrypt()
/openssl/crypto/camellia/
H A Dcmll_cfb.c27 unsigned char *ivec, int *num, const int enc) in Camellia_cfb128_encrypt() argument
30 CRYPTO_cfb128_encrypt(in, out, length, key, ivec, num, enc, in Camellia_cfb128_encrypt()
37 unsigned char *ivec, int *num, const int enc) in Camellia_cfb1_encrypt() argument
39 CRYPTO_cfb128_1_encrypt(in, out, length, key, ivec, num, enc, in Camellia_cfb1_encrypt()
45 unsigned char *ivec, int *num, const int enc) in Camellia_cfb8_encrypt() argument
47 CRYPTO_cfb128_8_encrypt(in, out, length, key, ivec, num, enc, in Camellia_cfb8_encrypt()
/openssl/include/openssl/
H A Ddes.h80 DES_key_schedule *ks3, int enc);
91 int enc);
95 int enc);
103 int enc);
106 DES_key_schedule *ks, int enc);
121 void DES_encrypt1(DES_LONG *data, DES_key_schedule *ks, int enc);
134 void DES_encrypt2(DES_LONG *data, DES_key_schedule *ks, int enc);
145 DES_cblock *ivec, int enc);
155 DES_cblock *ivec, int enc);
171 DES_cblock *ivec, int enc);
[all …]
H A Daes.h64 const AES_KEY *key, const int enc);
68 unsigned char *ivec, const int enc);
72 unsigned char *ivec, int *num, const int enc);
76 unsigned char *ivec, int *num, const int enc);
80 unsigned char *ivec, int *num, const int enc);
90 unsigned char *ivec, const int enc);
95 const unsigned char *ivec, const int enc);
H A Dcamellia.h70 const int enc);
76 const int enc);
83 const int enc);
90 const int enc);
97 const int enc);
/openssl/crypto/evp/
H A De_idea.c34 const unsigned char *iv, int enc);
58 const unsigned char *iv, int enc) in BLOCK_CIPHER_func_cbc()
60 if (!enc) { in BLOCK_CIPHER_func_cbc()
62 enc = 1; in BLOCK_CIPHER_func_cbc()
64 enc = 1; in BLOCK_CIPHER_func_cbc()
66 if (enc) in BLOCK_CIPHER_func_cbc()
/openssl/test/helpers/
H A Dpkcs12.c295 enc->iter, enc->pass))) in end_contentinfo_encrypted()
299 enc->iter, enc->pass, test_ctx, in end_contentinfo_encrypted()
319 if (enc) { in STACK_OF()
322 bags = PKCS12_unpack_p7encdata(p7, enc->pass, strlen(enc->pass)); in STACK_OF()
410 const PKCS12_ATTR *attrs, const PKCS12_ENC *enc) in add_keybag() argument
427 bag = PKCS12_add_key(&pb->bags, pkey, 0 /*keytype*/, enc->iter, enc->nid, enc->pass); in add_keybag()
429 bag = PKCS12_add_key_ex(&pb->bags, pkey, 0 /*keytype*/, enc->iter, enc->nid, enc->pass, in add_keybag()
577 const PKCS12_ATTR *attrs, const PKCS12_ENC *enc) in check_keybag() argument
610 p8 = PKCS12_decrypt_skey(bag, enc->pass, strlen(enc->pass)); in check_keybag()
612 p8 = PKCS12_decrypt_skey_ex(bag, enc->pass, strlen(enc->pass), test_ctx, test_propq); in check_keybag()
[all …]
H A Dpkcs12.h77 void end_contentinfo_encrypted(PKCS12_BUILDER *pb, const PKCS12_ENC *enc);
82 const PKCS12_ATTR *attrs, const PKCS12_ENC *enc);
94 void start_check_contentinfo_encrypted(PKCS12_BUILDER *pb, const PKCS12_ENC *enc);
100 const PKCS12_ATTR *attrs, const PKCS12_ENC *enc);
/openssl/crypto/des/asm/
H A Ddesboth.pl15 local($name,$enc)=@_;
38 if ($enc)
54 &mov(&swtmp(2), (DWC(($enc)?"1":"0")));
58 &mov(&swtmp(2), (DWC(($enc)?"0":"1")));
62 &mov(&swtmp(2), (DWC(($enc)?"1":"0")));
/openssl/crypto/modes/
H A Dcfb128.c28 int enc, block128_f block) in CRYPTO_cfb128_encrypt() argument
40 if (enc) { in CRYPTO_cfb128_encrypt()
152 unsigned char ivec[16], int enc, in cfbr_encrypt_block() argument
167 if (enc) /* encrypt the input */ in cfbr_encrypt_block()
189 int enc, block128_f block) in CRYPTO_cfb128_1_encrypt() argument
196 cfbr_encrypt_block(c, d, 1, key, ivec, enc, block); in CRYPTO_cfb128_1_encrypt()
205 int enc, block128_f block) in CRYPTO_cfb128_8_encrypt() argument
210 cfbr_encrypt_block(&in[n], &out[n], 8, key, ivec, enc, block); in CRYPTO_cfb128_8_encrypt()
/openssl/providers/implementations/ciphers/
H A Dciphercommon_hw.c20 (*dat->stream.cbc) (in, out, len, dat->ks, dat->iv, dat->enc); in ossl_cipher_hw_generic_cbc()
21 else if (dat->enc) in ossl_cipher_hw_generic_cbc()
38 (*dat->stream.ecb) (in, out, len, dat->ks, dat->enc); in ossl_cipher_hw_generic_ecb()
64 CRYPTO_cfb128_encrypt(in, out, len, dat->ks, dat->iv, &num, dat->enc, in ossl_cipher_hw_generic_cfb128()
76 CRYPTO_cfb128_8_encrypt(in, out, len, dat->ks, dat->iv, &num, dat->enc, in ossl_cipher_hw_generic_cfb8()
90 dat->enc, dat->block); in ossl_cipher_hw_generic_cfb1()
97 dat->iv, &num, dat->enc, dat->block); in ossl_cipher_hw_generic_cfb1()
104 dat->enc, dat->block); in ossl_cipher_hw_generic_cfb1()
H A Dcipher_des_hw.c31 dctx->dstream.cbc = ctx->enc ? des_t4_cbc_encrypt : in cipher_hw_des_initkey()
61 (const_DES_cblock *)(out + i), key, ctx->enc); in cipher_hw_des_ecb_cipher()
78 ctx->enc); in cipher_hw_des_cbc_cipher()
85 ctx->enc); in cipher_hw_des_cbc_cipher()
119 &num, ctx->enc); in cipher_hw_des_cfb64_cipher()
148 DES_cfb_encrypt(c, d, 1, 1, key, (DES_cblock *)ctx->iv, ctx->enc); in cipher_hw_des_cfb1_cipher()
170 (DES_cblock *)ctx->iv, ctx->enc); in cipher_hw_des_cfb8_cipher()
177 (DES_cblock *)ctx->iv, ctx->enc); in cipher_hw_des_cfb8_cipher()
H A Dciphercommon_gcm.c57 ctx->enc = enc; in gcm_init()
133 || ctx->enc) in setivinv()
210 || !ctx->enc in ossl_gcm_get_ctx_params()
247 if (sz == 0 || ctx->enc) { in ossl_gcm_set_ctx_params()
409 if (!ctx->enc || !gcm_iv_generate(ctx, 0)) in gcm_cipher_internal()
466 if (!dat->enc) { in gcm_tls_init()
493 if (ctx->enc in gcm_tls_iv_set_fixed()
528 if (ctx->enc && ++ctx->tls_enc_records == 0) { in gcm_tls_cipher()
537 if (ctx->enc) { in gcm_tls_cipher()
553 if (!ctx->enc) in gcm_tls_cipher()
[all …]
H A Dcipher_aes_wrp.c79 size_t ivlen, const OSSL_PARAM params[], int enc) in aes_wrap_init() argument
87 ctx->enc = enc; in aes_wrap_init()
89 wctx->wrapfn = enc ? CRYPTO_128_wrap_pad : CRYPTO_128_unwrap_pad; in aes_wrap_init()
91 wctx->wrapfn = enc ? CRYPTO_128_wrap : CRYPTO_128_unwrap; in aes_wrap_init()
114 use_forward_transform = ctx->enc; in aes_wrap_init()
116 use_forward_transform = !ctx->enc; in aes_wrap_init()
161 if (!ctx->enc && (inlen < 16 || inlen & 0x7)) { in aes_wrap_cipher_internal()
173 if (ctx->enc) { in aes_wrap_cipher_internal()
H A Dcipher_tdes_default_hw.c36 tctx->tstream.cbc = ctx->enc ? des_t4_ede3_cbc_encrypt : in ossl_cipher_hw_tdes_ede2_initkey()
79 (DES_cblock *)ctx->iv, &num, ctx->enc); in ossl_cipher_hw_tdes_cfb()
87 (DES_cblock *)ctx->iv, &num, ctx->enc); in ossl_cipher_hw_tdes_cfb()
111 (DES_cblock *)ctx->iv, ctx->enc); in ossl_cipher_hw_tdes_cfb1()
127 (DES_cblock *)ctx->iv, ctx->enc); in ossl_cipher_hw_tdes_cfb8()
135 (DES_cblock *)ctx->iv, ctx->enc); in ossl_cipher_hw_tdes_cfb8()
/openssl/crypto/bf/asm/
H A Dbf-586.pl38 local($name,$enc)=@_;
59 if ($enc)
106 local($i,$L,$R,$P,$tmp1,$tmp2,$tmp3,$tmp4,$enc)=@_;
132 if (($enc && ($i != 16)) || ((!$enc) && ($i != 1)))
136 &comment("Load parameter 0 ($i) enc=$enc");
/openssl/include/crypto/
H A Dsm4_platform.h49 unsigned char *ivec, const int enc);
52 const int enc);
67 unsigned char *ivec, const int enc);
70 const int enc);
/openssl/crypto/x509/
H A Dx509rset.c22 x->req_info.enc.modified = 1; in X509_REQ_set_version()
30 x->req_info.enc.modified = 1; in X509_REQ_set_subject_name()
38 x->req_info.enc.modified = 1; in X509_REQ_set_pubkey()
/openssl/ssl/
H A Dssl_ciph.c487 *enc = NULL; in ssl_cipher_get_evp_cipher()
572 if ((*enc != NULL) in ssl_cipher_get_evp()
611 *enc = evp; in ssl_cipher_get_evp()
1802 enc = "DES(56)"; in SSL_CIPHER_description()
1808 enc = "RC4(128)"; in SSL_CIPHER_description()
1811 enc = "RC2(128)"; in SSL_CIPHER_description()
1817 enc = "None"; in SSL_CIPHER_description()
1820 enc = "AES(128)"; in SSL_CIPHER_description()
1823 enc = "AES(256)"; in SSL_CIPHER_description()
1863 enc = "MAGMA"; in SSL_CIPHER_description()
[all …]

Completed in 70 milliseconds

12345678