Provider type not defined. (Exception from HRESULT: 0x80090017) (Could not load file or assembly 'Microsoft.IdentityModel.Extensions')

Sajit Kurup 1 Reputation point
2020-12-18T06:14:31.447+00:00

We have an issue which occurs intermittently on one of our test environment. The issue is mostly observed when a deployment is carried out but the peculiar behavior about the issue is the post deployment sanity test completes with out any issues however when the system is accessed bit later it results in a server error. 49402-3e4a5229-ae9c-45ec-97ec-bfd58fb1efe2.jpg

The primary website is an onprem Sharepoint 2013. We have two asp.net MVC web application which are accessed through a custom webpart in a iframe. The assembly (Microsoft.IdentityModel.Extensions) is used as part of the asp.net application for authentication. When the user clicks on the menu item it open one of these asp.net web application opens however in the error scenario it presents us the the server error.

We do an iisreset which resolve the issue immediately without any change to the config, IIS settings or any type of code change. My question is how do we stop from getting the exception at first place. At the moment it occurs only on one of the test environment and not observed on production. Is something to do with IIS not loading the assembly what could be the possible trigger or any patch or a known issue?

ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,231 questions
.NET Runtime
.NET Runtime
.NET: Microsoft Technologies based on the .NET software framework.Runtime: An environment required to run apps that aren't compiled to machine language.
1,130 questions
SharePoint Development
SharePoint Development
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Development: The process of researching, productizing, and refining new or existing technologies.
2,704 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Sam Wu-MSFT 7,046 Reputation points Microsoft Vendor
    2020-12-18T08:31:20.903+00:00

    Hi @Sajit Kurup ,

    Please check if you have installed Windows Identity Foundation, if not, you can install it on your project.

    Installed in your project: Microsoft.Identity.Model.Extensions


    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.