Package org.italiangrid.utils.https

Examples of org.italiangrid.utils.https.SSLOptions


   
   
  }

  private SSLOptions getSSLOptions() {
    SSLOptions options = new SSLOptions();

    options.setCertificateFile(getStringFromSecurityConfiguration(
        "certificate", PAPStandaloneServiceDefaults.CERTIFICATE_PATH));
    options.setKeyFile(getStringFromSecurityConfiguration("private_key",
        PAPStandaloneServiceDefaults.PRIVATE_KEY_PATH));

    options.setNeedClientAuth(true);
    options.setWantClientAuth(true);
    options.setTrustStoreDirectory(getStringFromSecurityConfiguration(
        "trust_store_dir",
        String.valueOf(PAPStandaloneServiceDefaults.TRUST_STORE_DIR)));

    int trustStoreRefreshInMinutes = getIntFromStandaloneConfiguration(
        "crl_update_interval",
        PAPStandaloneServiceDefaults.TRUST_STORE_REFRESH_PERIOD_IN_MINUTES);

    long trustStoreUpdatePeriod = TimeUnit.MINUTES
        .toMillis(trustStoreRefreshInMinutes);

    options.setTrustStoreRefreshIntervalInMsec(trustStoreUpdatePeriod);

    return options;
  }
View Full Code Here


        PAPStandaloneServiceDefaults.PORT);

    String host = getStringFromStandaloneConfiguration("hostname",
        PAPStandaloneServiceDefaults.HOSTNAME);

    SSLOptions options = getSSLOptions();
   
    CANLListener l = new CANLListener();
   
    X509CertChainValidatorExt validator = CertificateValidatorBuilder
        .buildCertificateValidator(options.getTrustStoreDirectory(),
            l,
            l,
            options.getTrustStoreRefreshIntervalInMsec());
   
    PAPConfiguration.instance().setCertChainValidator(validator);
   
    int maxRequestQueueSize = getIntFromStandaloneConfiguration(
        "max_request_queue_size",
View Full Code Here

TOP

Related Classes of org.italiangrid.utils.https.SSLOptions

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.