locked
.net core + angular - windows authentication RRS feed

  • Question

  • User-1970279282 posted

    Hello,
    I want to prepare a solution with 2 projects asp.net core web application + Angular template with domain authentication. But when i chose this template I can't select windows authentication when I create project. Is this possible to add windows authentication
    to project with angular? Should I create project in MVC with windows authentication and then manually add angular?

    Also how can I block users who are not in current domain? Is windows authentication is good choice?
    Thursday, July 9, 2020 5:25 AM

Answers

  • User-474980206 posted

    there is no angular code involved with windows authentication. all the docs are for oauth. to configure:

      https://docs.microsoft.com/en-us/aspnet/core/security/authentication/windowsauth?view=aspnetcore-3.1&tabs=visual-studio

    iif you use windows authentication with CORS, the preflight (OPTIONS) requests must be anonymous. You may need to allow anonymous and use middleware to force authentication when not a preflight. google for examples.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, July 9, 2020 3:13 PM

All replies

  • User-474980206 posted

    there is no angular code involved with windows authentication. all the docs are for oauth. to configure:

      https://docs.microsoft.com/en-us/aspnet/core/security/authentication/windowsauth?view=aspnetcore-3.1&tabs=visual-studio

    iif you use windows authentication with CORS, the preflight (OPTIONS) requests must be anonymous. You may need to allow anonymous and use middleware to force authentication when not a preflight. google for examples.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, July 9, 2020 3:13 PM
  • User-1970279282 posted
    Ok. Thank you so much.
    Friday, July 10, 2020 4:37 AM