-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Audit Log
Sliver keeps an audit log of every command and its arguments executed by the server (including commands executed by operators in multiplayer mode), as well as most events (such as a new session opening). This will include any commands executed by any operator on any session, but note some console commands only perform actions on the "client-side" and may not appear in the audit log, but will still appear in the client's command history. Additionally, interactive commands (e.g., shell
) may not appear in the logs aside from the initial usage of the shell
command. The audit log's intended use is for after-action analysis; providing a detailed history of the entire engagement, including which commands were executed on which hosts when.
By default the audit log is located on the server at: ~/.sliver/logs/audit.json
. However, this can be changed by modifying the SLIVER_ROOT_DIR
environment variable.
The audit log is stored in a newline delimited nested-JSON format designed to be primarily machine readable, an example entry is shown below:
{"level":"info","msg":"{\"request\":\"{\\\"Port\\\":8888}\",\"method\":\"/rpcpb.SliverRPC/StartMTLSListener\"}","time":"2021-06-16T10:22:54-05:00"}
NOTE: Due to limitations in the logging APIs the audit log contains nested JSON objects that may require additional parsing.
The top level JSON should always contain:
-
level
- The level indicates the type of action performed. Currently,info
indicates commands andwarn
indicates events. -
msg
- A JSON object encoded as a string. This object should always contain arequest
and amethod
. The contents ofmethod
indicate which command was executed,request
will contain parameters to that command. The contents ofrequest
will vary depending on the command, but it will be based on the corresponding gRPC/Protobuf message. -
time
- The server's timestamp of the log entry
"Bred as living shields, these slivers have proven unruly—they know they cannot be caught."