Audit Log

An Audit log is a set of records for the sequence of NPS toolkit web activities. Log entries include host IP, path information, remote address, request method, response, server name, topology name, and user login information.

Location of Audit log file in the NPS toolkit VM: /var/nps/logs/audit_log

Audit log for user creation and token generation is present in nps_audit.log file.

The content of the Log file is as follows:
2019-02-19 12:48:07,826 nps.audit_log audit_log.py 72 INFO Logged in user info with performed action:
 {
    "HTTP_HOST": "10.14.132.102",
    "PATH_INFO": "/nps/v2/tokens/",
    "REMOTE_ADDR": "10.32.0.1",
    "REQUEST_METHOD": "POST",
    "RESPONSE": "201 CREATED",
    "SERVER_NAME": "10.14.132.102",
    "TOPOLOGY_NAME": "NA",
    "USER": "admin"
}

Audit log for all other NPS toolkit web activities is present in “<topology_name>_audit.log” file. The content of the Log file is as follows:
2019-02-27 06:46:46,438 nps.audit_log audit_log.py 72 INFO Logged in user info with performed action:
 {
    "HTTP_HOST": "10.14.132.102",
    "PATH_INFO": "/nps/v2/",
    "REMOTE_ADDR": "10.32.0.1",
    "REQUEST_METHOD": "POST",
    "RESPONSE": "201 CREATED",
    "SERVER_NAME": "10.14.132.102",
    "TOPOLOGY_NAME": "dhcp-test",
    "USER": "admin"
}