Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging of system/acl events in mod_logging #2057

Merged
merged 18 commits into from
May 6, 2019
Merged

Logging of system/acl events in mod_logging #2057

merged 18 commits into from
May 6, 2019

Conversation

mworrell
Copy link
Member

@mworrell mworrell commented May 3, 2019

Description

This re-uses mod_logging to log more system related events:

  • Sudo as another user
  • Config changes
  • Rate limiter on auth or reset kicking in
  • Error during file clamav checks on files
  • User changes
  • User role changes

Known Issues

  • We don't know the user who removed a user-group member (as this is signaled via the edge update log, which is filled via a trigger)

Checklist

  • documentation updated
  • tests added
  • no BC breaks

@mworrell mworrell added this to the 0.49 milestone May 3, 2019
@mworrell mworrell requested a review from ddeboer May 3, 2019 15:19
@mworrell mworrell mentioned this pull request May 3, 2019
4 tasks
@mworrell
Copy link
Member Author

mworrell commented May 6, 2019

@ddeboer Can you give this a test run?

@mworrell mworrell changed the title WIP: Logging of system events in mod_logging Logging of system/acl events in mod_logging May 6, 2019
src/models/m_config.erl Outdated Show resolved Hide resolved
@ddeboer
Copy link
Member

ddeboer commented May 6, 2019

Just pushed a fix for the status page, which breaks at z_db:transaction/2 because it has no database connection.

src/models/m_config.erl Outdated Show resolved Hide resolved
@mworrell
Copy link
Member Author

mworrell commented May 6, 2019

Which config was set by the status? We could also check on having a db connection, and if not then return an error code from the config-set

@ddeboer
Copy link
Member

ddeboer commented May 6, 2019

Ratelimit at the status login:

{rollback,{no_database_connection,[{m_config,set_value,4,[{file,"/Users/david/src/zotonic/src/models/m_config.erl"},{line,181}]},{mod_ratelimit,generate_device_secret, 
…

Checking db conn is probably better; feel free to change!

@mworrell mworrell merged commit 52cb13d into 0.x May 6, 2019
@mworrell mworrell deleted the logging branch May 6, 2019 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants