Home
last modified time | relevance | path

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

123456789

/openssl/crypto/asn1/
H A Dtasn_utl.c146 enc->enc = NULL; in ossl_asn1_enc_init()
147 enc->len = 0; in ossl_asn1_enc_init()
157 OPENSSL_free(enc->enc); in ossl_asn1_enc_free()
158 enc->enc = NULL; in ossl_asn1_enc_free()
159 enc->len = 0; in ossl_asn1_enc_free()
169 if (enc == NULL) in ossl_asn1_enc_save()
172 OPENSSL_free(enc->enc); in ossl_asn1_enc_save()
175 if ((enc->enc = OPENSSL_malloc(inlen)) == NULL) in ossl_asn1_enc_save()
177 memcpy(enc->enc, in, inlen); in ossl_asn1_enc_save()
189 if (enc == NULL || enc->modified) in ossl_asn1_enc_restore()
[all …]
/openssl/test/
H A Dpkcs12_format_test.c369 OBJ_nid2sn(enc->nid), enc->iter); in test_single_key()
400 PKCS12_ENC enc; in test_single_key_enc_alg() local
406 enc.pass = enc_default.pass; in test_single_key_enc_alg()
414 PKCS12_ENC enc; in test_single_key_enc_pass() local
416 enc.nid = enc_default.nid; in test_single_key_enc_pass()
417 enc.pass = passwords[z]; in test_single_key_enc_pass()
425 PKCS12_ENC enc; in test_single_key_enc_iter() local
427 enc.nid = enc_default.nid; in test_single_key_enc_iter()
429 enc.iter = iters[z]; in test_single_key_enc_iter()
630 OBJ_nid2sn(enc->nid), enc->iter); in test_single_secret()
[all …]
H A Dhpke_test.c100 unsigned char enc[256]; in do_testhpke() local
103 size_t enclen = sizeof(enc); in do_testhpke()
1134 size_t enclen = sizeof(enc); in test_hpke_export()
1650 unsigned char enc[200]; in test_hpke_random_suites() local
1651 size_t enclen = sizeof(enc); in test_hpke_random_suites()
1686 enclen = sizeof(enc); in test_hpke_random_suites()
1694 enclen = sizeof(enc); in test_hpke_random_suites()
1702 enclen = sizeof(enc); in test_hpke_random_suites()
1709 enclen = sizeof(enc); in test_hpke_random_suites()
1810 size_t enclen = sizeof(enc); in test_hpke_compressed()
[all …]
/openssl/crypto/cms/
H A Dcms_enc.c40 int enc, keep_key = 0; in ossl_cms_EncryptedContent_init_bio() local
44 enc = ec->cipher ? 1 : 0; in ossl_cms_EncryptedContent_init_bio()
55 if (enc) { in ossl_cms_EncryptedContent_init_bio()
83 if (enc) { in ossl_cms_EncryptedContent_init_bio()
122 if (!enc || !ec->key) { in ossl_cms_EncryptedContent_init_bio()
134 if (enc) in ossl_cms_EncryptedContent_init_bio()
148 if (enc || ec->debug) { in ossl_cms_EncryptedContent_init_bio()
166 if (enc) { in ossl_cms_EncryptedContent_init_bio()
250 CMS_EncryptedData *enc = cms->d.encryptedData; in ossl_cms_EncryptedData_init_bio() local
251 if (enc->encryptedContentInfo->cipher && enc->unprotectedAttrs) in ossl_cms_EncryptedData_init_bio()
[all …]
/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/include/crypto/
H A Dsm4_platform.h65 unsigned char *ivec, const int enc);
68 const int enc);
83 unsigned char *ivec, const int enc);
86 const int enc);
92 const unsigned char ivec[16], const int enc);
95 const unsigned char ivec[16], const int enc);
107 unsigned char *ivec, const int enc);
110 const int enc);
116 const unsigned char ivec[16], const int enc);
120 const int enc);
/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()
418 const PKCS12_ATTR *attrs, const PKCS12_ENC *enc) in add_keybag() argument
435 bag = PKCS12_add_key(&pb->bags, pkey, 0 /*keytype*/, enc->iter, enc->nid, enc->pass); in add_keybag()
437 bag = PKCS12_add_key_ex(&pb->bags, pkey, 0 /*keytype*/, enc->iter, enc->nid, enc->pass, in add_keybag()
584 const PKCS12_ATTR *attrs, const PKCS12_ENC *enc) in check_keybag() argument
617 p8 = PKCS12_decrypt_skey(bag, enc->pass, strlen(enc->pass)); in check_keybag()
619 p8 = PKCS12_decrypt_skey_ex(bag, enc->pass, strlen(enc->pass), test_ctx, test_propq); in check_keybag()
[all …]
/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_gcm.c58 ctx->enc = enc; in gcm_init()
134 || ctx->enc) in setivinv()
222 || !ctx->enc in ossl_gcm_get_ctx_params()
270 if (sz == 0 || ctx->enc) { in ossl_gcm_set_ctx_params()
435 if (!ctx->enc || !gcm_iv_generate(ctx, 0)) in gcm_cipher_internal()
492 if (!dat->enc) { in gcm_tls_init()
519 if (ctx->enc) { in gcm_tls_iv_set_fixed()
556 if (ctx->enc && ++ctx->tls_enc_records == 0) { in gcm_tls_cipher()
565 if (ctx->enc) { in gcm_tls_cipher()
581 if (!ctx->enc) in gcm_tls_cipher()
[all …]
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 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()
H A Dcipher_aes_wrp.c102 size_t ivlen, const OSSL_PARAM params[], int enc) in aes_wrap_init() argument
110 ctx->enc = enc; in aes_wrap_init()
112 wctx->wrapfn = enc ? CRYPTO_128_wrap_pad : CRYPTO_128_unwrap_pad; in aes_wrap_init()
114 wctx->wrapfn = enc ? CRYPTO_128_wrap : CRYPTO_128_unwrap; in aes_wrap_init()
137 use_forward_transform = ctx->enc; in aes_wrap_init()
139 use_forward_transform = !ctx->enc; in aes_wrap_init()
184 if (!ctx->enc && (inlen < 16 || inlen & 0x7)) { in aes_wrap_cipher_internal()
196 if (ctx->enc) { in aes_wrap_cipher_internal()
/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/crypto/x509/
H A Dx509cset.c29 x->crl.enc.modified = 1; in X509_CRL_set_version()
39 x->crl.enc.modified = 1; in X509_CRL_set_issuer_name()
47 return ossl_x509_set1_time(&x->crl.enc.modified, &x->crl.lastUpdate, tm); in X509_CRL_set1_lastUpdate()
54 return ossl_x509_set1_time(&x->crl.enc.modified, &x->crl.nextUpdate, tm); in X509_CRL_set1_nextUpdate()
70 c->crl.enc.modified = 1; in X509_CRL_sort()
179 crl->crl.enc.modified = 1; in i2d_re_X509_CRL_tbs()
H A Dx509_set.c31 x->cert_info.enc.modified = 1; in X509_set_version()
40 x->cert_info.enc.modified = 1; in X509_set_version()
53 x->cert_info.enc.modified = 1; in X509_set_serialNumber()
61 x->cert_info.enc.modified = 1; in X509_set_issuer_name()
69 x->cert_info.enc.modified = 1; in X509_set_subject_name()
93 return ossl_x509_set1_time(&x->cert_info.enc.modified, in X509_set1_notBefore()
101 return ossl_x509_set1_time(&x->cert_info.enc.modified, in X509_set1_notAfter()
111 x->cert_info.enc.modified = 1; in X509_set_pubkey()
/openssl/ssl/record/methods/
H A Dtls1_meth.c31 int enc = (rl->direction == OSSL_RECORD_DIRECTION_WRITE) ? 1 : 0; in tls1_set_crypto_state() local
88 if (!EVP_CipherInit_ex(ciph_ctx, ciph, NULL, key, NULL, enc) in tls1_set_crypto_state()
95 if (!EVP_CipherInit_ex(ciph_ctx, ciph, NULL, NULL, NULL, enc) in tls1_set_crypto_state()
178 const EVP_CIPHER *enc; in tls1_cipher() local
199 enc = EVP_CIPHER_CTX_get0_cipher(rl->enc_ctx); in tls1_cipher()
206 && EVP_CIPHER_get_mode(enc) == EVP_CIPH_CBC_MODE) in tls1_cipher()
207 ivlen = EVP_CIPHER_get_iv_length(enc); in tls1_cipher()
223 if (!ossl_assert(enc != NULL)) { in tls1_cipher()
228 provided = (EVP_CIPHER_get0_provider(enc) != NULL); in tls1_cipher()
377 if (EVP_CIPHER_get_mode(enc) == EVP_CIPH_GCM_MODE) { in tls1_cipher()
[all …]

Completed in 60 milliseconds

123456789