Skip to content

fix(deps): move lettre to 0.11.24, which fixes six SMTP advisories that fail cargo deny - #312

Merged
aRustyDev merged 1 commit into
mainfrom
fix/lettre-0-11-24
Nov 18, 2026
Merged

aRustyDev merged 1 commit into
mainfrom
fix/lettre-0-11-24

Conversation

@aRustyDev

Copy link
Copy Markdown
Owner

lettre 0.11.23, which main locks, now has six RUSTSEC advisories (all fixed in 0.11.24), so cargo deny check advisories fails. One of them, RUSTSEC-2026-0560, lets a man-in-the-middle forge SMTP replies on a STARTTLS connection; the others are SMTP command injection by a bare LF or CR, two panics on malformed input, a message sent to the wrong address for a quoted local part, and an unbounded reply buffer. The SMTP adapter (thrust-adapters-selfhosted, used by thrust-server) is the only user.

The security / deny job runs only when a pull request changes Cargo.lock, which is why main itself was green. #310 changes the lockfile (workspace-internal dev-dependency edges), and security / deny failed on it with these six errors and nothing else (ci run 44368874336; every other job of that run passed). Any pull request that touches the lockfile will fail the same way until this lands, so #310 is waiting for it.

The change

Cargo.lock, two lines: lettre's version and checksum. cargo update -p lettre also rewrote one unrelated line (tempfile's getrandom, 0.4.3 to 0.3.4); I put it back so the diff is the one package, and scripts/check-cargo-lock.sh agrees the lockfile is what cargo writes.

What was run

On this Mac, on this branch:

  • cargo deny check: advisories, bans, licenses and sources all ok. The control is the same check on 0.11.23: it failed with those six errors in the run above.
  • The SMTP adapter's tests against a real SMTP server in Docker (smtp_sink, 7 tests: STARTTLS required with the relay's certificate checked, implicit TLS, a wrong login, a certificate for the wrong host, the server's own refusals): 7 of 7 pass on 0.11.24.

Not run here: the rest of CI, which runs on this pull request.

🤖 Generated with Claude Code

…at fail cargo deny

`cargo deny check advisories` began to fail on 2026-11-18 against lettre 0.11.23, the version main locks (thrust-adapters-selfhosted,
the SMTP adapter, used by thrust-server). Six advisories, all fixed in 0.11.24:

- STARTTLS response injection lets a man-in-the-middle forge SMTP replies (RUSTSEC-2026-0560; only `Tls::Required` and
  `Tls::Opportunistic` connections, not implicit TLS)
- missing dot-stuffing after a bare LF or CR allows SMTP command injection
- a panic on an EHLO reply line of only white space
- messages for an address with a quoted local part are sent to a different address
- a panic on a mailbox display name containing CR or LF
- unbounded buffering of an SMTP reply

It was found because the `security / deny` job runs only when a pull request changes Cargo.lock; #310 did (dev-dependency edges inside the
workspace), and the job failed there on lettre alone. Any pull request that touches the lockfile fails the same way until this lands.

The change is one package: `cargo update -p lettre`, with the one unrelated line it also rewrote (tempfile's getrandom, 0.4.3 to 0.3.4)
put back, so the diff is lettre's version and checksum. `scripts/check-cargo-lock.sh` agrees the lockfile is what cargo writes.

Verified on this Mac:
- `cargo deny check`: advisories, bans, licenses and sources all ok. The control is the same check on lettre 0.11.23, which failed with
  those six errors in CI run 44368874336.
- the SMTP adapter's own tests against a real server in Docker (`smtp_sink`, 7 tests, which include STARTTLS required with the relay's
  certificate checked, implicit TLS, a wrong login, the server's own refusals): 7 of 7 pass on 0.11.24.

Not run: the rest of CI (it runs on the pull request).

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@aRustyDev
aRustyDev temporarily deployed to preview-control-plane November 18, 2026 18:40 — with GitHub Actions Inactive
@socket-security

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatedcargo/​lettre@​0.11.23 ⏵ 0.11.2410010093100100

View full report

@aRustyDev
aRustyDev enabled auto-merge (squash) November 18, 2026 18:56
@aRustyDev
aRustyDev merged commit 82aabb2 into main Nov 18, 2026
45 checks passed
@aRustyDev
aRustyDev deleted the fix/lettre-0-11-24 branch November 18, 2026 18:58
aRustyDev added a commit that referenced this pull request Nov 18, 2026
Main moved four commits while #310 was open (#307, #308, #309 and the lettre fix #312), and two files conflicted:

- crates/adapters/postgres/src/lib.rs: #308 made `Migration` borrow its strings (`Migration<'a>`), and this branch added migration 0020 to
  the list. The list is `[Migration<'static>; 20]`: #308's type, this branch's twentieth entry.
- docs/src/testing/status.md: #309 rewrote the G-46 row and this branch added G-47 after it. G-46 is main's row, byte for byte
  (compared with `diff`), and G-47 follows it.

Merged, not rebased, because a force-push is blocked on this repository and #310 is already published.

The lettre bump of #312 comes in with the merge, which is what turns the `security / deny` job green on this branch (it failed on lettre
0.11.23 alone).

Checked on the merged tree before this commit: no conflict markers left, `scripts/check-contract-counts.sh` (74, 6; stage 2: 68, 4),
`cargo fmt --all --check`, `cargo clippy --workspace --all-targets -- -D warnings` and the wasm32 clippy of the Worker crates. The
test batteries are re-run on the merge commit and listed in the pull request.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>

This branch was previously deployed

1 inactive deployment
preview-control-plane — 49df4c92 Deployed Nov 18, 2026 by aRustyDev via reconcile #155
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant