Package org.ejbca.util.provider

Examples of org.ejbca.util.provider.TLSProvider


                    System.setProperty("javax.net.ssl.keyStore", "NONE");
                } else {
                    throw new ServletException("If "+OcspConfiguration.REKEYING_WSURL+" is defined, either "+OcspConfiguration.WSSWKEYSTOREPATH+" or P11 must be defined.");
                }
                // setting ejbca trust provider that accept all server certs
                final Provider tlsProvider = new TLSProvider();
                Security.addProvider(tlsProvider);
                Security.setProperty("ssl.TrustManagerFactory.algorithm", "AcceptAll");
                Security.setProperty("ssl.KeyManagerFactory.algorithm", "NewSunX509");
            } else {
                if ( renewTimeBeforeCertExpiresInSeconds>=0 ) {
View Full Code Here


                handler.clean();
                System.setProperty("javax.net.ssl.keyStoreType", "pkcs11");
                System.setProperty("javax.net.ssl.keyStoreProvider", providerName);
                System.setProperty("javax.net.ssl.keyStore", "NONE");
                if ( trustStorePath==null ) {
                    final Provider tlsProvider = new TLSProvider();
                    Security.addProvider(tlsProvider);
                    Security.setProperty("ssl.TrustManagerFactory.algorithm", "AcceptAll");
                }
            } else {
                final String keyStorePath = props.getProperty("ejbcawsracli.keystore.path", "keystore.jks");
                checkIfFileExists(keyStorePath);
                System.setProperty("javax.net.ssl.keyStore", keyStorePath);
                if (keyStorePath.endsWith(".p12")) {
                  System.setProperty("javax.net.ssl.keyStoreType", "pkcs12");
                }
                if ( trustStorePath==null  ) {
                    if (keyStorePath.endsWith(".p12")) {
                        final Provider tlsProvider = new TLSProvider();
                        Security.addProvider(tlsProvider);
                        Security.setProperty("ssl.TrustManagerFactory.algorithm", "AcceptAll");
                    } else {
                        System.setProperty("javax.net.ssl.trustStore", keyStorePath);
                    }
View Full Code Here

TOP

Related Classes of org.ejbca.util.provider.TLSProvider

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.