commit 23b86e518fc269eb180f931d7d08308ad654a1ce Author: bim dsnake@protonmail.com Date: Sun Dec 13 14:13:32 2020 -0500
missing netcipher integration stuff --- app/src/main/AndroidManifest.xml | 6 ++++-- app/src/main/java/org/torproject/android/OrbotMainActivity.java | 6 +++--- 2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 7b81951f..0f69c722 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -39,7 +39,6 @@ android:launchMode="singleTop"> <intent-filter> <action android:name="android.intent.action.MAIN" /> - <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> <intent-filter> @@ -52,9 +51,12 @@ </intent-filter> <intent-filter> <action android:name="org.torproject.android.REQUEST_HS_PORT" /> - <category android:name="android.intent.category.DEFAULT" /> </intent-filter> + <intent-filter> + <action android:name="org.torproject.android.REQUEST_V3_ONION_SERVICE"/> + <category android:name="android.intent.category.DEFAULT"/> + </intent-filter> <intent-filter> <action android:name="org.torproject.android.START_TOR" />
diff --git a/app/src/main/java/org/torproject/android/OrbotMainActivity.java b/app/src/main/java/org/torproject/android/OrbotMainActivity.java index a2922af7..773c7fa6 100644 --- a/app/src/main/java/org/torproject/android/OrbotMainActivity.java +++ b/app/src/main/java/org/torproject/android/OrbotMainActivity.java @@ -539,11 +539,11 @@ public class OrbotMainActivity extends AppCompatActivity implements OrbotConstan sendIntentToService(ACTION_START_VPN); }
- private void enableV3OnionServiceOnV3(int localPort, int onionPort, String name) { + private void enableV3OnionService(int localPort, int onionPort, String name) { ContentValues fields = new ContentValues(); fields.put(OnionServiceContentProvider.OnionService.PORT, localPort); fields.put(OrbotService.OnionService.NAME, name); - fields.put(OnionServiceContentProvider.OnionService.PORT, onionPort); + fields.put(OnionServiceContentProvider.OnionService.ONION_PORT, onionPort); fields.put(OnionServiceContentProvider.OnionService.ENABLED, 1); fields.put(OnionServiceContentProvider.OnionService.CREATED_BY_USER, 0);
@@ -697,7 +697,7 @@ public class OrbotMainActivity extends AppCompatActivity implements OrbotConstan final String finalName = name; new AlertDialog.Builder(this) .setMessage(getString(R.string.hidden_service_request, String.valueOf(v3LocalPort))) - .setPositiveButton(R.string.allow, (d, w) -> enableV3OnionServiceOnV3(v3LocalPort, v3onionPort, finalName)) + .setPositiveButton(R.string.allow, (d, w) -> enableV3OnionService(v3LocalPort, v3onionPort, finalName)) .setNegativeButton(R.string.deny, (d, w) -> d.dismiss()) .show(); return;
tor-commits@lists.torproject.org