NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
NuGet
NuGet, #1276 most downloaded on NuGet
IPNetwork C# library take care of complex network, ip, ipv4, ipv6, netmask, cidr, subnet, subnetting, supernet and supernetting calculation for .Net developpers. It works with IPv4 and IPv6 as well. It is written in C# for .NetStandard and coreclr and has a light and clean API and is fully unit tested.
Latest stable
5.0.1
Last release 29 days ago
24 Oct 2026
Release timing varies
gaps range from 8 days to 11 months
Rarely documented
notes for 12 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
11 years old
294 releases · first in 2015
Drag across the ruler to compare, or tap a release to open it.
See 5.0.0 for the thread-safety changes and breaking changes of the 5.x line.
Release packaging fix for 5.0.0. No library code changes: the IPNetwork2 package is functionally identical to 5.0.0 and keeps AssemblyVersion 5.0.0.0, so upgrading needs no recompilation.
osx-arm64 and linux-arm64 and the Homebrew formula were not published: the ConsoleApplication lock file carried package hashes from a local SDK feed that did not match nuget.org (NU1403). The lock file is regenerated from nuget.org, and local restores now ignore that feed (DisableImplicitLibraryPacksFolder).See 5.0.0 for the thread-safety changes and breaking changes of the 5.x line.
Full changelog: 5.0.0...5.0.1
IPNetwork2 is safe to share between threads
The address, family and CIDR now live in one immutable snapshot behind a single reference. Assigning Value replaces the whole network in one store, so a concurrent reader always observes a network that was actually assigned, never a mix of the old and the new one. Every single call (ToString, Contains, CompareTo, Network, Broadcast, FirstUsable, LastUsable, Usable, WildcardMask, ...) reports one coherent network.
The memoized broadcast address and hash code live on that snapshot too, so they are invalidated together with the network they describe.
The IANA_* blocks and the UniqueLocalAddress ULA prefixes used to hand out process-wide instances. Since Value is publicly settable, any caller could change what the library considers reserved or ULA. They now return a copy that shares the immutable snapshot.
IPNetworkCollection hands out an enumerator of its own per GetEnumerator() call. A second, nested or concurrent enumeration no longer disturbs another one.IPNetworkCollection and IPAddressCollection reject negative indexes.GetHashCode follows Value, as the Equals/GetHashCode contract requires. A network mutated after being added to a Dictionary or a HashSet can no longer be found there.UniqueLocalAddress.UlaLocallyAssigned, UlaCentrallyAssigned and UlaRange are properties instead of static readonly fields. Source compatible, but code compiled against 4.x must be recompiled.IANA_* and the ULA properties return a new instance on every call, so ReferenceEquals between two calls no longer holds. Use Equals.AssemblyVersion is now 5.0.0.0 (it had been left at 3.2.0.0).Full changelog: 4.3.0...5.0.0
Your coding agent can read these notes before it upgrades. Set up the MCP server →
The library targets netstandard2.0 again — consumable from .NET Framework 4.6.1+, .NET Core 2.x, and other ns2.0-compatible runtimes. (ns2.0 was dropp
The library targets netstandard2.0 again — consumable from .NET Framework 4.6.1+, .NET Core 2.x, and other ns2.0-compatible runtimes. (ns2.0 was dropped in 4.0; this release restores it without breaking anything else.)
Source changes that made ns2.0 viable:
NotNullWhenAttribute polyfill compiled only under #if NETSTANDARD2_0SHA256.ComputeHash fallback widened from #if NETSTANDARD2_1 to #if NETSTANDARDnnin[^1] replaced with nnin[Length - 1] (ns2.0 lacks System.Index)Contains(char) replaced with IndexOf('/') >= 0 (char overload is .NET Core 2.1+)TestProject now multi-targets net10.0;net48 and a new windows-latest job runs the net48 build directly. This is the only CI path that actually loads the ns2.0 DLL at runtime, so ns2.0-specific regressions get caught before release.
MSTest.TestAdapter to 4.2.3 to match MSTest.TestFramework, fixing the module-initializer InvalidOperationException that crashed the test hostConsoleApplication lock file for Microsoft.NET.ILLink.Tasks 10.0.7| Consumer runtime | Lib resolved from package |
|---|---|
| .NET Framework 4.6.1 – 4.8.1 | netstandard2.0 (new) |
| .NET Core 2.x | netstandard2.0 (new) |
| .NET Core 3.x, .NET 5/6/7 | netstandard2.1 |
| .NET 8 | net8.0 |
| .NET 9 | net9.0 |
| .NET 10 | net10.0 |
Full changelog: https://github.com/lduchosal/ipnetwork/compare/4.2.0...4.3.0
dependencies .NET
·
2
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/4.1.1...4.2.0
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/4.1.1...4.2.0
Fixed NullReferenceException when displaying IPv6 /128 networks (Broadcast, FirstUsable, LastUsable can be null)
NullReferenceException when displaying IPv6 /128 networks (Broadcast, FirstUsable, LastUsable can be null)macos-13 runner, added --skip-duplicate for NuGet push| Platform | File |
|---|---|
| Windows x64 | ipnetwork-win-x64.zip |
| macOS Apple Silicon | ipnetwork-osx-arm64.tar.gz |
| macOS Intel | ipnetwork-osx-x64.tar.gz |
| Linux x64 | ipnetwork-linux-x64.tar.gz |
| Linux ARM64 | ipnetwork-linux-arm64.tar.gz |
| Chocolatey | choco install ipnetwork |
| NuGet (library) | dotnet add package IPNetwork2 |
Native AOT binaries — self-contained, no .NET runtime required (~3MB)
ipnetwork instead of ConsoleApplicationdotnet-10.0-runtime dependency| Platform | File |
|---|---|
| Windows x64 | ipnetwork-win-x64.zip |
| macOS Apple Silicon | ipnetwork-osx-arm64.tar.gz |
| macOS Intel | ipnetwork-osx-x64.tar.gz |
| Linux x64 | ipnetwork-linux-x64.tar.gz |
| Linux ARM64 | ipnetwork-linux-arm64.tar.gz |
| Chocolatey | choco install ipnetwork |
| NuGet (library) | dotnet add package IPNetwork2 |
See v4.0.1 release notes for the complete list of breaking changes and improvements in the 4.0 series.
Contains, Overlap, Print, Subnet, TrySubnet, Supernet, TrySupernet, IsIANAReserved(IPNetwork2)FilterEnum enum and ListIPAddress(FilterEnum) overload — use Filter and ListIPAddress(Filter) instead/ → /src).vscode/, qodana.yaml).DS_Store and .vscode/ to .gitignoreSee v4.0.1 release notes for the complete list of breaking changes and improvements in the 4.0 series.
IPNetwork2 is free and open source. If it saves you time or you use it in production, consider supporting its development:
Thank you!
Removed deprecated static methods that have instance equivalents: Contains , Overlap , Subnet , TrySubnet , Supernet , TrySupernet , Print , IsIANARes…
netstandard2.0 and System.Memory dependencynet8.0, net9.0, net10.0, netstandard2.1<Nullable>enable</Nullable> with TreatWarningsAsErrors?, [NotNullWhen(true)])Contains, Overlap, Subnet, TrySubnet, Supernet, TrySupernet, Print, IsIANAReserved(IPNetwork2)FilterEnum enum and ListIPAddress(FilterEnum) overloadIsIANAReserved() now returns true for many more addresses — applications relying on the previous (incomplete) behavior may be affected0.0.0.0/8), Loopback (127.0.0.0/8), Link-local (169.254.0.0/16), IETF Protocol (192.0.0.0/24), TEST-NET-1/2/3, Benchmarking (198.18.0.0/15), Multicast (224.0.0.0/4), Reserved (240.0.0.0/4), Broadcast (255.255.255.255/32)::/128), Loopback (::1/128), IPv4-mapped (::ffff:0:0/96), IPv4/IPv6 translation (64:ff9b::/96), TEREDO (2001::/32), Documentation (2001:db8::/32), Unique local (fc00::/7), Link-local (fe80::/10), Multicast (ff00::/8)IsIANAReserved() now supports IPv6 addresses and networks nativelyEnforceCodeStyleInBuild and WarningLevel 5ArgumentException instancesis null instead of ReferenceEquals[^1]string.Contains(char) instead of string.Contains(string)SHA256.HashData on .NET 5+ targetsInternalToNetmask and InternalSubnet from void to bool with [NotNullWhen(true)] — eliminated null-forgiving operatorsAssert.ThrowsExactly lambdas now contain single statements#pragma warning disable 0618 pragmassanitanize → sanitize.DS_Store to .gitignoreIPNetwork2 is free and open source. If it saves you time or you use it in production, consider supporting its development:
Thank you!
⚠️ Recommended upgrade: please use v4.0.1
⚠️ Recommended upgrade: please use v4.0.1
Version 4.0.0 mistakenly kept the obsolete static methods (
Contains,Overlap,Subnet,Supernet, etc.) instead of removing them. Version 4.0.1 properly removes these methods.If you are migrating from 3.x, go directly to 4.0.1.
Nothing published for this version
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/3.5.2...3.5.3
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/3.5.2...3.5.3
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/3.5.1...3.5.2
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/3.5.1...3.5.2
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/3.5...3.5.1
Full Changelog: https://github.com/lduchosal/ipnetwork/compare/3.5...3.5.1
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
One column per quarter.