1

I have two separate projects: a front end app (Angular 2, using Visual Studio Code) and a back end app (ASP.NET Core, using Visual Studio 2015). For the back end app, when I did File > New Project, I selected "Windows Authentication."

I want the back end app to expose a simple ASP.NET Web API Controller to the front end app, so it can make calls to perform CRUD operations.

Issue: Whenever I try to make a call from the front end app to the back end app's API, I get this error:

enter image description here

The error is caused by Windows Authentication, not CORS. I know this because I created 2 identical projects, one with Windows Authentication and one with Individual User Accounts. I enabled CORS in both. Individual User Accounts worked fine, Windows Authentication still gives the error.

What's the best way for ASP.NET Core to allow the call to get through? Or alternatively, pass along my Windows credentials in Angular 2 call itself?

Tseng
  • 61,549
  • 15
  • 193
  • 205
Derek
  • 5,137
  • 9
  • 28
  • 39

0 Answers0