Skip to content

Update Rust crate socket2 to 0.6#522

Merged
taspelund merged 3 commits intomainfrom
renovate/socket2-0.x
Mar 24, 2026
Merged

Update Rust crate socket2 to 0.6#522
taspelund merged 3 commits intomainfrom
renovate/socket2-0.x

Conversation

@oxide-renovate
Copy link
Copy Markdown
Contributor

@oxide-renovate oxide-renovate Bot commented Jul 7, 2025

This PR contains the following updates:

Package Type Update Change
socket2 workspace.dependencies minor 0.50.6

Release Notes

rust-lang/socket2 (socket2)

v0.6.3

Compare Source

  • Added support for wasm32-wasip2.
  • Added Socket::(set_)ip_transparent_v6.
  • Added Socket::set_tcp_ack_frequency.
  • Support windows-sys v0.61 in addition to v0.60.

POTENTIALLY BREAKING The MSRV of windows-sys v0.61 is 1.71. To use socket2
with its MSRV of 1.70, please downgrade windows-sys to v0.60.x. This can be done
using: cargo update windows-sys --precise 0.60.2

v0.6.2

Compare Source

  • MsgHdr and MsgHdrMut are marked as transparent meaning both have the same
    layout as msghdr on Unix and WSAMSG on Windows
    (#​635).
  • Don't set SO_NOSIGPIPE when accepting sockets, this is inherited from the
    parent socket (#​632).
  • Fixes Socket::tcp_notsent_lowat by using the correct argument type
    (#​622).

v0.6.1

Compare Source

Added

  • Added support for Windows Registered I/O (RIO)
    (#​604).
  • Added support for TCP_NOTSENT_LOWAT on Linux via Socket::(set_)tcp_notsent_lowat
    (#​611).
  • Added support for SO_BUSY_POLL on Linux via Socket::set_busy_poll
    (#​607).
  • SockFilter::new is now a const function
    (#​609).

Changed

  • Updated the windows-sys dependency to version 0.60
    (#​605).

v0.6.0

Breaking changes

All IPv4 methods now have a _v4 suffix, IPv6 uses _v6. TCP methods have a
tcp_ prefix (looked better than a suffix).

Furthermore we removed all types from external libraries (i.e. libc or
windows-sys) from the public API, allowing us to update those without breaking
the API.

  • Renamed Socket::freebind_ipv6 to freebind_v6
    (#​592).
  • Renamed Socket::freebind to freebind_v4
    (#​592).
  • Renamed Socket::original_dst to original_dst_v4
    (#​592).
  • Renamed Socket::original_dst_ipv6 to original_dst_v6
    (#​592).
  • Bump MSRV to 1.70
    (#​597).
  • Use c_int from std::ffi instead of from libc
    (#​599,
    #​595).
  • SockAddr's methods now accept/return SockAddrStorage instead of
    sockaddr_storage/SOCKADDR_STORAGE
    (#​576):
    • new
    • try_init
    • as_ptr
    • as_storage
  • Add SockFilter, wrapper around libc::sock_filter, argument to
    Socket::attach_filter
    (#​581).
  • Various renames of TCP methods on Socket
    (#​592):
    • keepalive_time -> tcp_keepalive_time
    • keepalive_interval -> tcp_keepalive_interval
    • keepalive_retries -> tcp_keepalive_retries
    • nodelay -> tcp_nodelay
    • set_nodelay -> set_tcp_nodelay
    • tcp_mss -> mss
    • tcp_set_mss -> set_mss
    • tcp_cork -> cork
    • tcp_set_cork -> set_cork
    • tcp_quickack -> quickack
    • tcp_set_quickack -> set_quickack
    • thin_linear_timeouts -> tcp_thin_linear_timeouts.

Non-breaking changes

  • Added Socket::(set_)priority
    (#​588).
  • Added TCP retries on Windows
    (#​557).
  • Added SockAddrStorage, wrapper around sockaddr_storage/SOCKADDR_STORAGE
    for usage with SockAddr (instead of the types from libc/windows-sys)
    (#​576).
  • Implemented Socket::bind_device_by_index_{v4,v6} on Android and Linux
    (#​572).
  • Implemented Copy and Clone for InterfaceIndexOrAddress
    (#​571).
  • Updated to Windows-sys v0.59
    (#​579).
  • We now use OwnedFd/OwnedSocket internally for Socket
    (#​600).

Configuration

📅 Schedule: Branch creation - "after 8pm,before 6am" in timezone America/Los_Angeles, Automerge - "after 8pm,before 6am" in timezone America/Los_Angeles.

🚦 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 Renovate Bot.

@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch from 109655a to 934fda4 Compare July 17, 2025 03:30
@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch 3 times, most recently from 4f470e7 to 46e2b62 Compare September 13, 2025 03:06
@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch from 46e2b62 to f7f1080 Compare October 2, 2025 03:14
@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch from f7f1080 to 7671608 Compare December 3, 2025 05:50
@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch 2 times, most recently from d8544be to 7050a9d Compare January 8, 2026 04:15
@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch 2 times, most recently from d1603c8 to 56f4609 Compare February 12, 2026 04:30
@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch 2 times, most recently from 86a2998 to 84550fa Compare March 21, 2026 03:26
@oxide-renovate oxide-renovate Bot force-pushed the renovate/socket2-0.x branch from 84550fa to 55d0ade Compare March 24, 2026 16:45
@oxide-renovate
Copy link
Copy Markdown
Contributor Author

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.

@taspelund taspelund force-pushed the renovate/socket2-0.x branch from f00888e to 02539c1 Compare March 24, 2026 19:40
oxide-renovate Bot and others added 3 commits March 24, 2026 14:26
socket2 0.6 changed SockAddr::as_storage() to return an opaque
SockAddrStorage wrapper instead of libc::sockaddr_storage. Cast through
as_ptr() to obtain the sockaddr_storage that TcpMd5Sig expects, and
consolidate the two unsafe operations into a single block.
@taspelund taspelund force-pushed the renovate/socket2-0.x branch from 02539c1 to 3a280bf Compare March 24, 2026 20:27
@taspelund taspelund merged commit 2cd2867 into main Mar 24, 2026
15 checks passed
@taspelund taspelund deleted the renovate/socket2-0.x branch March 24, 2026 22:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant