Blogged: An introduction to Compact Binary Object Notation (CBOR) in .NET andrewlock.net/an-introduct... In this post I introduce CBOR as a JSON alternative, and show how to use the System.Formats.Cbor NuGet package to read and write CBOR encoded data #dotnet #aspnetcore
Andrew Lock "Sock"
Andrew Lock "Sock"
@andrewlock.bsky.social
Microsoft MVP and blogger, focused on ASP.NET Core. Author of ASP.NET Core in Action (https://mng.bz/5mRz) Blog: https://andrewlock.net Mastadon: @andrewlock@hachyderm.io Twitter: @andrewlocknet
2.4K followers352 following940 posts
Andrew Lock "Sock" reposted
Just published a new issues of .NET R&D Digest! Thanks to @lemire.bsky.social, @maartenballiauw.be, @andrewlock.bsky.social, @chrisnas.bsky.social, @meziantou.net and other great authors for their amazing content! olegkarasik.wordpress.com/2026/10/02/n... #dotnet
Stripping extra dependencies in .NET NativeAOT apps using linker substitutions andrewlock.net/stripping-ex... In this post I describe how to perform method substitutions with the NativeAOT linker to remove additional dependencies that the linker couldn't see were unused #dotnet #nativeaot
Andrew Lock "Sock" reposted
I published a new article: the hidden trap of fixed buffers in C#. It explains a quirk of fixed buffers that could easily bite you, if you're one of the few people who still have to use that feature. minidump.net/the-hidden-t...
Andrew Lock "Sock" reposted
Time to look at Github Copilot in the fourth episode of my long series about AI harnesses internals chrisnas.github.io/posts/2026-0...
Andrew Lock "Sock" reposted
Experimental support for Device Bound Session Credentials (DBSC) in ASP .NET Core: Exploring the .NET 11 preview - Part 8 by @andrewlock.bsky.social andrewlock.net/exploring-th... #aspnetcore
Blogged: Experimental support for Device Bound Session Credentials (DBSC) in ASP.NET Core - Exploring the .NET 11 preview - Part 8 andrewlock.net/exploring-th... In this post I look at the new experimental support for DBSC coming in .NET 11 #dotnet #security #aspnetcore
Andrew Lock "Sock" reposted
Understanding Device Bound Session Credentials (DBSC) andrewlock.net/understandin... In this post I provide an introduction to Device Bound Session Credentials, I look at how DBSC protects against session hijacking, and how the protocol works. #security #dotnet
Andrew Lock "Sock" reposted
A new issue of .NET R&D digest is here! Thanks to @birgitta410.bsky.social, @andrewlock.bsky.social, @lemire.bsky.social, @meziantou.net, @maartenballiauw.be and other great authors for their amazing content! olegkarasik.wordpress.com/2026/09/04/n... #dotnet
Andrew Lock "Sock" reposted
Blogged: The pain of serializing unions and closed class hierarchies with System.Text.Json in .NET 11 andrewlock.net/exploring-th... In this post I discuss the System.Text.Json support for unions and closed hierarchies coming in .NET 11, the decisions made and some of the sharp edges I hit #dotnet
Andrew Lock "Sock" reposted
Blogged: Using multiline Parameters for Aspire and ASP.NET Core with user secrets and Azure default deployments damienbod.com/2026/09/01/u... #aspire #aspnetcore #dotnet #azure #aca #biceps #pem
Andrew Lock "Sock" reposted
Better know your HTTP headers! If you've seen Sec-Fetch-Dest and friends but never really knew what they were for, you're in luck!
Blogged: Finding the total number of processors on a machine with .NET andrewlock.net/finding-the-... In this post I show how to find the total number of logical CPUs on a host (not just those available to a process); something that isn't exposed in modern .NET #dotnet
@nuget.org we have packages stuck in "validating" for over 24 hours - what's going on? No response from customer support, and no problems at status.nuget.org, so what's going on? 🤷
3 days later and @nuget.org _still_ hasn't validated our packages 🙄 Can someone please go and kick the server?
Andrew Lock "Sock" reposted
Just published a new issue of .NET R&D Digest! Thx to @rasbt.bsky.social, @maartenballiauw.be, @andrewlock.bsky.social, @kevingosse.net, @meziantou.net, @simonwillison.net & other authors for their g8 content! olegkarasik.wordpress.com/2026/08/04/n... #dotnet
Andrew Lock "Sock" reposted
Understanding the Fetch Metadata HTTP headers: Sec-Fetch-Site and friends by @andrewlock.bsky.social andrewlock.net/understandin... #aspnetcore
Blogged: Automatic CSRF protection based on Fetch Metadata headers - Exploring the .NET 11 preview andrewlock.net/exploring-th... In this post I describe the new Cross-Site Request Forgery protection added to ASP.NET Core that uses Fetch Metadata headers instead of tokens #aspnetcore #security
Blogged: Understanding the Fetch Metadata HTTP headers: Sec-Fetch-Site and friends andrewlock.net/understandin... In this post I describe the Fetch Metadata HTTP headers like Sec-Fetch-Site and Sec-Fetch-Mode which give information to a server about the context of a request #Security #aspnetcore
Blogged: Improvements to reading Process outputs - Exploring the .NET 11 preview - Part 5 andrewlock.net/exploring-th... In this post I show some of the improvements to the Process API in .NET 11 for running processes and reading their outputs without risk of deadlock #dotnet
Andrew Lock "Sock" reposted
I published part 10 of my "Writing a .NET Garbage Collector in C#" series: minidump.net/writing-a-ne... This time, I implemented support for finalization, which reveals some intricacies of the .NET runtime.
Andrew Lock "Sock" reposted
New issue of .NET R&D Digest is here! Thx to @lemire.bsky.social, @maartenballiauw.be, @chrisnas.bsky.social, @meziantou.net, @andrewlock.bsky.social & other authors for their g8 content! olegkarasik.wordpress.com/2026/07/02/n... #dotnet
Blogged: Closed class hierarchies - Exploring the .NET 11 preview - Part 4 andrewlock.net/exploring-th... In this post I describe what a closed closed hierarchy is, how to create one, and discuss why you might want one #dotnet #csharp
Andrew Lock "Sock" reposted
Let's dig into the new cDAC way to access .NET runtime internals :^) chrisnas.github.io/posts/2026-0... Happy reading!
Blogged: Exploring the .NET 11 preview - Part 3 - Avoiding ToString() allocations with StringBuilder.MoveChunks andrewlock.net/exploring-th... In this post I take a look at the new MoveChunks() API, explore how it works, what it's for, and how the new API provides opportunities for public APIs
Andrew Lock "Sock" reposted
Blogged: Software development and AI damienbod.com/2026/06/15/s... #ai #software #code #copilot
Andrew Lock "Sock" reposted
One more issue of .NET R&D Digest is here! Thanks to @martinfowler.com, @kentbeck.com, @andrewlock.bsky.social, @b0rk.jvns.ca, and other great authors for the amazing content! olegkarasik.wordpress.com/2026/06/05/n... #dotnet
Blogged: .NET finally gets union types🎉 - Exploring the .NET 11 preview - Part 2 andrewlock.net/exploring-th... In this post I discuss the support for union types released in .NET 11, how they're implemented, the choices made, and how to create your own union types #dotnet
Andrew Lock "Sock" reposted
Blogged: Aspire Azure SQL deployment bug damienbod.com/2026/05/18/a... #aspire #azure #dotnet #aspnetcore #sql
Blogged: Running background tasks in Blazor with Web Workers - Exploring the .NET 11 preview - Part 1 andrewlock.net/exploring-th... In this post I discuss the new Web Worker template available in .NET 11 for running CPU intensive tasks without blocking the UI #dotnet #blazor
Andrew Lock "Sock" reposted
New issue of .NET R&D Digest is here! Thanks to @lemire.bsky.social, @andrewlock.bsky.social, @martinfowler.com, @meziantou.net, @steplyakov.bsky.social and other authors for their g8 content! olegkarasik.wordpress.com/2026/05/04/n... #dotnet
Andrew Lock "Sock" reposted
Andrew Lock "Sock" reposted
attention git users there are no excuses left for wip wip wip in your repo histories
Blogged: New features in Git 2.54: easier rebasing, hooks, and statistics andrewlock.net/new-features... In this post I show some of the new features in Git 2.54 including simple rebases with git history, config-based hooks, and stats with git repo structure #git
Blogged: New features in Git 2.54: easier rebasing, hooks, and statistics andrewlock.net/new-features... In this post I show some of the new features in Git 2.54 including simple rebases with git history, config-based hooks, and stats with git repo structure #git
Blogged: Removing byte[] allocations in .NET Framework using ReadOnlySpan<T> andrewlock.net/removingbyte... In this post I describe how to remove static byte[] allocations, even on .NET Framework, by using Span<T> look at the associated IL, and discuss the potential risks #dotnet
Andrew Lock "Sock" reposted
Blogged: Running AI agents with customized templates using docker sandbox andrewlock.net/running-ai-a... In this post I describe how to create custom templates for Docker Sandboxes, so that your sandboxes start with additional tools immediately available (like .NET) #docker #dotnet
Blogged: Running AI agents safely in a microVM using docker sandbox andrewlock.net/running-ai-a... In this post I show how to run AI coding agents safely while still using YOLO/dangerous mode using docker sandboxes and the sbx tool #ai #docker #sandbox #claude
Andrew Lock "Sock" reposted
New issue of .NET R&D Digest is here! Thx to @simonwillison.net, @birgitta410.bsky.social, @kief.com, @lemire.bsky.social, @kevingosse.net, @andrewlock.bsky.social, @meziantou.net, @stevesanderson.bsky.social & other authors for their g8 content! #dotnet olegkarasik.wordpress.com/2026/04/03/n...
Blogged: Configuring contextual options with Microsoft.Extensions.Options.Contextual andrewlock.net/configuring-... In this post I take a brief look at the Microsoft.Extensions.Options.Contextual package to understand what it's for, how to use it, and discuss whether to use it or not #dotnet
Andrew Lock "Sock" reposted
I can hardly believe that (finally!) there is a great file explorer alternative for those of us who have to stick with windows -- File Pilot is absolutely sleek and marvelous 😍 🔗 filepilot.tech ht @andrewlock.bsky.social (andrewlock.net/windows-expl...)
Andrew Lock "Sock" reposted
Announcing Polecat: Event Sourcing with SQL Server jeremydmiller.com/2026/03/22/a... I'll happily take any RTs please and thank you! #polecat #critterstack #sqlserver
Andrew Lock "Sock" reposted
Want the power of Duende IdentityServer but with faster time-to-value? ⏱️ We’re previewing a first-party user management .NET SDK on March 24th that gives you Passkeys, MFA, and audit trails out-of-the-box. Keep your data control, ditch the custom coding. RSVP: duende.link/78q3hk #dotnet #aspnet
Andrew Lock "Sock" reposted
Have you ever noticed that a simple .NET Core applications on 64-bit uses more than 2TB of virtual memory? In a new episode of the series "writing a .NET garbage collector in C#", we discover the kind of problem that it intends to solve: minidump.net/writing-a-ne...