Admin-level audit logging
- Dominant language
- Erlang
- Stars
- 7k
- Forks
- 1.1k
- Avg merge
- 1d 16h
- Merged PRs (30d)
- 9
Description
The idea is to log, with detail, any admin-level changes made thru the HTTP interface (or Erlang `remsh`? Hm.)
Logging any configuration changes to a node for posterity is useful for documentation and forensic purposes. At a minimum, I propose to force-log the entire payload to any `/_node/*/_config` endpoint, regardless of logging level.
This could be disable-able, but that would defeat the purpose, since a hacker finding a way around in-built security features would simply reconfigure that value first, before proceeding to more sensitive endpoints. So, perhaps, it's an opt-in thing you enable from `vm.args`, with the understanding that secrets may be logged in it (e.g. changing/setting a password).
## Context
Forensic investigation of hacked CouchDB servers (due to disclosed CVEs) is complicated by the fact that logging of what config changes have been made is terse to the point of uselessness, even at debug level.
Contributor guide
Research direction
Start by tracing the HTTP `/_node/*/_config` endpoints and the existing logging of configuration changes; the issue does not name specific source files or tests. Clarify whether Erlang `remsh` is in scope and decide how `vm.args` enables the behavior, including the treatment of secrets. Done should mean admin-level configuration changes are recorded with enough detail for forensic investigation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- erlang
- Domain
- api, databases, security
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100