What happened to my Thread.CurrentPrincipal
This is not the IPrincipal you are looking for...
Overview
Like the title claims, if you’re using ASP.NET Core and expecting the Thread.CurrentPrincipal or ClaimsPrincipal.Current to be populated you’d be wrong. This is not the
IPrincipal you’re looking for. In this post we’ll discuss what happened and what you need to do now. Additionally we’ll cover all the peripheral benefits as a result of this change.
History
If you have ever done any .NET Framework development, you’ve probably seen the Thread class. You’re probably familiar with the
member. This member of the <a href="https://msdn.microsoft.com/en-us/library/system.threading.thread.currentprincipal" target='_blank'>Thread.CurrentPrincipal</a>
Thread class is defined as follows: