Commit 6dfb043
committed
bluebubbles: address Greptile review (P1 auth-header forwarding, P2 cache fingerprint)
Greptile findings from the first review cycle on #68234 — both real, both
asymptomatic under today's query-string auth default but blocking for the
header-auth flip (#66869).
P1: Thread auth-decorated headers through multipart + media paths.
- `postMultipartFormData` now accepts an optional `extraHeaders` param and
merges caller headers with its own Content-Type (Content-Type always wins
so the multipart boundary stays authoritative).
- `client.requestMultipart` forwards `prepared.init.headers` — attachment
uploads and group-icon sets keep working under header auth.
- `client.downloadAttachment` fetchImpl merges `prepared.init.headers` with
runtime-supplied headers (runtime wins on conflict, e.g. Range for partial
reads) — attachment downloads via `fetchRemoteMedia` now carry auth too.
P2: Include auth strategy in the client cache fingerprint.
- `BlueBubblesAuthStrategy` gets a stable `id` field
(`query-string` / `header:<name>`).
- Built-in factories set it; the cache key is now
`{baseUrl}|{password}|{authStrategyId}` so different strategies for the
same account + credential no longer silently share a cached instance.
Three new regression tests pin the above behavior (465 total, was 462).
Full BB suite green, lint clean.1 parent 783cad5 commit 6dfb043
3 files changed
Lines changed: 125 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
191 | 191 | | |
192 | 192 | | |
193 | 193 | | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
194 | 241 | | |
195 | 242 | | |
196 | 243 | | |
| |||
494 | 541 | | |
495 | 542 | | |
496 | 543 | | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
497 | 561 | | |
498 | 562 | | |
499 | 563 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
45 | 52 | | |
46 | 53 | | |
47 | 54 | | |
48 | 55 | | |
49 | 56 | | |
| 57 | + | |
50 | 58 | | |
51 | 59 | | |
52 | 60 | | |
| |||
58 | 66 | | |
59 | 67 | | |
60 | 68 | | |
| 69 | + | |
61 | 70 | | |
62 | 71 | | |
63 | 72 | | |
| |||
265 | 274 | | |
266 | 275 | | |
267 | 276 | | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
268 | 280 | | |
269 | 281 | | |
270 | 282 | | |
| |||
283 | 295 | | |
284 | 296 | | |
285 | 297 | | |
| 298 | + | |
286 | 299 | | |
287 | 300 | | |
288 | 301 | | |
| |||
387 | 400 | | |
388 | 401 | | |
389 | 402 | | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
390 | 410 | | |
391 | 411 | | |
392 | 412 | | |
393 | 413 | | |
394 | 414 | | |
395 | 415 | | |
396 | 416 | | |
397 | | - | |
398 | | - | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
399 | 424 | | |
400 | | - | |
| 425 | + | |
401 | 426 | | |
402 | 427 | | |
403 | | - | |
| 428 | + | |
| 429 | + | |
404 | 430 | | |
405 | 431 | | |
406 | 432 | | |
| |||
423 | 449 | | |
424 | 450 | | |
425 | 451 | | |
426 | | - | |
| 452 | + | |
427 | 453 | | |
428 | 454 | | |
429 | 455 | | |
430 | 456 | | |
431 | | - | |
432 | | - | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
433 | 466 | | |
434 | 467 | | |
435 | 468 | | |
| |||
447 | 480 | | |
448 | 481 | | |
449 | 482 | | |
| 483 | + | |
| 484 | + | |
450 | 485 | | |
451 | 486 | | |
452 | 487 | | |
| 488 | + | |
453 | 489 | | |
454 | 490 | | |
455 | 491 | | |
| |||
461 | 497 | | |
462 | 498 | | |
463 | 499 | | |
464 | | - | |
465 | 500 | | |
466 | 501 | | |
467 | 502 | | |
| |||
471 | 506 | | |
472 | 507 | | |
473 | 508 | | |
474 | | - | |
| 509 | + | |
475 | 510 | | |
476 | 511 | | |
477 | 512 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
21 | 28 | | |
22 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
23 | 39 | | |
24 | 40 | | |
25 | 41 | | |
26 | 42 | | |
27 | | - | |
28 | | - | |
29 | | - | |
| 43 | + | |
30 | 44 | | |
31 | 45 | | |
32 | 46 | | |
| |||
0 commit comments