TNT/include
m1ngsama 562ee5296d refactor: extract ratelimit module (PR2-M1)
Move IP rate-limiting, auth-failure tracking, and global connection
counting out of ssh_server.c into a dedicated module.

New API (include/ratelimit.h):
- ratelimit_init()
- ratelimit_check_ip() / ratelimit_release_ip()
- ratelimit_record_auth_failure()
- ratelimit_check_and_increment_total() / ratelimit_decrement_total()
- ratelimit_get_active_total()  (replaces the direct g_total_connections
  read that exec_command_stats was doing under g_conn_count_lock)

env_int() also moves up to common.{c,h} since multiple modules need it.

ssh_server.c drops from 2469 to 2200 lines.  Behaviour is preserved:
the new functions are byte-for-byte the same implementations, only the
file boundary moved.

g_idle_timeout and g_access_token reads stay inline in ssh_server_init()
for now; they will follow the auth.c and input.c extractions later.
2026-05-16 23:06:56 +08:00
..
.gitkeep Initial commit 2025-07-01 09:00:00 +08:00
chat_room.h feat: consolidated improvements, manpage, and deployment prep 2026-04-19 17:49:06 +08:00
common.h refactor: extract ratelimit module (PR2-M1) 2026-05-16 23:06:56 +08:00
message.h feat: add :last, :search, :mute-joins commands and MOTD support 2026-04-23 12:03:27 +08:00
ratelimit.h refactor: extract ratelimit module (PR2-M1) 2026-05-16 23:06:56 +08:00
ssh_server.h feat: add :last, :search, :mute-joins commands and MOTD support 2026-04-23 12:03:27 +08:00
tui.h Replace telnet with SSH and fix full-screen display 2025-11-24 16:48:14 +08:00
utf8.h refactor: stabilize SSH runtime and add exec interface 2026-03-10 18:52:20 +08:00