Forwarding the audit trail to a SIEM
This page is for administrators and hosting teams of public bodies that have a security operations center or a central log platform. Forwarding audit records off the web server means a compromised machine cannot quietly rewrite its own history, and lets your analysts correlate the site with the rest of your estate (Security hardening: Watching). The configuration comes from 6.5 SIEM forwarding.
Contents
The two sinks
| Sink | Transport | Good for |
|---|---|---|
syslog | local syslog/journald, UDP, TCP or TLS to a collector | the full stream, into any SIEM that reads syslog |
webhook | HTTPS POST, batched, signed with a shared secret (X-Exponential-Signature) | selected security events, into a SIEM's HTTP ingest |
Sinks are attached per channel ([AuditChannel_<channel>] Sinks[]); the webhook and network syslog deliveries are
spooled and sent by the cronjob part.
A configuration
In settings/override/audit.ini.append.php (never in version control):
[AuditSink_syslog]
Transport=tls
Host=siem.example.gov
Port=6514
Facility=local4
MinSeverity=info
[AuditSink_webhook]
URL=https://siem.example.gov/api/ingest/exponential
SigningSecret=<output of: openssl rand -hex 32>
BatchSize=200
MinSeverity=notice
Events[]
Events[]=access.*
Events[]=system.audit.*
Events[]=system.setting.*
[AuditChannel_content]
Sinks[]=syslog
[AuditChannel_access]
Sinks[]=webhook
[AuditChannel_system]
Sinks[]=webhook
[AuditChannel_commerce]
Sinks[]=syslogSinks[] lines append to the shipped lists, so access and system keep their shipped syslog entry. With TLS,
PHP verifies the collector's certificate against the system CA store.
Testing delivery
./console exp:audit sinks list --allow-root-user
./console exp:audit sinks test syslog --allow-root-user
./console exp:audit sinks test webhook --allow-root-userEach test sends one record; the receiver must answer with a 2xx status. The receiver checks the webhook signature;
in PHP the check is expAuditWebhookSink::verify( $body, $headers, $secret ).
Operating it
- Forward the daily signed checkpoints (
system.audit.checkpoint) as a minimum: they let you prove later that the local chain was not recomputed. - Monitor the spool:
./console exp:audit sinks flush --apply --allow-root-usersends what waits; the dashboard's Operations card shows the sinks. - Remember the privacy settings apply before forwarding: addresses truncated, sessions hashed. Agree the retention in the SIEM with your data protection officer.
- In a cluster, each server forwards its own records (6.3 Cluster).
Related pages
- Audit guide, 6.5 SIEM forwarding
- Audit integrity and verification
- Audit trail for hosts
- Free documentation: this page is free to copy, translate and improve under the GNU FDL 1.3.
Become an Exponential Partner
Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.