chore(deps): update rust crate tokio to v1.53.3 [security] #40

Merged
martin merged 1 commit from renovate/crate-tokio-vulnerability into main 2026-10-24 14:38:46 +00:00
Member

This PR contains the following updates:

Package Type Update Change
tokio (source) workspace.dependencies patch 1.53.2 → 1.53.3

RUSTSEC-2026-0386

More information

Details

tokio::io::unix::AsyncFd provides safe constructors (new, with_interest, try_new, and try_with_interest) that accept any T: AsRawFd rather than requiring proof of ownership or validity of the file descriptor. Because RawFd implements AsRawFd, safe code can construct an AsyncFd from an arbitrary or closed file descriptor, or close/replace the underlying file descriptor while the AsyncFd is still alive.

This violates I/O safety in two ways:

  1. AsyncFd<T> implements AsFd for all T: AsRawFd by calling BorrowedFd::borrow_raw(self.as_raw_fd()), allowing safe code to obtain an arbitrary BorrowedFd<'_> without owning the file descriptor.
  2. Tokio's I/O driver stores a pointer to an internal allocation in the epoll/kqueue user data for registered file descriptors. If the underlying file descriptor is duplicated and then closed while an AsyncFd is alive, and the OS reuses that file descriptor number for a another IO resource on the same runtime, dropping the first AsyncFd deregisters the reused file descriptor number and frees the first while the original file description remains registered in epoll, leading to a use-after-free when a readiness event fires.

Starting in Tokio 1.51.6, 1.53.3, and 1.54.0, AsyncFd::new, AsyncFd::with_interest, AsyncFd::try_new, and AsyncFd::try_with_interest are deprecated in favor of the unsafe constructors AsyncFd::register and AsyncFd::register_with_interest. Callers must ensure that the file descriptor remains valid, open, and unchanged for the lifetime of the AsyncFd.

Severity

Unknown

References

This data is provided by OSV and the Rust Advisory Database (CC0 1.0).


Release Notes

tokio-rs/tokio (tokio)

v1.53.3: Tokio v1.53.3

Compare Source

1.53.3 (October 13th, 2026)

Added
  • io: add AsyncFd::register and AsyncFd::register_with_interest (#​8587)
Changed
  • io: deprecate AsyncFd::{new, with_interest, try_new, try_with_interest} (#​8587)
Fixed
  • io: wake and drop DuplexStream wakers outside the lock (#​8618)
  • macros: avoid unreachable_code in join! and try_join! for Infallible (#​8518)
  • runtime: fix paused time auto-advancing when I/O wakes a task on current_thread (#​8595)
  • sync: wake waiters outside the lock when closing a semaphore (#​8529)
  • test: fix several flaky tests (#​8196, #​8427, #​8609)
Fixed (unstable)
  • rt: keep io_uring op alive when submission fails after push (#​8185)

Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate CLI.

This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [tokio](https://tokio.rs) ([source](https://github.com/tokio-rs/tokio)) | workspace.dependencies | patch | `1.53.2` → `1.53.3` | --- ### `AsyncFd::new` and related constructors violate I/O safety [RUSTSEC-2026-0386](https://rustsec.org/advisories/RUSTSEC-2026-0386.html) <details> <summary>More information</summary> #### Details `tokio::io::unix::AsyncFd` provides safe constructors (`new`, `with_interest`, `try_new`, and `try_with_interest`) that accept any `T: AsRawFd` rather than requiring proof of ownership or validity of the file descriptor. Because `RawFd` implements `AsRawFd`, safe code can construct an `AsyncFd` from an arbitrary or closed file descriptor, or close/replace the underlying file descriptor while the `AsyncFd` is still alive. This violates I/O safety in two ways: 1. `AsyncFd<T>` implements `AsFd` for all `T: AsRawFd` by calling `BorrowedFd::borrow_raw(self.as_raw_fd())`, allowing safe code to obtain an arbitrary `BorrowedFd<'_>` without owning the file descriptor. 2. Tokio's I/O driver stores a pointer to an internal allocation in the `epoll`/`kqueue` user data for registered file descriptors. If the underlying file descriptor is duplicated and then closed while an `AsyncFd` is alive, and the OS reuses that file descriptor number for a another IO resource on the same runtime, dropping the first `AsyncFd` deregisters the reused file descriptor number and frees the first while the original file description remains registered in `epoll`, leading to a use-after-free when a readiness event fires. Starting in Tokio 1.51.6, 1.53.3, and 1.54.0, `AsyncFd::new`, `AsyncFd::with_interest`, `AsyncFd::try_new`, and `AsyncFd::try_with_interest` are deprecated in favor of the `unsafe` constructors `AsyncFd::register` and `AsyncFd::register_with_interest`. Callers must ensure that the file descriptor remains valid, open, and unchanged for the lifetime of the `AsyncFd`. #### Severity Unknown #### References - [https://crates.io/crates/tokio](https://crates.io/crates/tokio) - [https://rustsec.org/advisories/RUSTSEC-2026-0386.html](https://rustsec.org/advisories/RUSTSEC-2026-0386.html) - [https://github.com/tokio-rs/tokio/pull/8587](https://github.com/tokio-rs/tokio/pull/8587) - [https://github.com/tokio-rs/tokio/issues/8538](https://github.com/tokio-rs/tokio/issues/8538) - [https://github.com/tokio-rs/tokio/issues/8539](https://github.com/tokio-rs/tokio/issues/8539) This data is provided by [OSV](https://osv.dev/vulnerability/RUSTSEC-2026-0386) and the [Rust Advisory Database](https://github.com/RustSec/advisory-db) ([CC0 1.0](https://github.com/rustsec/advisory-db/blob/main/LICENSE.txt)). </details> --- ### Release Notes <details> <summary>tokio-rs/tokio (tokio)</summary> ### [`v1.53.3`](https://github.com/tokio-rs/tokio/releases/tag/tokio-1.53.3): Tokio v1.53.3 [Compare Source](https://github.com/tokio-rs/tokio/compare/tokio-1.53.2...tokio-1.53.3) ### 1.53.3 (October 13th, 2026) ##### Added - io: add `AsyncFd::register` and `AsyncFd::register_with_interest` ([#&#8203;8587]) ##### Changed - io: deprecate `AsyncFd::{new, with_interest, try_new, try_with_interest}` ([#&#8203;8587]) ##### Fixed - io: wake and drop `DuplexStream` wakers outside the lock ([#&#8203;8618]) - macros: avoid `unreachable_code` in `join!` and `try_join!` for `Infallible` ([#&#8203;8518]) - runtime: fix paused time auto-advancing when I/O wakes a task on `current_thread` ([#&#8203;8595]) - sync: wake waiters outside the lock when closing a semaphore ([#&#8203;8529]) - test: fix several flaky tests ([#&#8203;8196], [#&#8203;8427], [#&#8203;8609]) ##### Fixed (unstable) - rt: keep `io_uring` op alive when submission fails after push ([#&#8203;8185]) [#&#8203;8185]: https://github.com/tokio-rs/tokio/pull/8185 [#&#8203;8196]: https://github.com/tokio-rs/tokio/pull/8196 [#&#8203;8427]: https://github.com/tokio-rs/tokio/pull/8427 [#&#8203;8518]: https://github.com/tokio-rs/tokio/pull/8518 [#&#8203;8529]: https://github.com/tokio-rs/tokio/pull/8529 [#&#8203;8587]: https://github.com/tokio-rs/tokio/pull/8587 [#&#8203;8595]: https://github.com/tokio-rs/tokio/pull/8595 [#&#8203;8609]: https://github.com/tokio-rs/tokio/pull/8609 [#&#8203;8618]: https://github.com/tokio-rs/tokio/pull/8618 </details> --- ### Configuration 📅 **Schedule**: (UTC) - Branch creation - At any time (no schedule defined) - Automerge - At any time (no schedule defined) 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate CLI](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC43OS4yIiwidXBkYXRlZEluVmVyIjoiNDQuNzkuMiIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiZGVwZW5kZW5jaWVzIiwidnVsbmVyYWJpbGl0eSJdfQ==-->
chore(deps): update rust crate tokio to v1.53.3 [security]
All checks were successful
ci/woodpecker/pr/pr-review Pipeline was successful
ci/woodpecker/pr/global-rust-verify Pipeline was successful
e8de739fed
martin force-pushed renovate/crate-tokio-vulnerability from e8de739fed
All checks were successful
ci/woodpecker/pr/pr-review Pipeline was successful
ci/woodpecker/pr/global-rust-verify Pipeline was successful
to 0fb9658eae
All checks were successful
ci/woodpecker/pr/pr-review Pipeline was successful
ci/woodpecker/push/renovate-lint Pipeline was successful
ci/woodpecker/pr/global-rust-verify Pipeline was successful
2026-10-24 11:59:31 +00:00
Compare
Author
Member

Edited/Blocked Notification

Renovate will not automatically rebase this PR, because it does not recognize the last commit author and assumes somebody else may have edited the PR.

You can manually request rebase by checking the rebase/retry box above.

⚠️ Warning: custom changes will be lost.

### Edited/Blocked Notification Renovate will not automatically rebase this PR, because it does not recognize the last commit author and assumes somebody else may have edited the PR. You can manually request rebase by checking the rebase/retry box above. ⚠️ **Warning**: custom changes will be lost.
martin force-pushed renovate/crate-tokio-vulnerability from 0fb9658eae
All checks were successful
ci/woodpecker/pr/pr-review Pipeline was successful
ci/woodpecker/push/renovate-lint Pipeline was successful
ci/woodpecker/pr/global-rust-verify Pipeline was successful
to 9c413fb350
All checks were successful
ci/woodpecker/pr/pr-review Pipeline was successful
ci/woodpecker/pr/global-rust-verify Pipeline was successful
2026-10-24 13:56:02 +00:00
Compare
martin merged commit 7baeb64bcb into main 2026-10-24 14:38:46 +00:00
martin deleted branch renovate/crate-tokio-vulnerability 2026-10-24 14:38:48 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Personal/woodpecker-extension!40
No description provided.