security: root-only backup credentials, internal-only key feed, corrected cadence

This commit is contained in:
inference-admin committed 2026-11-19 23:41:16 +00:00
1 parent d106f7cf01
commit 5ad233c612
3 files changed
+22 -14

No files matched your search

+12 -9
View File
@@ -34,15 +34,18 @@ exposure window is bounded by how fast misuse would show.
## What is in place instead (2026-11-05)
1. **Access logging on the route**: every fetch logs a WARNING line
`librechat key feed served: N member key(s) to <ip> (ua=…)`. Count only —
never key material, never member emails (the portal's log redactor strips
emails anyway).
2. **Daily-digest watch** (cron job 95e5b8fece86, §7 anomaly list): the
sandbox polls ~every 10 min (~144 serves/day expected). The digest counts
`librechat key feed served` lines and flags (a) a rate far above that
cadence, or (b) any 401 burst on the route — either is a suspected token
misuse and becomes a decision item.
1. **Internal-network restriction**: `/admin/librechat/keys` refuses any
request whose last `X-Forwarded-For` hop is a public address (`403 Internal
network only`). A stolen sync token used from the internet no longer looks
like the sandbox.
2. **Access logging on the route**: every fetch logs a WARNING line
`librechat key feed served: N member key(s) to <ip>`. Count and client
address only — never key material, never member emails.
3. **Daily-digest watch** (cron job 95e5b8fece86, §7 anomaly list): the
sandbox polls **every minute (~1,440/day) by design**; the old ~144/day
baseline was stale. The digest flags (a) a rate far above ~1/min, (b) any
401/ERROR burst, or (c) any `REFUSED for non-internal address` line —
either is suspected token misuse and becomes a decision item.
## What a real fix looks like (if ever needed)