Commit Graph

383 Commits

Author SHA1 Message Date
emanuele-f
547af36b73 Implement splash screen for cold start 2021-03-30 13:00:26 +02:00
emanuele-f
2b52fcaa50 Make fab down clickable on Android TV 2021-03-30 13:00:26 +02:00
emanuele-f
049af45f42 Implement dark theme
Closes #46
2021-03-30 13:00:26 +02:00
emanuele-f
4ac471f3a1 Handle missing Storage Access Framework on save
The Storage Access Framework may be missing in some Android devices,
expecially TVs, which sometimes implement an empty stub. In such cases,
PCAPdroid uses the deprecated API to save the file to the Downloads
folder in the internal memory.

Fixes #53
2021-03-30 00:56:49 +02:00
emanuele-f
8a8e96ee39 Remove home screen channel on Android TV 2021-03-29 22:14:07 +02:00
emanuele-f
1bb6ae3165 Fix UDP broadcast connections 2021-03-29 12:01:51 +02:00
emanuele-f
9bb1741456 Handle file selector exception 2021-03-29 11:11:03 +02:00
emanuele-f
fbabe5478f Fix host LRU resolution not performed in some cases 2021-03-25 11:29:40 +01:00
emanuele-f
429215400e Refresh connection details activity 2021-03-24 00:52:21 +01:00
emanuele-f
ab3d684fe7 Implement language switch
It is now possible to switch between the system default language and
the english language.
2021-03-23 23:40:14 +01:00
emanuele-f
6ae5f3fd04 Add initial language switch support
Also add italian translation
2021-03-23 19:26:15 +01:00
emanuele-f
7430687d8c Improve connection status reporting 2021-03-23 18:00:34 +01:00
emanuele-f
47e1d88aab Add IPv6 support
IPv6 must be manually enabled from the preferences. However, when an IPv6 gateway
is not available, the connections will fail with network unreachable.

Closes #2
2021-03-18 19:25:25 +01:00
emanuele-f
08e65d7223 Rework uid_resolver.c
Closes #1
2021-03-17 18:30:55 +01:00
emanuele-f
e7bdb27727 Avoid "No Apps" after starting the AppsActivity 2021-03-17 11:52:43 +01:00
emanuele-f
adcc8b6e5a Avoid unnecessary updates when in background 2021-03-17 11:38:49 +01:00
emanuele-f
6ae6a0f7b8 Use fallback DNS server when main network changes
This avoids using a private DNS server which isn't reachable anymore
2021-03-17 10:37:31 +01:00
emanuele-f
5e43340002 Add ICMP support
Closes #3
2021-03-09 16:19:47 +01:00
emanuele-f
afdd8ad043 Avoid loading all the installed apps when not necessary
This reduces the CPU and memory usage and also improves the adapters
responsiveness.

Closes #40
2021-03-08 21:20:31 +01:00
emanuele-f
778362fd07 Prevent crash in Bitmap.createBitmap 2021-03-08 13:10:58 +01:00
emanuele-f
407f1386ec Color fix 2021-03-07 13:09:36 +01:00
emanuele-f
d04b93edd0 Fix startup crash before Oreo 2021-03-07 12:35:45 +01:00
emanuele-f
d117a9342a Add ability to filter by unknown app 2021-03-05 16:56:25 +01:00
emanuele-f
569523f091 Remove unused resources and add TLS decryption help 2021-03-04 23:46:40 +01:00
emanuele-f
e8a56aa669 Add about view and share app 2021-03-04 23:14:30 +01:00
emanuele-f
fc31bf6e7c Add message for old untracked connections 2021-03-04 22:02:46 +01:00
emanuele-f
0f09214a09 Update copyright 2021-03-04 18:48:24 +01:00
emanuele-f
279c189f20 Honor uid filter while exporting CSV 2021-03-04 18:05:31 +01:00
emanuele-f
7c1075b6e7 Add Android TV support 2021-03-04 17:26:48 +01:00
emanuele-f
29d7ce8d63 Remove share action on connections log
The share intent data size is limited and the connections log can easily
exceed it.
2021-03-04 10:59:30 +01:00
emanuele-f
bea157d5e5 Add more known apps 2021-03-04 10:50:58 +01:00
emanuele-f
b31975c650 Restore ability to apply filter from the Apps view 2021-03-03 18:12:31 +01:00
emanuele-f
c51c765369 Implement connections export as CSV 2021-03-03 17:32:48 +01:00
emanuele-f
3f1028604d Ability to copy/share stats and connection details 2021-03-03 16:05:42 +01:00
emanuele-f
3ad73afcec Improve connection items layout
Also add first/last seen infromation in the connection details
2021-03-03 00:42:21 +01:00
emanuele-f
63cedf972c Restore status and connections tabs view 2021-03-02 18:52:11 +01:00
emanuele-f
6f009ce19a Rework app settings in status view quick settings 2021-03-02 17:39:39 +01:00
emanuele-f
94b93f3175 Fix notification icon 2021-03-02 10:32:25 +01:00
emanuele-f
76d422e92d Fix BroadcastReceiver leaks 2021-03-01 22:28:17 +01:00
emanuele-f
3460e27703 Unify sendCaptureStats and sendVPNStats 2021-03-01 22:11:55 +01:00
emanuele-f
6555724cc7 Fix notification not removed 2021-03-01 21:24:47 +01:00
emanuele-f
138f9c4650 Implement capture service notification 2021-03-01 21:05:40 +01:00
emanuele-f
7e7d469666 Implement ability to save the PCAP file in the device
Closes #24
2021-03-01 17:57:34 +01:00
emanuele-f
3e08121edc Add inspector link into the status view 2021-03-01 10:14:45 +01:00
emanuele-f
e5a774847b Retain UID filter on screen rotation 2021-02-28 11:07:08 +01:00
emanuele-f
46579b31db Fix apps information loading in fragments 2021-02-28 11:02:05 +01:00
emanuele-f
5df007ec38 Improve navigation drawer 2021-02-28 10:47:57 +01:00
emanuele-f
30fdea4d31 Rework layout via Navigation Drawer 2021-02-28 00:21:55 +01:00
emanuele-f
995f3cdfef Decouple fragments from MainActivity 2021-02-27 17:44:23 +01:00
emanuele-f
62b4c9e1d8 Decouple apps loading from MainActivity 2021-02-27 17:13:47 +01:00
emanuele-f
897a464809 Fix warnings 2021-02-27 11:01:19 +01:00
emanuele-f
dc08b8a18b Merge branch 'master' into dev 2021-02-20 21:36:42 +01:00
emanuele-f
673a70eed4 Fix wrong app state on first app start
On the first app start, when the VPN confirmation dialog was shown, the
app state remained in the "ready" state rather than transitioning to to
"running" state. The play button was not replaced with the stop button.
2021-02-20 21:34:58 +01:00
emanuele-f
f1490a05ea Revert "Add option to start the app with predefined settings"
This reverts commit 02f238a7b2.
Check out https://github.com/emanuele-f/PCAPdroid/issues/33 for details.
2021-02-20 10:37:53 +01:00
samuelp
02f238a7b2 Add option to start the app with predefined settings 2021-02-19 23:40:00 +01:00
emanuele-f
b2a7544bfd Add ability to filter the connections by app 2021-02-19 22:06:50 +01:00
emanuele-f
8d508b7cd1 Merge branch 'master' into dev 2021-02-19 14:40:18 +01:00
emanuele-f
c78aba0dae Show fatal errors in the gui and terminate vpn 2021-02-17 17:27:53 +01:00
emanuele-f
d5a8c14131 Add apps view with per-app connections and volumes 2021-02-17 16:00:37 +01:00
emanuele-f
6d47d75805 Add check on FD_SETSIZE 2021-02-16 12:27:23 +01:00
emanuele-f
0713a674be Fix 0.0.0.0 sometimes shown in HTTP server mode 2021-02-16 12:08:01 +01:00
emanuele-f
e325a52153 Reorganize code in subdirectories 2021-02-14 22:53:37 +01:00
emanuele-f
cd154b261f Merge branch 'master' into dev 2021-02-14 22:16:12 +01:00
emanuele-f
3235c0334b Prevent IPv6 DNS servers from being used
Also show the currently used DNS server in the runtime stats
2021-02-14 19:04:37 +01:00
emanuele-f
20b949267d Fix app filter selection when search is used 2021-02-14 18:51:38 +01:00
emanuele-f
99bd931817 Sync adapter items count with its notifications
This should prevent an occasional IndexOutOfBoundsException: Inconsistency detected
after resuming the app
2021-02-14 18:34:08 +01:00
emanuele-f
452683f0b8 Implement app filter search bar and sort 2021-02-14 15:45:51 +01:00
emanuele-f
0abb670099 Increase max number of connections 2021-02-14 12:20:56 +01:00
emanuele-f
d52e7217ae Fix crash in RecyclerView due to misaligned state 2021-02-13 14:55:19 +01:00
emanuele-f
dd1011809a Show active connections indicator and improve layout 2021-02-13 12:42:41 +01:00
emanuele-f
90dc3cf4f9 Optimize RecyclerView operations
This provides both better performance and nice animations
2021-02-12 23:53:40 +01:00
emanuele-f
d08c3d3f64 Implement connections autoscroll and scroll to bottom 2021-02-12 23:03:14 +01:00
emanuele-f
86ae093e31 Add missing license comments 2021-02-12 18:41:31 +01:00
emanuele-f
9722b221ce Migrate connections view to RecyclerView 2021-02-12 18:25:54 +01:00
emanuele-f
c43f2e8f6c Implement persistent connections log 2021-02-12 17:14:18 +01:00
emanuele-f
8cbad66676 Hide settings menu item when app is running
Settings only have affect when the start button is pressed
2021-02-11 19:21:42 +01:00
emanuele-f
a36936fc3e Dropped connections counter color set to red 2021-02-11 19:05:50 +01:00
emanuele-f
dc31cbcb59 Add runtime stats view 2021-02-11 18:52:56 +01:00
emanuele-f
1bb08e3b0c Reduce probability of sending packets with private IPs
When starting/stopping the VPNService, some packets with internal IP
addresses 10.215.173.1 and 10.215.173.2 may be sent over the LAN.
Based on trial and error, this patch reduces such events. In
particular we can see:

- At startup, DNS queries with internal DNS server 10.215.173.2
- At shutdown, some packets with source IP 10.215.173.1

The shutdown issue is more frequent when stopping the VPN from the
android VPN settings. This also happens with other VPN apps.
2021-02-08 01:00:02 +01:00
emanuele-f
13706f8baa Add apps loading in progress message 2021-02-07 18:13:57 +01:00
emanuele-f
f862e8fe05 Move start/stop button to the action bar 2021-02-07 17:51:16 +01:00
emanuele-f
5c8c8ddec0 Clear connections fragment on capture restart 2021-02-07 16:50:31 +01:00
emanuele-f
b3f222cd3a Remove activity dependency on fragments 2021-02-07 12:44:40 +01:00
emanuele-f
c389468037 Fix filter icon issues 2021-02-06 15:18:50 +01:00
TacoTheDank
3a1613c876 Fix some drawables 2021-02-04 17:11:50 -05:00
TacoTheDank
f41d8655ec Migrate activity to ViewPager2 2021-02-04 17:11:37 -05:00
emanuele-f
4c8ba2da10 Fix no traffic when "No Filter" is selected 2021-01-26 19:16:49 +01:00
emanuele-f
c14597d92b Properly capture DNS traffic when app filter is set
This allows PCAPdroid to only capture the DNS traffic of the target
application rather than any DNS traffic with unknown app as before.
2021-01-26 18:35:32 +01:00
emanuele-f
4bc4745b50 Move to minimum API version 21 (lollypop)
It provides material design as long as new VPNService related APIs.
2021-01-26 17:47:18 +01:00
emanuele-f
8bb3666702 Fix empty apps list in Android 11
Due to package visibility changes in the API, QUERY_ALL_PACKAGES is now required.
2021-01-25 16:24:45 +01:00
emanuele-f
a0cad89658 Fix disabled button when VPN request is denied 2021-01-22 15:00:44 +01:00
emanuele-f
ef09f36109 Change telegram channel to group 2021-01-21 22:53:42 +01:00
emanuele-f
e1a6436489 Add check for existing VPN
Android only supports running one VPNService at a time. Added a check to
ask user confirmation in case another VPN connection is active.
2021-01-21 22:07:25 +01:00
emanuele-f
9518e3bd6a Fix app crash when stopped from VPN settings 2021-01-16 23:20:35 +01:00
emanuele-f
94ff1487e1 Add null check 2021-01-11 14:39:44 +01:00
emanuele-f
31bf679ffb Resolve system apps UIDs 2021-01-07 23:46:34 +01:00
emanuele-f
6d9e625806 Add links: rate app, telegram channel, user guide 2020-11-16 15:03:09 +01:00
emanuele-f
afebac6904 Fix view consistency when app filter is in use
The Connections view now only shows the connections matching the current
app filter. TLS mitm is now performed based on the app filter.
2020-11-16 14:30:21 +01:00
emanuele-f
1c81c2d9ff Add TLS decryption settings 2020-11-08 23:50:29 +01:00
emanuele-f
1c9d5b8a11 Update copyright 2020-09-18 18:58:20 +02:00
emanuele-f
3b6eb249ba JNI fixes and optimizations 2020-09-18 17:37:54 +02:00
emanuele-f
47aacace96 Fix some traffic not being monitored
The 128.0.0.0/1 route was missing, resulting in all the traffic for
higher IP addresses not being monitored
2020-06-09 19:02:42 +02:00
emanuele-f
cb3b34d697 Improve local IP address detection
The IP address of the WiFi interface is tried first. If inactive, then all the network interfaces
are iterated.
2020-01-11 15:45:25 +01:00
emanuele-f
b1da40d478 Fix crash due to null drawable 2020-01-11 15:05:53 +01:00
emanuele-f
4f25d1496b Bump version to 1.2.1, add CHANGELOG 2020-01-06 20:56:51 +01:00
emanuele-f
dab1bcb2fe Rename project to PCAPdroid 2020-01-06 19:38:47 +01:00
emanuele-f
14435311a5 Implement embedded HTTP server to provide an easy PCAP download option
It's now possible to choose the PCAP dump mode: none (no external PCAP dump), HTTP server, UDP exporter.
The HTTP server mode is a convenient way to download a PCAP without any client side configuration.
This also makes it possible to capture the PCAP data on a Windows pc, where the UDP collection mode is
not normally applicable.

Closes #13
2020-01-06 18:12:53 +01:00
emanuele-f
930bfaa218 Implement PCAP dump mode selector 2020-01-05 21:05:11 +01:00
emanuele-f
9f2ca6c335 Implement connection details view
Closes #17
2020-01-01 23:40:54 +01:00
emanuele-f
44a9f1fb67 Use the system DNS server if possible
Closes #5
2020-01-01 19:31:28 +01:00
emanuele-f
31d4ea1af4 Fix some connections not shown
Some quick purged connections (e.g. DNS) were not shown. A 10 seconds
timeout is now used to ensure that all the connections are visualized.
2019-11-10 14:02:10 +01:00
emanuele-f
fed5223a04 Fix native crashes 2019-11-10 12:26:01 +01:00
emanuele-f
4e25aac8e6 Show nDPI information
NOTE: the code is still buggy and crashes randomly due to
unaligned accesses
2019-11-10 00:30:31 +01:00
emanuele-f
acfabc2991 Remove inactive connections 2019-11-09 19:59:03 +01:00
emanuele-f
a7f926f763 Improve connections view 2019-11-09 13:23:04 +01:00
emanuele-f
11d948c6e2 Inititial active connection list visualization 2019-11-09 01:03:24 +01:00
emanuele-f
2b0b179e33 Add swipe view to show active connections 2019-11-08 23:47:42 +01:00
emanuele-f
b0b525128a Export active connections data 2019-11-08 00:33:31 +01:00
emanuele-f
1dd7e982d6 Add option to enable/disable unknown app traffic capture 2019-11-03 18:58:40 +01:00
emanuele-f
d5c366c17e Fix app state handling
Fixes #6
2019-11-03 18:01:44 +01:00
emanuele-f
ab6083bc13 Add playstore assets and fix crash on some devices 2019-10-26 13:08:18 +02:00
emanuele-f
dce44afe20 Add about link 2019-10-26 11:24:20 +02:00
emanuele-f
57f2f5bc95 Add support for TCP dumper socket 2019-10-26 01:37:00 +02:00
emanuele-f
33eb55119e Fix bad stats 2019-10-26 01:13:13 +02:00
emanuele-f
c4b34757b5 Implement runtime captured bytes monitor 2019-10-25 23:36:06 +02:00
emanuele-f
4b67d2b856 Replace apps filter ListView with RecycleView 2019-10-25 00:12:00 +02:00
emanuele-f
b9d093d520 Start loading apps asynchronously to speed up apps list dialog opening 2019-10-24 23:28:39 +02:00
emanuele-f
d20062fb69 Move app selector to menu dialog 2019-10-24 00:58:22 +02:00
emanuele-f
bb7968c541 Move settings to Prefs activity 2019-10-23 23:40:34 +02:00
emanuele-f
6741ad3d02 Disable app filter change while capturing 2019-10-05 21:55:28 +02:00
emanuele-f
701467a94e Fix missing filter initialization resulting in no packets being dumped 2019-10-05 21:51:06 +02:00
emanuele-f
8d1a1689c0 Integrate CustomActivityOnCrash to view stack traces 2019-09-11 22:38:30 +02:00
emanuele-f
7feaf9b2c5 First commit 2019-09-08 22:09:03 +02:00