set MTU back to 1500 default

This commit is contained in:
Nathan Freitas 2014-10-28 01:05:53 -04:00
parent 284a5398b4
commit 97ca6fbd05
1 changed files with 4 additions and 2 deletions

View File

@ -52,6 +52,8 @@ public class OrbotVpnService extends VpnService implements Handler.Callback {
private int mSocksProxyPort = 9999;
private ProxyServer mProxyServer;
private final static int VPN_MTU = 1500;
@Override
public int onStartCommand(Intent intent, int flags, int startId) {
@ -125,7 +127,7 @@ public class OrbotVpnService extends VpnService implements Handler.Callback {
Builder builder = new Builder();
builder.setMtu(3000);
builder.setMtu(VPN_MTU);
builder.addAddress("10.0.0.1",8);
builder.setSession("OrbotVPN");
builder.addRoute("0.0.0.0",0);
@ -141,7 +143,7 @@ public class OrbotVpnService extends VpnService implements Handler.Callback {
try
{
Tun2Socks.Start(mInterface, 3000, "10.0.0.2", "255.255.255.0", "localhost:" + TorServiceConstants.PORT_SOCKS_DEFAULT, "50.116.51.157:7300", true);
Tun2Socks.Start(mInterface, VPN_MTU, "10.0.0.2", "255.255.255.0", "localhost:" + TorServiceConstants.PORT_SOCKS_DEFAULT, "50.116.51.157:7300", true);
}
catch (Exception e)
{