mirror of
https://github.com/fawney19/Aether.git
synced 2026-09-02 09:20:22 +08:00
feat(claude-code): 增加 TLS 指纹伪装、Cache TTL 统一、CLI 限制与流超时冷却
- 新增 curl_cffi Transport,支持真实浏览器 TLS 指纹伪装 (Chrome/Node.js) - 增加 Cache TTL Override 功能,强制统一 cache_control 类型防止行为指纹差异 - 增加 CLI-only 客户端限制,支持仅允许 Claude Code CLI 访问 - 池健康策略增加 stream timeout 计数与自动冷却机制 - OAuth 账号 Region 选择改为从 AWS API 动态获取,支持搜索和自定义输入 - 前端 PoolConfigDialog 增加对应配置 UI
This commit is contained in:
@@ -8,3 +8,4 @@ export * from './models'
|
||||
export * from './adaptive'
|
||||
export * from './global-models'
|
||||
export * from './pool'
|
||||
export * from './system'
|
||||
|
||||
12
frontend/src/api/endpoints/system.ts
Normal file
12
frontend/src/api/endpoints/system.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { client } from '../client'
|
||||
|
||||
// AWS Regions
|
||||
|
||||
let _awsRegionsCache: string[] | null = null
|
||||
|
||||
export async function getAwsRegions(): Promise<string[]> {
|
||||
if (_awsRegionsCache) return _awsRegionsCache
|
||||
const resp = await client.get<{ regions: string[] }>('/api/admin/system/aws-regions')
|
||||
_awsRegionsCache = resp.data.regions
|
||||
return _awsRegionsCache
|
||||
}
|
||||
@@ -450,6 +450,11 @@ export interface ClaudeCodeAdvancedConfig {
|
||||
enable_tls_fingerprint?: boolean
|
||||
// 会话 ID 伪装(固定 metadata.user_id 中 session 片段)
|
||||
session_id_masking_enabled?: boolean
|
||||
// Cache TTL 统一(强制所有 cache_control 使用相同 TTL 类型)
|
||||
cache_ttl_override_enabled?: boolean
|
||||
cache_ttl_override_target?: string
|
||||
// 仅允许 CLI 客户端
|
||||
cli_only_enabled?: boolean
|
||||
}
|
||||
|
||||
export interface PoolAdvancedConfig {
|
||||
|
||||
Reference in New Issue
Block a user