@Test(expected = UnsupportedOperationException.class) public void testEngineLoadInputStreamCharArray() throws Exception { store.engineLoad(null,new char[3]); }
@Override public void engineLoad(LoadStoreParameter params) throws IOException, NoSuchAlgorithmException, CertificateException { logger.debug("creating cert store."); if (params == null) { throw new IllegalArgumentException("parameter null"); } else if (!(params instanceof SimpleMemoryKeyStoreLoadStoreParameter)) { throw new IllegalArgumentException("Wrong parameter type"); } X509Certificate[] certs = ((SimpleMemoryKeyStoreLoadStoreParameter) params).getCerts(); this.certMap = new ConcurrentHashMap<String,X509Certificate>(); if (certs != null) { for (X509Certificate cert : certs) { if (cert != null) { logger.debug("adding cert " + cert.getSubjectDN().getName()); certMap.put(cert.getSubjectDN().getName(), cert); } } } }
SimpleMemoryKeyStore extends KeyStoreSpi { @Override public void engineLoad(LoadStoreParameter params) throws IOException, NoSuchAlgorithmException, CertificateException { logger.debug("creating cert store."); if (params == null) { throw new IllegalArgumentException("parameter null"); } else if (!(params instanceof SimpleMemoryKeyStoreLoadStoreParameter)) { throw new IllegalArgumentException("Wrong parameter type"); } X509Certificate[] certs = ((SimpleMemoryKeyStoreLoadStoreParameter) params).getCerts(); this.certMap = new ConcurrentHashMap<String,X509Certificate>(); if (certs != null) { for (X509Certificate cert : certs) { if (cert != null) { logger.debug("adding cert " + cert.getSubjectDN().getName()); certMap.put(cert.getSubjectDN().getName(), cert); } } } } }
SimpleMemoryKeyStore extends KeyStoreSpi { @Override public void engineLoad(LoadStoreParameter params) throws IOException, NoSuchAlgorithmException, CertificateException { logger.debug("creating cert store."); if (params == null) { throw new IllegalArgumentException("parameter null"); } else if (!(params instanceof SimpleMemoryKeyStoreLoadStoreParameter)) { throw new IllegalArgumentException("Wrong parameter type"); } X509Certificate[] certs = ((SimpleMemoryKeyStoreLoadStoreParameter) params).getCerts(); this.certMap = new ConcurrentHashMap<String,X509Certificate>(); if (certs != null) { for (X509Certificate cert : certs) { if (cert != null) { logger.debug("adding cert " + cert.getSubjectDN().getName()); certMap.put(cert.getSubjectDN().getName(), cert); } } } }  }
SimpleMemoryKeyStore extends KeyStoreSpi { @Override public void engineLoad(LoadStoreParameter params) throws IOException, NoSuchAlgorithmException, CertificateException { logger.debug("creating cert store."); if (params == null) { throw new IllegalArgumentException("parameter null"); } else if (!(params instanceof SimpleMemoryKeyStoreLoadStoreParameter)) { throw new IllegalArgumentException("Wrong parameter type"); } X509Certificate[] certs = ((SimpleMemoryKeyStoreLoadStoreParameter) params).getCerts(); this.certMap = new ConcurrentHashMap<String,X509Certificate>(); if (certs != null) { for (X509Certificate cert : certs) { if (cert != null) { logger.debug("adding cert " + cert.getSubjectDN().getName()); certMap.put(cert.getSubjectDN().getName(), cert); } } } }  @Override void engineLoad(LoadStoreParameter params); @Override Enumeration<String> engineAliases(); @Override boolean engineContainsAlias(String alias); @Override void engineDeleteEntry(String alias); @Override Certificate engineGetCertificate(String alias); @Override boolean engineIsCertificateEntry(String alias); @Override boolean engineIsKeyEntry(String alias); @Override void engineSetCertificateEntry(String alias, Certificate cert); @Override int engineSize(); @Override void engineStore(OutputStream stream, char[] password); @Override void engineSetKeyEntry(String alias, byte[] key, Certificate[] chain); @Override void engineSetKeyEntry(String alias, Key key, char[] password, Certificate[] chain); @Override void engineLoad(InputStream stream, char[] password); @Override String engineGetCertificateAlias(Certificate cert); @Override Certificate[] engineGetCertificateChain(String alias); @Override Date engineGetCreationDate(String alias); @Override Key engineGetKey(String alias, char[] password); }
SimpleMemoryKeyStore extends KeyStoreSpi { @Override public void engineLoad(LoadStoreParameter params) throws IOException, NoSuchAlgorithmException, CertificateException { logger.debug("creating cert store."); if (params == null) { throw new IllegalArgumentException("parameter null"); } else if (!(params instanceof SimpleMemoryKeyStoreLoadStoreParameter)) { throw new IllegalArgumentException("Wrong parameter type"); } X509Certificate[] certs = ((SimpleMemoryKeyStoreLoadStoreParameter) params).getCerts(); this.certMap = new ConcurrentHashMap<String,X509Certificate>(); if (certs != null) { for (X509Certificate cert : certs) { if (cert != null) { logger.debug("adding cert " + cert.getSubjectDN().getName()); certMap.put(cert.getSubjectDN().getName(), cert); } } } }  @Override void engineLoad(LoadStoreParameter params); @Override Enumeration<String> engineAliases(); @Override boolean engineContainsAlias(String alias); @Override void engineDeleteEntry(String alias); @Override Certificate engineGetCertificate(String alias); @Override boolean engineIsCertificateEntry(String alias); @Override boolean engineIsKeyEntry(String alias); @Override void engineSetCertificateEntry(String alias, Certificate cert); @Override int engineSize(); @Override void engineStore(OutputStream stream, char[] password); @Override void engineSetKeyEntry(String alias, byte[] key, Certificate[] chain); @Override void engineSetKeyEntry(String alias, Key key, char[] password, Certificate[] chain); @Override void engineLoad(InputStream stream, char[] password); @Override String engineGetCertificateAlias(Certificate cert); @Override Certificate[] engineGetCertificateChain(String alias); @Override Date engineGetCreationDate(String alias); @Override Key engineGetKey(String alias, char[] password);  }