Several components usually sit between producing an audit event and making it available for investigation. Each should explain what it accepted, where it stored the data and what happens on failure. This note presents implementation ideas for central logging without collector code or server configuration.
01 / Separate acknowledgment points in the delivery path
Start with stages for Shell or system events, local acceptance, buffering, remote acceptance, persistence and search. Define success for each stage. Writing to a local interface does not establish remote storage, while unavailable search does not necessarily mean the underlying data was lost.
- Distinguish memory queues, disk queues and persistence acknowledgments, including possible loss during process crashes, power failure and full disks.
- rsyslog disk-assisted queues still use memory. Enabling disk support does not mean every event is on disk; evaluate checkpoints, synchronization and orderly shutdown behavior.
- Bound sending and processing so backend failures do not indefinitely block interactive entry points.
- Record queueing, acceptance, persistence and search availability times separately to locate delays.
02 / Normalize fields while retaining source semantics
Common fields can cover event identifiers, hosts, boots, sessions, processes, identities, collector versions and source types. Retain the original meanings of Shell, Linux Audit and sudo data rather than reducing everything to an unexplained “command succeeded” record.
- Separate source time, receipt time and order within a session. Do not conceal differences between host clocks.
- Store syscall return values, Shell status and application results separately instead of overloading a status field.
- Define structured encoding and truncation markers for multiline content, control characters and oversized records to preserve record boundaries.
- When a relay or agent sends records, preserve both original event identity and forwarding identity; the agent's process identity is not the operator.
- Make failed correlation, unknown fields and parsing failures searchable so coverage gaps can be found.
03 / Handle sensitive fields before the first persistent write
Arguments, working directories, redirection targets and terminal output can contain secrets or personal information. Define which fields have a concrete purpose before collecting raw text. Hiding content only in the search interface does not remove values already written to buffers, files or backups.
- Minimize collection first; do not automatically collect the entire environment or all terminal output.
- For necessary text, evaluate redaction before the first persistent write and mark omitted or transformed fields.
- String matching cannot recognize every secret. Improve handling through argument categories, structured sources and sample reviews.
- If investigations require restricted raw evidence, give it separate encryption, access and retention policies, explicitly distinguishing it from the redacted search view.
- Use synthetic scenarios in public examples. Removing a few obvious fields is not sufficient preparation for publishing real logs.
04 / Define retry, duplication and ordering behavior
An approach can combine authenticated encrypted transport with bounded local buffering during remote outages. TLS protects transport and authenticates peers; it does not independently establish that every event generated by an endpoint is true or complete.
- Keep event identifiers stable across retries and make repeated acceptance idempotent.
- Distinguish protocol acknowledgments from storage acknowledgments. TCP, TLS or RELP alone does not establish end-to-end exactly-once delivery.
- Use session sequence numbers to help identify gaps without inventing a globally proven order across all hosts.
- Define retry backoff, queue limits, expiry and certificate renewal, making failures visible.
- After an outage, verify replay, deduplication and preservation of original timestamps, not only restored connectivity.
05 / Design integrity and administration separately
Central storage can reduce the impact of individual host failures or local log changes, but ownership still matters: who changes collection, who reads content and who deletes records. Separating operational privileges from audit storage administration reduces the risk of one account controlling the entire chain of evidence.
- Define retention, access and export procedures around investigation needs, while recording access to and changes in audit data itself.
- If using digests or signatures, identify where trusted keys and verification baselines reside. An actor able to rewrite both data and its digest can still undermine verification.
- Immutable retention or independent storage can protect accepted data, but cannot recover events missed before collection or during transport.
- Test restoration of data, search indexes and permissions without broadening access to raw records.
06 / Validate the whole path with failure scenarios
Cover traffic spikes, network outages, stopped receivers, full disks, invalid certificates, collector restarts, rotation, clock differences and partially damaged records. For each scenario, define acceptable interactive impact, loss boundaries, alert timing and recovery requirements.
Useful signals include the age of the oldest unsent event, queue depth, discarded records, parsing failures, truncation, receipt latency and collection configuration changes. A host with no logs may have no activity or a failed collection path; distinguish these using collector health and controlled verification events.
For input design, see Shell collection ideas. For combining evidence sources, see Linux Audit and sudo. This series describes designs and acceptance methods; actual coverage must be validated in the target environment.
References
- rsyslog: queue concepts
- rsyslog: reliable forwarding
- rsyslog: TLS access control
- systemd: official journal field documentation source