Package br.com.caelum.stella.nfe

Examples of br.com.caelum.stella.nfe.HSKeyManager


      String defaultAlgorithm = TrustManagerFactory.getDefaultAlgorithm();
      TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance(defaultAlgorithm);
      trustManagerFactory.init(trustStore);

      TrustManager[] trustManagers = trustManagerFactory.getTrustManagers();
      KeyManager[] keyManagers = { new HSKeyManager(certificate, privateKey) };

      SSLContext sslContext = SSLContext.getInstance("TLS");
      sslContext.init(keyManagers, trustManagers, null);
      HttpsURLConnection.setDefaultSSLSocketFactory(sslContext.getSocketFactory());
View Full Code Here

TOP

Related Classes of br.com.caelum.stella.nfe.HSKeyManager

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.