/libcore/luni/src/main/java/javax/net/ssl/ |
D | DefaultHostnameVerifier.java | 50 public boolean verify(String host, X509Certificate certificate) { in verify() argument 52 ? verifyIpAddress(host, certificate) in verify() 53 : verifyHostName(host, certificate); in verify() 59 private boolean verifyIpAddress(String ipAddress, X509Certificate certificate) { in verifyIpAddress() argument 60 for (String altName : getSubjectAltNames(certificate, ALT_IPA_NAME)) { in verifyIpAddress() 71 private boolean verifyHostName(String hostName, X509Certificate certificate) { in verifyHostName() argument 74 for (String altName : getSubjectAltNames(certificate, ALT_DNS_NAME)) { in verifyHostName() 82 X500Principal principal = certificate.getSubjectX500Principal(); in verifyHostName() 93 private List<String> getSubjectAltNames(X509Certificate certificate, int type) { in getSubjectAltNames() argument 96 Collection<?> subjectAltNames = certificate.getSubjectAlternativeNames(); in getSubjectAltNames()
|
/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/ |
D | KeyStorePrivateKeyEntryTest.java | 62 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()
|
D | KeyStore3Test.java | 49 private Certificate certificate; field in KeyStore3Test 74 certificate = cf.generateCertificate(certArray); in KeyStore3Test() 104 mockKeyStore.setKeyEntry("Alias", null, null, new Certificate[]{certificate}); in test_setKeyEntry_key_is_null() 125 mockKeyStore.setKeyEntry("Alias", key, null, new Certificate[]{certificate}); in test_setKeyEntry_key_is_private() 135 mockKeyStore.setKeyEntry("Alias3", key, null, new Certificate[]{certificate}); in test_setKeyEntry_key_is_public() 143 mockKeyStore.setCertificateEntry(null, certificate); in test_setCertificateEntry_null()
|
D | Identity2Test.java | 85 String certificate = "-----BEGIN CERTIFICATE-----\n" field in Identity2Test 101 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate.getBytes());
|
/libcore/luni/src/main/java/java/security/ |
D | Identity.java | 90 public void addCertificate(Certificate certificate) throws KeyManagementException { in addCertificate() argument 91 PublicKey certPK = certificate.getPublicKey(); in addCertificate() 102 certificates.add(certificate); in addCertificate() 137 public void removeCertificate(Certificate certificate) throws KeyManagementException { in removeCertificate() argument 139 if (!certificates.contains(certificate)) { in removeCertificate() 142 certificates.removeElement(certificate); in removeCertificate()
|
D | Signature.java | 287 public final void initVerify(Certificate certificate) in initVerify() argument 289 if (certificate instanceof X509Certificate) { in initVerify() 290 Set<String> ce = ((X509Certificate) certificate).getCriticalExtensionOIDs(); in initVerify() 301 boolean[] keyUsage = ((X509Certificate) certificate) in initVerify() 315 engineInitVerify(certificate.getPublicKey()); in initVerify()
|
/libcore/luni/src/test/java/tests/security/ |
D | CertificateFactoryTest.java | 43 Certificate certificate = certificateFactory.generateCertificate( in testCertificateFactory() local 45 assertNotNull(certificate); in testCertificateFactory()
|
/libcore/luni/src/test/java/tests/targets/security/cert/ |
D | CertificateTest.java | 597 Certificate certificate = certificateFactory in testVerifyMD5() local 601 certificate.verify(certificate.getPublicKey()); in testVerifyMD5() 611 Certificate certificate = certificateFactory in testVerifyMD2() local 615 certificate.verify(certificate.getPublicKey()); in testVerifyMD2()
|
D | CertPathBuilderTestPKIX.java | 77 Certificate certificate = certificates.get(0); in validateCertPath() local 79 assertEquals("unexpected certificate type", "X.509", certificate in validateCertPath() 82 X509Certificate x509Certificate = (X509Certificate) certificate; in validateCertPath()
|
/libcore/luni/src/main/java/java/security/cert/ |
D | X509CRL.java | 219 public X509CRLEntry getRevokedCertificate(X509Certificate certificate) { in getRevokedCertificate() argument 220 if (certificate == null) { in getRevokedCertificate() 223 return getRevokedCertificate(certificate.getSerialNumber()); in getRevokedCertificate()
|
D | X509CertSelector.java | 88 public void setCertificate(X509Certificate certificate) { in setCertificate() argument 89 certificateEquals = certificate; in setCertificate() 1102 public boolean match(Certificate certificate) { in match() argument 1103 if (! (certificate instanceof X509Certificate)) { in match() 1107 X509Certificate cert = (X509Certificate) certificate; in match()
|
/libcore/luni/src/test/java/libcore/java/security/cert/ |
D | CertificateFactoryTest.java | 284 Certificate certificate = cf.generateCertificate(certStream); in test_generateCertificate_InputStream_Offset_Correct() local 285 assertNotNull(certificate); in test_generateCertificate_InputStream_Offset_Correct() 371 certs.add(cert3.certificate); in testGenerateCertPath() 372 certs.add(cert2.certificate); in testGenerateCertPath() 373 certs.add(cert1.certificate); in testGenerateCertPath() 376 duplicatedCerts.add(cert2.certificate); in testGenerateCertPath() 515 public X509Certificate certificate; field in CertificateFactoryTest.KeyHolder 537 serial = issuer.certificate.getSerialNumber().add(BigInteger.ONE); in generateCertificate() 539 issuerPrincipal = issuer.certificate.getSubjectX500Principal(); in generateCertificate() 567 new AuthorityKeyIdentifierStructure(issuer.certificate)); in generateCertificate() [all …]
|
D | SubjectAlternativeNameTest.java | 66 private X509Certificate bouncycastleToJava(Certificate certificate) throws Exception { in bouncycastleToJava() argument 67 byte[] encoded = certificate.getEncoded(); in bouncycastleToJava()
|
D | X509CertSelectorTest.java | 133 private X509Certificate bouncycastleToJava(Certificate certificate) throws Exception { in bouncycastleToJava() argument 134 byte[] encoded = certificate.getEncoded(); in bouncycastleToJava()
|
/libcore/luni/src/test/java/tests/targets/security/ |
D | KeyStoreTest.java | 103 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/ |
D | PKIXBuilderParametersTest.java | 48 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()
|
D | X509CRL2Test.java | 41 String certificate = "-----BEGIN CERTIFICATE-----\n" field in X509CRL2Test 68 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate in setUp()
|
D | X509CRLTest.java | 59 String certificate = "-----BEGIN CERTIFICATE-----\n" field in X509CRLTest 75 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate
|
/libcore/support/src/test/java/libcore/java/security/ |
D | TestKeyStore.java | 725 X509Certificate certificate = (X509Certificate) privateKey.getCertificate(); in privateKey() local 726 if (!certificate.getSigAlgName().contains(signatureAlgorithm)) { in privateKey() 778 Certificate certificate = certificateEntry.getTrustedCertificate(); in issuer() local 779 if (!(certificate instanceof X509Certificate)) { in issuer() 782 X509Certificate x = (X509Certificate) certificate; in issuer() 790 + "\nsecond: " + certificate ); in issuer() 792 found = certificate; in issuer() 823 Certificate certificate = certificateEntry.getTrustedCertificate(); in rootCertificate() local 824 if (!certificate.getPublicKey().getAlgorithm().equals(algorithm)) { in rootCertificate() 827 if (!(certificate instanceof X509Certificate)) { in rootCertificate() [all …]
|
/libcore/luni/src/main/java/javax/crypto/ |
D | Cipher.java | 878 public final void init(int opmode, Certificate certificate) in init() argument 883 init(opmode, certificate, secureRandom); in init() 921 public final void init(int opmode, Certificate certificate, in init() argument 924 if (certificate instanceof X509Certificate) { in init() 925 Set<String> ce = ((X509Certificate) certificate).getCriticalExtensionOIDs(); in init() 935 boolean[] keyUsage = ((X509Certificate) certificate).getKeyUsage(); in init() 966 final Key key = certificate.getPublicKey(); in init()
|
/libcore/support/src/test/java/org/apache/harmony/xnet/tests/support/ |
D | X509KeyManagerImpl.java | 25 String certificate = "-----BEGIN CERTIFICATE-----\n" field in X509KeyManagerImpl 41 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate
|
/libcore/luni/src/test/java/libcore/javax/net/ssl/ |
D | KeyManagerFactoryTest.java | 242 X509Certificate certificate = certificateChain[0]; in test_X509KeyManager_alias() local 243 assertEquals(keyType, keyAlgName, certificate.getPublicKey().getAlgorithm()); in test_X509KeyManager_alias() 248 String actualSigAlgName = certificate.getSigAlgName().toUpperCase(); in test_X509KeyManager_alias()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/javax/net/ssl/ |
D | X509KeyManagerTest.java | 80 String certificate = "-----BEGIN CERTIFICATE-----\n" field in X509KeyManagerTest 101 ByteArrayInputStream certArray = new ByteArrayInputStream(certificate
|
/libcore/support/src/test/java/libcore/javax/net/ssl/ |
D | TestSSLContext.java | 238 public static void assertCertificateInKeyStore(Certificate certificate, in assertCertificateInKeyStore() argument 246 if (certificate.equals(keyStoreCertificate)) { in assertCertificateInKeyStore()
|
/libcore/support/src/test/java/tests/resources/x509/ |
D | default.cnf | 91 certificate = $dir/cacert.pem # The CA certificate 143 req_extensions = v3_req # The extensions to add to a certificate request
|