Explore Knowledge Base

Default Users (All roles)

23. 12. 2024

By the System set-up there are pre-registered default users in the system, with assigned default permissions.

Deletion of the default Administrator user without any other administrator user who can manage users and create an administrator will lead to a situation when the system can’t be manageable. So now the System does not allow to delete the default user with the administrator role or changing their permission to manage users if there is no other administrator user (deletion of the default administrator user or deletion of their permission to manage users was prevented).

System flow when using an  API DELETE /v1​/users​/{userId} to delete a user with an administrator role:

  • System checks if there is any other user with the administrator role
    • if yes – allow to delete user
    • if no return error “Deletion of the last administrator user is not allowed”

isDefault=true/false parameter in the User entity for all roles

  • there is isDefault=true/false parameter in the User entity (parameter is set in application-bootstrap.yaml for all predefined .tech users of all roles)
  • deletion of the tech (isDefault=true) users of all supported roles (all default users) is disallowed
  • set isActive=false for the Administrator user is disallowed for all other users, no Administrator role (even with user management permission)