tweaked the new settings for relays and firewalls; updated parsing script too
svn:r21826
This commit is contained in:
parent
99cc2d75be
commit
84d5e3dcba
8
AUTHORS
8
AUTHORS
|
@ -12,13 +12,13 @@ Main Authors:
|
||||||
Nathan Freitas <nathan@freitas.net> developed the primary
|
Nathan Freitas <nathan@freitas.net> developed the primary
|
||||||
Android application and managed the porting of Tor to Android.
|
Android application and managed the porting of Tor to Android.
|
||||||
|
|
||||||
|
Jake Appelbaum <jake@appelbaum.net > regular gave Nathan a
|
||||||
|
swift kick in the rear to get this done. He has also provided
|
||||||
|
extensive guidance and review. Most recently he has been
|
||||||
|
promoted to Chief Application Resource Editor.
|
||||||
|
|
||||||
Contributors:
|
Contributors:
|
||||||
-------------
|
-------------
|
||||||
Jake Appelbaum <jake@appelbaum.net > regular gave Nathan a
|
|
||||||
swift kick in the rear to get this done. He has also provided
|
|
||||||
extensive guidance and review.
|
|
||||||
|
|
||||||
Nick Mathewson <nickm@freehaven.net> wrote some of the patch
|
Nick Mathewson <nickm@freehaven.net> wrote some of the patch
|
||||||
code to support the compiling of Tor and LibEvent on Android,
|
code to support the compiling of Tor and LibEvent on Android,
|
||||||
and generaly provided guidance in the entire effort.
|
and generaly provided guidance in the entire effort.
|
||||||
|
|
|
@ -4,8 +4,10 @@
|
||||||
android:versionName="011301.2" android:versionCode="2">
|
android:versionName="011301.2" android:versionCode="2">
|
||||||
|
|
||||||
<uses-permission android:name="android.permission.INTERNET" />
|
<uses-permission android:name="android.permission.INTERNET" />
|
||||||
<uses-permission android:name="android.permission.WRITE_SETTINGS" />
|
|
||||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
<!-- <uses-permission android:name="android.permission.WRITE_SETTINGS" /> -->
|
||||||
|
|
||||||
|
<!-- <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> -->
|
||||||
|
|
||||||
<application android:icon="@drawable/icon" android:label="@string/app_name" android:debuggable="false">
|
<application android:icon="@drawable/icon" android:label="@string/app_name" android:debuggable="false">
|
||||||
<activity android:name=".Orbot"
|
<activity android:name=".Orbot"
|
||||||
|
|
|
@ -10,7 +10,5 @@ CookieAuthentication 1
|
||||||
RelayBandwidthRate 20 KBytes
|
RelayBandwidthRate 20 KBytes
|
||||||
RelayBandwidthBurst 20 KBytes
|
RelayBandwidthBurst 20 KBytes
|
||||||
UseBridges 0
|
UseBridges 0
|
||||||
UpdateBridgesFromAuthority 1
|
AutomapHostsOnResolve 1
|
||||||
bridge 74.82.1.191:19030
|
TransPort 9040
|
||||||
bridge 221.31.40.135:4430
|
|
||||||
bridge 24.110.168.130:443
|
|
|
@ -1,5 +1,6 @@
|
||||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
<PreferenceScreen android:title="Bridges">
|
||||||
|
|
||||||
<CheckBoxPreference android:defaultValue="false"
|
<CheckBoxPreference android:defaultValue="false"
|
||||||
android:title="Use Bridges" android:key="pref_bridges_enabled"
|
android:title="Use Bridges" android:key="pref_bridges_enabled"
|
||||||
|
@ -14,6 +15,7 @@ android:title="Bridges"
|
||||||
android:summary="IP address and port of bridges"
|
android:summary="IP address and port of bridges"
|
||||||
android:dialogTitle="Enter Bridge Addresses"
|
android:dialogTitle="Enter Bridge Addresses"
|
||||||
/>
|
/>
|
||||||
|
</PreferenceScreen>
|
||||||
|
|
||||||
|
|
||||||
<CheckBoxPreference
|
<CheckBoxPreference
|
||||||
|
@ -23,13 +25,13 @@ android:title="Transparent Proxying"
|
||||||
android:summary="ROOTED DEVICES ONLY: Activate Tor for all web traffic and DNS"
|
android:summary="ROOTED DEVICES ONLY: Activate Tor for all web traffic and DNS"
|
||||||
android:enabled="true"/>
|
android:enabled="true"/>
|
||||||
|
|
||||||
<PreferenceCategory android:title="Relays">
|
<PreferenceScreen android:title="Relays">
|
||||||
<CheckBoxPreference android:key="pref_or"
|
<CheckBoxPreference android:key="pref_or"
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:title="Relaying"
|
android:title="Relaying"
|
||||||
android:summary="Enable your device to be a relay"
|
android:summary="Enable your device to be a relay"
|
||||||
android:dialogTitle="Enter Bridge Addresses"
|
android:dialogTitle="Enter Bridge Addresses"
|
||||||
android:enabled="false"
|
android:enabled="true"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<EditTextPreference android:key="pref_or_port"
|
<EditTextPreference android:key="pref_or_port"
|
||||||
|
@ -46,15 +48,14 @@ android:summary="The nickname for your Tor relay"
|
||||||
android:dialogTitle="Enter a custom relay nickname"
|
android:dialogTitle="Enter a custom relay nickname"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
</PreferenceCategory>
|
</PreferenceScreen>
|
||||||
|
|
||||||
<PreferenceCategory android:title="FascistFirewalling">
|
<PreferenceScreen android:title="FascistFirewalling">
|
||||||
<CheckBoxPreference
|
<CheckBoxPreference
|
||||||
android:key="pref_fascist_firewall"
|
android:key="pref_fascist_firewall"
|
||||||
android:defaultValue="false"
|
|
||||||
android:title="Fascist Firewall"
|
android:title="Fascist Firewall"
|
||||||
android:summary="Run as a client behind a firewall with restrictive policies"
|
android:summary="Run as a client behind a firewall with restrictive policies"
|
||||||
android:enabled="false"></CheckBoxPreference>
|
android:enabled="true"></CheckBoxPreference>
|
||||||
|
|
||||||
<EditTextPreference android:key="pref_fascist_firewall_ports"
|
<EditTextPreference android:key="pref_fascist_firewall_ports"
|
||||||
android:defaultValue="80,443"
|
android:defaultValue="80,443"
|
||||||
|
@ -62,6 +63,6 @@ android:title="Reachable ports"
|
||||||
android:summary="Ports reachable behind a restrictive firewall"
|
android:summary="Ports reachable behind a restrictive firewall"
|
||||||
android:dialogTitle="Enter ports"
|
android:dialogTitle="Enter ports"
|
||||||
/>
|
/>
|
||||||
</PreferenceCategory>
|
</PreferenceScreen>
|
||||||
|
|
||||||
</PreferenceScreen>
|
</PreferenceScreen>
|
||||||
|
|
|
@ -477,6 +477,7 @@ public class Orbot extends Activity implements OnClickListener, TorConstants, On
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
String bridgeList = prefs.getString(PREF_BRIDGES_LIST,"");
|
String bridgeList = prefs.getString(PREF_BRIDGES_LIST,"");
|
||||||
|
|
||||||
if (useBridges)
|
if (useBridges)
|
||||||
|
@ -512,6 +513,7 @@ public class Orbot extends Activity implements OnClickListener, TorConstants, On
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
torrcText.append("UseBridges 0");
|
torrcText.append("UseBridges 0");
|
||||||
|
torrcText.append('\n');
|
||||||
}
|
}
|
||||||
|
|
||||||
try
|
try
|
||||||
|
@ -531,13 +533,13 @@ public class Orbot extends Activity implements OnClickListener, TorConstants, On
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Toast.makeText(this, "Your FascistFirewall settings caused an exception!",
|
Toast.makeText(this,"Your FascistFirewall settings caused an exception!",
|
||||||
Toast.LENGTH_LONG).show();
|
Toast.LENGTH_LONG).show();
|
||||||
}
|
}
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (becomeRelay && !useBridges && !fascistFirewall)
|
if (becomeRelay && (!useBridges) && (!fascistFirewall))
|
||||||
{
|
{
|
||||||
int ORPort = Integer.parseInt(prefs.getString(PREF_OR_PORT, "9001"));
|
int ORPort = Integer.parseInt(prefs.getString(PREF_OR_PORT, "9001"));
|
||||||
String nickname = prefs.getString(PREF_OR_NICKNAME, "Orbot");
|
String nickname = prefs.getString(PREF_OR_NICKNAME, "Orbot");
|
||||||
|
@ -556,7 +558,7 @@ public class Orbot extends Activity implements OnClickListener, TorConstants, On
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Toast.makeText(this, "Your relay settings caused an exception!", Toast.LENGTH_LONG).show();
|
Toast.makeText(this,"Your relay settings caused an exception!", Toast.LENGTH_LONG).show();
|
||||||
}
|
}
|
||||||
|
|
||||||
Utils.saveTextFile(TorServiceConstants.TORRC_INSTALL_PATH, torrcText.toString());
|
Utils.saveTextFile(TorServiceConstants.TORRC_INSTALL_PATH, torrcText.toString());
|
||||||
|
|
|
@ -34,8 +34,8 @@ public interface TorConstants {
|
||||||
public final static String PREF_BRIDGES_ENABLED = "pref_bridges_enabled";
|
public final static String PREF_BRIDGES_ENABLED = "pref_bridges_enabled";
|
||||||
public final static String PREF_BRIDGES_UPDATED = "pref_bridges_enabled";
|
public final static String PREF_BRIDGES_UPDATED = "pref_bridges_enabled";
|
||||||
public final static String PREF_BRIDGES_LIST = "pref_bridges_list";
|
public final static String PREF_BRIDGES_LIST = "pref_bridges_list";
|
||||||
public final static String PREF_OR = "pref_relay";
|
public final static String PREF_OR = "pref_or";
|
||||||
public final static String PREF_OR_PORT = "pref_relay_port";
|
public final static String PREF_OR_PORT = "pref_or_port";
|
||||||
public final static String PREF_OR_NICKNAME = "pref_or_nickname";
|
public final static String PREF_OR_NICKNAME = "pref_or_nickname";
|
||||||
public final static String PREF_FASCIST_FIREWALL = "pref_fascist_firewall";
|
public final static String PREF_FASCIST_FIREWALL = "pref_fascist_firewall";
|
||||||
public final static String PREF_FASCIST_FIREWALL_PORTS = "pref_fascist_firewall_ports";
|
public final static String PREF_FASCIST_FIREWALL_PORTS = "pref_fascist_firewall_ports";
|
||||||
|
|
Loading…
Reference in New Issue