asp.net-mvcauthenticationasp.net-coreadfsws-federation

ADFS authentication on a public network


I don't know much about networking so I may not explain this well.

I'm working on an app that has WS-Federation setup to authenticate users with ADFS. When the app is tested on the local network, it works fine and ADFS authenticates the user. However, when the app is published to a website that's open to the public it does not work.

The user is able to reach the ADFS authentication form and input username and password. But when "Login" is clicked the user is linked to https://www.app-website.net/signin-wsfed which does not exist, so a 404 error is thrown.

I used the Microsoft guide on how to set up authentication (with no identity). Maybe there is some option that has to be enabled, or would this be strictly a networking issue? Thank you.


Solution

  • It did not have anything to do with the fact that the website is open to the public.

    The issue was with a slash at the end of the URL for Wtrealm in Startup.cs.

    The URL that was set in ADFS did not have a slash at the end and that caused the error.

    enter image description here