Ejemplo n.º 1
0
 /**
  * Sets the default (app-wide) Trust Store to use. The Trust Store is used to verify server
  * certificates in SSL negotiations.<br>
  * <br>
  * If this method is not called the HTTPSWrapper will use the default JDK Trust Store. <br>
  * <br>
  *
  * @param store_name Path to the Trust store file.
  * @param store_passphrase Passphrase to unlock Trust Store.
  */
 public static void setDefaultTrustStore(String store_name, String store_passphrase)
     throws IOException {
   default_trust_store = KeyStoreReader.loadKeyStore(store_name, store_passphrase);
 }
Ejemplo n.º 2
0
 /**
  * Sets the Key Store to use. The Key Store is used to authenticate with using SSL.<br>
  * <br>
  * If this method is not called the HTTPSWrapper will use the default JDK Key Store (none). <br>
  * <br>
  * To set your own Key Store this method must be called before making either a GET or POST
  * request.
  *
  * @param key_store_file
  * @throws IOException
  */
 public void setKeyStore(String key_store_file, String key_store_password) throws IOException {
   setKeyStore(
       KeyStoreReader.loadKeyStore(key_store_file, key_store_password), key_store_password);
 }
Ejemplo n.º 3
0
 /**
  * Sets the Trust Store to use. The Trust Store is used to verify server certificates in SSL
  * negotiations.<br>
  * <br>
  * If this method is not called the HTTPSWrapper will use the default JDK Trust Store. <br>
  * <br>
  * To set your own Trust Store this method must be called before making either a GET or POST
  * request.
  *
  * @param store_name Path to the Trust store file.
  * @param store_passphrase Passphrase to unlock Trust Store.
  */
 public void setTrustStore(String store_name, String store_passphrase) throws IOException {
   trust_store = KeyStoreReader.loadKeyStore(store_name, store_passphrase);
   ssl_initialized = false;
 }