SET TRUSTED ROLE
Sets the active role of the current session to the trusted role
DSQL
SET TRUSTED ROLE
The SET TRUSTED ROLE
statement makes it possible to assume the role assigned to the user through a mapping rule (see Mapping of Users to Objects).The role assigned through a mapping rule is assumed automatically on connect, if the user hasn’t specified an explicit role.The SET TRUSTED ROLE
statement makes it possible to assume the mapped (or “trusted”) role at a later time, or to assume it again after the current role was changed using SET ROLE
.
A trusted role is not a specific type of role, but can be any role that was created using CREATE ROLE
, or a predefined system role such as RDB$ADMIN
.An attachment (session) has a trusted role when the security objects mapping subsystem finds a match between the authentication result passed from the plugin and a local or global mapping to a role for the current database.The role may be one that is not granted explicitly to that user.
When a session has no trusted role, executing SET TRUSTED ROLE
will raise error “Your attachment has no trusted role”.
Note
|
While the |