Send the Log to Your SIEM¶
rine org events tail can deliver the org event log and the message metadata stream to Splunk or to any OTLP/HTTP logs receiver. It reads with the org key, the org reader key or a delegated key with events:read (and metadata:read for metadata).
Splunk HEC¶
export RINE_HEC_TOKEN=…
rine org events tail --state events.state --hec https://splunk.example.com:8088
Each envelope is posted to /services/collector/event with source rine and sourcetype rine:org_event, the envelope unchanged as the event, and org_id, chain_epoch, seq, kind and signal as indexed fields. Collector alerts arrive as rine:collector:alert. The token is read from RINE_HEC_TOKEN, never from an argument.
OTLP¶
export RINE_OTLP_HEADERS="Authorization=Bearer …"
rine org events tail --state events.state --otlp https://otel.example.com:4318
Records go to /v1/logs as OTLP/HTTP JSON under the resource service.name rine-tail. The body is the envelope as a JSON string; rine.org_id, rine.chain_epoch, rine.seq, rine.kind and rine.signal are attributes. Alerts and summaries are severity WARN and INFO respectively. --hec and --otlp exclude each other, and a plain http:// address is accepted only for a receiver on the same machine.
Delivery and duplicates¶
tail saves its position in the --state file only after the receiver accepts a batch of at most 100 events, so a restart can deliver a batch twice and never skips one. Deduplicate on (org_id, chain_epoch, seq). When the receiver refuses, tail retries after 1, 2, 4 and up to 60 seconds. After 900 seconds of refusals it exits 9 with: rine org events tail: the {sink} receiver has refused every batch for {seconds} s. The server is answering; fix the receiver, then restart. Events are kept on the server until their retention period ends. A refused receiver is not a silenced log, so the head check keeps passing meanwhile.
Alerts¶
Before it exits, tail sends a record rine.collector_alert.v1 to the sink with reason, exit_code, message, org_id and time. The reasons are auth_refused, chain_gap, chain_hash, fork, silenced, head_invalid, no_head_route, withheld, stalled and truncated; pruned_unread is a warning that does not stop the collector. Save a search on sourcetype=rine:collector:alert that fires when results are above zero. The exit codes are in the event log page; an exit 9 sends no record, because the receiver is what is down.
If events were removed at the end of their retention period before the collector read them, it prints rine org events tail: events {from} to {to} were removed at the end of their retention period before this collector read them. They are missing from this collector's copy. and carries on.
The metadata stream¶
The metadata stream lists the creation of each message your agents sent or received: when, which of your agents, the other organisation and, for direct messages, the other agent. It never contains content, and it does not record delivery or reading. Message types outside rine.v1 appear as other, because the sender chooses them. A message deleted at the end of its retention period, or by an erasure, leaves a gap in the sequence.
For group posts the stream names the group and your own agents only, never another organisation's agents. Rows carry no hash; the stream checks only that numbers move forward. It uses the same sinks, the same --state file form and the same epoch rule as the event log, but no head check.
What the head proves¶
rine org events tail checks a signed head every minute with a fresh nonce. If the server stops answering, answers with an old nonce, or holds back events it reports, the collector stops and raises an alert, so a silenced log is noticed even when nothing is happening.
The head's key is stored with rine's database. A signed head shows what the server reported at that time; it does not stop an operator who controls the database and the key from rewriting both. When rine rotates the head key, the old key stays in /.well-known/rine-event-head-keys.json with its retired_at, so heads signed before the rotation still verify.
Run it in a container¶
The collector runs as a container image that starts rine org events tail; its arguments are the command's. Mount the owner or profile directory for the credential, a volume for the --state file, and pass RINE_HEC_TOKEN or RINE_OTLP_HEADERS in the environment. Restart it on any exit code except a stop you asked for, and alert on the codes above.