Skip to content

Sponsor: Do you build complex software systems? See how NServiceBus makes it easier to design, build, and manage software systems that use message queues to achieve loose coupling. Get started for free.

Learn more about Software Architecture & Design.
Join thousands of developers getting weekly updates to increase your understanding of software architecture and design concepts.


Follow @CodeOpinion

ASP.NET Core

Browser/Javascript SignalR Authorization

I recently started working with ASP.NET Core SignalR 1.0 and immediately ran into roadblock with authorization.  If you need to add SignalR authorization via header such as the Authorization header, you’re going to also run into this roadblock.  Specifically this is only an issue when running in the browser/javascript as it’s not supported. Headers I was unaware that browsers do not support additional headers such as Authorization.  This was problematic for me as the authorization header sending a bearer token is the method of authorization used in the application I was adding SignalR hub to. So how are you supposed… Read More »Browser/Javascript SignalR Authorization

Troubleshooting StackOverflow Exceptions

Is your .NET application randomly crashing? In Production? Without any relevant application logs?  You may be hitting a StackOverflowException if you see exception code 0xc00000fd in the event log. Here’s how to start troubleshooting StackOverflow Exceptions. 0xc00000fd First take a look in your event log.  If you see a log similar to this: Faulting application name: MyApp.exe, version: 1.0.0.0, time stamp: 0xdfd8c80b Faulting module name: clr.dll, version: 4.7.2558.0, time stamp: 0x59d413ce Exception code: 0xc00000fd The important part here is the exception code 0xc00000fd is a StackOverflowException. Troubleshooting a .NET StackOverflowException First thing I would recommend is looking for any recursion… Read More »Troubleshooting StackOverflow Exceptions

ASP.NET Core Data Protection

Continuing from my last post on Configuring ASP.NET Core behind a Load Balancer, the next hurdle you may run into is with ASP.NET Core Data Protection. Specifically I was using Cookie Authentication (without Identity). In this scenario, ASP.NET Core’s Data Protection must share the same key ring and app identifier for each instance of your application.  This means if you are load balanced across multiple containers or even machines, you must configure ASP.NET Core’s Data Protection system. If you do not, the process that generates your authentication cookie (or bearer token) will be the only process that will be able… Read More »ASP.NET Core Data Protection