summaryrefslogtreecommitdiffhomepage
path: root/mullvad-jni
AgeCommit message (Collapse)AuthorFilesLines
2025-10-15Enable the user to include their account token in problem reportsJonatan Rhodin1-0/+7
2025-09-23Remove unused dependencies from `mullvad-jni`Markus Pettersson1-2/+0
2025-09-23Remove unused `rand` dependency from `mullvad-jni`Markus Pettersson1-1/+0
2025-07-10Run `cargo fmt`Sebastian Holmin3-9/+9
2025-06-10Update nix to 0.30 everywhereJoakim Hulthe1-1/+0
2025-05-26Add BoringtunJoakim Hulthe1-0/+1
Co-authored-by: Joakim Hulthe <joakim.hulthe@mullvad.net> Co-authored-by: Sebastian Holmin <sebastian.holmin@mullvad.net> Co-authored-by: David Göransson <david.goransson@mullvad.net> Co-authored-by: Markus Pettersson <markus.pettersson@mullvad.net> Co-authored-by: David Lönnhager <david.l@mullvad.net>
2025-05-21Supply IP address when using API overrideDavid Göransson1-17/+21
Previously we did a DNS lookup for Stagemole and Devmole however, this causes problem when starting the app with no internet and is different from how the app performs in production mode. This commit removes that logic in order to align closer to what we expect in prod.
2025-05-06Run `cargo fix --edition`Markus Pettersson1-1/+1
2025-04-03Add product flavor to in app logsKalle Lindström3-0/+6
2025-03-25Avoid using an unavailable ip version to connect to a relayJonatan Rhodin1-1/+3
Co-authored-by: Sebastian Holmin <sebastian.holmin@mullvad.net>
2025-03-17Fix building for Android, rename api to access_mode in mullvad-apiBug Magnet1-1/+1
2025-03-07Track IPv6 connectivity on AndroidDavid Lönnhager1-0/+2
Co-authored-by: Jonatan Rhoidn <jonatan.rhodin@mullvad.net> Co-authored-by: David Göransson <david.goransson@mullvad.net>
2025-02-24Set exception logging file on AndroidJoakim Hulthe1-4/+11
2025-02-12Replace `#[no_mangle]` with `#[unsafe(no_mangle)]`Sebastian Holmin2-4/+4
2025-02-06Replace old waitForTunnelUp functionDavid Göransson3-188/+13
After invoking VpnService.establish() we will get a tunnel file descriptor that corresponds to the interface that was created. However, this has no guarantee of the routing table beeing up to date, and we might thus send traffic outside the tunnel. Previously this was done through looking at the tunFd to see that traffic is sent to verify that the routing table has changed. If no traffic is seen some traffic is induced to a random IP address to ensure traffic can be seen. This new implementation is slower but won't risk sending UDP traffic to a random public address at the internet.
2025-01-02Change how daemon is startedEmīls1-31/+15
2025-01-02Remove global API endpointEmīls3-12/+19
2024-11-27Handle legacy always-on vpn profilesDavid Göransson1-1/+3
Co-authored-by: Jonatan Rhodin <jonatan.rhodin@mullvad.net>
2024-11-22Add comment about tokio runtime and getaddrinfoDavid Lönnhager1-0/+3
2024-09-25Add `futures` to workspace dependenciesSebastian Holmin1-1/+1
2024-08-30Initialize mullvad daemon directly in vpn service on createJonatan Rhodin2-79/+72
As a consequence move the address resolve to the daemon
2024-08-13Refactor tunnel provider and TalpidVpnServiceDavid Lönnhager1-19/+4
This also fixes the issue of the VPN service being restarted unnecessarily
2024-08-12Fix apparently incorrect codeDavid Lönnhager1-2/+2
2024-08-12Refactor TalpidVpnService in mullvad-jniDavid Lönnhager1-28/+33
2024-08-07Fix shutdown issue on AndroidMarkus Pettersson1-0/+3
The daemon never received the shutdown event, causing it to never actually triggering a shutdown. This was fixed by actually using the correct `DaemonCommandChannel` to send the shutdown event.
2024-08-06Shut down gRPC server gracefullyMarkus Pettersson1-14/+2
This commit also removes the `EventListener` trait and the daemon is no longer parameterized over it.
2024-07-25Upgrade pfctl to 0.5.0 and ipnetwork to 0.20Linus Färnstrand1-1/+1
2024-06-24Remove unused HashSet from preloaded Java classesDavid Lönnhager1-1/+0
2024-06-24Remove unused IsNull traitDavid Lönnhager2-19/+0
2024-06-24Refactor daemon init and deinit on AndroidDavid Lönnhager4-416/+259
2024-06-17Get value of data directory value at app startupMarkus Pettersson2-15/+26
Remove `APP_PATH` from `mullvad-paths` on Android since it should not be a constant value. Instead, it is passed down from the Android app startup. As it turns out, it is really ever used for pointing to the RPC socket in use.
2024-06-14Change crate_type into crate-type since the first is deprecatedLinus Färnstrand1-1/+1
2024-05-29Migrate to gRPCDavid Göransson4-2007/+54
Co-authored-by: Jonatan Rhodin <jonatan.rhodin@mullvad.net> Co-authored-by: Markus Pettersson <markus.pettersson@mullvad.net> Co-authored-by: David Lönnhager <david.l@mullvad.net>
2024-04-09Use single-threaded runtime when launching serviceDavid Lönnhager1-2/+2
2024-04-03Enable single-use-lifetimes rustc lintLinus Färnstrand1-2/+2
Removes superfluous lifetime definitions. Simplifying the code
2024-03-19Implement JNI support for Server IP overridesDavid Göransson3-4/+185
2024-03-14Return success or error when creating and updating a custom listJonatan Rhodin2-15/+76
2024-02-27Replace err_derive with thiserrorJoakim Hulthe5-44/+40
`err_derive` is unmaintained and will probably stop working with rust edition 2024. `thiserror` is almost a drop-in replacement. This commit simply replaces all occurences of `derive(err_derive::Error)` with `derive(thiserror::Error)` and fixes the attributes, but the Error and Display impls should be identical.
2024-02-08Add support for custom lists in jniJonatan Rhodin3-0/+103
2024-01-16Add rust-version to all Cargo.tomlLinus Färnstrand1-0/+1
2024-01-11Synchronize `mullvad-api` and `mullvad-daemon` when the `api-override`Markus Pettersson1-10/+4
feature is enabled Move the logic for using overridden API endpoints for API calls from `mullvad-api::rest` to `mullvad_daemon::api`. This is in line with how the interaction between the two crates work for a normal release build, i.e. when the `api-override` feature is disabled. This commit also removes references to `force_direct_connection` in the Android code. The flag does not exist in the `mullvad-*` rust crates anymore, so it would be erroneous to try to serialize/deserialize the value from the Android client.
2024-01-09Remove version and publish cargo metadataLinus Färnstrand1-2/+0
Since Rust 1.75.0 the `version` field is optional. The version defaults to "0.0.0" if it's not specified, and `publish` defaults to false if no version has been given. So by not specifying a version we get both `version = "0.0.0" and `publish = false` "for free"
2024-01-08Add new internal daemon event `AccessMethodEvent`Markus Pettersson1-0/+6
Add a new `InternalDaemonEvent` for announcing when the current API access method changes.
2024-01-04Rename Android enum variants to conform to lint rulesLinus Färnstrand3-16/+14
2024-01-04Add workspace level lintsLinus Färnstrand2-1/+3
2023-12-21Support new tunnel state API in the Android frontend.David Göransson2-36/+0
Remove `get_current_location` from jni.
2023-12-21Handle am.i.mullvad.net with internal daemon eventSebastian Holmin1-1/+0
Add `geoip::GeoIpHandler`, which sends an `InternalDaemonEvent::LocationEvent` when the location arrives. It also handles aborting in-flight requests and retries.
2023-11-17Add missing FirewallPolicyError classJonatan Rhodin1-0/+1
2023-10-31Replace UpdateRelaySettings with SetRelaySettingsDavid Lönnhager3-10/+7
2023-10-25Add providers model and enable it in the daemonJonatan Rhodin1-0/+2