fix(bridge): system audit + 5-file bug fix — PATS Deny trigger removal, auto_resolved chat dedup, UUID filenames, IP rate limit leak, bot.py deque
This commit is contained in:
@@ -16,6 +16,7 @@ import json
|
||||
import os
|
||||
import time
|
||||
import logging
|
||||
import uuid
|
||||
from pathlib import Path
|
||||
|
||||
from bridge import LocalTransport, RemoteTransport
|
||||
@@ -338,7 +339,7 @@ class CollectorBridge:
|
||||
project_intervals[project] = _BASE_INTERVAL
|
||||
project_empty_streak[project] = 0
|
||||
for cmd in commands:
|
||||
cmd_id = cmd.get("id", str(int(time.time() * 1000)))
|
||||
cmd_id = cmd.get("id", f"{int(time.time() * 1000)}_{uuid.uuid4().hex[:8]}")
|
||||
fname = f"{cmd_id}.json"
|
||||
self.local.write_json("commands", fname, cmd)
|
||||
logger.info(f"[COLLECTOR] ← Gateway: command [{project}] {cmd.get('text', '?')[:30]}")
|
||||
|
||||
Reference in New Issue
Block a user