Commit Graph

120 Commits

Author SHA1 Message Date
Mygod
26043bdefc Fix a deadlock in IpNeighbourMonitor 2018-10-08 13:08:48 +08:00
Mygod
a14f324a90 Allow irrelevant info in DefaultNetworkMonitor as well 2018-10-08 12:05:41 +08:00
Mygod
0d83c17b89 Known issue: client features won't work when upgrading from 1.x w/o shutting down service 2018-10-05 00:50:03 +08:00
Mygod
255cfac486 Add more locks 2018-10-05 00:45:53 +08:00
Mygod
c7e79dfb6a Allow unregister to fail
Race condition might occur when cleaning.
2018-10-04 19:45:54 +08:00
Mygod
722855caf7 Refine code 2018-10-04 16:45:44 +08:00
Mygod
89234b37a4 Create a copy before returning 2018-10-04 16:41:19 +08:00
Mygod
e85d792218 Refine IpNeighbour parsing 2018-10-04 16:34:40 +08:00
Mygod
ed1e1a581e Allow records not found in TrafficRecorder 2018-10-04 16:03:59 +08:00
Mygod
b9d5a63c23 Add synchronization in IpNeighbourMonitor 2018-10-04 15:56:24 +08:00
Mygod
e66025c746 Only care about losing one network 2018-10-04 15:50:58 +08:00
Mygod
395e5da871 Fix InvalidConfigurationError 2018-10-04 15:50:07 +08:00
Mygod
913e21328e Misc refinements 2018-10-03 15:02:07 +08:00
Mygod
c573a68ee1 Prevent creating 2 ip link monitors 2018-10-03 14:34:55 +08:00
Mygod
a4e69c5a9b Tell user when blocking won't work 2018-10-03 14:16:31 +08:00
Mygod
f7978a5a2f Handle default network changes 2018-10-03 13:58:57 +08:00
Mygod
408c84f8d7 Fix DNS not updated onLost 2018-10-03 13:54:01 +08:00
Mygod
1eb84bf1a3 Handle duplicated upstreams 2018-10-03 13:46:44 +08:00
Mygod
8e09e8cd8a Replace strict mode with fallback upstream interface
Fixes #40. Apparently we can no longer take advantage of default network rules set by Android system since Android 9.0 thanks to this commit: 758627c4d9
2018-10-03 13:02:28 +08:00
Mygod
8e3567954e Remove unused imports 2018-10-02 23:49:46 +08:00
Mygod
4de93c5c02 Move monitors to a separate package 2018-10-02 23:44:06 +08:00
dwuku
d131d5d46b Make compatible with F-Droid (#42)
* Make compatible with F-Droid
* Fix title bar empty
2018-10-02 23:13:12 +08:00
Mygod
5f5bb063c0 Record stats before exit 2018-10-02 22:41:43 +08:00
Mygod
8419734df8 Ignore extra records coming later
This can happen when the application is terminated incorrectly. Due to how we add routing rules, new client-wise rules are always added to the top. Therefore, we should always assume that the input at the top is the correct one.
2018-10-02 22:36:47 +08:00
Mygod
38f95a382e VPN Hotspot 2.0: Client+ (#39)
Fix #13, #38. I don't have a lot of confidence that this would work very well for every device.

Also here's an SQL command that hopefully somebody could make into the app for me: `SELECT TrafficRecord.mac, SUM(TrafficRecord.sentPackets), SUM(TrafficRecord.sentBytes), SUM(TrafficRecord.receivedPackets), SUM(TrafficRecord.receivedBytes) FROM TrafficRecord LEFT JOIN TrafficRecord AS Next ON TrafficRecord.id = Next.previousId WHERE Next.id IS NULL GROUP BY TrafficRecord.mac;`
2018-10-02 21:12:19 +08:00
Mygod
dbbc27485c Fix exit code 143 not handled 2018-09-18 17:15:38 +08:00
Mygod
268376a7d5 Use DialogFragments everywhere 2018-09-18 17:09:50 +08:00
Mygod
204145ef4f Move edit configuration logic out of WifiP2pDialogFragment 2018-09-17 23:35:59 +08:00
Mygod
d21193ba17 Fix monitor not set 2018-09-15 15:45:37 +08:00
Mygod
c7faa24be9 Use monospace for password 2018-09-08 17:08:20 +08:00
Mygod
1db6d6e9ad Fix crashes on root missing 2018-09-07 11:35:09 +08:00
Mygod
823ae9633b Migrate from NoisySu to RootSession
Fix #24. Note that just like before, IpMonitor doesn't use RootSession.
2018-09-06 15:39:00 +08:00
Mygod
e3f1abbb22 Fully support strict mode for system tethering 2018-09-04 17:49:59 +08:00
Mygod
4ea235b52b Fix p2p_supplicant.conf path on Android 9 2018-09-04 08:15:56 +08:00
Mygod
89c26fe384 Support strict mode for system tethering
TODO: Set up rules when upstream interface not found.
2018-09-03 16:37:54 +08:00
Mygod
7a8412407b Use exec whenever possible 2018-08-26 19:24:45 +08:00
Mygod
cd778589c3 Fix bad token 2018-08-20 23:31:34 +08:00
Mygod
a9e483f3ff Add DHCP workaround
Thanks to petergunn666 for debugging this with me.
2018-08-13 01:41:45 +08:00
Mygod
15d838893c SmartSnackbars 2018-08-08 16:03:30 +08:00
Mygod
b0d2db2d2d Update dependencies 2018-08-08 15:12:48 +08:00
Mygod
6939efed0d Refine styling 2018-07-29 01:42:06 +08:00
Mygod
d38d201212 Revert "Disable editing repeater credentials on Android 5"
This reverts commit df304fe674.

This kind of addresses #31. Apparently we can't predict which wpa_supplicant is bundled into the system by inspecting Android version, especially now that it is put into /vendor/bin/hw (see also Project Treble: https://source.android.com/devices/architecture/vndk/).

It might be cool if someone makes a Magisk module that replaces wpa_supplicant to the latest version.
2018-07-28 23:11:41 +08:00
Mygod
9220f9f113 Refine code style 2018-07-21 19:04:53 +08:00
Mygod
b526de681e Refactor WifiP2pDialog as DialogFragment 2018-07-21 18:26:14 +08:00
Mygod
179675a374 Refine code style 2018-07-21 17:18:21 +08:00
Mygod
df304fe674 Disable editing repeater credentials on Android 5 2018-07-21 14:43:56 +08:00
Mygod
af20a084cb Use Android KTX 2018-07-15 20:58:39 +08:00
Mygod
d0e92b2505 Initial draft for porting to AndroidX 2018-07-15 14:28:42 +08:00
Mygod
89cbd96280 Prefer SnackBars 2018-07-14 23:30:05 +08:00
Mygod
845ede3235 Fix crash when getLinkProperties returns null 2018-07-13 17:57:46 +08:00