Appearance
Full logging and masking Since v0.2
Security events, captures, traffic records and SIEM messages keep complete values by default: the full matched value, the full URL and query, every header including Cookie and Authorization, the user name, and the request body up to the size the inspection read. An analyst can then judge whether an attack is real, and an audit has the whole record. Control characters are escaped for safe display, and the length of the original bytes is kept.
For an application in card-payment scope you turn on masking. Masking replaces credentials, cookies, tokens, card numbers and fields marked sensitive. The viewer role always reads masked values.
Before you begin
- Role:
operatorchanges an application's masking.operatorwith access to every application changes the storage settings. - Decide masking before the application takes card traffic. Values already stored with masking off stay until they are pruned.
Mask logged values for an application
text
1. Open Applications > All applications, and select the application.
2. Open Request checks > Logging.
3. Set Mask logged values to pci.
4. Select Preview changes, add a comment and select Apply.sh
waap apps set -app shop -m "card payment scope" policy.logging.mask=pciyaml
applications:
- name: shop
policy:
logging:
mask: pciUse pci for applications in card-payment scope
Card numbers and authentication data must not be stored. With off, whatever the client sent is stored.
Who sees what
| Reader | Sees |
|---|---|
viewer | Masked values always. The API applies the pci masking when a viewer reads events, traffic records or exports, and the record says masked: role. |
operator, admin | Values as stored. |
Records of an application with pci | Masked in storage; the record says masked: pci. |
| The analyst and its tools | Full values only for an operator or admin. |
With session attribution on, a user name shows in full under off, hashed (first character and a keyed hash) under pci, and nobody is named when attribution is off. Counters and metrics never carry user names.
Control how much is kept
Sizes are limits, not masking. A value is cut only where the inspection stopped reading: the body at the application's request body limit, a header at the header size limit, a header list at the header count limit. A cut value ends with …[truncated: N bytes], where N is its full length. The event says so too: a reason has truncated and full_bytes, the capture has body_truncated, headers_truncated and headers_omitted, and body_files when the body carries uploaded files.
text
1. Open System > Settings > Event storage.
2. Set Request body kept per event, Retention, Most events kept and Most event storage.
3. Select Preview changes, then Apply.sh
waap settings set events -m "keep 60 days" retention=1440hyaml
events:
capture_body: 16KiB
retention: 720h
max_bytes: 2GiBLarge bodies fill storage sooner
With full values, large bodies use the storage budget faster. If events are pruned earlier than retention, raise max_bytes or lower capture_body.
Export events
Export writes the matching events as JSON lines, newest first. Each export is recorded in the audit log with its filter and count. A viewer receives masked values.
text
1. Open Events, set the filters.
2. Select Export.sh
waap events export -max 5000 -since 24htext
POST /v1/events/exportSIEM messages carry the same full values. The security stream leaves out the captured request and trace unless the destination turns on Include captured request and trace (JSON format). A message over 64 KiB is sent with its long values cut and marked with their full length; only a message that is still too large is dropped and counted. For details, see SIEM export.
Settings reference
Application logging
| Setting | What it does | Default | Allowed values | Applies in |
|---|---|---|---|---|
Mask logged values (policy.logging.mask) | Whether values are masked in storage. | off | off, pci | the application |
Traffic log (policy.logging.traffic) | Whether this application's requests enter the traffic log. | inherit | inherit, all, sample, off | the application |
Record response bodies (policy.logging.response_body) | Record this application's response bodies. Adds latency. | false | true, false | the application |
Event storage
| Setting | What it does | Default | Allowed values | Applies in |
|---|---|---|---|---|
Request body kept per event (events.capture_body) | Request body bytes stored with each event. | empty: each application's request body limit | size up to 64 KiB; 0 keeps none | all applications |
Retention (events.retention) | Events older than this are deleted. | 720h (30 days) | duration, at least 1h | all applications |
Most events kept (events.max_events) | The oldest events beyond this are deleted. | 1000000 | at least 1000 | all applications |
Most event storage (events.max_bytes) | The oldest events beyond this size are deleted. | 2 GiB | 1 MiB to 16 TiB | all applications |
Limits
| Limit | Value |
|---|---|
| Event body capture | at most 64 KiB |
| Export | default 10,000 events, at most 100,000 |
| SIEM message | 64 KiB before long values are cut |
Troubleshooting
Events are pruned earlier than the retention
- Cause: the storage size limit is reached first, usually because bodies are kept in full.
- Check: System > Settings > Event storage.
- Fix: raise Most event storage or lower Request body kept per event.
A viewer sees masked values
- Cause: the
viewerrole always reads masked values. - Fix: sign in as an operator or admin to read stored values.