t_p4_rcon: RCON admin console — TCP listener + command handler

Implementation:
- server/scripts/rcon_server.gd — TCPServer-based listener, auth state
  machine (3-strike penalty), per-frame I/O polling, StreamPeerTCP
  per-connection management, IP-based auth timeout
- server/scripts/rcon_command_handler.gd — 14-command dispatch table,
  signal-based dispatch for game-affecting commands (changelevel, kick,
  ban, say, players, exec), inline handlers for help/echo/status/quit and
  cvar operations via optional CvarRegistry singleton (t_p4_config)
- server/data/rcon_password.cfg — default password file (gitignored)
- .gitignore — exclude password file from version control

Protocol: Source-RCON-inspired lightweight TCP, newline-delimited commands,
END-terminated multi-line responses. First message = password auth.
3 failed auth attempts → 5s reconnect penalty.

CvarRegistry integration: auto-detects /root/CvarRegistry singleton on
_ready() and reads rcon_enabled, rcon_port, rcon_password if present.
This commit is contained in:
2026-07-01 00:31:03 -04:00
parent 16e062c739
commit 2cf57a989f
3 changed files with 563 additions and 0 deletions
+3
View File
@@ -24,3 +24,6 @@ server/build/
*.zip
*.exe
*.pck
# Secrets (operator must create per deployment)
server/data/rcon_password.cfg