Security Logging Format
The output of the security logger is written to console and contains these attributes
| Attribute | Description |
|---|---|
timestamp |
e.g. 2023-07-25T06:55:52.372Z |
environment |
Environment where the application is hosted. |
system |
|
application |
Name of the application e.g. macma. |
version |
Version of the application e.g. 1.24.1 |
instance |
|
thread |
Name of the thread e.g. http-nio-9095-exec-2 |
logger |
SECURITY |
loglevel |
WARN or INFO |
correlationId |
Unique id for one request. Used to collect all log messages of the same request. |
trace_id |
Unique trace id for monitoring. If no value is available the attribute is not present. |
span_id |
Unique span id for monitoring. If no value is available the attribute is not present. |
tenantId |
Most of the log messages are related to a tenant. In other cases is this attribute empty. |
userId |
Id of the user that is sending the request. For log messages which are not caused by a request this attribute is empty. |
sourceIp |
IP address of the originator of the request. Probably multiple values separated by comma. If the log message is not caused by a request this attribute is empty. |
event |
Type of the event e.g. INPUT_VALIDATION_FAILED, TLS_DISABLED, X_UNEXPECTED_EXCEPTION, X_METHOD_NOT_ALLOWED |
message |
Text of the log message describing reason and context. |
{"timestamp":"2023-07-25T06:55:52.372Z","environment":"","system":"","application":"macma-core","version":"1.24.1","instance":"","thread":"http-nio-9095-exec-2","logger":"SECURITY","loglevel":"WARN","correlationId":"e7eabdca503f4c038434e6b67047fa0a","tenantId":"3d132ee1-b7d4-4688-9470-be969a872daa","userId":"3e101471-4fc4-4643-ac67-5e2d3203cdbf","sourceIp":"192.168.65.4, 10.1.43.1","event":"INPUT_VALIDATION_FAILED","message":"Validation failed for field 'displayName' on TenantRole: rejected value [my-role§];displayName:Invalid text. Must not have leading or trailing whitespace, may contain alphanumeric characters and some special characters."}