LooT Manuals
Deutsch

Permissions

The LooT permission model in brief and loot permission grant, to give or deny users and groups permissions on the tenant, on nodes and on other objects.

The permission model in brief#

LooT grants permissions to users and groups. The workbench manual describes the permission model in detail; this page covers what you need for the command.

Who receives permissions

  • Users who are members of the tenant.
  • Groups of the tenant. Groups can contain other groups. The built-in group Everyone (named Jeder in the installation) automatically contains all members of the tenant. The server rejects a deny for Everyone.

A user's effective permissions are their own plus those inherited from the groups they belong to.

The permissions on nodes and other objects

PermissionOption for --rightsMeaning
ReadreadSee the node, its values and its subtree
WritewriteSet values. Devices usually need only this permission.
ExecuteexecuteTrigger commands
ManagemanageChange the structure: create, rename, move and delete nodes; change properties such as unit or description; grant permissions on the node
AllallRead, Write, Execute and Manage together

Permissions that exist only on the tenant

These permissions allow the recipient to create new things in the tenant or use functions. They have no effect on nodes.

PermissionOption for --rightsMeaning
Create data sourcescreate-sourcesSet up new data sources
Create componentscreate-componentsSet up new component usages
Create scriptscreate-scriptsCreate new scripts
Publish time rangespublish-timerangesShare time ranges with all members of the tenant
Use forecastsforecastUse the forecasts of the AI analysis
Ask AIchatAsk a language model questions
Assign realtimerealtimeMark nodes as realtime (Manage on the node is also needed)

Denials and inheritance

  • A permission on the tenant applies to all nodes of the tenant, one on a node to its whole subtree.
  • Permissions can be allowed or denied. A denial takes precedence over every allowance, even if it sits higher in the tree.
  • Links grant no permissions: access through a link needs permissions on the target.
  • Tenant admins and system admins have all permissions without needing an entry.

loot permission grant#

loot permission grant is the only command of the loot permission group. It sets the permission entry of a user or a group: on the tenant if you name no target, otherwise on each target you name.

text
loot permission grant --tenant <tenant> (--group <name> | --user <name>) --rights <rights>
                      [--deny] [--skip-missing]
                      [--node <path>]… [--chart <name>]… [--dashboard <name>]… [--workflow <name>]…
                      [--source <name>]… [--component <name>]… [--script <name>]…
OptionMeaning
--tenant <tenant>Required. Name or id of the tenant
--group <group>Name of the tenant's group
--user <user>Member of the tenant, by display name or e-mail address. If the name matches several members, give the e-mail address.
--rights <rights>Required. Permissions, separated by commas: read, write, execute, manage, all, create-sources, create-components, create-scripts, publish-timeranges, forecast, chat, realtime
--denyDenies the permissions instead of allowing them
--skip-missingSkips named charts, dashboards, workflows, data sources, components and scripts that do not exist instead of aborting
--node <path>Node as a target, repeatable. The path may be relative to the tenant (Plant.Line1) if you give --tenant by name.
--chart <name>Saved chart as a target, repeatable; * means all visible charts of the tenant
--dashboard <name>Dashboard as a target, repeatable; * means all visible ones
--workflow <name>Workflow as a target, repeatable; * means all visible ones
--source <name>Data source as a target, repeatable; * means all visible ones
--component <name>Component usage as a target, repeatable; * means all visible ones
--script <name>Script as a target, repeatable; * means all visible ones

Give exactly one of --group and --user. The target options can be mixed; without a target the entry applies to the tenant. The asterisk * applies to charts, dashboards, workflows, data sources, components and scripts, not to --node.

How the entry is set#

  • For each target there is one allow entry and one deny entry per user or group. loot permission grant replaces an existing entry that has other permissions with the new permissions: permissions are set, not added. If the permissions are equal the command leaves the entry unchanged, so a script may repeat it any number of times.
  • For each target the command prints one line: gesetzt (set), ersetzt (replaced) or unverändert (unchanged).
  • All targets are resolved before the first one is changed. A typo in the last name therefore leaves no half-set permissions behind. With --skip-missing the command skips missing named objects and reports them in its output.
  • The server decides which permissions a target accepts. It rejects unsuitable ones, for example create-sources on a node (the command reports the error with the target and exit code 1; targets already set stay set).
TargetPossible permissions
Tenantread, write, execute, manage, all and the tenant-only permissions
Noderead, write, execute, manage, all
Chart, dashboard, workflow, scriptread, write, manage
Data sourceread, manage
Component usageread, execute, manage

Examples#

A group may read in the whole tenant:

console
$ loot permission grant --tenant "Brewery" --group Operators --rights read
Tenant: gesetzt

A user may write values and trigger commands on a production line:

console
$ loot permission grant --tenant "Brewery" --user alice --rights read,write,execute --node Plant.Line1
Node 'Plant.Line1': gesetzt

If the selection of permissions changes, the entry is replaced; repeating the same call changes nothing:

console
$ loot permission grant --tenant "Brewery" --user alice --rights read,write --node Plant.Line1
Node 'Plant.Line1': ersetzt
$ loot permission grant --tenant "Brewery" --user alice --rights read,write --node Plant.Line1
Node 'Plant.Line1': unverändert

A group sees all charts and one particular dashboard and gets the permission to create scripts:

console
$ loot permission grant --tenant "Brewery" --group Analysts --rights read --chart "*" --dashboard "Line overview"
Chart 'Temperatures': gesetzt
Chart 'Throughput': gesetzt
Dashboard 'Line overview': gesetzt
$ loot permission grant --tenant "Brewery" --group Analysts --rights create-scripts
Tenant: gesetzt

A subtree stays closed to guests. A denial takes precedence over allowances:

console
$ loot permission grant --tenant "Brewery" --group Guests --rights read --deny --node Plant.Secret
Node 'Plant.Secret': gesetzt

Permissions for objects that do not exist in some tenants, without aborting:

console
$ loot permission grant --tenant "Brewery" --group Operators --rights read --dashboard "Line overview" --dashboard "Old board" --skip-missing
Dashboard 'Old board': übersprungen (gibt es im Tenant nicht)
Dashboard 'Line overview': gesetzt
A product of Rheinwert Datentechnik · rheinwert.deVersion: LooT 0.9.10