Repository navigation
v1.2(Liuhui): BBS comment moderation, notifications, and i18n
v1.2 (Liuhui)
Named after Liu Hui (刘徽), 3rd-century Chinese mathematician.
BBS
- Comment edit/delete:
/bbs cmtedit <id> <idx> <text>and/bbs cmtdel <id> <idx>(author or operator only), with feature flagsCHATTER_BBS_COMMENT_EDIT/CHATTER_BBS_COMMENT_DELETE - Localized subcommand aliases in all 8 languages (EN/KO/JP/ZH/RU/DE/FR/PL), including cmtedit/cmtdel: 댓글수정, コメント編集, 评论编辑, комментред, kommentarbearbeiten, modifiercommentaire, edytujkomentarz (and deletion counterparts)
- Edited marker: edited comments show
(edited)(storage format v1→v2, old state files still load and auto-upgrade) - Pagination:
list [all|hot|top|new] [page](20 posts/page); post capacity 128 → 256 - Anti-flood rate limiting: min 3s between comments, 30s between posts, per-user across sessions (operators bypass)
- Reply notifications + @mentions: replies and
@nickmentions enqueue notifications (notifications.dat), drained on BBS dashboard entry - Read tracking: "N new posts since your last visit" (
readmark.dat) - Comment quoting:
:Ninside a comment renders as an excerpt quote of comment N - List/search views show post author; tip blocks cover voting and comment editing
- Backup rotation: hourly timestamped backups of
bbs_state.dat, newest 7 kept
Moderation & operator tools (storage v3)
report <id> [reason]user queue with operatorreports; posthide/pinflags (hidden posts invisible to non-operators, pinned posts sort first)mute/unmute/mutesenforced before rate limits; operators cannot be mutedmodlogaction audit (operator actions and IP lookups)
IP audit log with automatic expiry
- Connect/disconnect records with operator-only
ipaudit <user>/ipaudit ip <addr>lookups; every entry is destroyed 5 days after the session ends, and the log is never backup-rotated. Queries are themselves logged.
Internationalization
- Full 8-language coverage for BBS messages, help tables (descriptions and labels), subcommand aliases, DOOR-game and palette strings
Terminal encoding
- Lossless CP949/CP932/CP936 conversion state machine (no more dropped bytes, trail-in-lead-range pairs now decode)
- No UTF-8 sequence truncation on small output buffers; partial results kept on iconv errors
- Stricter UTF-8 auto-detection (rejects overlongs, surrogates, out-of-range leads)
- iconv fallbacks: GB18030 for CP936, SJIS/SHIFT_JIS/ISO-2022-JP for CP932, ISO-2022-KR for CP949
- Conversion context reset at line boundaries (Enter/backspace)
Crash fix
- SIGSEGV on login (production core dump) fixed: host-lifetime sidecar arrays (notifications, reports, mutes, modlog, ipaudit) were lazily allocated inside the calling session's memory context, which is destroyed when the session ends — the next access used a dangling pointer. All five allocations now register in the host memory context.
Full changelog: v1.1b...v1.2
-
Crash forensics: SIGSEGV handler now logs first-fault rip/address/tid before re-raising, so core dumps no longer lose the real crash location
-
Harden BBS post lookup against corrupt capacity and wild ids (2026-09-23 15:01 SEGV defense): refuse to iterate the post arena when capacity exceeds SSH_CHATTER_BBS_MAX_POSTS and reject ids above 2^40