/libcore/luni/src/test/java/org/apache/harmony/crypto/tests/javax/crypto/func/ |
CipherRSATest.java | 25 CipherRSAThread rsa = new CipherRSAThread("RSA", new int[] {512}, local 30 rsa.launcher(); 32 assertEquals(rsa.getFailureMessages(), 0, rsa.getTotalFailuresNumber()); 37 CipherRSAThread rsa = new CipherRSAThread("RSA", new int[] {1024}, local 42 rsa.launcher(); 44 assertEquals(rsa.getFailureMessages(), 0, rsa.getTotalFailuresNumber()) 49 CipherRSAThread rsa = new CipherRSAThread("RSA", new int[] {2048}, local 60 CipherRSAThread rsa = new CipherRSAThread("RSA", new int[] {1024}, local [all...] |
/external/openssl/crypto/rsa/ |
rsa_depr.c | 1 /* crypto/rsa/rsa_depr.c */ 63 #include <openssl/rsa.h> 71 RSA *RSA_generate_key(int bits, unsigned long e_value, 76 RSA *rsa = RSA_new(); local 79 if(!rsa || !e) goto err; 92 if(RSA_generate_key_ex(rsa, bits, e, &cb)) { 94 return rsa; 98 if(rsa) RSA_free(rsa); [all...] |
rsa_ameth.c | 1 /* crypto/rsa/rsa_ameth.c */ 63 #include <openssl/rsa.h> 74 penclen = i2d_RSAPublicKey(pkey->pkey.rsa, &penc); 89 RSA *rsa = NULL; local 92 if (!(rsa = d2i_RSAPublicKey(NULL, &p, pklen))) 97 EVP_PKEY_assign_RSA (pkey, rsa); 103 if (BN_cmp(b->pkey.rsa->n,a->pkey.rsa->n) != 0 104 || BN_cmp(b->pkey.rsa->e,a->pkey.rsa->e) != 0 112 RSA *rsa; local [all...] |
rsa_pmeth.c | 1 /* crypto/rsa/rsa_pmeth.c */ 63 #include <openssl/rsa.h> 69 /* RSA pkey context structure */ 78 /* RSA padding mode */ 156 RSA *rsa = ctx->pkey->pkey.rsa; local 174 sig, rsa, RSA_X931_PADDING); 180 tbs, tbslen, sig, &sltmp, rsa); 189 if (!RSA_padding_add_PKCS1_PSS(rsa, rctx->tbuf, tbs 270 RSA *rsa = ctx->pkey->pkey.rsa; local 522 RSA *rsa = NULL; local [all...] |
/external/ipsec-tools/src/racoon/ |
rsalist.h | 38 #include <openssl/rsa.h> 52 RSA *rsa; member in struct:rsa_key 55 int rsa_key_insert(struct genlist *list, struct netaddr *src, struct netaddr *dst, RSA *rsa); 61 RSA *rsa_try_check_rsasign(vchar_t *source, vchar_t *sig, struct genlist *list);
|
prsa_par.h | 99 RSA *rsa; member in union:YYSTYPE
|
handler.h | 38 #include <openssl/rsa.h> 171 RSA *rsa; /* my RSA key */ member in struct:ph1handle 172 RSA *rsa_p; /* peer's RSA key */ 173 struct genlist *rsa_candidates; /* possible candidates for peer's RSA key */
|
/external/openssl/apps/ |
genrsa.c | 11 * apply to all code found in this distribution, be it the RC4, RSA, 75 #include <openssl/rsa.h> 108 RSA *rsa = NULL; local 266 BIO_printf(bio_err,"Generating RSA private key, %d bit long modulus\n", 269 rsa = RSA_new(); 271 rsa = RSA_new_method(e); 273 if (!rsa) 276 if(!BN_set_word(bn, f4) || !RSA_generate_key_ex(rsa, num, bn, &cb)) 284 for (i=0; i<rsa->e->top; i++ [all...] |
rsa.c | 1 /* apps/rsa.c */ 11 * apply to all code found in this distribution, be it the RC4, RSA, 68 #include <openssl/rsa.h> 92 * -modulus - print the RSA key modulus 104 RSA *rsa=NULL; local 240 BIO_printf(bio_err," -modulus print the RSA key modulus\n"); 296 rsa = EVP_PKEY_get1_RSA(pkey); 300 if (rsa == NULL) 326 if (!RSA_print(out,rsa,0) [all...] |
rsautl.c | 66 #include <openssl/rsa.h> 100 RSA *rsa = NULL; local 224 rsa = EVP_PKEY_get1_RSA(pkey); 227 if(!rsa) { 228 BIO_printf(bio_err, "Error getting RSA key\n"); 258 keysize = RSA_size(rsa); 281 rsa_outlen = RSA_public_decrypt(rsa_inlen, rsa_in, rsa_out, rsa, pad); 285 rsa_outlen = RSA_private_encrypt(rsa_inlen, rsa_in, rsa_out, rsa, pad); 289 rsa_outlen = RSA_public_encrypt(rsa_inlen, rsa_in, rsa_out, rsa, pad) [all...] |
/external/chromium/third_party/libjingle/source/talk/base/ |
opensslidentity.cc | 35 #include <openssl/rsa.h> 46 // Strength of generated keys. Those are RSA. 61 RSA* rsa = RSA_generate_key(KEY_LENGTH, 0x10001, NULL, NULL); local 62 if (!EVP_PKEY_assign_RSA(pkey, rsa)) { 64 RSA_free(rsa); 70 RSA* rsa = RSA_new(); local 71 if (!pkey || !exponent || !rsa || 72 !BN_set_word(exponent, 0x10001) || // 65537 RSA exponen [all...] |
/external/openssl/ssl/ |
s2_srvr.c | 11 * apply to all code found in this distribution, be it the RC4, RSA, 1115 RSA *rsa; local 1128 rsa=c->pkeys[SSL_PKEY_RSA_ENC].privatekey->pkey.rsa; 1131 i=RSA_private_decrypt(len,from,to,rsa,padding);
|
ssl_rsa.c | 11 * apply to all code found in this distribution, be it the RC4, RSA, 152 int SSL_use_RSAPrivateKey(SSL *ssl, RSA *rsa) 157 if (rsa == NULL) 173 RSA_up_ref(rsa); 174 EVP_PKEY_assign_RSA(pkey,rsa); 205 (RSA_flags(pkey->pkey.rsa) & RSA_METHOD_FLAG_NO_CHECK)) 233 RSA *rsa=NULL; local 250 rsa=d2i_RSAPrivateKey_bio(in,NULL) 280 RSA *rsa; local 555 RSA *rsa=NULL; local 602 RSA *rsa; local [all...] |
d1_clnt.c | 68 * apply to all code found in this distribution, be it the RC4, RSA, 814 RSA *rsa; local 818 rsa=s->session->sess_cert->peer_rsa_tmp; 824 (pkey->pkey.rsa == NULL)) 829 rsa=pkey->pkey.rsa; 845 tmp_buf,p,rsa,RSA_PKCS1_PADDING); [all...] |
s3_lib.c | 11 * apply to all code found in this distribution, be it the RC4, RSA, 172 /* The RSA ciphers */ 2303 RSA *rsa = (RSA *)parg; local 2579 RSA *rsa; local [all...] |
d1_srvr.c | 68 * apply to all code found in this distribution, be it the RC4, RSA, 381 /* option SSL_OP_EPHEMERAL_RSA sends temporary RSA key 390 * RSA but we have a sign only certificate */ 879 RSA *rsa; local 917 rsa=cert->rsa_tmp; 918 if ((rsa == NULL) && (s->cert->rsa_tmp_cb != NULL)) 920 rsa=s->cert->rsa_tmp_cb(s, 923 if(rsa == NULL) 929 RSA_up_ref(rsa); [all...] |
s3_clnt.c | 11 * apply to all code found in this distribution, be it the RC4, RSA, 1240 RSA *rsa=NULL; local 2102 RSA *rsa; local 2950 RSA *rsa; local [all...] |
/libcore/luni/src/main/java/org/apache/harmony/xnet/provider/jsse/ |
OpenSSLSignature.java | 46 jdkToOpenSsl.put("MD5/RSA", MD5RSA.class); 52 jdkToOpenSsl.put("SHA1/RSA", SHA1RSA.class); 53 jdkToOpenSsl.put("SHA-1/RSA", SHA1RSA.class); 91 * Holds a pointer to the native RSA key. 93 private int rsa; field in class:OpenSSLSignature 133 * @param algorithm OpenSSL name of the algorithm, e.g. "RSA-SHA1". 139 if ("RSA-MD2".equals(algorithm)) { 190 rsa = NativeCrypto.EVP_PKEY_new_RSA(rsaPublicKey.getModulus().toByteArray(), 197 throw new InvalidKeyException("Need DSA or RSA public key"); 218 int handle = (rsa != 0) ? rsa : dsa [all...] |
/external/openssl/crypto/pem/ |
pvkfmt.c | 68 #include <openssl/rsa.h> 114 /* Convert private key blob to EVP_PKEY: RSA and DSA keys supported */ 375 RSA *rsa = NULL; local 379 rsa = RSA_new(); 381 if (!rsa || !ret) 383 rsa->e = BN_new(); 384 if (!rsa->e) 386 if (!BN_set_word(rsa->e, read_ledword(&p))) 388 if (!read_lebn(&p, nbyte, &rsa->n) [all...] |
/external/wpa_supplicant/ |
crypto_cryptoapi.c | 25 L"Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)" 28 "Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)" 658 HCRYPTKEY rsa; member in struct:crypto_public_key 663 HCRYPTKEY rsa; member in struct:crypto_private_key 711 &pk->rsa)) { 741 if (!CryptEncrypt(key->rsa, 0, TRUE, 0, tmp, &clen, *outlen)) { 772 CryptDestroyKey(key->rsa); 782 CryptDestroyKey(key->rsa);
|
crypto_libtomcrypt.c | 415 rsa_key rsa; member in struct:crypto_public_key 419 rsa_key rsa; member in struct:crypto_private_key 432 res = rsa_import(key, len, &pk->rsa); 441 if (pk->rsa.type != PK_PUBLIC) { 444 rsa_free(&pk->rsa); 463 res = rsa_import(key, len, &pk->rsa); 472 if (pk->rsa.type != PK_PRIVATE) { 475 rsa_free(&pk->rsa); 585 return crypto_rsa_encrypt_pkcs1(2, &key->rsa, PK_PUBLIC, in, inlen, 594 return crypto_rsa_encrypt_pkcs1(1, &key->rsa, PK_PRIVATE, in, inlen [all...] |
/external/wpa_supplicant_6/wpa_supplicant/src/crypto/ |
crypto_cryptoapi.c | 25 L"Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)" 28 "Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)" 643 HCRYPTKEY rsa; member in struct:crypto_public_key 648 HCRYPTKEY rsa; member in struct:crypto_private_key 696 &pk->rsa)) { 726 if (!CryptEncrypt(key->rsa, 0, TRUE, 0, tmp, &clen, *outlen)) { 757 CryptDestroyKey(key->rsa); 767 CryptDestroyKey(key->rsa);
|
crypto_libtomcrypt.c | 415 rsa_key rsa; member in struct:crypto_public_key 419 rsa_key rsa; member in struct:crypto_private_key 432 res = rsa_import(key, len, &pk->rsa); 441 if (pk->rsa.type != PK_PUBLIC) { 444 rsa_free(&pk->rsa); 463 res = rsa_import(key, len, &pk->rsa); 472 if (pk->rsa.type != PK_PRIVATE) { 475 rsa_free(&pk->rsa); 585 return crypto_rsa_encrypt_pkcs1(2, &key->rsa, PK_PUBLIC, in, inlen, 594 return crypto_rsa_encrypt_pkcs1(1, &key->rsa, PK_PRIVATE, in, inlen [all...] |
/external/wpa_supplicant_8/src/crypto/ |
crypto_cryptoapi.c | 25 L"Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)" 28 "Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)" 639 HCRYPTKEY rsa; member in struct:crypto_public_key 644 HCRYPTKEY rsa; member in struct:crypto_private_key 693 &pk->rsa)) { 723 if (!CryptEncrypt(key->rsa, 0, TRUE, 0, tmp, &clen, *outlen)) { 754 CryptDestroyKey(key->rsa); 764 CryptDestroyKey(key->rsa);
|
crypto_libtomcrypt.c | 414 rsa_key rsa; member in struct:crypto_public_key 418 rsa_key rsa; member in struct:crypto_private_key 431 res = rsa_import(key, len, &pk->rsa); 440 if (pk->rsa.type != PK_PUBLIC) { 443 rsa_free(&pk->rsa); 463 res = rsa_import(key, len, &pk->rsa); 472 if (pk->rsa.type != PK_PRIVATE) { 475 rsa_free(&pk->rsa); 585 return crypto_rsa_encrypt_pkcs1(2, &key->rsa, PK_PUBLIC, in, inlen, 594 return crypto_rsa_encrypt_pkcs1(1, &key->rsa, PK_PRIVATE, in, inlen [all...] |