Wesley Liddick
27f094e096
Merge pull request #4638 from superman2003/fix/s3-secret-ephemeral-encryption-key
...
fix(backup): 拒绝用自动生成的临时密钥持久化 S3 SecretAccessKey,修复重启后解密失败
2026-07-20 16:21:46 +08:00
Wesley Liddick
c4a8878f1f
Merge pull request #4626 from put-go/fix/grok-chained-video-content
...
fix(grok): support chained video content proxies
2026-07-20 15:30:46 +08:00
Wesley Liddick
95c8b2401e
Merge pull request #4616 from zhangxaochen/codex/openai-quota-error
...
fix(openai): return standard insufficient quota errors
2026-07-20 15:30:41 +08:00
Wesley Liddick
e669e51b92
Merge pull request #4565 from abbzbb/fix/prompt-audit-fail-closed-4560
...
fix(security-audit): 仅在 blocking 意图下 fail-closed,修复无法关闭审计
2026-07-20 15:30:36 +08:00
Wesley Liddick
ce9e70d5cf
Merge pull request #4569 from Astrenix/fix/codex-models-openai-list-envelope
...
fix(openai): accept standard OpenAI model list for Codex model discovery
2026-07-20 15:30:31 +08:00
Wesley Liddick
deb5e8756a
Merge pull request #4572 from catoncat/fix/openai-agent-identity-team-isolation
...
fix(openai): 按 Team 隔离 Agent Identity 导入
2026-07-20 15:30:26 +08:00
Wesley Liddick
78f85583ea
Merge pull request #4630 from feitianbubu/fix/api-key-update-ip-list-clear
...
fix: 部分更新 API Key 时不再静默清空 IP 白/黑名单
2026-07-20 15:28:51 +08:00
superman2003
7a7f51a534
fix(backup): 拒绝用自动生成的临时密钥持久化 S3 SecretAccessKey
...
totp.encryption_key 未配置时,加密密钥每次进程启动都会随机重新生成。
备份/图床把 S3 SecretAccessKey 用这把临时密钥加密落库后,重启或升级
即无法解密(decrypt: cipher: message authentication failed),S3 备份
与图床静默失效(#4524)。
对齐支付(payment.ProvideEncryptionKey)与 TOTP 启用已有的护栏:在
持久化新 secret 之前,若密钥非固定配置则返回可操作的
SECRET_ENCRYPTION_KEY_NOT_CONFIGURED(400),提示配置固定
TOTP_ENCRYPTION_KEY。不带 secret 的更新(沿用已存值)与
ReuseBackupS3 模式不受影响;已配置固定密钥的部署无感。
2026-07-20 15:20:51 +08:00
shaw
3c41984733
style(apicompat): gofmt types.go after merge
2026-07-20 11:47:13 +08:00
shaw
04617cc0ff
Merge branch 'main' into fix/grok-claude-messages-prompt-cache
...
Resolve const-block conflict in openai_gateway_grok_cache.go:
keep #4590 client tool cache constants and #4585 xai-package limit
(grokFreeRolling24hTokenLimit removed), add claudeCodeSessionHeader.
2026-07-20 11:39:37 +08:00
shaw
a90c18cbea
Merge branch 'main' into fix/issues-4561-4562-4566-4582
...
Resolve const-block conflict in openai_gateway_grok_cache.go:
keep #4590 's client tool cache constants, drop grokFreeRolling24hTokenLimit
(moved to pkg/xai as IsGrokFreeRolling24hTokenLimit with legacy 2M support).
2026-07-20 11:25:11 +08:00
feitianbubu
e502766170
fix: 部分更新 API Key 时不再静默清空 IP 白/黑名单
2026-07-20 11:15:37 +08:00
Wesley Liddick
b8e844f4ee
Merge pull request #4612 from catoncat/fix/codex-call-id-length
...
fix(openai): 限制 Codex call_id 归一化后的长度
2026-07-20 11:05:18 +08:00
Wesley Liddick
80a533c890
Merge pull request #4606 from orchief/codex/issue-4603-dedupe-oauth-system-prompt
...
fix(openai): 避免 OAuth Chat 转译重复 system 前缀
2026-07-20 11:03:00 +08:00
Wesley Liddick
6d152893ff
Merge pull request #4590 from superman2003/fix/grok-client-cache-codex-trae
...
fix(grok): cache client tools from Codex, Trae, and Claude Desktop
2026-07-20 10:47:05 +08:00
shaw
97afb4089c
fix(lint): check strings.Builder WriteString return value (errcheck)
2026-07-20 10:46:37 +08:00
put-go
48fad26433
fix(grok): support chained video content proxies
2026-07-20 10:40:18 +08:00
Wesley Liddick
1b4029b050
Merge pull request #4595 from kinsolee/fix/http-bridge-failover-terminal-safety
...
fix(openai): make HTTP bridge failover safe
2026-07-20 10:29:00 +08:00
Wesley Liddick
139a3d4346
Merge pull request #4589 from huangjunsen0406/fix/anthropic-message-start-stop-reason-null
...
fix(apicompat): emit null stop_reason on Anthropic message_start
2026-07-20 10:28:52 +08:00
Wesley Liddick
8c9cda1803
Merge pull request #4583 from BenjaminAaron196/codex/ops-report-email-template
...
(feat) 运维定时报表支持可编辑摘要模板与多语言展示
2026-07-20 10:28:44 +08:00
Wesley Liddick
0a8831777b
Merge pull request #4619 from superman2003/fix/grok-manual-test-scheduling-gate
...
fix(grok): let manual connection tests bypass the scheduling gate
2026-07-20 10:26:55 +08:00
Wesley Liddick
34c8dbd604
Merge pull request #4618 from superman2003/fix/system-update-detach-request-ctx
...
fix(update): detach in-place update from the HTTP request lifetime
2026-07-20 10:26:47 +08:00
Wesley Liddick
e311d368d3
Merge pull request #4611 from superman2003/fix/codex-models-manifest-401-unschedulable
...
fix(openai): mark OAuth accounts unschedulable on Codex models manifest 401
2026-07-20 10:26:39 +08:00
Wesley Liddick
f133fde643
Merge pull request #4602 from jianjianai/new/perf-responses-image-intent
...
perf(openai): 复用 Responses 生图意图判定
2026-07-20 10:26:31 +08:00
Wesley Liddick
c0b8f6b0a8
Merge pull request #4601 from jianjianai/new/perf-responses-sse-type
...
perf(openai): 复用 Responses SSE 事件类型解析
2026-07-20 10:26:23 +08:00
Wesley Liddick
9ccc9077cc
Merge pull request #4581 from wucm667/feat/issue-4375-github-release-token
...
feat: support GitHub token for update checks
2026-07-20 10:26:15 +08:00
Wesley Liddick
f5e484aa70
Merge pull request #4625 from wucm667/fix/issue-4624-sticky-force-cache-billing
...
fix(handler): avoid cache billing on same-account retry
2026-07-20 10:24:38 +08:00
Wesley Liddick
032001598a
Merge pull request #4617 from wucm667/fix/issue-4610-anthropic-json-content-type
...
fix(openai): correct buffered messages content type
2026-07-20 10:24:22 +08:00
Wesley Liddick
6def36a171
Merge pull request #4614 from cugxuan/codex/fix-subscription-expiry-days
...
fix(subscription): round remaining days up
2026-07-20 10:24:14 +08:00
shaw
2518691dbc
fix(config): 为 trusted_proxies 与 forwarded_client_ip_headers 注册 BindEnv,修复 env 可达性守卫测试
...
#4593 引入的 TestConfigKeysAreEnvReachable 与 #4604 新增的两个配置键语义相撞:
两键在 setDefaults 中无注册,守卫测试判定其环境变量不可达。
不能按守卫注释直接 SetDefault:viper 的 IsSet 会连同 defaults 一起上报,
任何已注册默认值都会让 load() 中 trustedProxiesConfigured 的显式配置探测
永远为真,摧毁 #4600 的 absent/empty 区分。改用 BindEnv 注册——绑定键同样
进入 AllKeys()(守卫测试与 Unmarshal 均可见),而变量缺席时不影响 IsSet。
两个环境变量本就由 load() 中 os.LookupEnv 手工解析,行为不变。
2026-07-20 09:41:02 +08:00
Wesley Liddick
bfabfe60c8
Merge pull request #4593 from StarryKira/fix/image-storage-env-unreachable
...
fix: 异步生图开关配了却不生效(环境变量被静默丢弃 + 迁移到后台开关)
2026-07-20 09:20:15 +08:00
wucm667
a2acbf553b
fix(handler): avoid cache billing on same-account retry
2026-07-20 02:20:58 +08:00
Jlypx and Sisyphus
dd0cbe91c9
fix: 避免复制客户端 IP 原子状态
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:22:45 +08:00
Jlypx and Sisyphus
ff5b0e6254
test: 更新客户端 IP 设置响应契约
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:09:47 +08:00
Jlypx and Sisyphus
fedeba2568
feat: 审计客户端 IP 请求头变更
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:09:37 +08:00
Jlypx and Sisyphus
3c86e249f4
feat: 接入客户端 IP 请求头管理接口
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:09:21 +08:00
Jlypx and Sisyphus
f72958d530
feat: 持久化客户端 IP 请求头设置
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:09:11 +08:00
Jlypx and Sisyphus
8b8b6b3132
feat: 定义客户端 IP 请求头系统设置
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:09:00 +08:00
Jlypx and Sisyphus
9bc7d10c08
fix: 快照自定义客户端 IP 请求头
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:08:48 +08:00
Jlypx and Sisyphus
496005d688
fix: 按自定义请求头解析客户端 IP
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:08:36 +08:00
Jlypx and Sisyphus
041db5d824
feat: 支持自定义客户端 IP 请求头配置
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-20 00:08:26 +08:00
superman2003
4a97491be6
fix(grok): let manual connection tests bypass the scheduling gate
...
Grok OAuth 'test connection' reused the production GrokTokenProvider
request path, whose eligibility gate rejects any account that is not
currently schedulable (manual switch off, rate limited, overloaded,
temporarily cooled down). Every such test failed before reaching xAI
with the generic 'oauth refresh account state changed', while
Codex/OpenAI account tests read credentials regardless of scheduling
state (#4598 ).
Add GetAccessTokenForManualTest and use it from the account test
service:
- skips the request-path scheduling eligibility gate so admins can
probe excluded accounts; credential integrity checks (configured
proxy present, refresh token present) still apply
- refreshes expired tokens through the shared OAuthRefreshAPI without
the request-path marker, so the lock protocol and DB re-read keep
working while scheduling state no longer blocks the refresh;
credential rotation for non-active accounts stays blocked inside
RefreshIfNeeded
- falls back to the still-valid current token when a refresh attempt
fails or another worker holds the refresh lock, and otherwise
surfaces the concrete refresh error instead of the generic message
Fixes #4598
2026-07-19 22:40:58 +08:00
superman2003
35b5edb24c
fix(update): detach in-place update from the HTTP request lifetime
...
The in-place update ran entirely inside c.Request.Context(). Browsers and
reverse proxies commonly abort long-idle requests (axios global timeout
30s, nginx proxy_read_timeout 60s by default), which canceled the request
context mid-download and killed every slow update with
'download failed: context canceled' while the version stayed unchanged.
Users behind slow GitHub links saw the update button fail at a wall-clock
ceiling (~60s) on every attempt (#4504 ).
- Run PerformUpdate and RollbackToVersion on a context detached from the
request (context.WithoutCancel) and bounded by a 15-minute deadline so
the 10-minute GitHub download client owns its own timeout. A client
disconnect no longer aborts the binary swap; retries then hit the
system operation lock or report 'Already up to date'.
- Raise the frontend timeout for the update/rollback calls from the
global 30s axios default to 15 minutes so the browser can actually
wait for the result.
Fixes #4504
2026-07-19 22:40:44 +08:00
wucm667
01062c3244
fix(openai): correct buffered messages content type
2026-07-19 22:28:49 +08:00
zhangxaochen
604b764cf5
fix(openai): return standard insufficient quota errors
2026-07-19 21:59:45 +08:00
Jlypx and Sisyphus
93717394b2
fix: 迁移客户端 IP 兼容开关
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-19 21:41:45 +08:00
Jlypx and Sisyphus
6aa6b3a968
fix: 将客户端 IP 模式注入请求上下文
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-19 21:41:12 +08:00
Jlypx and Sisyphus
39107ca457
fix: 安全初始化 Gin 可信代理
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-19 21:40:32 +08:00
Jlypx and Sisyphus
6e2ba0e4cd
fix: 统一请求级客户端 IP 模式
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-19 21:39:49 +08:00
Jlypx and Sisyphus
8a147fcc51
fix: 解析显式可信代理配置
...
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent )
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai >
2026-07-19 21:39:24 +08:00