diff options
| -rw-r--r-- | Cargo.lock | 87 | ||||
| -rw-r--r-- | mullvad-cli/Cargo.toml | 2 | ||||
| -rw-r--r-- | mullvad-daemon/Cargo.toml | 4 | ||||
| -rw-r--r-- | mullvad-problem-report/Cargo.toml | 2 | ||||
| -rw-r--r-- | mullvad-setup/Cargo.toml | 2 | ||||
| -rw-r--r-- | mullvad-setup/src/daemon_paths.rs | 7 | ||||
| -rw-r--r-- | talpid-core/Cargo.toml | 3 | ||||
| -rw-r--r-- | talpid-core/src/routing/windows.rs | 2 | ||||
| -rw-r--r-- | talpid-core/src/split_tunnel/windows/driver.rs | 7 | ||||
| -rw-r--r-- | talpid-core/src/split_tunnel/windows/mod.rs | 2 | ||||
| -rw-r--r-- | talpid-core/src/tunnel/openvpn/mod.rs | 2 | ||||
| -rw-r--r-- | talpid-core/src/tunnel/openvpn/wintun.rs | 2 | ||||
| -rw-r--r-- | talpid-core/src/tunnel/windows.rs | 2 | ||||
| -rw-r--r-- | talpid-core/src/tunnel/wireguard/wireguard_go.rs | 6 | ||||
| -rw-r--r-- | talpid-core/src/tunnel/wireguard/wireguard_nt.rs | 2 | ||||
| -rw-r--r-- | talpid-core/src/windows/mod.rs | 6 | ||||
| -rw-r--r-- | talpid-openvpn-plugin/Cargo.toml | 2 | ||||
| -rw-r--r-- | talpid-platform-metadata/Cargo.toml | 2 |
18 files changed, 98 insertions, 44 deletions
diff --git a/Cargo.lock b/Cargo.lock index c5fb503238..572e38f197 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1541,7 +1541,7 @@ dependencies = [ "libc", "log", "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys", + "windows-sys 0.36.1", ] [[package]] @@ -1610,7 +1610,7 @@ dependencies = [ "serde", "talpid-types", "tokio", - "windows-sys", + "windows-sys 0.42.0", "winres", ] @@ -1656,7 +1656,7 @@ dependencies = [ "uuid", "winapi", "windows-service", - "windows-sys", + "windows-sys 0.42.0", "winres", ] @@ -1741,7 +1741,7 @@ dependencies = [ "talpid-types", "tokio", "uuid", - "windows-sys", + "windows-sys 0.42.0", "winres", ] @@ -1784,7 +1784,7 @@ dependencies = [ "talpid-types", "tokio", "widestring 0.5.1", - "windows-sys", + "windows-sys 0.42.0", ] [[package]] @@ -2104,7 +2104,7 @@ dependencies = [ "libc", "redox_syscall", "smallvec", - "windows-sys", + "windows-sys 0.36.1", ] [[package]] @@ -3153,7 +3153,7 @@ dependencies = [ "widestring 0.5.1", "winapi", "windows-service", - "windows-sys", + "windows-sys 0.42.0", "winreg", "zeroize", ] @@ -3185,7 +3185,7 @@ dependencies = [ "tonic", "tonic-build", "tower", - "windows-sys", + "windows-sys 0.42.0", "winres", ] @@ -3195,7 +3195,7 @@ version = "0.1.0" dependencies = [ "rs-release", "talpid-dbus", - "windows-sys", + "windows-sys 0.42.0", ] [[package]] @@ -3968,7 +3968,7 @@ dependencies = [ "bitflags", "err-derive", "widestring 1.0.2", - "windows-sys", + "windows-sys 0.36.1", ] [[package]] @@ -3977,44 +3977,101 @@ version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ea04155a16a59f9eab786fe12a4a450e75cdb175f9e0d80da1e17db09f55b8d2" dependencies = [ - "windows_aarch64_msvc", - "windows_i686_gnu", - "windows_i686_msvc", - "windows_x86_64_gnu", - "windows_x86_64_msvc", + "windows_aarch64_msvc 0.36.1", + "windows_i686_gnu 0.36.1", + "windows_i686_msvc 0.36.1", + "windows_x86_64_gnu 0.36.1", + "windows_x86_64_msvc 0.36.1", ] [[package]] +name = "windows-sys" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" +dependencies = [ + "windows_aarch64_gnullvm", + "windows_aarch64_msvc 0.42.0", + "windows_i686_gnu 0.42.0", + "windows_i686_msvc 0.42.0", + "windows_x86_64_gnu 0.42.0", + "windows_x86_64_gnullvm", + "windows_x86_64_msvc 0.42.0", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41d2aa71f6f0cbe00ae5167d90ef3cfe66527d6f613ca78ac8024c3ccab9a19e" + +[[package]] name = "windows_aarch64_msvc" version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9bb8c3fd39ade2d67e9874ac4f3db21f0d710bee00fe7cab16949ec184eeaa47" [[package]] +name = "windows_aarch64_msvc" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd0f252f5a35cac83d6311b2e795981f5ee6e67eb1f9a7f64eb4500fbc4dcdb4" + +[[package]] name = "windows_i686_gnu" version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "180e6ccf01daf4c426b846dfc66db1fc518f074baa793aa7d9b9aaeffad6a3b6" [[package]] +name = "windows_i686_gnu" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbeae19f6716841636c28d695375df17562ca208b2b7d0dc47635a50ae6c5de7" + +[[package]] name = "windows_i686_msvc" version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e2e7917148b2812d1eeafaeb22a97e4813dfa60a3f8f78ebe204bcc88f12f024" [[package]] +name = "windows_i686_msvc" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84c12f65daa39dd2babe6e442988fc329d6243fdce47d7d2d155b8d874862246" + +[[package]] name = "windows_x86_64_gnu" version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4dcd171b8776c41b97521e5da127a2d86ad280114807d0b2ab1e462bc764d9e1" [[package]] +name = "windows_x86_64_gnu" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf7b1b21b5362cbc318f686150e5bcea75ecedc74dd157d874d754a2ca44b0ed" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09d525d2ba30eeb3297665bd434a54297e4170c7f1a44cad4ef58095b4cd2028" + +[[package]] name = "windows_x86_64_msvc" version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c811ca4a8c853ef420abd8592ba53ddbbac90410fab6903b3e79972a631f7680" [[package]] +name = "windows_x86_64_msvc" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f40009d85759725a34da6d89a94e63d7bdc50a862acf0dbc7c8e488f1edcb6f5" + +[[package]] name = "winreg" version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" diff --git a/mullvad-cli/Cargo.toml b/mullvad-cli/Cargo.toml index 01c3627ef1..4ca6714911 100644 --- a/mullvad-cli/Cargo.toml +++ b/mullvad-cli/Cargo.toml @@ -36,7 +36,7 @@ clap_complete = { version = "3.0" } winres = "0.1" [target.'cfg(windows)'.build-dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_System_SystemServices", ] diff --git a/mullvad-daemon/Cargo.toml b/mullvad-daemon/Cargo.toml index 19acc1e3d5..c962f73755 100644 --- a/mullvad-daemon/Cargo.toml +++ b/mullvad-daemon/Cargo.toml @@ -57,7 +57,7 @@ winapi = { version = "0.3", features = ["winnt", "excpt"] } dirs-next = "2.0" [target.'cfg(windows)'.dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_Foundation", "Win32_Security", @@ -73,7 +73,7 @@ features = [ winres = "0.1" [target.'cfg(windows)'.build-dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_System_SystemServices", ] diff --git a/mullvad-problem-report/Cargo.toml b/mullvad-problem-report/Cargo.toml index 75c1cc4939..95c7a7a4de 100644 --- a/mullvad-problem-report/Cargo.toml +++ b/mullvad-problem-report/Cargo.toml @@ -32,7 +32,7 @@ duct = "0.13" winres = "0.1" [target.'cfg(windows)'.build-dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_System_SystemServices", ] diff --git a/mullvad-setup/Cargo.toml b/mullvad-setup/Cargo.toml index 980bba5358..7fa8760e0d 100644 --- a/mullvad-setup/Cargo.toml +++ b/mullvad-setup/Cargo.toml @@ -32,7 +32,7 @@ talpid-types = { path = "../talpid-types" } widestring = "0.5" [target.'cfg(windows)'.dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_Foundation", "Win32_Security", diff --git a/mullvad-setup/src/daemon_paths.rs b/mullvad-setup/src/daemon_paths.rs index 1a084d7655..fdb683f2e3 100644 --- a/mullvad-setup/src/daemon_paths.rs +++ b/mullvad-setup/src/daemon_paths.rs @@ -44,7 +44,7 @@ fn get_system_service_known_folder(known_folder_id: *const GUID) -> std::io::Res adjust_current_thread_token_privilege(&system_debug_priv, true)?; let known_folder: io::Result<PathBuf> = (|| { - let mut lsass_path = get_known_folder_path(&FOLDERID_System, KF_FLAG_DEFAULT as u32, 0)?; + let mut lsass_path = get_known_folder_path(&FOLDERID_System, KF_FLAG_DEFAULT, 0)?; lsass_path.push("lsass.exe"); let lsass_pid = get_running_process_id_from_name(&lsass_path)?; @@ -75,8 +75,7 @@ fn get_system_service_known_folder(known_folder_id: *const GUID) -> std::io::Res )); } - let known_folder = - get_known_folder_path(known_folder_id, KF_FLAG_DEFAULT as u32, lsass_token); + let known_folder = get_known_folder_path(known_folder_id, KF_FLAG_DEFAULT, lsass_token); unsafe { CloseHandle(lsass_token) }; known_folder @@ -173,7 +172,7 @@ fn adjust_token_privilege( fn get_known_folder_path( folder_id: *const GUID, - flags: u32, + flags: i32, user_token: HANDLE, ) -> std::io::Result<PathBuf> { let mut folder_path: PWSTR = ptr::null_mut(); diff --git a/talpid-core/Cargo.toml b/talpid-core/Cargo.toml index 922958259f..b2c04dac53 100644 --- a/talpid-core/Cargo.toml +++ b/talpid-core/Cargo.toml @@ -87,11 +87,12 @@ memoffset = "0.6" windows-service = "0.5.0" [target.'cfg(windows)'.dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_Foundation", "Win32_Globalization", "Win32_Security", + "Win32_Storage_FileSystem", "Win32_System_Com", "Win32_System_Diagnostics_ToolHelp", "Win32_System_Ioctl", diff --git a/talpid-core/src/routing/windows.rs b/talpid-core/src/routing/windows.rs index b391184f1a..fad8540ecd 100644 --- a/talpid-core/src/routing/windows.rs +++ b/talpid-core/src/routing/windows.rs @@ -8,7 +8,7 @@ use futures::{ StreamExt, }; use std::{collections::HashSet, net::IpAddr}; -use windows_sys::Win32::NetworkManagement::IpHelper::NET_LUID_LH; +use windows_sys::Win32::NetworkManagement::Ndis::NET_LUID_LH; use winnet::WinNetAddrFamily; /// Windows routing errors. diff --git a/talpid-core/src/split_tunnel/windows/driver.rs b/talpid-core/src/split_tunnel/windows/driver.rs index a3eb338c8c..b03d8b72af 100644 --- a/talpid-core/src/split_tunnel/windows/driver.rs +++ b/talpid-core/src/split_tunnel/windows/driver.rs @@ -26,17 +26,14 @@ use talpid_types::ErrorExt; use windows_sys::Win32::{ Foundation::{ ERROR_ACCESS_DENIED, ERROR_FILE_NOT_FOUND, ERROR_INVALID_PARAMETER, ERROR_IO_PENDING, - HANDLE, NTSTATUS, WAIT_FAILED, + HANDLE, NTSTATUS, WAIT_ABANDONED, WAIT_ABANDONED_0, WAIT_FAILED, WAIT_OBJECT_0, }, Networking::WinSock::{IN6_ADDR, IN_ADDR}, Storage::FileSystem::FILE_FLAG_OVERLAPPED, System::{ Diagnostics::ToolHelp::TH32CS_SNAPPROCESS, Ioctl::{FILE_ANY_ACCESS, METHOD_BUFFERED, METHOD_NEITHER}, - Threading::{ - WaitForMultipleObjects, WaitForSingleObject, WAIT_ABANDONED, WAIT_ABANDONED_0, - WAIT_OBJECT_0, - }, + Threading::{WaitForMultipleObjects, WaitForSingleObject}, WindowsProgramming::INFINITE, IO::{DeviceIoControl, GetOverlappedResult, OVERLAPPED}, }, diff --git a/talpid-core/src/split_tunnel/windows/mod.rs b/talpid-core/src/split_tunnel/windows/mod.rs index ed5102ab45..0bde6ac435 100644 --- a/talpid-core/src/split_tunnel/windows/mod.rs +++ b/talpid-core/src/split_tunnel/windows/mod.rs @@ -30,7 +30,7 @@ use std::{ }; use talpid_types::{tunnel::ErrorStateCause, ErrorExt}; use windows_sys::Win32::{ - Foundation::ERROR_OPERATION_ABORTED, NetworkManagement::IpHelper::NET_LUID_LH, + Foundation::ERROR_OPERATION_ABORTED, NetworkManagement::Ndis::NET_LUID_LH, }; const DRIVER_EVENT_BUFFER_SIZE: usize = 2048; diff --git a/talpid-core/src/tunnel/openvpn/mod.rs b/talpid-core/src/tunnel/openvpn/mod.rs index 9643c83cc2..439427c8e6 100644 --- a/talpid-core/src/tunnel/openvpn/mod.rs +++ b/talpid-core/src/tunnel/openvpn/mod.rs @@ -35,7 +35,7 @@ use which; #[cfg(windows)] use widestring::U16CString; #[cfg(windows)] -use windows_sys::{core::GUID, Win32::NetworkManagement::IpHelper::NET_LUID_LH}; +use windows_sys::{core::GUID, Win32::NetworkManagement::Ndis::NET_LUID_LH}; #[cfg(windows)] mod wintun; diff --git a/talpid-core/src/tunnel/openvpn/wintun.rs b/talpid-core/src/tunnel/openvpn/wintun.rs index 5834587e59..92a670aa66 100644 --- a/talpid-core/src/tunnel/openvpn/wintun.rs +++ b/talpid-core/src/tunnel/openvpn/wintun.rs @@ -14,7 +14,7 @@ use windows_sys::{ core::GUID, Win32::{ Foundation::{HINSTANCE, NO_ERROR}, - NetworkManagement::IpHelper::{ConvertInterfaceLuidToGuid, NET_LUID_LH}, + NetworkManagement::{IpHelper::ConvertInterfaceLuidToGuid, Ndis::NET_LUID_LH}, System::{ LibraryLoader::{ FreeLibrary, GetProcAddress, LoadLibraryExW, LOAD_WITH_ALTERED_SEARCH_PATH, diff --git a/talpid-core/src/tunnel/windows.rs b/talpid-core/src/tunnel/windows.rs index 14206a0d83..cb1cea345c 100644 --- a/talpid-core/src/tunnel/windows.rs +++ b/talpid-core/src/tunnel/windows.rs @@ -1,7 +1,7 @@ use crate::windows::{get_ip_interface_entry, set_ip_interface_entry, AddressFamily}; use std::io; use windows_sys::Win32::{ - Foundation::ERROR_NOT_FOUND, NetworkManagement::IpHelper::NET_LUID_LH, + Foundation::ERROR_NOT_FOUND, NetworkManagement::Ndis::NET_LUID_LH, Networking::WinSock::RouterDiscoveryDisabled, }; diff --git a/talpid-core/src/tunnel/wireguard/wireguard_go.rs b/talpid-core/src/tunnel/wireguard/wireguard_go.rs index d78e422697..60705d324f 100644 --- a/talpid-core/src/tunnel/wireguard/wireguard_go.rs +++ b/talpid-core/src/tunnel/wireguard/wireguard_go.rs @@ -168,7 +168,7 @@ impl WgGoTunnel { let has_ipv6 = config.tunnel.addresses.iter().any(|addr| addr.is_ipv6()); let setup_handle = tokio::spawn(async move { - use windows_sys::Win32::NetworkManagement::IpHelper::NET_LUID_LH; + use windows_sys::Win32::NetworkManagement::Ndis::NET_LUID_LH; let luid = NET_LUID_LH { Value: interface_luid, }; @@ -214,8 +214,8 @@ impl WgGoTunnel { default_route: winnet::WinNetDefaultRoute, _ctx: *mut libc::c_void, ) { - use windows_sys::Win32::NetworkManagement::IpHelper::{ - ConvertInterfaceLuidToIndex, NET_LUID_LH, + use windows_sys::Win32::NetworkManagement::{ + IpHelper::ConvertInterfaceLuidToIndex, Ndis::NET_LUID_LH, }; use winnet::WinNetDefaultRouteChangeEventType::*; diff --git a/talpid-core/src/tunnel/wireguard/wireguard_nt.rs b/talpid-core/src/tunnel/wireguard/wireguard_nt.rs index b0ffab20fa..08a75fd887 100644 --- a/talpid-core/src/tunnel/wireguard/wireguard_nt.rs +++ b/talpid-core/src/tunnel/wireguard/wireguard_nt.rs @@ -28,7 +28,7 @@ use windows_sys::{ core::GUID, Win32::{ Foundation::{BOOL, ERROR_MORE_DATA, HINSTANCE}, - NetworkManagement::IpHelper::NET_LUID_LH, + NetworkManagement::Ndis::NET_LUID_LH, Networking::WinSock::{ ADDRESS_FAMILY, AF_INET, AF_INET6, IN6_ADDR, IN_ADDR, SOCKADDR_INET, }, diff --git a/talpid-core/src/windows/mod.rs b/talpid-core/src/windows/mod.rs index 13efa824f0..d853991707 100644 --- a/talpid-core/src/windows/mod.rs +++ b/talpid-core/src/windows/mod.rs @@ -24,9 +24,9 @@ use windows_sys::{ GetIpInterfaceEntry, GetUnicastIpAddressEntry, GetUnicastIpAddressTable, InitializeUnicastIpAddressEntry, MibAddInstance, NotifyIpInterfaceChange, SetIpInterfaceEntry, MIB_IPINTERFACE_ROW, MIB_UNICASTIPADDRESS_ROW, - MIB_UNICASTIPADDRESS_TABLE, NET_LUID_LH, + MIB_UNICASTIPADDRESS_TABLE, }, - Ndis::NDIS_IF_MAX_STRING_SIZE, + Ndis::{IF_MAX_STRING_SIZE, NET_LUID_LH}, }, Networking::WinSock::{ IpDadStateDeprecated, IpDadStateDuplicate, IpDadStateInvalid, IpDadStatePreferred, @@ -431,7 +431,7 @@ pub fn luid_from_alias<T: AsRef<OsStr>>(alias: T) -> io::Result<NET_LUID_LH> { /// Returns the alias of an interface given its LUID. pub fn alias_from_luid(luid: &NET_LUID_LH) -> io::Result<OsString> { - let mut buffer = [0u16; NDIS_IF_MAX_STRING_SIZE as usize + 1]; + let mut buffer = [0u16; IF_MAX_STRING_SIZE as usize + 1]; let status = unsafe { ConvertInterfaceLuidToAlias(luid, &mut buffer[0] as *mut _, buffer.len()) }; if status != NO_ERROR as i32 { diff --git a/talpid-openvpn-plugin/Cargo.toml b/talpid-openvpn-plugin/Cargo.toml index 6a7e080ce8..49e577c5cb 100644 --- a/talpid-openvpn-plugin/Cargo.toml +++ b/talpid-openvpn-plugin/Cargo.toml @@ -32,7 +32,7 @@ tonic-build = { version = "0.8", default-features = false, features = ["transpor winres = "0.1" [target.'cfg(windows)'.build-dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_System_SystemServices", ] diff --git a/talpid-platform-metadata/Cargo.toml b/talpid-platform-metadata/Cargo.toml index 170e88c74d..2710451c02 100644 --- a/talpid-platform-metadata/Cargo.toml +++ b/talpid-platform-metadata/Cargo.toml @@ -13,7 +13,7 @@ rs-release = "0.1.7" talpid-dbus = { path = "../talpid-dbus" } [target.'cfg(target_os = "windows")'.dependencies.windows-sys] -version = "0.36.1" +version = "0.42.0" features = [ "Win32_Foundation", "Win32_System_LibraryLoader", |
