Masquerade
Masquerade is a feature that allows administrators to temporarily assume the identity of another user in the system. This can be useful for troubleshooting issues or providing support to users.
How do I use masquerade with Blueprint?
The Kraken support site is used to masquerade as a user in Blueprint. This is done using the 'masquerade' button found under the 'users' tab of the account they would like to masquerade as.
This action generates a URL with the user's ID and a masquerade token. Blueprint's middleware file and matcher config check if the current route is /masquerade
. The userID and masqueradeToken are then taken from the URL and used as the input values of the masqueradeAuthentication
mutation within the middleware.
If the mutation is successful, the masquerade token is stored in a cookie. The administrator is then redirected to the dashboard and is now masquerading as the selected user. The session state is updated to reflect that the administrator is currently masquerading.
When does a masquerade session end?
The administrator may use the Logout button to stop masquerading as a user. The session will also expire when the browser window is closed, however, this session may still be restored using the browsers "session restore" feature.