Advisory

RUSTSEC-2025-0051

Also known as: GHSA-655h-hg88-5qmf

Summary

xcb::Connection::connect_to_fd* functions violate I/O safety

Details

The API of xcb::Connection has constructors which allow an arbitrary RawFd
to be used as a socket connection. On either failure of these constructors or
on the drop of Connection, it closes the associated file descriptor. Thus, a
program which uses an OwnedFd (such as a UnixStream) as the file descriptor
can close the file descriptor and continue to attempt using it or close an
already-closed file descriptor, violating I/O safety.

Starting in version 1.6.0, xcb provides Connection::connect_with_fd and
Connection::connect_with_fd_and_extensions as safe alternatives and
deprecates the problematic functions.

Severity

Not rated by the source.

Dates

Published
2025-08-05 12:00 UTC
Modified
2025-10-28 06:29 UTC

Affected packages and fixes

xcb

crates.io · All systems

Affected

  • introduced 0.0.0-0, fixed 1.6.0 (semver)

Fixed versions

1.6.0

Fix

  • Fixed version 1.6.0
    cargo update -p xcb --precise 1.6.0

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: RustSec Advisory Database · CC0-1.0

Sources & licences