[Feature Request] Audit Logging #1779

Closed
opened 2026-02-05 01:50:56 +03:00 by OVERLORD · 8 comments
Owner

Originally created by @evilexecutable on GitHub (Jul 6, 2020).

Describe the feature you'd like
We use bookstack in a corporate environment to hold a lot of our internal documentation. As a system administrator, I have no way of tracking user logins, user events (page read, files downloaded).

Describe the benefits this feature would bring to BookStack users
Being able to audit users will allow for monitoring of bad behavior, as well as ensuring users are using the system correctly, and can find the information they need.

Originally created by @evilexecutable on GitHub (Jul 6, 2020). **Describe the feature you'd like** We use bookstack in a corporate environment to hold a lot of our internal documentation. As a system administrator, I have no way of tracking user logins, user events (page read, files downloaded). **Describe the benefits this feature would bring to BookStack users** Being able to audit users will allow for monitoring of bad behavior, as well as ensuring users are using the system correctly, and can find the information they need.
OVERLORD added the :cat2:🐈 Possible duplicate label 2026-02-05 01:50:56 +03:00
Author
Owner

@c0shea commented on GitHub (Jul 6, 2020):

There is some logging of events in the activities and views tables.

@c0shea commented on GitHub (Jul 6, 2020): There is some logging of events in the `activities` and `views` tables.
Author
Owner

@ssddanbrown commented on GitHub (Jul 11, 2020):

Thanks for the suggestion @evilexecutable,

As said by @c0shea, Many, although not all, events can be found in the activities table and some level of per-user+item view activity can be found in the views table. I've been wanting to expose some of this in the admin interface for the last couple of releases but have lacked the time,

It's unlikely I'll look to track individual events for read-only events since the scale may start to introduce it's own options but we'd look to cover all operations that cause changes.

I feel this is already covered by existing issues #848, #1167 & #1243 so I'll close this off as a duplicate.

@ssddanbrown commented on GitHub (Jul 11, 2020): Thanks for the suggestion @evilexecutable, As said by @c0shea, Many, although not all, events can be found in the `activities` table and some level of per-user+item view activity can be found in the `views` table. I've been wanting to expose some of this in the admin interface for the last couple of releases but have lacked the time, It's unlikely I'll look to track individual events for read-only events since the scale may start to introduce it's own options but we'd look to cover all operations that cause changes. I feel this is already covered by existing issues #848, #1167 & #1243 so I'll close this off as a duplicate.
Author
Owner

@ssddanbrown commented on GitHub (Sep 19, 2020):

An audit log interface will be available as part of the upcoming v0.30 release:

image

@ssddanbrown commented on GitHub (Sep 19, 2020): An audit log interface will be available as part of the upcoming v0.30 release: ![image](https://user-images.githubusercontent.com/8343178/93666466-6a04b600-fa76-11ea-9a60-97383c175f9f.png)
Author
Owner

@stonemaker01 commented on GitHub (Sep 30, 2020):

This is a nice feature. Could this be extended (and filtered) to user sign in logs? This way i can monitor user activities regarding frequency, moment in day, and inactive accounts.

Ultimately auto sign out users when update need to be implemented.

@stonemaker01 commented on GitHub (Sep 30, 2020): This is a nice feature. Could this be extended (and filtered) to user sign in logs? This way i can monitor user activities regarding frequency, moment in day, and inactive accounts. Ultimately auto sign out users when update need to be implemented.
Author
Owner

@Cave-Johnson commented on GitHub (Sep 30, 2020):

Love the new audit log, thanks for that @ssddanbrown!

Agree it would be nice to get user logins added to this. Alternatively (or in addition) on the "users" tab, add a column with the users last sign in (similar to how gitlab does it)
image

@Cave-Johnson commented on GitHub (Sep 30, 2020): Love the new audit log, thanks for that @ssddanbrown! Agree it would be nice to get user logins added to this. Alternatively (or in addition) on the "users" tab, add a column with the users last sign in (similar to how gitlab does it) ![image](https://user-images.githubusercontent.com/19388624/94689017-3d7a5500-0326-11eb-8ee5-e8f8778916da.png)
Author
Owner

@ssddanbrown commented on GitHub (Sep 30, 2020):

@stonemaker01 @Cave-Johnson Yeah, The intention is to extend this out to other event types including sign-ins. I'm aware that #848 is still open for that.

@ssddanbrown commented on GitHub (Sep 30, 2020): @stonemaker01 @Cave-Johnson Yeah, The intention is to extend this out to other event types including sign-ins. I'm aware that #848 is still open for that.
Author
Owner

@SudoComrade commented on GitHub (Aug 14, 2021):

@ssddanbrown Is there any default retention time for the audit log or a way to customize it to purge the audit logs which are more than 30 days old or something like that :) ?

@SudoComrade commented on GitHub (Aug 14, 2021): @ssddanbrown Is there any default retention time for the audit log or a way to customize it to purge the audit logs which are more than 30 days old or something like that :) ?
Author
Owner

@ssddanbrown commented on GitHub (Aug 16, 2021):

@SudoComrade nothing like that in right now, apart from a command to delete all. It's all part of the activities table if you wanted to run something yourself on the MySQL side of things.

@ssddanbrown commented on GitHub (Aug 16, 2021): @SudoComrade nothing like that in right now, apart from a command to delete all. It's all part of the `activities` table if you wanted to run something yourself on the MySQL side of things.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#1779