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)
314if (await _schemes.GetSchemeAsync(IdentityConstants.TwoFactorUserIdScheme) != null) 316await Context.SignOutAsync(IdentityConstants.TwoFactorUserIdScheme); 701var claimsIdentity = new ClaimsIdentity(IdentityConstants.TwoFactorUserIdScheme); 703await Context.SignInAsync(IdentityConstants.TwoFactorUserIdScheme, claimsPrincipal, props); 712var result = await Context.AuthenticateAsync(IdentityConstants.TwoFactorUserIdScheme); 713await Context.SignOutAsync(IdentityConstants.TwoFactorUserIdScheme); 862if (await _schemes.GetSchemeAsync(IdentityConstants.TwoFactorUserIdScheme) != null) 864await Context.SignOutAsync(IdentityConstants.TwoFactorUserIdScheme); 1176var identity = new ClaimsIdentity(IdentityConstants.TwoFactorUserIdScheme); 1233if (await _schemes.GetSchemeAsync(IdentityConstants.TwoFactorUserIdScheme) != null) 1237await Context.SignInAsync(IdentityConstants.TwoFactorUserIdScheme, StoreTwoFactorInfo(userId, loginProvider)); 1266var 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, 660IdentityConstants.TwoFactorUserIdScheme, 668IdentityConstants.TwoFactorUserIdScheme); 676IdentityConstants.TwoFactorUserIdScheme, 685auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 723auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 724.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 764auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 765.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 803auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 804.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 887auth.Setup(a => a.SignOutAsync(context, IdentityConstants.TwoFactorUserIdScheme, It.IsAny<AuthenticationProperties>())).Returns(Task.FromResult(0)).Verifiable(); 893auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 894.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1142auth.Setup(a => a.SignOutAsync(context, IdentityConstants.TwoFactorUserIdScheme, It.IsAny<AuthenticationProperties>())).Returns(Task.FromResult(0)).Verifiable(); 1157auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 1158.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1192auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 1193.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1323auth.Setup(a => a.SignOutAsync(context, IdentityConstants.TwoFactorUserIdScheme, It.IsAny<AuthenticationProperties>())).Returns(Task.FromResult(0)).Verifiable(); 1750auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 1751.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1816auth.Setup(a => a.AuthenticateAsync(context, IdentityConstants.TwoFactorUserIdScheme)) 1817.ReturnsAsync(AuthenticateResult.Success(new AuthenticationTicket(id, null, IdentityConstants.TwoFactorUserIdScheme))).Verifiable(); 1906[IdentityConstants.TwoFactorUserIdScheme] = CreateCookieScheme(IdentityConstants.TwoFactorUserIdScheme),