Skip to main content

max / makenotwork

7.5 KB · 221 lines History Blame Raw
1 [package]
2 name = "makenotwork"
3 version = "0.11.1"
4 edition = "2024"
5 license-file = "LICENSE"
6 # Server binary: never published to a registry. Marks the crate private so
7 # supply-chain tooling (cargo-deny) treats its first-party path deps correctly.
8 publish = false
9
10 [features]
11 fast-tests = []
12
13 [dependencies]
14 # Async trait (for StorageBackend trait object)
15 async-trait = "0.1"
16
17 # Web framework
18 axum = { version = "0.8.8", features = ["macros"] }
19 axum-extra = { version = "0.12.6", features = ["cookie", "form", "query", "typed-header"] }
20
21 # OpenAPI spec generation
22 utoipa = { version = "5", features = ["axum_extras", "chrono", "uuid"] }
23 utoipa-axum = "0.2"
24 utoipa-swagger-ui = { version = "9", features = ["axum"] }
25 serde = { version = "1.0.228", features = ["derive"] }
26 serde_json = "1.0.149"
27 toml = "1.1"
28 tokio = { version = "1.50.0", features = ["macros", "rt-multi-thread", "net", "signal"] }
29 tokio-stream = { version = "0.1", features = ["sync"] }
30 tokio-util = { version = "0.7", features = ["io"] }
31 tower = "0.5.3"
32 tower-http = { version = "0.7.0", features = ["trace", "fs", "limit", "request-id", "propagate-header", "set-header"] }
33 tracing = "0.1.44"
34 tracing-subscriber = { version = "0.3.22", features = ["env-filter", "json"] }
35
36 # Templates
37 askama = "0.16.0"
38
39 # Environment & Configuration
40 dotenvy = "0.15.7"
41
42 # Database
43 sqlx = { version = "0.8.6", features = ["runtime-tokio", "postgres", "uuid", "chrono", "migrate", "macros"] }
44 uuid = { version = "1.22.0", features = ["v4", "serde"] }
45 chrono = { version = "0.4.44", features = ["serde"] }
46
47 # Authentication
48 argon2 = "0.5.3"
49 tower-sessions = { version = "0.14.0", features = ["axum-core"] }
50 tower-sessions-sqlx-store = { version = "0.15.0", features = ["postgres"] }
51
52 # Concurrent hash map (session touch cache)
53 dashmap = "6"
54
55 # Rate Limiting
56 tower_governor = "0.8.0"
57 governor = "0.10.4"
58
59 # JWT (SyncKit)
60 jsonwebtoken = { version = "10.4.0", features = ["rust_crypto"] }
61
62 # TOTP / 2FA
63 totp-rs = { version = "5.7", features = ["qr"] }
64
65 # WebAuthn / Passkeys
66 webauthn-rs = { version = "0.5", features = ["danger-allow-state-serialisation", "conditional-ui"] }
67 webauthn-rs-proto = "0.5"
68
69 # OpenSSL (transitive dep from git2, webauthn-rs: vendored for cross-compilation)
70 openssl = { version = "0.10", features = ["vendored"] }
71
72 # Security
73 rand = "0.10"
74 hmac = "0.13.0"
75 sha1 = "0.11.0"
76 sha2 = "0.11.0"
77 subtle = "2.6"
78 chacha20poly1305 = "0.11.0"
79 hex = "0.4.3"
80 base64 = "0.22.1"
81
82 # Temp files (content export)
83 tempfile = "3"
84
85 # File scanning
86 infer = "0.22"
87 goblin = "0.10"
88 zip = "8.2"
89 # Single-stream decompressors for archive-bomb detection (already in the tree
90 # transitively via `zip`; pinned to the resolved versions so no new build).
91 flate2 = "1"
92 bzip2 = "0.6"
93 xz2 = "0.1"
94 zstd = "0.13"
95 yara-x = "1.16"
96 fs2 = "0.4"
97 memmap2 = "0.9"
98
99 # CSV parsing (import system)
100 csv = "1.3"
101
102 # CLI
103 clap = { version = "4", features = ["derive"] }
104
105 # Logging (used by sqlx slow query config)
106 log = "0.4"
107
108 # Error handling
109 thiserror = "2.0.18"
110 anyhow = "1.0.102"
111 bytes = "1"
112
113 # Email validation (used at notify-me signup and guest-checkout entry points)
114 email_address = "0.2"
115
116 # Metrics
117 metrics = "0.24"
118 metrics-exporter-prometheus = { version = "0.18.1", default-features = false }
119
120 # Markdown rendering + documentation engine
121 docengine = { path = "../../Libraries/docengine", features = ["doc-loader", "directives", "frontmatter", "media-urls"] }
122 mnw-assumptions = { path = "../shared/mnw-assumptions" }
123
124 # Tag standard
125 tagtree = { path = "../shared/tagtree" }
126
127 # Shared theme palette + the bundled theme set (Tier 0 creator theming).
128 makeover = "2.3.0"
129
130 # Git source browser
131 git2 = { version = "0.21", features = ["vendored-libgit2"] }
132 syntect = { version = "5", default-features = false, features = ["default-syntaxes", "default-themes", "html", "regex-fancy"] }
133 regex = "1"
134 semver = "1"
135
136 # S3 Storage
137 s3-storage = { path = "../shared/s3-storage" }
138
139 # Stripe Payments: async-stripe 1.0.0-rc.6 (split into sub-crates).
140 # The umbrella `async-stripe` provides the HTTP client; resource types live in
141 # per-domain sub-crates. The `deserialize` feature on each resource crate is
142 # required to derive `serde::Deserialize` on Subscription, Invoice, etc: we
143 # parse them from webhook payloads ourselves (no built-in webhook helper in the
144 # rc line; see `payments::webhooks::verify_signature` for our HMAC check).
145 async-stripe = { version = "1.0.0-rc.6", features = ["default-tls"] }
146 async-stripe-shared = { version = "1.0.0-rc.6", features = ["deserialize"] }
147 async-stripe-billing = { version = "1.0.0-rc.6", features = ["deserialize", "subscription", "billing_portal_session"] }
148 async-stripe-checkout = { version = "1.0.0-rc.6", features = ["deserialize", "checkout_session"] }
149 async-stripe-connect = { version = "1.0.0-rc.6", features = ["deserialize", "account", "account_link", "transfer", "transfer_reversal"] }
150 async-stripe-core = { version = "1.0.0-rc.6", features = ["deserialize", "balance", "refund", "customer"] }
151 async-stripe-payment = { version = "1.0.0-rc.6", features = ["deserialize"] }
152 async-stripe-product = { version = "1.0.0-rc.6", features = ["deserialize", "product", "price"] }
153 async-stripe-types = { version = "1.0.0-rc.6", features = ["deserialize"] }
154 reqwest = { version = "0.13", features = ["json", "cookies", "form", "query"] }
155 urlencoding = "2.1.3"
156
157 # URL parsing
158 url = "2.5.8"
159 apple-codesign = { version = "0.29.0", default-features = false }
160 authenticode = { version = "0.6.0", features = ["std", "object"] }
161 x509-cert = "0.2.5"
162 const-oid = { version = "0.9", features = ["db"] }
163 object = { version = "0.39", features = ["pe"] }
164 ammonia = "4"
165 lightningcss = { version = "1.0.0-alpha.71", default-features = false, features = ["visitor"] }
166
167 [[bin]]
168 name = "mnw-admin"
169 path = "src/bin/mnw-admin.rs"
170
171 [dev-dependencies]
172 tower = { version = "0.5.3", features = ["util"] }
173 http-body-util = "0.1"
174 webauthn-authenticator-rs = { version = "0.5", features = ["softpasskey"] }
175 tempfile = "3"
176 proptest = "1"
177 wiremock = "0.6"
178 pom-contract = { path = "../shared/pom-contract" }
179
180 [profile.release]
181 # Drop the symbol table from the shipped binary. Release builds already carry no
182 # debuginfo, so this is purely the symbol table: measured 161.3 MiB -> 120.7 MiB
183 # on 0.10.19 (25.1%) for no runtime cost. Every tier rsyncs that difference on
184 # every promote. Nothing here reads a symbolized backtrace (no `backtrace` crate,
185 # no RUST_BACKTRACE in the unit file). If a panic ever does need symbolizing,
186 # rebuild the sha with `--config profile.release.strip=false`: the build is
187 # reproducible from the git sha the release was cut from.
188 strip = true
189
190 [lints.rust]
191 unused = "warn"
192 unreachable_pub = "warn"
193
194 [lints.clippy]
195 pedantic = { level = "warn", priority = -1 }
196 # Allow-list tuned from a measured breakdown across server/multithreaded/pter
197 # (2026-07-22). These are the high-churn / low-signal pedantic lints; everything
198 # else in `pedantic` stays a warning. Keep this block identical across repos.
199 module_name_repetitions = "allow"
200 # Doc lints. No docs-completeness push is underway.
201 missing_errors_doc = "allow"
202 missing_panics_doc = "allow"
203 doc_markdown = "allow"
204 # Numeric casts. Endemic and mostly intentional in size and byte math.
205 cast_possible_truncation = "allow"
206 cast_sign_loss = "allow"
207 cast_precision_loss = "allow"
208 cast_possible_wrap = "allow"
209 cast_lossless = "allow"
210 # Subjective structure and style nags. High churn, low signal.
211 must_use_candidate = "allow"
212 too_many_lines = "allow"
213 struct_excessive_bools = "allow"
214 similar_names = "allow"
215 items_after_statements = "allow"
216 single_match_else = "allow"
217 # Frequent false-positives in TUI and router-heavy code.
218 match_same_arms = "allow"
219 unnecessary_wraps = "allow"
220 type_complexity = "allow"
221