Questions tagged [asp.net-authentication]

Questions regarding ASP.NET identity authentication methods

ASP.NET, in conjunction with Microsoft Internet Information Services (IIS), can authenticate user credentials such as names and passwords using any of the following authentication methods:

  • Windows: Basic, digest, or Integrated Windows Authentication (NTLM or Kerberos).

  • Forms authentication, in which you create a login page and manage authentication in your application.

  • Client Certificate authentication

ASP.NET controls access to site information by comparing authenticated credentials, or representations of them, to NTFS file system permissions or to an XML file that lists authorized users, authorized roles (groups), or authorized HTTP verbs.

ASP.NET Web Application Security

185 questions
1
vote
1 answer

Authenticate client certificate using HttpSelfHostServer in C#

I have a service written in C# that currently works on Http. I want to migrate this to Https and want that when some client uses this service, there should be a option to select certificate to proceed and only certificates issued by one particular…
1
vote
1 answer

Add JWT Bearer Authentication in Server Side Blazor (3.0.0-preview.6)

I'm trying to add JWT Bearer authentication using Azure B2C. I'm using the default project template for creating Blazor Server Side application with Authentication. I chose B2C authentication at the creation page, which sets the default…
1
vote
1 answer

How to correctly set up AspNet Core 2 authentication behind a load balancer?

I've set up AspNet Core 2 authentication successfully, but now would like to get it working behind a load balancer. Because the load balancer address is different from my app address I'm changing the redirect Uri in my startup.cs ConfigureServices…
user704772
  • 309
  • 2
  • 11
1
vote
1 answer

How do you create an Authentication scheme that does nothing in .Net Core?

In development, staging and production, my controllers use the [Authorize] attribute to make sure only authorized users have access to the methods. This obviously requires connection to an authentication service. However, me and my team travel a…
Quark Soup
  • 4,272
  • 3
  • 42
  • 74
1
vote
1 answer

ASP.NET Core 2.2 MVC problem redirecting after signing in

I have recently been experiencing an issue when attempting to login on the web app that I am working on, I did not modify the Startup.cs file and it used to work last time when I used it, but now when I am trying to log in it redirects me back to…
1
vote
0 answers

ASP.NET Core 2.0 Identity 2FA using SMS, Not Authenticated after TwoFactorSignInAsync() with multiple schemas

I have an ASP.NET Core 2.0 solution and I copied the functionality for SMS 2FA from version 1.1. All good, I receive the sms with code I validate the code and _signInManager.TwoFactorSignInAsync result.Succeeded = true. However, I have 2 schemas…
1
vote
1 answer

How can i change authentication type as phone number instead of user name on my web api?

My authentication is working fine on it is own but i need to use phoneNumber of users instead of user names. There is my Provider class using Identity.Infrastructure; using Microsoft.AspNet.Identity.Owin; using Microsoft.Owin.Security; using…
1
vote
0 answers

Session, FormsAuthenticationTicket, store data about the user?

I'm building a web application that needs to be able to scale. We want to store a connection string, an object that says what organization the user is working on right now and the identity of the user. We could serialize down this and send through…
NPehrsson
  • 1,548
  • 18
  • 26
1
vote
0 answers

Use only one authentication scheme (jwt bearer)

I am building an ASP.Net Core API and am using JWT for authentication. I have the following configuration: public void ConfigureServices(IServiceCollection services) { services.AddMvc(); services.AddAuthentication(option => …
Matthew Goulart
  • 2,873
  • 4
  • 28
  • 63
1
vote
1 answer

Setting Up Social Authentication in ASP.NET Core 2.0

I'm setting up social login in an ASP.NET Core 2.0 application without using Identity. I simply want to authenticate the user through Facebook, Google and LinkedIn and receive their info. I handle storing user info myself. Here's what I've done so…
Sam
  • 26,817
  • 58
  • 206
  • 383
1
vote
1 answer

ApplicationUserManager's Generate ___ Token methods

I see there are 5 different Generate Token methods on ApplicationUserManager such…
1
vote
0 answers

LDAP Authentication Handler ASP.Net

Currently I have to implement an LDAP authentication handler for IdentityServer4 and ASP.Net where a user will login to a site, have IdentityServer handle authentication using an LDAP query and return ticket, token and embedded custom claims. I have…
1
vote
2 answers

auth0 authentication issue: HttpContext.Current is null. This code path is only valid when in the execution context of ASP.NET

I am using auth0 for authentication, roles and permission in my application. I am following below tutorial to implement auth0 in my application, https://auth0.com/docs/quickstart/webapp/aspnet It created login screen for me, After giving email-id…
Keval Patel
  • 161
  • 1
  • 15
1
vote
2 answers

Can't access or authorize ASP.Net Web API after setting Thread and HttpContext principal

Pretty new to Authorization and Authentication so maybe I'm missing some important step... Just looking at numerous references, guides, and tutorials. I may need to do something in my WebApiConfig? public static class WebApiConfig { public…
1
vote
1 answer

Custom ASP.NET Forms Authentication Service with WCF

I am trying to create a custom ASP.NET Forms Authentication Service using WCF. I am calling it via a test page that contains only a single line of JS (except for the ScriptManager scripts). The problem is that the server returns response code 500…
Stilgar
  • 22,354
  • 14
  • 64
  • 101