Class BackOfficeExternalLoginProviders
Service to return BackOfficeExternalLoginProvider instances
Inheritance
System.Object
Namespace: Umbraco.Cms.Web.BackOffice.Security
Assembly: Umbraco.Web.BackOffice.dll
Syntax
public class BackOfficeExternalLoginProviders : IBackOfficeExternalLoginProviders
Constructors
View SourceBackOfficeExternalLoginProviders(IEnumerable<BackOfficeExternalLoginProvider>, IAuthenticationSchemeProvider)
Declaration
public BackOfficeExternalLoginProviders(IEnumerable<BackOfficeExternalLoginProvider> externalLogins, IAuthenticationSchemeProvider authenticationSchemeProvider)
Parameters
| Type | Name | Description |
|---|---|---|
| IEnumerable<BackOfficeExternalLoginProvider> | externalLogins | |
| Microsoft.AspNetCore.Authentication.IAuthenticationSchemeProvider | authenticationSchemeProvider |
BackOfficeExternalLoginProviders(IEnumerable<BackOfficeExternalLoginProvider>, IAuthenticationSchemeProvider, IKeyValueService, IExternalLoginWithKeyService, IUserService, ILogger<BackOfficeExternalLoginProviders>)
Declaration
public BackOfficeExternalLoginProviders(IEnumerable<BackOfficeExternalLoginProvider> externalLogins, IAuthenticationSchemeProvider authenticationSchemeProvider, IKeyValueService keyValueService, IExternalLoginWithKeyService externalLoginWithKeyService, IUserService userService, ILogger<BackOfficeExternalLoginProviders> logger)
Parameters
| Type | Name | Description |
|---|---|---|
| IEnumerable<BackOfficeExternalLoginProvider> | externalLogins | |
| Microsoft.AspNetCore.Authentication.IAuthenticationSchemeProvider | authenticationSchemeProvider | |
| IKeyValueService | keyValueService | |
| IExternalLoginWithKeyService | externalLoginWithKeyService | |
| IUserService | userService | |
| Microsoft.Extensions.Logging.ILogger<BackOfficeExternalLoginProviders> | logger |
Methods
View SourceGetAsync(String)
Get the BackOfficeExternalLoginProvider for the specified scheme
Declaration
public async Task<BackOfficeExternaLoginProviderScheme> GetAsync(string authenticationType)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | authenticationType |
Returns
| Type | Description |
|---|---|
| Task<BackOfficeExternaLoginProviderScheme> |
GetAutoLoginProvider()
Returns the authentication type for the last registered external login (oauth) provider that specifies an auto-login redirect option
Declaration
public string GetAutoLoginProvider()
Returns
| Type | Description |
|---|---|
| System.String |
GetBackOfficeProvidersAsync()
Get all registered BackOfficeExternalLoginProvider
Declaration
public async Task<IEnumerable<BackOfficeExternaLoginProviderScheme>> GetBackOfficeProvidersAsync()
Returns
| Type | Description |
|---|---|
| Task<IEnumerable<BackOfficeExternaLoginProviderScheme>> |
HasDenyLocalLogin()
Returns true if there is any external provider that has the Deny Local Login option configured
Declaration
public bool HasDenyLocalLogin()
Returns
| Type | Description |
|---|---|
| System.Boolean |
InvalidateSessionsIfExternalLoginProvidersChanged()
Used during startup to see if the configured external login providers is different from the persisted information. If they are different, this will invalidate backoffice sessions and clear external logins for removed providers if the external login provider setup has changed.
Declaration
public void InvalidateSessionsIfExternalLoginProvidersChanged()