Table of Contents

RecroSec Configuration

Configure RecroSec, the integrated authorization system of the RecroGrid Framework, through the backend application settings.

Authentication configuration is available under Authentication.

RecroSec settings

Configure RecroSec under Recrovit:RecroSec in the backend application settings.

"Recrovit": {
  "RecroSec": {
    "Enabled": true,
    "SingleUserMode": false,
    "AutoCreateUser": true,
    "AdministratorRoleName": "RGF.Administrators",
    "DefaultRoleName": "RGF.Users"
  }
}

Available settings:

  • Enabled: Enables RecroSec globally. With global RecroSec enabled, objects participate in the RecroSec permission configuration. Entity-level configuration is available through RGO_RecroSec when global enablement is not used.
  • SingleUserMode: Treats the application as a single-user application and considers all RecroSec permission checks successful.
  • AutoCreateUser: Controls automatic user creation in the RecroSec integration.
  • AdministratorRoleName: Defines the administrator role name. A typical value is RGF.Administrators.
  • DefaultRoleName: Defines the default role name assigned by the RecroSec configuration. Use the role name configured by the application, such as RGF.Users or Users.

SingleUserMode is useful in local development when direct access to the RecroGrid Framework API is needed without obtaining an Access Token. For example, it allows API requests to be tested conveniently from Postman or another API client while RecroSec treats the caller as fully authorized.

Historically, before automatic RecroGrid Framework database migration was available, the same behavior was also used to bootstrap a new database through the built-in API administration interface before an administrator existed. In the current Blazor application model, the migration command is not exposed through the Blazor UI, and the recommended AutoMigrateRGFDatabase: true workflow removes the need for this bootstrap step. See Database Settings for migration details.

When AutoCreateUser is true and RgfIdentity does not yet contain any users, the first user created by RecroSec is automatically assigned the administrator role configured by AdministratorRoleName.

SingleUserMode is independent of this administrator assignment behavior.

Configure the general RecroGrid Framework menu scope separately under Recrovit:RecroGridFramework:

"Recrovit": {
  "RecroGridFramework": {
    "DefaultMenuScope": ";identity;"
  }
}

DefaultMenuScope belongs to the RecroGridFramework configuration section and defines the default menu scope used by the application.

See Also