Skip to content

Allow bind to both ipv4/ipv6 #5683

Closed
Closed

Description

Describe the feature you'd like supported

A AF_INET6 socket that is bound to a port with bind() function and a sockaddr_in6 structure can also receive ipv4 connections when

			DWORD ag = 0;
			setsockopt(X, IPPROTO_IPV6, IPV6_V6ONLY, (char*)&ag, 4);

is used.

Proposed solution

Why not having a QUIC_ADDRESS_FAMILY_BOTH into ListenerStart. This would help us avoid two listeners, one for 4 and one for 6.

Additional context

No response

Activity

  1. anrossi commented on Jan 6, 2026

    @anrossi
    Contributor

    MsQuic's listener is already a dual mode socket and receives both IPv4 and IPv6 traffic. See the document here:
    https://microsoft.github.io/msquic/msquicdocs/docs/api/ListenerStart.html#:~:text=The%20server%20application%20may,within%20the%20QUIC%20layer.

    Can you explain further how the existing dual mode socket is not meeting your needs?

  2. WindowsNT commented on Jan 6, 2026

    @WindowsNT
    Author

    QUIC_ADDR -> QUIC_ADDRESS_FAMILY_UNSPEC -> Dual mode? Or QUIC_ADDRESS_FAMILY_IPV6 ?

  3. locked and limited conversation to collaborators on Jan 16, 2026
  4. converted this issue into a discussion #5720 on Jan 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

feature request

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions