summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorcyBerta <cyberta@riseup.net>2022-01-31 23:50:52 +0100
committercyBerta <cyberta@riseup.net>2022-01-31 23:50:52 +0100
commit30cedf1f95f4f430ddc378d963e8cd46c1bd0903 (patch)
tree41796be8a9b56f5a66ab803b8a98a10f9d43f6af /app
parent43d997abba66cbf8ea6d78af75f6275cdb8c3157 (diff)
fix insecure builds
Diffstat (limited to 'app')
-rw-r--r--app/src/insecure/java/se/leap/bitmaskclient/providersetup/ProviderApiManager.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/app/src/insecure/java/se/leap/bitmaskclient/providersetup/ProviderApiManager.java b/app/src/insecure/java/se/leap/bitmaskclient/providersetup/ProviderApiManager.java
index dfb5346b..221871ef 100644
--- a/app/src/insecure/java/se/leap/bitmaskclient/providersetup/ProviderApiManager.java
+++ b/app/src/insecure/java/se/leap/bitmaskclient/providersetup/ProviderApiManager.java
@@ -69,6 +69,7 @@ import static se.leap.bitmaskclient.base.utils.ConfigHelper.getProviderFormatted
import static se.leap.bitmaskclient.providersetup.ProviderAPI.ERRORS;
import static se.leap.bitmaskclient.providersetup.ProviderSetupFailedDialog.DOWNLOAD_ERRORS.ERROR_CERTIFICATE_PINNING;
import static se.leap.bitmaskclient.providersetup.ProviderSetupFailedDialog.DOWNLOAD_ERRORS.ERROR_CORRUPTED_PROVIDER_JSON;
+import static se.leap.bitmaskclient.tor.TorStatusObservable.getProxyPort;
/**
* Created by cyberta on 04.01.18.
@@ -325,7 +326,7 @@ public class ProviderApiManager extends ProviderApiManagerBase {
String responseString;
JSONObject errorJson = new JSONObject();
- OkHttpClient okHttpClient = clientGenerator.initCommercialCAHttpClient(errorJson);
+ OkHttpClient okHttpClient = clientGenerator.initCommercialCAHttpClient(errorJson, getProxyPort());
if (okHttpClient == null) {
return errorJson.toString();
}
@@ -360,7 +361,7 @@ public class ProviderApiManager extends ProviderApiManagerBase {
private String downloadFromUrlWithProviderCA(String urlString, Provider provider, boolean dangerOn) {
String responseString;
JSONObject errorJson = new JSONObject();
- OkHttpClient okHttpClient = clientGenerator.initSelfSignedCAHttpClient(provider.getCaCert(), errorJson);
+ OkHttpClient okHttpClient = clientGenerator.initSelfSignedCAHttpClient(provider.getCaCert(), getProxyPort(), errorJson);
if (okHttpClient == null) {
return errorJson.toString();
}
@@ -395,7 +396,7 @@ public class ProviderApiManager extends ProviderApiManagerBase {
JSONObject initError = new JSONObject();
String responseString;
- OkHttpClient okHttpClient = clientGenerator.initSelfSignedCAHttpClient(caCert, initError);
+ OkHttpClient okHttpClient = clientGenerator.initSelfSignedCAHttpClient(caCert, getProxyPort(), initError);
if (okHttpClient == null) {
return initError.toString();
}