.NET Libraries in .NET 11 Preview 3 - Release Notes
April 14, 2026 · View on GitHub
.NET 11 Preview 3 includes new library features and reliability improvements:
- System.Text.Json offers more control over naming and ignore defaults
- Zstandard moved to System.IO.Compression and ZIP reads validate CRC32
- SafeFileHandle and RandomAccess expand pipe support
- Regex recognizes all Unicode newline sequences
- Breaking changes
- Bug fixes
- Community contributors
.NET Libraries updates in .NET 11:
System.Text.Json offers more control over naming and ignore defaults
Preview 3 expands the built-in naming and ignore options in System.Text.Json.
JsonNamingPolicy.PascalCase adds to the existing camel, snake, and kebab
presets, [JsonNamingPolicy] lets you override naming on individual members,
and type-level [JsonIgnore(Condition = ...)] lets a model set its default
ignore behavior in one place
(dotnet/runtime #124644,
dotnet/runtime #124645,
dotnet/runtime #124646).
using System.Text.Json;
using System.Text.Json.Serialization;
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public sealed class EventData
{
[JsonNamingPolicy(JsonKnownNamingPolicy.CamelCase)]
public string EventName { get; set; } = "";
public string? Notes { get; set; }
}
var options = new JsonSerializerOptions
{
PropertyNamingPolicy = JsonNamingPolicy.PascalCase
};
Zstandard moved to System.IO.Compression and ZIP reads validate CRC32
The Zstandard APIs introduced earlier in .NET 11 now live in
System.IO.Compression, so they sit alongside DeflateStream, GZipStream,
and BrotliStream
(dotnet/runtime #124634).
Preview 3 also adds CRC32 validation when reading ZIP entries, which means
corrupted payloads now fail fast with InvalidDataException instead of being
silently accepted
(dotnet/runtime #124766).
If you used the earlier preview package, remove the separate
System.IO.Compression.Zstandard package reference.
-<PackageReference Include="System.IO.Compression.Zstandard" />
SafeFileHandle and RandomAccess expand pipe support
Preview 3 adds several low-level I/O updates. SafeFileHandle.Type reports
whether a handle is a file, pipe, socket, directory, or other OS object
(dotnet/runtime #124561).
SafeFileHandle.CreateAnonymousPipe creates pipe pairs with separate async
behavior for each end
(dotnet/runtime #125220), and
RandomAccess.Read / Write now work with non-seekable handles such as pipes
(dotnet/runtime #125512). On
Windows, Process now uses overlapped I/O for redirected stdout/stderr, which
reduces thread-pool blocking in process-heavy apps
(dotnet/runtime #125643).
using Microsoft.Win32.SafeHandles;
using System.IO;
SafeFileHandle.CreateAnonymousPipe(out SafeFileHandle readEnd, out SafeFileHandle writeEnd,
asyncReads: true, asyncWrites: false);
Console.WriteLine(readEnd.Type); // Pipe
Regex recognizes all Unicode newline sequences
A new RegexOptions.AnyNewLine flag makes ^, $, and . treat the full set
of Unicode newline characters as line terminators, not just \n
(dotnet/runtime #124701). This
helps when you parse text that may mix Windows, Unix, and Unicode-specific line
endings. Preview 3 also includes optimizer improvements for common regex
patterns.
using System.Text.RegularExpressions;
string text = "line1\r\nline2\u0085line3\u2028line4";
var matches = Regex.Matches(
text,
@"^line\d$",
RegexOptions.Multiline | RegexOptions.AnyNewLine);
Breaking changes
ZipArchivenow validates CRC32 while reading entries. Corrupt or truncated archives that previously slipped through may now throwInvalidDataException(dotnet/runtime #124766).- Unhandled
BackgroundServiceexceptions now stop the host instead of being quietly swallowed (dotnet/runtime #124863). - AIA certificate downloads are now disabled by default during server client-certificate validation. If you depended on online AIA fetching, review your validation setup (dotnet/runtime #125049).
TarWriternow emitsHardLinkentries when the same hard-linked file is archived more than once (dotnet/runtime #123874).
Bug fixes
- Dependency injection
- Factory-based circular dependencies now throw a clear
InvalidOperationExceptioninstead of failing with a less helpful error (dotnet/runtime #124331).
- Factory-based circular dependencies now throw a clear
- Logging
- The logging source generator now supports generic methods (dotnet/runtime #124638).
- Networking
HttpListeneron Windows can now control HTTP.sys kernel response buffering (dotnet/runtime #124720).
Community contributors
Thank you contributors! ❤️
- @am11
- @ArcadeMode
- @DoctorKrolic
- @gwr
- @haltandcatchwater
- @jgh07
- @jonathandavies-arm
- @karimsalem1
- @koszeggy
- @kzrnm
- @laveeshb
- @lolleko
- @lufen
- @martincostello
- @matantsach
- @Neo-vortex
- @pentp
- @prozolic
- @RenderMichael
- @rogerbriggen
- @Ruihan-Yin
- @rustamque
- @sethjackson
- @ShreyaLaxminarayan
- @Smaug123
- @teo-tsirpanis
- @tmds
- @Tomius
- @ylpoonlg
- @Zurisen