switch back to DNS on 10.0.0.1, update after VPN refresh

This commit is contained in:
Nathan Freitas 2015-04-09 09:10:14 -04:00
parent 690a8c3b69
commit 7d8eea24b1
2 changed files with 8 additions and 2 deletions

View File

@ -1478,6 +1478,12 @@ public class TorService extends Service implements TorServiceConstants, OrbotCon
intent.setAction("refresh"); intent.setAction("refresh");
startService(intent); startService(intent);
updateConfiguration("DNSListenAddress","10.0.0.1:" + TorServiceConstants.TOR_DNS_PORT_DEFAULT,false);
updateConfiguration("DisableNetwork","0", false);
saveConfiguration();
// conn.setConf("DisableNetwork", "0"); // conn.setConf("DisableNetwork", "0");
} }
catch (Exception ioe) catch (Exception ioe)
@ -2477,7 +2483,7 @@ public class TorService extends Service implements TorServiceConstants, OrbotCon
if (mUseVPN) if (mUseVPN)
{ {
// updateConfiguration("DNSListenAddress","10.0.0.1:" + TorServiceConstants.TOR_DNS_PORT_DEFAULT,false); updateConfiguration("DNSListenAddress","10.0.0.1:" + TorServiceConstants.TOR_DNS_PORT_DEFAULT,false);
} }
updateConfiguration("DisableNetwork","0", false); updateConfiguration("DisableNetwork","0", false);

View File

@ -241,7 +241,7 @@ public class OrbotVpnService extends VpnService implements Handler.Callback {
final String virtualIP = "10.0.0.2"; final String virtualIP = "10.0.0.2";
final String virtualNetMask = "255.255.255.0"; final String virtualNetMask = "255.255.255.0";
final String localSocks = "127.0.0.1:" + TorServiceConstants.PORT_SOCKS_DEFAULT; final String localSocks = "127.0.0.1:" + TorServiceConstants.PORT_SOCKS_DEFAULT;
final String localDNS = "127.0.0.1:" + TorServiceConstants.TOR_DNS_PORT_DEFAULT; final String localDNS = "10.0.0.1:" + TorServiceConstants.TOR_DNS_PORT_DEFAULT;
Builder builder = new Builder(); Builder builder = new Builder();