In our ASP.Net project, I am using 'Kentor.AuthServices' as SAML2 Authentication Service. For testing purpose, I am using 'Kentor.AuthServices.StubIDP'.
Currently we gave an anchor tag in the page with href as: [email protected]("~/AuthServices/SignIn?idp=" + entityId)
This works perfectly fine and once we click the anchor tag, it gets redirected to Identity Provider: http://localhost:17009//SamplePath/AuthServices/SignIn?idp=http://stubidp.kentor.se/Metadata
But what we need to achieve is without using the anchor tag,where we directly enter our site URL address in the browser, it should automatically redirect to Identity Provider.
When using the HttpModule, you use the forms authentication setup in the web.config to cause unauthenticated requests to be redirected to the sign in sequence.
<authentication mode="Forms">
<forms loginUrl="~/AuthServices/SignIn"></forms>
</authentication>