Class AuthKeyValidator
Uses MAC address as key if no app setting is found.
Inheritance
System.Object
AuthKeyValidator
Implements
Namespace: ImageVault.Common.Lib.Web
Assembly: ImageVault.Common.dll
Syntax
public class AuthKeyValidator : Object, IAuthKeyValidator
Constructors
AuthKeyValidator(IEnumerable<IAuthKeyReader>, ILogger<AuthKeyValidator>)
Initializes a new instance of the AuthKeyValidator class.
Declaration
public AuthKeyValidator(IEnumerable<IAuthKeyReader> readers = null, ILogger<AuthKeyValidator> logger = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Collections.Generic.IEnumerable<IAuthKeyReader> | readers | |
| Microsoft.Extensions.Logging.ILogger<AuthKeyValidator> | logger |
Properties
Logger
Logger if the validator. Might be null if not set from the constructor
Declaration
protected ILogger<AuthKeyValidator> Logger { get; }
Property Value
| Type | Description |
|---|---|
| Microsoft.Extensions.Logging.ILogger<AuthKeyValidator> |
Methods
Validate(String)
Declaration
public void Validate(string keyToTest)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | keyToTest |
Exceptions
| Type | Condition |
|---|---|
| System.Exception | If authKey validation failed: or if authKey validation failed: . |