security: document timestamped HMAC on the key feed
This commit is contained in:
1 parent
ec7fa33c77
commit
e2879dbdc2
1 file changed
+8
-2
@@ -38,10 +38,16 @@ exposure window is bounded by how fast misuse would show.
|
||||
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
|
||||
2. **Timestamped HMAC**: the sandbox sends `X-Sync-Timestamp` and
|
||||
`X-Sync-Signature` (HMAC-SHA256 over the timestamp, path and query) using
|
||||
`KEY_FEED_HMAC_SECRET`; the portal rejects a missing, stale (>60 s) or
|
||||
wrong signature. The secret lives in the portal app env and the sandbox's
|
||||
`/app/data/env`. If the secret is absent the portal falls back to token-only
|
||||
for rollout compatibility; production sets it.
|
||||
3. **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
|
||||
4. **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 —
|
||||
|
||||
Reference in new issue
Block a user