Package org.apache.xml.security.keys.storage.implementations

Examples of org.apache.xml.security.keys.storage.implementations.KeyStoreResolver$KeyStoreIterator


    * @param keyStore
    */
   public void add(KeyStore keyStore) {

      try {
         this.add(new KeyStoreResolver(keyStore));
      } catch (StorageResolverException ex) {
         log.error("Could not add KeyStore because of: ", ex);
      }
   }
View Full Code Here


        X509Certificate cert = (X509Certificate)ks.getCertificate("rsakey");
        PublicKey publicKey = cert.getPublicKey();
        PrivateKey privateKey = (PrivateKey) ks.getKey("rsakey", pwd);
        SecretKey secretKey = (SecretKey) ks.getKey("des3key", pwd);

        StorageResolver storage = new StorageResolver(new KeyStoreResolver(ks));
        KeyResolverSpi privateKeyResolver = new PrivateKeyResolver(ks, pwd);
        KeyResolverSpi secretKeyResolver = new SecretKeyResolver(ks, pwd);

        DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
        dbf.setNamespaceAware(true);
View Full Code Here

                                + SEP + "input" + SEP + "keystore2.jks");

        KeyStore ks = KeyStore.getInstance("JCEKS");
        ks.load(f, "xmlsecurity".toCharArray());

        KeyStoreResolver ksResolver = new KeyStoreResolver(ks);
        Iterator<?> iter = ksResolver.getIterator();
        checkIterator(iter);

        // check new iterator starts from the beginning
        Iterator<?> iter2 = ksResolver.getIterator();
        checkIterator(iter2);

        // check the iterators are independent
        // check calling next() without calling hasNext()
        iter = ksResolver.getIterator();
        iter2 = ksResolver.getIterator();

        while (iter.hasNext()) {
            X509Certificate cert = (X509Certificate) iter.next();
            X509Certificate cert2 = (X509Certificate) iter2.next();
            if (!cert.equals(cert2)) {
View Full Code Here

    * @param keyStore
    */
   public void add(KeyStore keyStore) {

      try {
         this.add(new KeyStoreResolver(keyStore));
      } catch (StorageResolverException ex) {
         log.error("Could not add KeyStore because of: ", ex);
      }
   }
View Full Code Here

TOP

Related Classes of org.apache.xml.security.keys.storage.implementations.KeyStoreResolver$KeyStoreIterator

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.