Skip to main content

DeviceAuthorizationOptionsValidator Class

Abblix.Oidc.Server

Abblix.Oidc.Server.Endpoints.DeviceAuthorization

DeviceAuthorizationOptionsValidator Class

Fails loudly the first time OidcOptions is resolved when the device authorization endpoint is enabled but its settings are absent, instead of letting the contradiction surface as an unhandled HTTP 500 on the first request. The endpoint is off in the default Base set and is turned on only by an explicit AddDeviceAuthorization() opt-in (or a host that sets the DeviceAuthorization flag itself), yet DeviceAuthorization has no default — so a host that enables it without configuring it has an internally inconsistent configuration this validator turns into a clear startup error. A no-op when the endpoint is disabled or the settings are present.

public class DeviceAuthorizationOptionsValidator : Microsoft.Extensions.Options.IValidateOptions<Abblix.Oidc.Server.Common.Configuration.OidcOptions>

Inheritance System.Object → DeviceAuthorizationOptionsValidator

Implements Microsoft.Extensions.Options.IValidateOptions<OidcOptions>