1 implementation of GetAndStoreTokens
Microsoft.AspNetCore.Antiforgery (1)
Internal\DefaultAntiforgery.cs (1)
40public AntiforgeryTokenSet GetAndStoreTokens(HttpContext httpContext)
18 references to GetAndStoreTokens
Microsoft.AspNetCore.Antiforgery (1)
IAntiforgery.cs (1)
33/// Unlike <see cref="GetAndStoreTokens(HttpContext)"/>, this method has no side effect. The caller
Microsoft.AspNetCore.Components.Endpoints (1)
RazorComponentEndpointInvoker.cs (1)
73antiforgery!.GetAndStoreTokens(context);
Microsoft.AspNetCore.Mvc.FunctionalTests (5)
AntiforgeryMiddlewareTest.cs (4)
38var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 122var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 154var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 186var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext());
SimpleWithWebApplicationBuilderTests.cs (1)
268var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext());
Microsoft.AspNetCore.Mvc.ViewFeatures (1)
AntiforgeryExtensions.cs (1)
36var tokenSet = antiforgery.GetAndStoreTokens(httpContext);
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (2)
AntiforgeryExtensionsTest.cs (1)
22.Setup(a => a.GetAndStoreTokens(It.IsAny<HttpContext>()))
DefaultHtmlGeneratorTest.cs (1)
1010.Setup(mock => mock.GetAndStoreTokens(It.IsAny<DefaultHttpContext>()))
Microsoft.AspNetCore.Routing.FunctionalTests (7)
MinimalFormTests.cs (7)
52var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 112var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 473var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 532var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 584var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 636var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext()); 685var tokens = antiforgery.GetAndStoreTokens(new DefaultHttpContext());
MinimalFormSample (1)
Program.cs (1)
18var token = antiforgery.GetAndStoreTokens(context);