How to Implement Session Timeout / Auto Logout with Orthanc Authorization Plugin

Hello everyone,

I’m currently using Orthanc with the Authorization Plugin, Keycloak, and an external authorization web service to handle user authentication and role-based access control.

I’d like to know if there is any built-in support or recommended approach to automatically log out users after a period of inactivity. Ideally, I’m looking for a way to enforce session timeout or idle session expiration to improve security.

Has anyone implemented something similar or found a good pattern for this use case?

Thanks in advance!

Hello Acatana,

There are some parameters related to the session in the Keycloak configuration, see https://www.keycloak.org/docs/latest/server_admin/index.html#_timeouts

There is a pre-configured sample here:

I hope this helps!
Feel free to clarify is you are looking for something else…

Regards,