Microsoft has rolled out the second preview of its upcoming .NET 10 developer platform, delivering a fresh round of improvements aimed at bolstering security, refining the runtime, and expanding C# language capabilities. Released on March 18, .NET 10 Preview 2 builds upon the foundation laid by the initial preview in February, with a full general availability release slated for November 2025. Developers can get hands-on with the preview by downloading it from the official .NET website.
A key highlight of Preview 2 is its advancement in encryption flexibility. New ExportPkcs12
methods on X509Certificate2
now allow developers to specify the encryption and digest algorithms used in certificate exports. This is a significant upgrade from the previous approach, which relied on outdated defaults tracing back to Windows XP. With the ability to opt into stronger, modern cryptographic standards, developers can better secure sensitive data in line with contemporary best practices.
On the language front, C# 14 brings important enhancements to partial members, extending support to partial instance constructors and partial events. These additions complement the partial methods and partial properties introduced in C# 13, providing more granular control and modularization in large codebases. These features are particularly useful in scenarios involving source generators, enabling cleaner separation of generated and user-defined code without sacrificing maintainability.
The runtime also sees notable improvements. Preview 2 continues to push forward enhancements to the JIT (Just-In-Time) compiler, specifically focusing on devirtualization for array interface methods. These optimizations build on work started in Preview 1 and aim to improve execution performance by allowing the runtime to make more efficient decisions during code execution. Combined, these updates underscore Microsoft’s ongoing commitment to performance, productivity, and security in the .NET ecosystem.