summaryrefslogtreecommitdiffhomepage
path: root/tunnel
AgeCommit message (Collapse)Author
2021-01-23libwg-go: update to go 1.15.6L.W.Reek
Signed-off-by: L.W.Reek <syphyr@gmail.com>
2020-12-23tunnel: bump libwg-goJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-12-16tunnel: bump libwg-goJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-11-07build: switch to Gradle's maven-publish pluginHarsh Shandilya
Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-10-27ToolsInstaller: unbreak cleanupJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-10-26tunnel: do not constantly raise toasts when process is opportunistically killedJason A. Donenfeld
Modern Android likes to kill processes to free ram and resources. When kernel-mode WireGuard is in use, this is quite alright with us, since the app doesn't actually need to consume any resources at all in order for the tunnel to run. So, we want to allow and encourage this resource frugality. However, when the quick settings tile is being used or when the app is referenced otherwise, the app will occasionally be restarted, to, for example, repaint the quick settings tile. This is also fine, as the process winds up being short-lived again. But, since process initialization means asking for a new root shell in order to check on kernel-mode WireGuard, this means that Magisk raises a systemwide toast. On some phones, this happens each and every time that the notification shade is pulled down. It's not only annoying but it sometimes obscures other notifications that users want to see, prompting their pulling down of the notification shade in the first place. In order to get rid of this nuisance, just disable these notifications and extraneous logs, so that we don't clutter the system every time that the process is opportunistically killed and restarted. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-10-20tunnel: clean up some docstring wordingJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-10-07tunnel: use more subtle roaming escape hatchJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-09-21Statistics: only do one hash lookupJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-09-21TunnelManager: catch exception in intent receiverJason A. Donenfeld
java.lang.IllegalStateException: at android.app.ContextImpl.startServiceCommon (ContextImpl.java:1720) at android.app.ContextImpl.startService (ContextImpl.java:1675) at android.content.ContextWrapper.startService (ContextWrapper.java:669) at com.wireguard.android.backend.GoBackend.startVpnService (GoBackend.java:4) at com.wireguard.android.backend.GoBackend.setStateInternal (GoBackend.java:4) at com.wireguard.android.backend.GoBackend.setState (GoBackend.java:2) at com.wireguard.android.model.TunnelManager$setTunnelState$2$1.invokeSuspend (TunnelManager.java:6) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith (BaseContinuationImpl.java:2) at kotlinx.coroutines.DispatchedTask.run (DispatchedTask.java:2) at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely (CoroutineScheduler.java) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask (CoroutineScheduler.java:7) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker (CoroutineScheduler.java:7) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run (CoroutineScheduler.java:7) Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-09-16libwg-go: use PeekLookAtSocketFd6(), not PeekLookAtSocketFd4()Jonathan Davies
Signed-off-by: Jonathan Davies <jpds@protonmail.com> Fixes: 3d088411 ("libwg-go: use conn.Bind for socketfd peek") Cc: David Crawshaw <crawshaw@tailscale.com> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-09-16tunnel: document more public API from backend packageHarsh Shandilya
Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-09-16Ed25519: use implementation from TinkJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-09-15wireguard-tools: bump to fix invalid freeJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-09-15libwg-go: update to go 1.15.2Jason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-09-15gradle: desugar retrofuture and remove old depsJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-08-26tools: bump for Android 11 ndc fixHarsh Shandilya
Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-08-25build: target SDK 30Harsh Shandilya
We're all set to support it from the application side of things. Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-08-23build: remove explicit buildToolsVersionHarsh Shandilya
AGP sets it automatically, let's rely on that Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-06-22libwg-go: use conn.Bind for socketfd peekDavid Crawshaw
Signed-off-by: David Crawshaw <crawshaw@tailscale.com> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-06-07tools: bump versionsJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-05-04tunnel: add windows-style killswitch semantics for GoBackendJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-04-26libwg-go: bump go versionHarsh Shandilya
Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-04-23ToolsInstaller: update Magisk directoryHarsh Shandilya
/data/adb/modules has been the location for modules since v18.0 and nobody should reasonably be on any older version anymore. This has continued to work for this long because Magisk created symlinks for backwards compat. However, these symlinks are not created anymore on Android 11, which is where this problem first surfaced. Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-04-19tunnel: disable LongLogTag lintHarsh Shandilya
Should have been part of the patch that disabled this for ui/ Fixes: 8d128cf2e963 ("ui: disable LongLogTag lint") Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-04-08tunnel: disable BuildConfig generationHarsh Shandilya
We don't (and shouldn't) use BuildConfig values, but the class was polluting our public API regardless which is undesirable. Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-04-05tunnel: support IncludedApplications as whitelistJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-04-06tunnel: hold peers in an ArrayListHarsh Shandilya
A set will cause identical peers to be dropped during save Reported-by: Jason A. Donenfeld <Jason@zx2c4.com> Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-04-03version: bumpJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-04-03tunnel: libwg-go: use deterministic verdef nameJason A. Donenfeld
From the ld.gold source: const char* name = parameters->options().soname(); if (name == NULL) name = parameters->options().output_file_name(); That means by default it uses `-o {output}` as the verdef aux name, which is random every time due to Go's build system. By passing in `--soname={somethingexplicit}` we can instead have a deterministic verdef. This commit makes wireguard-android reproducible. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-04-01tunnel: libwg-go: remove -x option from flockJason A. Donenfeld
It's already the default and the macOS port of flock doesn't support it. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-30global: cleanup code styleJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-29tunnel: libwg-go: check sha256 of downloaded tarballJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-29tunnel: libwg-go: stick go tarball in gradle cacheJason A. Donenfeld
This way we don't have to build over and over. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-29tunnel: libwg-go: prevent parallel downloadsJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-29tunnel: fix package name being passed through to cmakeJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-28global: hardcode tags so that minification doesn't ruin the logJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-22libwg-go: update go modulesJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-22libwg-go: bump go versionJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-19InetEndpoint: return proper parser exceptionJason A. Donenfeld
Wrapping this in something foreign doesn't make sense. Reported-by: Luis Ressel <aranea@aixah.de> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-14publish.gradle: Use non-deprecated API to prevent eager configuration of tasksHarsh Shandilya
Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-03-14tunnel: Add an initial set of unit testsHarsh Shandilya
Includes a control set of broken configuration files that we attempt to parse and verify that the parser fails in a predictable and consistent manner. Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-03-14tunnel: Remove MISSING_VALUE from BadConfigException reasonsHarsh Shandilya
This is covered under SYNTAX_ERROR which feels like a reasonable choice, so get rid of this unused field and associated resource string. Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
2020-03-13config: show missing section error correctlyJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-12tunnel: replace CompletableFuture with GhettoCompletableFutureJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-12tunnel: we return Optional types so mark retrostreams as apiJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-11tunnel: add javadoc supportJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-10tunnel: the external API does not expose java9Jason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-10tunnel: tools: update to latest goJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2020-03-10tunnel: make use of @RestrictToJason A. Donenfeld
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>