109 references to InterNetworkV6
IIS.Common.TestLib (2)
TestConnections.cs (2)
240if (addressFamily != AddressFamily.InterNetwork && addressFamily != AddressFamily.InterNetworkV6) 246var address = addressFamily == AddressFamily.InterNetworkV6
InMemory.FunctionalTests (2)
src\Servers\Kestrel\shared\test\TestConnection.cs (2)
60if (addressFamily != AddressFamily.InterNetwork && addressFamily != AddressFamily.InterNetworkV6) 66var address = addressFamily == AddressFamily.InterNetworkV6
Microsoft.AspNetCore.Grpc.JsonTranscoding (1)
Internal\JsonTranscodingServerCallContext.cs (1)
89case AddressFamily.InterNetworkV6:
Microsoft.AspNetCore.HttpOverrides (1)
IPNetwork.cs (1)
106AddressFamily.InterNetworkV6 => prefixLength <= 128,
Microsoft.AspNetCore.Rewrite (1)
PatternSegments\IsIPV6Segment.cs (1)
16return context.HttpContext.Connection.RemoteIpAddress.AddressFamily == AddressFamily.InterNetworkV6 ? "on" : "off";
Microsoft.AspNetCore.Server.HttpSys (3)
src\Shared\HttpSys\NativeInterop\SocketAddress.cs (3)
38if (Family == AddressFamily.InterNetworkV6) 81if (addressFamily == (ushort)AddressFamily.InterNetworkV6) 83var v6address = new SocketAddress(AddressFamily.InterNetworkV6, IPv6AddressSize);
Microsoft.AspNetCore.Server.IIS (3)
src\Shared\HttpSys\NativeInterop\SocketAddress.cs (3)
38if (Family == AddressFamily.InterNetworkV6) 81if (addressFamily == (ushort)AddressFamily.InterNetworkV6) 83var v6address = new SocketAddress(AddressFamily.InterNetworkV6, IPv6AddressSize);
Microsoft.AspNetCore.Server.Kestrel.Core (1)
Internal\Infrastructure\KestrelMetrics.cs (1)
335case AddressFamily.InterNetworkV6:
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (2)
src\Servers\Kestrel\shared\test\TestConnection.cs (2)
60if (addressFamily != AddressFamily.InterNetwork && addressFamily != AddressFamily.InterNetworkV6) 66var address = addressFamily == AddressFamily.InterNetworkV6
Microsoft.AspNetCore.Shared.Tests (3)
src\Shared\HttpSys\NativeInterop\SocketAddress.cs (3)
38if (Family == AddressFamily.InterNetworkV6) 81if (addressFamily == (ushort)AddressFamily.InterNetworkV6) 83var v6address = new SocketAddress(AddressFamily.InterNetworkV6, IPv6AddressSize);
Microsoft.Extensions.Diagnostics.ResourceMonitoring (2)
ResourceMonitoringOptionsCustomValidator.cs (1)
26|| (ipAddress.AddressFamily != AddressFamily.InterNetwork && ipAddress.AddressFamily != AddressFamily.InterNetworkV6))
Windows\Network\WindowsTcpStateInfo.cs (1)
38.Where(ip => IPAddress.TryParse(ip, out var ipAddress) && ipAddress.AddressFamily == AddressFamily.InterNetworkV6)
Microsoft.Extensions.ServiceDiscovery.Abstractions (1)
Internal\ServiceEndpointImpl.cs (1)
17IPEndPoint ip when ip.Port == 0 && ip.AddressFamily == System.Net.Sockets.AddressFamily.InterNetworkV6 => $"[{ip.Address}]",
Sockets.BindTests (12)
src\Servers\Kestrel\shared\test\TestConnection.cs (2)
60if (addressFamily != AddressFamily.InterNetwork && addressFamily != AddressFamily.InterNetworkV6) 66var address = addressFamily == AddressFamily.InterNetworkV6
src\Servers\Kestrel\shared\test\TransportTestHelpers\IPv6ScopeIdPresentConditionAttribute.cs (1)
27.Any(addressInfo => addressInfo.Address.AddressFamily == AddressFamily.InterNetworkV6 && addressInfo.Address.ScopeId != 0);
src\Servers\Kestrel\shared\test\TransportTestHelpers\IPv6SupportedConditionAttribute.cs (1)
24using (var socket = new Socket(AddressFamily.InterNetworkV6, SocketType.Stream, ProtocolType.Tcp))
src\Servers\Kestrel\test\BindTests\AddressRegistrationTests.cs (8)
573using (var socket = new Socket(AddressFamily.InterNetworkV6, SocketType.Stream, ProtocolType.Tcp)) 738ThrowsWhenBindingLocalhostToAddressInUse(AddressFamily.InterNetworkV6); 934var otherAddressFamily = addressFamily == AddressFamily.InterNetwork ? AddressFamily.InterNetworkV6 : AddressFamily.InterNetwork; 940using (var socket = new Socket(AddressFamily.InterNetworkV6, SocketType.Stream, ProtocolType.Tcp)) 976var otherAddressString = $"http://{(addressFamily == AddressFamily.InterNetworkV6 ? "127.0.0.1" : "[::1]")}:{port}"; 1076.Where(ip => ip.AddressFamily == AddressFamily.InterNetworkV6) 1124.Where(ip => ip.AddressFamily == AddressFamily.InterNetworkV6) 1160.Where(ip => ip.AddressFamily == AddressFamily.InterNetworkV6)
Sockets.FunctionalTests (4)
src\Servers\Kestrel\shared\test\TestConnection.cs (2)
60if (addressFamily != AddressFamily.InterNetwork && addressFamily != AddressFamily.InterNetworkV6) 66var address = addressFamily == AddressFamily.InterNetworkV6
src\Servers\Kestrel\shared\test\TransportTestHelpers\IPv6ScopeIdPresentConditionAttribute.cs (1)
27.Any(addressInfo => addressInfo.Address.AddressFamily == AddressFamily.InterNetworkV6 && addressInfo.Address.ScopeId != 0);
src\Servers\Kestrel\shared\test\TransportTestHelpers\IPv6SupportedConditionAttribute.cs (1)
24using (var socket = new Socket(AddressFamily.InterNetworkV6, SocketType.Stream, ProtocolType.Tcp))
System.Net.Http (1)
System\Net\Http\SocketsHttpHandler\SocksHelper.cs (1)
167Debug.Assert(hostIP.AddressFamily == AddressFamily.InterNetworkV6);
System.Net.NameResolution (3)
src\libraries\Common\src\System\Net\InteropIPAddressExtensions.Unix.cs (1)
18if (ipAddress.AddressFamily == AddressFamily.InterNetworkV6)
src\libraries\Common\src\System\Net\SocketProtocolSupportPal.cs (1)
13public static bool OSSupportsIPv6 { get; } = IsSupported(AddressFamily.InterNetworkV6) && !IsIPv6Disabled();
System\Net\Dns.cs (1)
324(address.AddressFamily != AddressFamily.InterNetworkV6 || SocketProtocolSupportPal.OSSupportsIPv6))
System.Net.NetworkInformation (3)
System\Net\NetworkInformation\IPAddressUtil.cs (1)
17if (address.AddressFamily == AddressFamily.InterNetworkV6)
System\Net\NetworkInformation\UnicastIPAddressInformation.cs (1)
73Debug.Assert((family == AddressFamily.InterNetwork) || (family == AddressFamily.InterNetworkV6));
System\Net\NetworkInformation\UnixNetworkInterface.cs (1)
39Sockets.AddressFamily.InterNetworkV6;
System.Net.Ping (6)
src\libraries\Common\src\System\Net\IPEndPointExtensions.cs (1)
15if (family == AddressFamily.InterNetworkV6)
src\libraries\Common\src\System\Net\RawSocketPermissions.cs (2)
11private static readonly Lazy<bool> s_canUseRawIPv6Sockets = new Lazy<bool>(() => CheckRawSocketPermissions(AddressFamily.InterNetworkV6)); 17addressFamily == AddressFamily.InterNetworkV6 ?
src\libraries\Common\src\System\Net\SocketProtocolSupportPal.cs (1)
13public static bool OSSupportsIPv6 { get; } = IsSupported(AddressFamily.InterNetworkV6) && !IsIPv6Disabled();
System\Net\NetworkInformation\Ping.cs (1)
744else if ((ip.AddressFamily == AddressFamily.InterNetworkV6 && !SocketProtocolSupportPal.OSSupportsIPv6))
System\Net\NetworkInformation\Ping.RawSocket.cs (1)
72if (addrFamily == AddressFamily.InterNetworkV6 && !SupportsDualMode)
System.Net.Primitives (11)
src\libraries\Common\src\System\Net\IPEndPointExtensions.cs (1)
15if (family == AddressFamily.InterNetworkV6)
src\libraries\Common\src\System\Net\SocketAddress.cs (2)
75AddressFamily.InterNetworkV6 => IPv6AddressSize, 103if (ipAddress.AddressFamily == AddressFamily.InterNetworkV6)
src\libraries\Common\src\System\Net\SocketAddressExtensions.cs (1)
14Debug.Assert(socketAddress.Family == AddressFamily.InterNetwork || socketAddress.Family == AddressFamily.InterNetworkV6);
System\Net\DnsEndPoint.cs (1)
25addressFamily != AddressFamily.InterNetworkV6 &&
System\Net\IPAddress.cs (3)
404return IsIPv4 ? AddressFamily.InterNetwork : AddressFamily.InterNetworkV6; 642if (AddressFamily == AddressFamily.InterNetworkV6) 651if (AddressFamily == AddressFamily.InterNetworkV6)
System\Net\IPEndPoint.cs (3)
148_address.AddressFamily == AddressFamily.InterNetworkV6 ? 158if (socketAddress.Family is not (AddressFamily.InterNetwork or AddressFamily.InterNetworkV6)) 163int minSize = AddressFamily == AddressFamily.InterNetworkV6 ? SocketAddress.IPv6AddressSize : SocketAddress.IPv4AddressSize;
System.Net.Quic (1)
src\libraries\Common\src\System\Net\IPEndPointExtensions.cs (1)
15if (family == AddressFamily.InterNetworkV6)
System.Net.Requests (2)
System\Net\FtpControlStream.cs (2)
1130else if (ServerAddress.AddressFamily == AddressFamily.InterNetworkV6) 1169if (templateSocket.AddressFamily == AddressFamily.InterNetworkV6 && templateSocket.DualMode)
System.Net.Sockets (44)
src\libraries\Common\src\System\Net\InteropIPAddressExtensions.Unix.cs (1)
18if (ipAddress.AddressFamily == AddressFamily.InterNetworkV6)
src\libraries\Common\src\System\Net\IPEndPointExtensions.cs (1)
15if (family == AddressFamily.InterNetworkV6)
src\libraries\Common\src\System\Net\SocketAddressExtensions.cs (1)
14Debug.Assert(socketAddress.Family == AddressFamily.InterNetwork || socketAddress.Family == AddressFamily.InterNetworkV6);
src\libraries\Common\src\System\Net\SocketProtocolSupportPal.cs (1)
13public static bool OSSupportsIPv6 { get; } = IsSupported(AddressFamily.InterNetworkV6) && !IsIPv6Disabled();
src\libraries\Common\src\System\Net\Sockets\ProtocolFamily.cs (1)
41InterNetworkV6 = AddressFamily.InterNetworkV6,
System\Net\Sockets\Socket.cs (23)
73: this(OSSupportsIPv6DualMode ? AddressFamily.InterNetworkV6 : AddressFamily.InterNetwork, socketType, protocolType) 163case AddressFamily.InterNetworkV6: 197case AddressFamily.InterNetworkV6: 325if (_addressFamily == AddressFamily.InterNetwork || _addressFamily == AddressFamily.InterNetworkV6) 371if (_addressFamily == AddressFamily.InterNetwork || _addressFamily == AddressFamily.InterNetworkV6) 619else if (_addressFamily == AddressFamily.InterNetworkV6) 640else if (_addressFamily == AddressFamily.InterNetworkV6) 657if (_addressFamily == AddressFamily.InterNetwork || (_addressFamily == AddressFamily.InterNetworkV6 && DualMode)) 671if (_addressFamily == AddressFamily.InterNetwork || (_addressFamily == AddressFamily.InterNetworkV6 && DualMode)) 694else if (_addressFamily == AddressFamily.InterNetworkV6) 712else if (_addressFamily == AddressFamily.InterNetworkV6) 748if (AddressFamily != AddressFamily.InterNetworkV6) 760if (AddressFamily != AddressFamily.InterNetworkV6) 775return AddressFamily == AddressFamily.InterNetworkV6 && DualMode; 912if (_addressFamily != AddressFamily.InterNetwork && _addressFamily != AddressFamily.InterNetworkV6) 947if (_addressFamily != AddressFamily.InterNetwork && _addressFamily != AddressFamily.InterNetworkV6) 1864else if (AddressFamily == AddressFamily.InterNetworkV6 && socketAddress.Family == AddressFamily.InterNetwork) 1983else if (endPointSnapshot.AddressFamily == AddressFamily.InterNetworkV6 && socketAddress.Family == AddressFamily.InterNetwork) 2314if (_addressFamily == AddressFamily.InterNetworkV6) 3318bool isIPv4MappedToIPv6 = socketAddress.Family == AddressFamily.InterNetworkV6 && socketAddress.GetIPAddress().IsIPv4MappedToIPv6; 3320isIPv6 = addressFamily == AddressFamily.InterNetworkV6; 3328fam == AddressFamily.InterNetworkV6 ? SocketAddressPal.IPv6AddressSize : 3582if (_addressFamily == AddressFamily.InterNetworkV6
System\Net\Sockets\Socket.Tasks.cs (1)
418if (remoteEndPoint!.AddressFamily != AddressFamily && AddressFamily == AddressFamily.InterNetworkV6 && IsDualMode)
System\Net\Sockets\SocketAsyncEventArgs.cs (5)
684endPoint.AddressFamily == AddressFamily.InterNetworkV6); 736if (address.AddressFamily == AddressFamily.InterNetworkV6) 738attemptSocket = tempSocketIPv6 ??= (Socket.OSSupportsIPv6 ? new Socket(AddressFamily.InterNetworkV6, socketType, protocolType) : null); 966if (_remoteEndPoint!.AddressFamily == AddressFamily.InterNetworkV6 && _socketAddress!.Family == AddressFamily.InterNetwork) 988if (_remoteEndPoint!.AddressFamily == AddressFamily.InterNetworkV6 && _socketAddress!.Family == AddressFamily.InterNetwork)
System\Net\Sockets\SocketPal.Unix.cs (2)
37if (!SupportsDualModeIPv4PacketInfo && socket.AddressFamily == AddressFamily.InterNetworkV6 && socket.DualMode) 75if (!OperatingSystem.IsWasi() && addressFamily == AddressFamily.InterNetworkV6 && socketType != SocketType.Raw)
System\Net\Sockets\TCPClient.cs (1)
35if (family is not (AddressFamily.InterNetwork or AddressFamily.InterNetworkV6 or AddressFamily.Unknown))
System\Net\Sockets\UDPClient.cs (7)
31if (family != AddressFamily.InterNetwork && family != AddressFamily.InterNetworkV6) 59if (family != AddressFamily.InterNetwork && family != AddressFamily.InterNetworkV6) 207return _family == AddressFamily.InterNetworkV6 && _clientSocket.DualMode; 268if (address.AddressFamily == AddressFamily.InterNetworkV6) 443if (_family != AddressFamily.InterNetworkV6) 512if (_family != AddressFamily.InterNetworkV6) 718ipv6Socket = new Socket(AddressFamily.InterNetworkV6, SocketType.Dgram, ProtocolType.Udp);