Home
last modified time | relevance | path

Searched refs:certificate (Results 1 – 25 of 30) sorted by relevance

12

/libcore/ojluni/src/main/java/java/security/
DIdentity.java246 public void addCertificate(Certificate certificate) in addCertificate() argument
255 if (!keyEquals(publicKey, certificate.getPublicKey())) { in addCertificate()
260 publicKey = certificate.getPublicKey(); in addCertificate()
262 certificates.addElement(certificate); in addCertificate()
296 public void removeCertificate(Certificate certificate) in removeCertificate() argument
302 if (certificate == null || !certificates.contains(certificate)) { in removeCertificate()
305 certificates.removeElement(certificate); in removeCertificate()
DSignature.java632 public final void initVerify(Certificate certificate) in initVerify() argument
637 if (certificate instanceof java.security.cert.X509Certificate) { in initVerify()
641 X509Certificate cert = (X509Certificate)certificate; in initVerify()
653 PublicKey publicKey = certificate.getPublicKey(); in initVerify()
/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/
DKeyStorePrivateKeyEntryTest.java62 Certificate certificate = cf.generateCertificate(certArray); in testGetCertificateChain() local
63 assertTrue(certificate instanceof X509Certificate); in testGetCertificateChain()
65 String algorithm = certificate.getPublicKey().getAlgorithm(); in testGetCertificateChain()
74 privateKey, new Certificate[] { certificate }); in testGetCertificateChain()
DKeyStore3Test.java49 private Certificate certificate; field in KeyStore3Test
78 mockKeyStore.setKeyEntry("Alias", null, null, new Certificate[]{certificate}); in test_setKeyEntry_key_is_null()
99 mockKeyStore.setKeyEntry("Alias", key, null, new Certificate[]{certificate}); in test_setKeyEntry_key_is_private()
109 mockKeyStore.setKeyEntry("Alias3", key, null, new Certificate[]{certificate}); in test_setKeyEntry_key_is_public()
117 mockKeyStore.setCertificateEntry(null, certificate); in test_setCertificateEntry_null()
167 certificate = cf.generateCertificate(certArray); in setUp()
DIdentity2Test.java84 String certificate = "-----BEGIN CERTIFICATE-----\n" field in Identity2Test
100 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate.getBytes());
/libcore/luni/src/test/java/tests/targets/security/cert/
DCertificateTest.java606 Certificate certificate = certificateFactory in testVerifyMD5() local
610 certificate.verify(certificate.getPublicKey()); in testVerifyMD5()
619 Certificate certificate = certificateFactory in testVerifyMD2() local
623 certificate.verify(certificate.getPublicKey()); in testVerifyMD2()
DCertPathBuilderTestPKIX.java55 for (Certificate certificate : pke.getCertificateChain()) { in getCertPathParameters()
56 certList.add(certificate); in getCertPathParameters()
/libcore/luni/src/test/java/tests/security/
DCertificateFactoryTest.java43 Certificate certificate = certificateFactory.generateCertificate( in testCertificateFactory() local
45 assertNotNull(certificate); in testCertificateFactory()
/libcore/ojluni/src/main/java/java/security/cert/
DX509CRL.java382 public X509CRLEntry getRevokedCertificate(X509Certificate certificate) { in getRevokedCertificate() argument
383 X500Principal certIssuer = certificate.getIssuerX500Principal(); in getRevokedCertificate()
388 return getRevokedCertificate(certificate.getSerialNumber()); in getRevokedCertificate()
/libcore/luni/src/test/java/libcore/java/security/
DCodeSourceTest.java64 Certificate certificate = keyStore.getCertificate(alias); in createCodeSigner() local
65 assertTrue(certificate instanceof X509Certificate); in createCodeSigner()
66 cert = (X509Certificate) certificate; in createCodeSigner()
DProtectionDomainTest.java96 Certificate certificate = keyStore.getCertificate(alias); in createCodeSigner() local
97 assertTrue(certificate instanceof X509Certificate); in createCodeSigner()
98 cert = (X509Certificate) certificate; in createCodeSigner()
/libcore/luni/src/test/java/tests/targets/security/
DKeyStoreTest.java103 Certificate certificate = null; in testKeyStoreCreate() local
105 certificate = certificateFactory in testKeyStoreCreate()
114 generator = KeyPairGenerator.getInstance(certificate.getPublicKey() in testKeyStoreCreate()
123 .getPrivate(), new Certificate[] {certificate}); in testKeyStoreCreate()
/libcore/luni/src/test/java/tests/security/cert/
DPKIXBuilderParametersTest.java48 String certificate = "-----BEGIN CERTIFICATE-----\n" field in PKIXBuilderParametersTest
239 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate in testPKIXBuilderParametersKeyStoreCertSelector04()
270 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate in testGetMaxPathLength()
298 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate in testSetMaxPathLength()
341 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate in testToString()
DX509CRL2Test.java41 String certificate = "-----BEGIN CERTIFICATE-----\n" field in X509CRL2Test
68 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate in setUp()
DX509CRLTest.java57 String certificate = "-----BEGIN CERTIFICATE-----\n" field in X509CRLTest
73 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate
/libcore/luni/src/test/java/libcore/java/security/cert/
DSubjectAlternativeNameTest.java66 private X509Certificate bouncycastleToJava(Certificate certificate) throws Exception { in bouncycastleToJava() argument
67 byte[] encoded = certificate.getEncoded(); in bouncycastleToJava()
DX509CertSelectorTest.java155 private X509Certificate bouncycastleToJava(Certificate certificate) throws Exception { in bouncycastleToJava() argument
156 byte[] encoded = certificate.getEncoded(); in bouncycastleToJava()
/libcore/support/src/test/java/libcore/java/security/
DTestKeyStore.java841 X509Certificate certificate = (X509Certificate) privateKey.getCertificate(); in privateKey() local
842 if (!certificate.getSigAlgName().contains(signatureAlgorithm)) { in privateKey()
894 Certificate certificate = certificateEntry.getTrustedCertificate(); in issuer() local
895 if (!(certificate instanceof X509Certificate)) { in issuer()
898 X509Certificate x = (X509Certificate) certificate; in issuer()
906 + "\nsecond: " + certificate ); in issuer()
908 found = certificate; in issuer()
986 Certificate certificate = certificateEntry.getTrustedCertificate(); in rootCertificate() local
987 if (!certificate.getPublicKey().getAlgorithm().equals(algorithm)) { in rootCertificate()
990 if (!(certificate instanceof X509Certificate)) { in rootCertificate()
[all …]
/libcore/ojluni/src/main/java/javax/crypto/
DCipher.java1507 public final void init(int opmode, Certificate certificate) in init() argument
1510 init(opmode, certificate, JceSecurity.RANDOM); in init()
1577 public final void init(int opmode, Certificate certificate, in init() argument
1586 if (certificate instanceof java.security.cert.X509Certificate) { in init()
1589 X509Certificate cert = (X509Certificate)certificate; in init()
1610 (certificate==null? null:certificate.getPublicKey()); in init()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/javax/net/ssl/
DX509KeyManagerTest.java80 String certificate = "-----BEGIN CERTIFICATE-----\n" field in X509KeyManagerTest
101 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate
DHandshakeCompletedEventTest.java51 private String certificate = "-----BEGIN CERTIFICATE-----\n" field in HandshakeCompletedEventTest
121 ByteArrayInputStream bis = new ByteArrayInputStream(certificate.getBytes()); in test_getPeerCertificateChain()
/libcore/ojluni/annotations/mmodule/javax/crypto/
DCipher.annotated.java81 public final void init(int opmode, java.security.cert.Certificate certificate) throws java.security… in init() argument
83 public final void init(int opmode, java.security.cert.Certificate certificate, java.security.Secure… in init() argument
/libcore/luni/src/test/java/libcore/javax/net/ssl/
DDefaultHostnameVerifierTest.java437 private boolean verifyWithServerCertificate(String hostname, X509Certificate certificate) { in verifyWithServerCertificate() argument
440 (certificate != null) ? new Certificate[] {certificate} : new Certificate[0]; in verifyWithServerCertificate()
/libcore/support/src/test/java/tests/resources/x509/
Ddefault.cnf91 certificate = $dir/cacert.pem # The CA certificate
143 req_extensions = v3_req # The extensions to add to a certificate request
/libcore/ojluni/annotations/mmodule/java/security/
DSignature.annotated.java51 public final void initVerify(java.security.cert.Certificate certificate) throws java.security.Inval… in initVerify() argument

12