Class BackOfficeAntiforgery
Anti-forgery implementation for the Umbraco back office
Inheritance
System.Object
Namespace: Umbraco.Cms.Web.BackOffice.Security
Assembly: Umbraco.Web.BackOffice.dll
Syntax
public class BackOfficeAntiforgery : IBackOfficeAntiforgery
Remarks
This is a wrapper around the global/default Microsoft.
Constructors
View SourceBackOfficeAntiforgery(IOptionsMonitor<GlobalSettings>)
Declaration
public BackOfficeAntiforgery(IOptionsMonitor<GlobalSettings> globalSettings)
Parameters
Type | Name | Description |
---|---|---|
Microsoft. |
globalSettings |
BackOfficeAntiforgery(IOptionsMonitor<GlobalSettings>, ILoggerFactory)
Declaration
public BackOfficeAntiforgery(IOptionsMonitor<GlobalSettings> globalSettings, ILoggerFactory loggerFactory)
Parameters
Type | Name | Description |
---|---|---|
Microsoft. |
globalSettings | |
Microsoft. |
loggerFactory |
Methods
View SourceGetAndStoreTokens(HttpContext)
Generates tokens to use for the cookie and header antiforgery values
Declaration
public void GetAndStoreTokens(HttpContext httpContext)
Parameters
Type | Name | Description |
---|---|---|
Microsoft. |
httpContext |
ValidateRequestAsync(HttpContext)
Validates the headers/cookies passed in for the request
Declaration
public async Task<Attempt<string>> ValidateRequestAsync(HttpContext httpContext)
Parameters
Type | Name | Description |
---|---|---|
Microsoft. |
httpContext |
Returns
Type | Description |
---|---|
Task<Attempt<System. |