UserCodeNormalizer Class
Abblix.Oidc.Server
Abblix.Oidc.Server.Features.DeviceAuthorization
UserCodeNormalizer Class
Canonicalizes user-entered user codes for the Device Authorization Grant (RFC 8628) following the input-processing guidance in Section 6.1: punctuation added for readability (dashes, spaces) and any other characters outside the configured alphabet are dropped, and case is folded when the alphabet is single-case so that a user typing the equivalent lowercase (or uppercase) form is not rejected.
public class UserCodeNormalizer : Abblix.Oidc.Server.Features.DeviceAuthorization.Interfaces.IUserCodeNormalizer
Inheritance System.Object → UserCodeNormalizer
Implements IUserCodeNormalizer
Constructors
UserCodeNormalizer(IOptions<OidcOptions>) Constructor
Canonicalizes user-entered user codes for the Device Authorization Grant (RFC 8628) following the input-processing guidance in Section 6.1: punctuation added for readability (dashes, spaces) and any other characters outside the configured alphabet are dropped, and case is folded when the alphabet is single-case so that a user typing the equivalent lowercase (or uppercase) form is not rejected.
public UserCodeNormalizer(Microsoft.Extensions.Options.IOptions<Abblix.Oidc.Server.Common.Configuration.OidcOptions> options);
Parameters
options Microsoft.Extensions.Options.IOptions<OidcOptions>
Configuration options carrying the user code alphabet.
Methods
UserCodeNormalizer.Normalize(string) Method
Produces the canonical form of a user code for comparison: characters outside the configured alphabet are removed, and case is folded when the alphabet is single-case.
public string Normalize(string userCode);
Parameters
userCode System.String
The raw user code as entered by the end-user.
Implements Normalize(string)
Returns
System.String
The canonical user code used for storage lookup and rate limiting.