Home
last modified time | relevance | path

Searched refs:RSAPrivateKey (Results 1 – 25 of 49) sorted by relevance

12

/external/libchrome/crypto/
Drsa_private_key.cc23 std::unique_ptr<RSAPrivateKey> RSAPrivateKey::Create(uint16_t num_bits) { in Create()
34 std::unique_ptr<RSAPrivateKey> result(new RSAPrivateKey); in Create()
43 std::unique_ptr<RSAPrivateKey> RSAPrivateKey::CreateFromPrivateKeyInfo( in CreateFromPrivateKeyInfo()
53 std::unique_ptr<RSAPrivateKey> result(new RSAPrivateKey); in CreateFromPrivateKeyInfo()
59 std::unique_ptr<RSAPrivateKey> RSAPrivateKey::CreateFromKey(EVP_PKEY* key) { in CreateFromKey()
63 std::unique_ptr<RSAPrivateKey> copy(new RSAPrivateKey); in CreateFromKey()
68 RSAPrivateKey::RSAPrivateKey() = default;
70 RSAPrivateKey::~RSAPrivateKey() = default;
72 std::unique_ptr<RSAPrivateKey> RSAPrivateKey::Copy() const { in Copy()
73 std::unique_ptr<RSAPrivateKey> copy(new RSAPrivateKey); in Copy()
[all …]
Drsa_private_key_unittest.cc75 std::unique_ptr<crypto::RSAPrivateKey> keypair1( in TEST()
76 crypto::RSAPrivateKey::Create(1024)); in TEST()
77 std::unique_ptr<crypto::RSAPrivateKey> keypair2( in TEST()
78 crypto::RSAPrivateKey::Create(2048)); in TEST()
92 std::unique_ptr<crypto::RSAPrivateKey> keypair3( in TEST()
93 crypto::RSAPrivateKey::CreateFromPrivateKeyInfo(privkey1)); in TEST()
94 std::unique_ptr<crypto::RSAPrivateKey> keypair4( in TEST()
95 crypto::RSAPrivateKey::CreateFromPrivateKeyInfo(privkey2)); in TEST()
115 std::unique_ptr<crypto::RSAPrivateKey> key( in TEST()
116 crypto::RSAPrivateKey::CreateFromPrivateKeyInfo(input)); in TEST()
[all …]
Drsa_private_key.h24 class CRYPTO_EXPORT RSAPrivateKey {
26 ~RSAPrivateKey();
29 static std::unique_ptr<RSAPrivateKey> Create(uint16_t num_bits);
34 static std::unique_ptr<RSAPrivateKey> CreateFromPrivateKeyInfo(
40 static std::unique_ptr<RSAPrivateKey> CreateFromKey(EVP_PKEY* key);
45 std::unique_ptr<RSAPrivateKey> Copy() const;
55 RSAPrivateKey();
59 DISALLOW_COPY_AND_ASSIGN(RSAPrivateKey);
Dsignature_creator_unittest.cc21 std::unique_ptr<crypto::RSAPrivateKey> key_original( in TEST()
22 crypto::RSAPrivateKey::Create(1024)); in TEST()
27 std::unique_ptr<crypto::RSAPrivateKey> key( in TEST()
28 crypto::RSAPrivateKey::CreateFromPrivateKeyInfo(key_info)); in TEST()
56 std::unique_ptr<crypto::RSAPrivateKey> key_original( in TEST()
57 crypto::RSAPrivateKey::Create(1024)); in TEST()
62 std::unique_ptr<crypto::RSAPrivateKey> key( in TEST()
63 crypto::RSAPrivateKey::CreateFromPrivateKeyInfo(key_info)); in TEST()
88 std::unique_ptr<crypto::RSAPrivateKey> key_original( in TEST()
89 crypto::RSAPrivateKey::Create(1024)); in TEST()
[all …]
Dsignature_creator.h22 class RSAPrivateKey; variable
39 static std::unique_ptr<SignatureCreator> Create(RSAPrivateKey* key,
44 static bool Sign(RSAPrivateKey* key,
/external/bouncycastle/bcprov/src/main/java/org/bouncycastle/jcajce/provider/asymmetric/rsa/
DKeyFactorySpi.java19 import org.bouncycastle.asn1.pkcs.RSAPrivateKey;
51 …isAssignableFrom(RSAPrivateKeySpec.class) && key instanceof java.security.interfaces.RSAPrivateKey) in engineGetKeySpec()
53 java.security.interfaces.RSAPrivateKey k = (java.security.interfaces.RSAPrivateKey)key; in engineGetKeySpec()
126 else if (key instanceof java.security.interfaces.RSAPrivateKey) in engineTranslateKey()
128 return new BCRSAPrivateKey((java.security.interfaces.RSAPrivateKey)key); in engineTranslateKey()
152 RSAPrivateKey.getInstance(((PKCS8EncodedKeySpec)keySpec).getEncoded())); in engineGeneratePrivate()
222 RSAPrivateKey rsaPrivKey = RSAPrivateKey.getInstance(keyInfo.parsePrivateKey()); in generatePrivate()
DBCRSAPrivateKey.java7 import java.security.interfaces.RSAPrivateKey;
23 implements RSAPrivateKey, PKCS12BagAttributeCarrier
53 RSAPrivateKey key) in BCRSAPrivateKey()
59 BCRSAPrivateKey(org.bouncycastle.asn1.pkcs.RSAPrivateKey key) in BCRSAPrivateKey()
87 …iers.rsaEncryption, DERNull.INSTANCE), new org.bouncycastle.asn1.pkcs.RSAPrivateKey(getModulus(), … in getEncoded()
92 if (!(o instanceof RSAPrivateKey)) in equals()
102 RSAPrivateKey key = (RSAPrivateKey)o; in equals()
DRSAUtil.java5 import java.security.interfaces.RSAPrivateKey;
51 RSAPrivateKey key) in generatePrivateKeyParameter()
63 RSAPrivateKey k = key; in generatePrivateKeyParameter()
DBCRSAPrivateCrtKey.java11 import org.bouncycastle.asn1.pkcs.RSAPrivateKey;
94 this(RSAPrivateKey.getInstance(info.parsePrivateKey())); in BCRSAPrivateCrtKey()
101 RSAPrivateKey key) in BCRSAPrivateCrtKey()
131 …dentifier(PKCSObjectIdentifiers.rsaEncryption, DERNull.INSTANCE), new RSAPrivateKey(getModulus(), … in getEncoded()
DCipherSpi.java10 import java.security.interfaces.RSAPrivateKey;
119 if (key instanceof RSAPrivateKey) in engineGetKeySize()
121 RSAPrivateKey k = (RSAPrivateKey)key; in engineGetKeySize()
291 else if (key instanceof RSAPrivateKey) in engineInit()
299 param = RSAUtil.generatePrivateKeyParameter((RSAPrivateKey)key); in engineInit()
/external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/jcajce/provider/asymmetric/rsa/
DKeyFactorySpi.java20 import com.android.org.bouncycastle.asn1.pkcs.RSAPrivateKey;
55 …isAssignableFrom(RSAPrivateKeySpec.class) && key instanceof java.security.interfaces.RSAPrivateKey) in engineGetKeySpec()
57 java.security.interfaces.RSAPrivateKey k = (java.security.interfaces.RSAPrivateKey)key; in engineGetKeySpec()
130 else if (key instanceof java.security.interfaces.RSAPrivateKey) in engineTranslateKey()
132 return new BCRSAPrivateKey((java.security.interfaces.RSAPrivateKey)key); in engineTranslateKey()
156 RSAPrivateKey.getInstance(((PKCS8EncodedKeySpec)keySpec).getEncoded())); in engineGeneratePrivate()
226 RSAPrivateKey rsaPrivKey = RSAPrivateKey.getInstance(keyInfo.parsePrivateKey()); in generatePrivate()
DBCRSAPrivateKey.java8 import java.security.interfaces.RSAPrivateKey;
27 implements RSAPrivateKey, PKCS12BagAttributeCarrier
57 RSAPrivateKey key) in BCRSAPrivateKey()
63 BCRSAPrivateKey(com.android.org.bouncycastle.asn1.pkcs.RSAPrivateKey key) in BCRSAPrivateKey()
91 …yption, DERNull.INSTANCE), new com.android.org.bouncycastle.asn1.pkcs.RSAPrivateKey(getModulus(), … in getEncoded()
96 if (!(o instanceof RSAPrivateKey)) in equals()
106 RSAPrivateKey key = (RSAPrivateKey)o; in equals()
DRSAUtil.java6 import java.security.interfaces.RSAPrivateKey;
53 RSAPrivateKey key) in generatePrivateKeyParameter()
65 RSAPrivateKey k = key; in generatePrivateKeyParameter()
DBCRSAPrivateCrtKey.java12 import com.android.org.bouncycastle.asn1.pkcs.RSAPrivateKey;
96 this(RSAPrivateKey.getInstance(info.parsePrivateKey())); in BCRSAPrivateCrtKey()
103 RSAPrivateKey key) in BCRSAPrivateCrtKey()
133 …dentifier(PKCSObjectIdentifiers.rsaEncryption, DERNull.INSTANCE), new RSAPrivateKey(getModulus(), … in getEncoded()
DCipherSpi.java11 import java.security.interfaces.RSAPrivateKey;
123 if (key instanceof RSAPrivateKey) in engineGetKeySize()
125 RSAPrivateKey k = (RSAPrivateKey)key; in engineGetKeySize()
295 else if (key instanceof RSAPrivateKey) in engineInit()
303 param = RSAUtil.generatePrivateKeyParameter((RSAPrivateKey)key); in engineInit()
/external/bouncycastle/bcprov/src/main/java/org/bouncycastle/asn1/pkcs/
DRSAPrivateKey.java14 public class RSAPrivateKey class
28 public static RSAPrivateKey getInstance( in getInstance()
35 public static RSAPrivateKey getInstance( in getInstance()
38 if (obj instanceof RSAPrivateKey) in getInstance()
40 return (RSAPrivateKey)obj; in getInstance()
45 return new RSAPrivateKey(ASN1Sequence.getInstance(obj)); in getInstance()
51 public RSAPrivateKey( in RSAPrivateKey() method in RSAPrivateKey
72 private RSAPrivateKey( in RSAPrivateKey() method in RSAPrivateKey
/external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/asn1/pkcs/
DRSAPrivateKey.java18 public class RSAPrivateKey class
32 public static RSAPrivateKey getInstance( in getInstance()
39 public static RSAPrivateKey getInstance( in getInstance()
42 if (obj instanceof RSAPrivateKey) in getInstance()
44 return (RSAPrivateKey)obj; in getInstance()
49 return new RSAPrivateKey(ASN1Sequence.getInstance(obj)); in getInstance()
55 public RSAPrivateKey( in RSAPrivateKey() method in RSAPrivateKey
76 private RSAPrivateKey( in RSAPrivateKey() method in RSAPrivateKey
/external/conscrypt/common/src/main/java/org/conscrypt/
DOpenSSLRSAKeyFactory.java26 import java.security.interfaces.RSAPrivateKey;
121 } else if (key instanceof RSAPrivateKey in engineGetKeySpec()
123 RSAPrivateKey rsaKey = (RSAPrivateKey) key; in engineGetKeySpec()
133 RSAPrivateKey privKey = in engineGetKeySpec()
134 (RSAPrivateKey) engineGeneratePrivate(new PKCS8EncodedKeySpec(encoded)); in engineGetKeySpec()
151 RSAPrivateKey rsaKey = in engineGetKeySpec()
152 (RSAPrivateKey) engineGeneratePrivate(new PKCS8EncodedKeySpec(encoded)); in engineGetKeySpec()
218 } else if (key instanceof RSAPrivateKey) { in engineTranslateKey()
219 RSAPrivateKey rsaKey = (RSAPrivateKey) key; in engineTranslateKey()
DOpenSSLRSAPrivateKey.java27 import java.security.interfaces.RSAPrivateKey;
35 class OpenSSLRSAPrivateKey implements RSAPrivateKey, OpenSSLKeyHolder {
98 static OpenSSLKey wrapPlatformKey(RSAPrivateKey rsaPrivateKey) in wrapPlatformKey()
129 static OpenSSLKey getInstance(RSAPrivateKey rsaPrivateKey) throws InvalidKeyException { in getInstance()
223 if (o instanceof RSAPrivateKey) { in equals()
225 RSAPrivateKey other = (RSAPrivateKey) o; in equals()
DOpenSSLSignatureRawRSA.java26 import java.security.interfaces.RSAPrivateKey;
96 } else if (privateKey instanceof RSAPrivateKey) { in engineInitSign()
97 RSAPrivateKey rsaPrivateKey = (RSAPrivateKey) privateKey; in engineInitSign()
/external/conscrypt/repackaged/common/src/main/java/com/android/org/conscrypt/
DOpenSSLRSAKeyFactory.java27 import java.security.interfaces.RSAPrivateKey;
126 } else if (key instanceof RSAPrivateKey in engineGetKeySpec()
128 RSAPrivateKey rsaKey = (RSAPrivateKey) key; in engineGetKeySpec()
138 RSAPrivateKey privKey = in engineGetKeySpec()
139 (RSAPrivateKey) engineGeneratePrivate(new PKCS8EncodedKeySpec(encoded)); in engineGetKeySpec()
156 RSAPrivateKey rsaKey = in engineGetKeySpec()
157 (RSAPrivateKey) engineGeneratePrivate(new PKCS8EncodedKeySpec(encoded)); in engineGetKeySpec()
223 } else if (key instanceof RSAPrivateKey) { in engineTranslateKey()
224 RSAPrivateKey rsaKey = (RSAPrivateKey) key; in engineTranslateKey()
DOpenSSLRSAPrivateKey.java28 import java.security.interfaces.RSAPrivateKey;
36 class OpenSSLRSAPrivateKey implements RSAPrivateKey, OpenSSLKeyHolder {
99 static OpenSSLKey wrapPlatformKey(RSAPrivateKey rsaPrivateKey) in wrapPlatformKey()
130 static OpenSSLKey getInstance(RSAPrivateKey rsaPrivateKey) throws InvalidKeyException { in getInstance()
224 if (o instanceof RSAPrivateKey) { in equals()
226 RSAPrivateKey other = (RSAPrivateKey) o; in equals()
DOpenSSLSignatureRawRSA.java27 import java.security.interfaces.RSAPrivateKey;
100 } else if (privateKey instanceof RSAPrivateKey) { in engineInitSign()
101 RSAPrivateKey rsaPrivateKey = (RSAPrivateKey) privateKey; in engineInitSign()
/external/wycheproof/java/com/google/security/wycheproof/testcases/
DRsaKeyTest.java24 import java.security.interfaces.RSAPrivateKey;
1429 private void checkPublicKey(RSAPublicKey pub, RSAPrivateKey priv) { in checkPublicKey()
1438 RSAPrivateKey priv = (RSAPrivateKey) keypair.getPrivate(); in checkKeyPair()
/external/python/pyasn1/docs/source/
Dexample-use-case.rst25 RSAPrivateKey ::= SEQUENCE {
72 class RSAPrivateKey(Sequence):
97 from rsakey import RSAPrivateKey
107 private_key, rest_of_input = der_decoder(der_serialisation, asn1Spec=RSAPrivateKey())
114 RSAPrivateKey:
170 >>> private_key = decode(py_private_key, asn1Spec=RSAPrivateKey())

12