Skip to main content
All docs
V25.2
  • SecurityOptions.UserType Property

    Specifies the application user type.

    Namespace: DevExpress.ExpressApp.Security

    Assembly: DevExpress.ExpressApp.Security.v25.2.dll

    NuGet Package: DevExpress.ExpressApp.Security

    Declaration

    public Type UserType { get; set; }

    Property Value

    Type Description
    Type

    The type of application users.

    Remarks

    static IServiceCollection ConfigureSecurity(this IServiceCollection services) {
        services.PostConfigure<SecurityOptions>(options => {
            options.Lockout.Enabled = true;
            options.Lockout.MaxFailedAccessAttempts = 3;
            options.RoleType = typeof(PermissionPolicyRole);
            options.UserType = typeof(ApplicationUser);
            options.UserTokenType = typeof(UserToken);
            options.UserLoginInfoType = typeof(ApplicationUserLoginInfo);
            options.SupportNavigationPermissionsForTypes = false;
            options.Events.OnSecurityStrategyCreated += securityStrategy => {
                ((SecurityStrategy)securityStrategy).PermissionsReloadMode = PermissionsReloadMode.CacheOnFirstAccess;
            };
        });
    

    Refer to the MainDemo.NET.EFCore demo application for the full code example.

    The following code snippets (auto-collected from DevExpress Examples) contain references to the UserType property.

    Note

    The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

    See Also