How to save extra data in Sessions table?

Hi everyone! I Hope you all are good. I want to know how to save extra data in session table when user successfully login. I am following cakephp default scheme for session table as official docs mention and there is only ID,DATA,EXPIRE fields are in session table… but i need other fields like user_id or device_info so how can i insert these data into session table during login, I am using Authentication/Authorization plugin for login and cakephp 5.
please if have any idea about it please share here!
Event I read docs about session but getting anything about extra things

I usually dont touch the sessions table
As usually a user can also be logged in mutliple times
E.g. 3 sessions, via browser, phone etc

So I use
OnlineActivities table that gets updated with session id and user id.
This way you can see what user is logged in and doing what with what device.

The advantage is that you can renove all user sessions.

1 Like

thanks @dereuromark me also thinking about create new table where save session id and user id or extra information, so thanks @dereuromark now i will create new table for tracking user activity