summaryrefslogtreecommitdiffhomepage
path: root/Cargo.toml
blob: d86354da7d8d7e9c2600956c7fa75257095b8ca5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
[workspace.package]
authors = ["Mullvad VPN"]
repository = "https://github.com/mullvad/mullvadvpn-app/"
license = "GPL-3.0-only"
edition = "2024"
# Must be less than or equal to `channel` in `rust-toolchain.toml`
rust-version = "1.88.0"

[workspace]
resolver = "2"
exclude = [ "ci/ios/test-router/raas" ]
members = [
  "android/translations-converter",
  "desktop/packages/nseventforwarder",
  "desktop/packages/windows-utils",
  "mullvad-api",
  "mullvad-cli",
  "mullvad-daemon",
  "mullvad-encrypted-dns-proxy",
  "mullvad-exclude",
  "mullvad-fs",
  "mullvad-ios",
  "mullvad-jni",
  "mullvad-leak-checker",
  "mullvad-management-interface",
  "mullvad-masque-proxy",
  "mullvad-nsis",
  "mullvad-paths",
  "mullvad-problem-report",
  "mullvad-relay-selector",
  "mullvad-setup",
  "mullvad-types",
  "mullvad-types/intersection-derive",
  "mullvad-update",
  "mullvad-update/mullvad-release",
  "mullvad-version",
  "talpid-core",
  "talpid-dbus",
  "talpid-future",
  "talpid-macos",
  "talpid-net",
  "talpid-openvpn",
  "talpid-openvpn-plugin",
  "talpid-platform-metadata",
  "talpid-routing",
  "talpid-time",
  "talpid-tunnel",
  "talpid-tunnel-config-client",
  "talpid-windows",
  "talpid-wireguard",
  "tunnel-obfuscation",
  "wireguard-go-rs",
  "windows-installer",
  "installer-downloader",
]
# Default members dictate what is built when running `cargo build` in the root directory.
# This is set to a minimal set of packages to speed up the build process and avoid building
# crates which might not compile without additional input, such as the `windows-installer` crate.
# To build or test everything, add `--workspace` to your cargo commands.
default-members = ["mullvad-cli", "mullvad-daemon", "mullvad-version", "mullvad-problem-report"]

# Keep all lints in sync with `test/Cargo.toml`
[workspace.lints.rust]
# Security
non_ascii_idents = "forbid"

# Deny old style Rust
rust_2018_idioms = { level = "deny", priority = -1 }
macro_use_extern_crate = "deny"
absolute_paths_not_starting_with_crate = "deny"

# Easy to read style and opinionated best practices
explicit_outlives_requirements = "warn"
missing_abi = "deny"
unused_lifetimes = "warn"
unused_macro_rules = "warn"
single_use_lifetimes = "warn"


[workspace.lints.clippy]
unused_async = "deny"
undocumented_unsafe_blocks = "warn"
implicit_clone = "warn"

[workspace.dependencies]
dirs = "6.0.0"
tokio = { version = "1.44" }
tokio-util = "0.7"
parity-tokio-ipc = "0.9"
futures = "0.3.15"
vec1 = "1.12"
sha2 = "0.10"
chrono = { version = "0.4.26", default-features = false }
clap = { version = "4.4.18", features = ["cargo", "derive"] }
once_cell = "1.16"
serde = "1.0.204"
serde_json = "1.0.122"
widestring = "1.2"
windows = "0.61.0"
windows-sys = "0.61.0"
winreg = "0.55"
nix = "0.30.1"
strum = { version = "0.27" }
rand = "0.9"

# Networking
pnet_packet = "0.35.0"
ipnetwork = "0.21.1"
tun = { version = "0.5.5", features = ["async"] }
socket2 = "0.5.7"
reqwest = { version = "0.12.23", default-features = false, features = ["rustls-tls"] }

rtnetlink = "0.18"
netlink-packet-core = "0.8.0"
netlink-packet-route = "0.25"
netlink-proto = "0.12"
netlink-sys = "0.8.3"

# Hickory & DNS
hickory-proto = "0.24.3"
hickory-resolver = "0.24.3"
hickory-server = { version = "0.24.3", features = ["resolver"] }

# Tonic and related crates
tonic = "0.13.1"
tonic-build = { version = "0.13.1", default-features = false }
tower = { version = "0.5.1", features = ["util"] }
prost = "0.13.3"
prost-types = "0.13.3"
hyper-util = { version = "0.1.8", features = [
  "client",
  "client-legacy",
  "http2",
  "http1",
] }

# Errors and logging
env_logger = "0.11.7"
thiserror = "2.0"
anyhow = "1.0"
log = "0.4"
fern = { version = "0.6", default-features = false }

# Shadowsocks
shadowsocks = "1.20.3"
shadowsocks-service = "1.20.3"

itertools = "0.14"

# Test dependencies
proptest = "1.4"
insta = { version = "1.42", features = ["yaml"] }

[profile.release]
opt-level = "s"
lto = true
strip = true

# Selectively optimize packages where we know it makes a difference
[profile.release.package]
boringtun.opt-level = 3
pqcrypto-hqc.opt-level = 3
quinn-proto.opt-level = 3
quinn-udp.opt-level = 3
quinn.opt-level = 3
mullvad-masque-proxy.opt-level = 3
ring.opt-level = 3

[profile.release-debuginfo]
inherits = "release"
debug = true
strip = false