
sub2api 的受限管理员密钥调用账户统计接口一律 403:白名单按方法与完整路径逐条手写,accounts 组 70 条路由只登记了 3 条,维护者已认领但补丁还没出现;同一小时 codex-proxy 把局域网开关搬进面板,CLIProxyAPI 在 dev 修掉了插件多入口的命名问题。
POST /accounts/today-stats/batch、POST /accounts/usage/batch、GET /accounts/:id/today-stats、GET /accounts/:id/usage 3。POST /api/v1/admin/openai/refresh-token。重新授权时选 RefreshToken 那条路,也断在同一处 4。admin.go 里四条统计路由都在册,两条 GET、两条 POST,处理器分别是 GetUsage、GetTodayStats、GetBatchUsage、GetBatchTodayStats 5。
backend/internal/server/routes/admin.go 第 399–413 行:第 405–408 行是那四条被 403 的统计路由,第 409–412 行是同组里清理限流、重置额度的写操作。路由存在、方法与路径都对,说明拒绝发生在准入,不在分发 6adminaccess 包里的一张手写白名单,RouteAllowed 拿「方法 + 完整路径」逐字符比。
backend/internal/pkg/adminaccess/catalog.go 第 12–22 行:第 17–18 行两句注释定下规矩,第 20 行是 accounts.read 的全部路由——GET /accounts、GET /accounts/:id、GET /accounts/:id/models,就这三条 7accounts.read 只覆盖开头三条。四个统计接口与 refresh-token 都落在剩下那批里。/api/v1/admin 前缀后与请求全等比较。accounts.read,一个 GET /accounts/:id/today-stats 也不会被它顺手放行。
catalog.go 第 87–106 行:第 87 行拼前缀后做 target == route 的全等比较,第 95–96 行不匹配就 continue,第 98–102 行才看权限本身。所以「同一目录」在这里没有任何继承可言 8catalog.go 9。accounts.read。accounts.read 不会多给出任何写权限。server.host 写成 0.0.0.0,关掉写回 127.0.0.1。pwd,直接回 400,文案是「先在 Master API Key 里设一个非默认的强密钥」 11。
src/routes/admin/settings.ts 第 199–208 行:第 201 行先校验类型,第 204–206 行读管理密钥,为空或等于 pwd 就 400 挡住。这是整个开关唯一的准入条件 12http://ip:端口/v1,端口取实际运行值。trust_proxy。0.0.0.0 听全部 IPv4 网卡,谁能连上由防火墙决定。config.server.host,手改 local.yaml 一样能听全网卡 13。AuthProviderEntry,把 identifier、name、logo 三件一起随 auth.identifier RPC 下发oauth_provider_entries,三个字段都过 HTML 清洗,entries 为空时整字段省略#7170 本身还是 open——引用提交不会自动关单 16。| 仓库 | 当前版本 | 发布时间(北京) | 本窗口 |
|---|---|---|---|
| CLIProxyAPI | v8.0.50 | 11-01 21:32 | 无新版本;dev 多一笔已修未发 |
| sub2api | 0.2.19 | 10-28 18:16 | 无 |
| codex-proxy | v2.1.21 | 10-28 04:33 | 无;一张局域网开关的 PR |
| codex2api | v3.1.2 | 10-28 04:39 | 无 |
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
github.com
status.openai.com
status.anthropic.com
status.cloud.google.com
codex-reset.com
opentherank.com
This story was produced automatically by a channel. One sentence is all it takes for Neodrop to keep producing for you.