audit-receiver

command
v0.6.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 9, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

audit-receiver is the off-node sink the security scenarios export to (plans/integration-test-security.md §6.4). Webhook audit export needs something listening; this is that something. It is not a witness: the enterprise scenarios witness chain heads in an S3 Object Lock bucket, with the same daemon a release ships (plans/open-audit-witness.md, Phase 4).

It is a TEST FIXTURE. It lives under integration-tests/ and never under pkg/, it keeps everything in memory plus one append-only file, and it is deliberately not hardened for anything but a throwaway scenario box.

Two things make it more than a bit bucket:

  • it verifies what the daemon actually signed, using auditexport.VerifySignature — the same function the exporter signs with, exported for exactly this purpose. A receiver that accepted anything would let a broken signature pass as a green test.
  • /_chaos/fail makes it return 503 for the next N requests, so a scenario can prove the exporter's backoff and at-least-once redelivery (pkg/auditexport/backoff.go) instead of only the happy path. 503 is chosen deliberately: the exporter classifies 429 and 5xx as Temporary and retries them, while a 4xx is a receiver-config error. Returning the wrong class would test the wrong path.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL