Skip to content

feat: pseudonymize source addresses in logs - #70

Closed
fionera wants to merge 1 commit into
agent/session-correlationfrom
agent/pseudonymous-source-logs
Closed

fionera wants to merge 1 commit into
agent/session-correlationfrom
agent/pseudonymous-source-logs

Conversation

@fionera

@fionera fionera commented Jul 10, 2026

Copy link
Copy Markdown
Member

Stacked on #63 so the privacy documentation can accurately describe support IDs.

What

  • Replace plaintext source addresses in Go agent logs with a 128-bit, domain-separated HMAC pseudonym.
  • Replace %ci in the example HAProxy log with a separately keyed 256-bit SHA-2 pseudonym.
  • Add the BERGHAIN_SOURCE_LOG_KEY Compose setting and document production key requirements and retention limits.
  • Correct the help page’s previous claim that nothing can survive cookie expiry.

Why

The omnibus branch reused the cookie HMAC and called low-entropy IP hashing irreversible. These values are pseudonymous, not anonymous: an operator with the key can enumerate IPv4 candidates, and ordinary infrastructure logs remain subject to operator retention.

Validation

  • go test -race ./..., go vet ./..., and staticcheck ./...
  • Both frontend builds and HAProxy config validation
  • Live access-log test matched the keyed pseudonym and found no plaintext source address
  • Full Compose privacy-log validation

@fionera
fionera force-pushed the agent/session-correlation branch 2 times, most recently from 4658a0d to 54bfba8 Compare July 10, 2026 15:02
@fionera
fionera force-pushed the agent/pseudonymous-source-logs branch from 1c00adf to 08b9b82 Compare July 10, 2026 15:03
@fionera
fionera force-pushed the agent/session-correlation branch from 54bfba8 to 1220e5c Compare July 10, 2026 15:13
@fionera
fionera force-pushed the agent/pseudonymous-source-logs branch from 08b9b82 to 3c3b9e1 Compare July 10, 2026 15:14
@fionera
fionera force-pushed the agent/session-correlation branch from 1220e5c to 7823ebb Compare July 10, 2026 18:47
@fionera
fionera force-pushed the agent/pseudonymous-source-logs branch from 3c3b9e1 to dfb5ca2 Compare July 10, 2026 18:48
@fionera
fionera force-pushed the agent/session-correlation branch from 7823ebb to b17c22a Compare July 10, 2026 19:03
@fionera
fionera force-pushed the agent/pseudonymous-source-logs branch from dfb5ca2 to 8e1d0f5 Compare July 10, 2026 19:03
@fionera fionera closed this Jul 11, 2026
@fionera
fionera deleted the agent/pseudonymous-source-logs branch July 11, 2026 01:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant