47 references to TwoFactorUserIdScheme
Microsoft.AspNetCore.Identity (18)
IdentityCookiesBuilderExtensions.cs (3)
100builder.AddCookie(IdentityConstants.TwoFactorUserIdScheme, o => 102o.Cookie.Name = IdentityConstants.TwoFactorUserIdScheme; 109return new OptionsBuilder<CookieAuthenticationOptions>(builder.Services, IdentityConstants.TwoFactorUserIdScheme);
IdentityServiceCollectionExtensions.cs (2)
80.AddCookie(IdentityConstants.TwoFactorUserIdScheme, o => 82o.Cookie.Name = IdentityConstants.TwoFactorUserIdScheme;
SecurityStampValidator.cs (1)
182/// Used to validate the <see cref="IdentityConstants.TwoFactorUserIdScheme"/> and
SignInManager.cs (12)
310if (await _schemes.GetSchemeAsync(IdentityConstants.TwoFactorUserIdScheme) != null) 312await Context.SignOutAsync(IdentityConstants.TwoFactorUserIdScheme); 688var claimsIdentity = new ClaimsIdentity(IdentityConstants.TwoFactorUserIdScheme); 690await Context.SignInAsync(IdentityConstants.TwoFactorUserIdScheme, claimsPrincipal, props); 699var result = await Context.AuthenticateAsync(IdentityConstants.TwoFactorUserIdScheme); 700await Context.SignOutAsync(IdentityConstants.TwoFactorUserIdScheme); 848if (await _schemes.GetSchemeAsync(IdentityConstants.TwoFactorUserIdScheme) != null) 850await Context.SignOutAsync(IdentityConstants.TwoFactorUserIdScheme); 1159var identity = new ClaimsIdentity(IdentityConstants.TwoFactorUserIdScheme); 1216if (await _schemes.GetSchemeAsync(IdentityConstants.TwoFactorUserIdScheme) != null) 1220await Context.SignInAsync(IdentityConstants.TwoFactorUserIdScheme, StoreTwoFactorInfo(userId, loginProvider)); 1249var result = await Context.AuthenticateAsync(IdentityConstants.TwoFactorUserIdScheme);
Microsoft.AspNetCore.Identity.InMemory.Test (1)
FunctionalTest.cs (1)
355var result = await context.AuthenticateAsync(IdentityConstants.TwoFactorUserIdScheme);
Microsoft.AspNetCore.Identity.Test (28)
IdentityOptionsTest.cs (1)
90Assert.Equal("d", options.Get(IdentityConstants.TwoFactorUserIdScheme).Cookie.Name);
SignInManagerTest.cs (27)
330auth.Setup(a => a.SignInAsync(context, IdentityConstants.TwoFactorUserIdScheme, 378auth.Setup(a => a.SignInAsync(context, IdentityConstants.TwoFactorUserIdScheme, 498IdentityConstants.TwoFactorUserIdScheme, 506IdentityConstants.TwoFactorUserIdScheme); 514IdentityConstants.TwoFactorUserIdScheme, 523auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 561auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 562.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 602auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 603.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 641auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 642.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 725auth.Setup(a => a.SignOutAsync(context, IdentityConstants.TwoFactorUserIdScheme, It.IsAny<AuthenticationProperties>())).Returns(Task.FromResult(0)).Verifiable(); 731auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 732.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 980auth.Setup(a => a.SignOutAsync(context, IdentityConstants.TwoFactorUserIdScheme, It.IsAny<AuthenticationProperties>())).Returns(Task.FromResult(0)).Verifiable(); 995auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 996.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1030auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 1031.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1161auth.Setup(a => a.SignOutAsync(context, IdentityConstants.TwoFactorUserIdScheme, It.IsAny<AuthenticationProperties>())).Returns(Task.FromResult(0)).Verifiable(); 1588auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 1589.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1654auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 1655.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1744[IdentityConstants.TwoFactorUserIdScheme] = CreateCookieScheme(IdentityConstants.TwoFactorUserIdScheme),