SUDOKU一岁啦!Happy Birthday!
sudoku从2025年10月22日项目建立到11月底第一个release,再到今天,sudoku迎来了v0.5.2版本,但为了图个喜庆,我们将此版本定为v0.5.2.0(520在中文里的谐音是我爱你),以此表达对支持sudoku的用户的感谢。
有个好消息和一个坏消息
-
好消息是sudoku从
v0.5.1->v0.5.2.0经历了上百个commit,大幅优化了一系列性能和占用,并引入了用户管理、外部api、全新的一键脚本TUI、全新设计的官方安卓客户端、桌面客户端等等,并同步把性能优化同步带到了目前支持sudoku的所有内核,也就是说接下来sudoku相关的使用体验会更加丝滑,由于用户管理和api的引入使得机场使用、拼车部署变得更方便。 -
坏消息则是我们一次性在v0.5.2.0更新了太多,以至于
原计划一直更新到明年的计划现在都更新完了,再加上后续开发人员有限,原本月更的sudoku也许会进入更新间隔周期更长的维护期,类似于半停更。 -
但不用担心,v0.5.2.0的sudoku就最初原型协议设计的理念来看已经是非常理想的结果了,团队对现版本都很满意。
更新概览:
feat(server). 新增 users 白名单机制,支持按用户哈希识别并配置别名、带宽限制与每月流量配额;
feat(cli). 重构 -tui 交互向导,采用分页确认流程并预设 HTTP mask 自动模式;
feat(controller). 实现 Clash/mihomo 语义的外部控制器,支持第三方面板接入及服务端用户状态监控;
feat(config). 支持可选的节点名称 (name/n),兼容旧版短链接解析;
perf(uot). 优化 UoT 数据报写入为单次操作并引入批量写入队列;缓存域名解析,显著提升 UDP 吞吐;
perf(memory). 移除空闲连接缓冲区并引入 sync.Pool 借用 record 帧;大幅降低 RSS 内存占用;
perf(codec). Sudoku 表查找改为位集并采用 wyrand 无分支路径;优化解码块处理,提升编解码效率;
perf(mux). 实现并发小帧合并写入并统一 keepalive 实现;降低单条 stream 内存占用;
perf(httpmask). 优化空闲 session 唤醒机制与缓冲池化;预构造请求头并精简定时器回收;
perf(handshake). 减少 KIP 与 OpenTCP 写入次数;实现地址编解码零分配,优化探测缓冲分配;
perf(app). UDP 中继与日志格式化实现零分配;优化路由决策路径与请求读取器复用;
perf(geodata). 引入不可变快照与写时复制域名集;纯文本列表绕过 YAML 解析,匹配过程零分配;
perf(dns). 缓存渲染后地址并合并并发同名查询,限制缓存大小;
perf(reverse). 响应改写按 Content-Length 分配缓冲并使用惰性拼接器;
refactor(httpmask). 拆分职责文件并合并 splitConn 逻辑;抽离 sessionStore 并简化重试机制;
refactor(tunnel). 统一握手 hello 交换并集中连接包装;合并 dialBase 变体与密钥派生逻辑;
refactor(app). 引入 routeAction 类型并重构 SOCKS/Mixed 处理函数;按数据报拆分 UDP 中继;
refactor(protocol). UoT、SOCKS5 UDP 与 KIP 共用统一的 IP 地址编码器;
refactor(geodata). 将 manager 拆分为解析、缓存、下载、匹配与地址段五个模块;
refactor(reverse). 将 manager 拆分为管理、路由与代理模块,并将响应改写移入独立子包;
refactor(config). 细化 Finalize 步骤并统一枚举规整逻辑;
fix(app). 修复 Accept 失败空转问题;处理 SOCKS4 超长请求并修复 HTTP CONNECT 字节丢失;
fix(geodata). 限制规则下载大小为 32MiB;固定关键字匹配顺序并修复 srcset 索引处理;
fix(config). Save 函数现在正确返回 Close 错误;
fix(dns). 移除内置 DoT 支持,统一默认使用 DoH;
fix(httpmask). 确保每个 session 仅持有一个 pull 租约并移除 downlinkMu;
build(deps). 升级 Go 至 1.27.2 并更新 huh、websocket 等核心依赖;
SUDOKU Turns One! Happy Birthday!
From the project’s creation on October 22, 2025, through its first release at the end of November, and now, sudoku has reached v0.5.2. To mark the occasion, though, we’re calling this release v0.5.2.0—“520” sounds like “I love you” in Chinese—as a way to thank everyone who supports sudoku.
Good News and Bad News
-
The good news: sudoku has gone through hundreds of commits between
v0.5.1andv0.5.2.0, bringing major performance and resource-usage improvements. It also adds user management, an external API, a completely redesigned one-click script TUI, a brand-new official Android client, and more. These performance improvements have also been carried over to all currently supported sudoku cores. In other words, using sudoku should feel much smoother from here on. With user management and the API, using it with proxy services and setting up shared deployments is now more convenient, too. -
The bad news: we packed so much into
v0.5.2.0thatwe’ve already finished everything we had planned to work on through next year. And with a limited number of developers available going forward, sudoku—which has previously received monthly updates—may enter a maintenance phase with longer gaps between releases, almost like a pause in development. -
But don’t worry: judged by the design philosophy of the original prototype protocol, sudoku in
v0.5.2.0is already a very solid result, and the team is happy with the current version.
Update Overview
feat(server). Added a users allowlist mechanism, with user identification by hash and support for aliases, bandwidth limits, and monthly traffic quotas;
feat(cli). Reworked the -tui interactive wizard with a paginated confirmation flow and HTTP mask automatic mode enabled by default;
feat(controller). Implemented an external controller with Clash/mihomo semantics, supporting integration with third-party dashboards and server-side user-status monitoring;
feat(config). Added optional node names (name/n) while maintaining compatibility with legacy short-link parsing;
perf(uot). Optimized UoT datagram writes into a single operation and added a batched write queue; cached domain lookups to significantly improve UDP throughput;
perf(memory). Removed idle connection buffers and introduced sync.Pool borrowing for record frames, substantially reducing RSS memory usage;
perf(codec). Replaced Sudoku table lookups with bitsets and adopted a branchless wyrand path; optimized decode-block processing to improve encoding and decoding efficiency;
perf(mux). Implemented concurrent small-frame write coalescing and unified keepalive handling, reducing memory usage per stream;
perf(httpmask). Optimized idle-session wakeups and buffer pooling; prebuilt request headers and streamlined timer cleanup;
perf(handshake). Reduced the number of KIP and OpenTCP writes; implemented zero-allocation address encoding and decoding, and optimized probe-buffer allocation;
perf(app). Made UDP relaying and log formatting allocation-free; optimized the routing decision path and reused request readers;
perf(geodata). Introduced immutable snapshots and copy-on-write domain sets; plain-text lists now bypass YAML parsing, and matching is allocation-free;
perf(dns). Cached rendered addresses, coalesced concurrent queries for the same name, and capped cache size;
perf(reverse). Response rewriting now allocates buffers based on Content-Length and uses a lazy concatenator;
refactor(httpmask). Split files by responsibility and consolidated splitConn logic; extracted sessionStore and simplified retry handling;
refactor(tunnel). Unified the handshake hello exchange and centralized connection wrapping; consolidated dialBase variants and key-derivation logic;
refactor(app). Introduced the routeAction type and refactored SOCKS/Mixed handlers; split UDP relaying by datagram;
refactor(protocol). UoT, SOCKS5 UDP, and KIP now share a unified IP address encoder;
refactor(geodata). Split the manager into five modules: parsing, caching, downloading, matching, and address ranges;
refactor(reverse). Split the manager into management, routing, and proxy modules, and moved response rewriting into its own subpackage;
refactor(config). Refined the Finalize steps and unified enum normalization logic;
fix(app). Fixed a busy loop when Accept fails; added handling for oversized SOCKS4 requests and fixed lost bytes in HTTP CONNECT;
fix(geodata). Capped rule-download size at 32 MiB; fixed keyword matching order and corrected srcset index handling;
fix(config). The Save function now correctly returns errors from Close;
fix(dns). Removed built-in DoT support and standardized on DoH by default;
fix(httpmask). Ensured each session holds only one pull lease and removed downlinkMu;
build(deps). Upgraded Go to 1.27.2 and updated core dependencies, including huh and websocket;