MoonshotAI / MoonshotAI/kimi-cli
[Bug] Windows 客户端 SSL 证书验证失败:EE certificate key too weak || [Bug] Windows client SSL certificate verification failed: EE certificate key too weak
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 11.4k
- Forks
- 1.3k
- Avg merge
- 9h 47m
- Merged PRs (30d)
- 2
Description
标题
[Bug] Windows 客户端 SSL 证书验证失败:EE certificate key too weak
问题描述
在 Windows 11 系统上使用 VS Code 的 Kimi Code 插件登录时,内置 CLI 工具 (kimi.exe) 无法连接 Kimi 服务器,报错 SSL 证书密钥太弱。
环境信息
- 操作系统: Windows 11 (10.0.22631)
- VS Code: 1.114.0 (user setup)
- Electron: 39.8.3
- Node.js: 22.22.1
- Kimi Code 插件: 最新版(从应用商店安装)
- 网络环境: 正常,无代理
错误日志
2026-04-03T08:51:02.182Z kimi-sdk:cli Running login --json
2026-04-03T08:51:02.182Z kimi-sdk:cli Executing: c:\Users\luozp\AppData\Roaming\Code\User\globalStorage\moonshot-ai.kimi-code\bin\kimi\kimi.exe [ 'login', '--json' ]
2026-04-03T08:51:06.041Z kimi-sdk:cli cli stdout: {"type": "error", "message": "Login failed: Cannot connect to host auth.kimi.com:443 ssl:True [SSLCertVerificationError: (1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: EE certificate key too weak (_ssl.c:1081)')]"}
设置 PYTHONHTTPSVERIFY=0 环境变量后,登录流程可以启动并获取到 verification_url,但后续获取模型列表时同样的错误发生在 api.kimi.com:{"type": "error", "message": "Failed to get models: Cannot connect to host api.kimi.com:443 ssl:True [SSLCertVerificationError: (1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: EE certificate key too weak (_ssl.c:1081)')]"}
已尝试的解决方案
- 调整 TLS 设置(1.0/1.1/1.2/1.3 组合均无效)
- 设置
PYTHONHTTPSVERIFY=0(仅部分有效,后续 API 请求仍失败) - 以管理员身份运行 VS Code
- 重装 Kimi Code 插件
Title
[Bug] Windows client SSL certificate verification failed: EE certificate key too weak
Problem description
When logging in using the Kimi Code plug-in of VS Code on a Windows 11 system, the built-in CLI tool (kimi.exe) cannot connect to the Kimi server and reports an error that the SSL certificate key is too weak.
Environment information
- Operating System: Windows 11 (10.0.22631)
- VS Code: 1.114.0 (user setup)
- Electron: 39.8.3
- Node.js: 22.22.1
- Kimi Code Plugin: latest version (install from app store)
- Network Environment: Normal, no proxy
Error log
2026-04-03T08:51:02.182Z kimi-sdk:cli Running login --json
2026-04-03T08:51:02.182Z kimi-sdk:cli Executing: c:\Users\luozp\AppData\Roaming\Code\User\globalStorage\moonshot-ai.kimi-code\bin\kimi\kimi.exe [ 'login', '--json' ]
2026-04-03T08:51:06.041Z kimi-sdk:cli cli stdout: {"type": "error", "message": "Login failed: Cannot connect to host auth.kimi.com:443 ssl:True [SSLCertVerificationError: (1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: EE certificate key too weak (_ssl.c:1081)')]"}
After setting the PYTHONHTTPSVERIFY=0 environment variable, the login process can be started and the verification_url is obtained, but the same error occurs in api.kimi.com when subsequently obtaining the model list: {"type": "error", "message": "Failed to get models: Cannot connect to host api.kimi.com:443 ssl:True [SSLCertVerificationError: (1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: EE certificate key too weak (_ssl.c:1081)')]"}
Tried solutions
- Adjust TLS settings (none of the 1.0/1.1/1.2/1.3 combinations work)
- Set
PYTHONHTTPSVERIFY=0(only partially effective, subsequent API requests still fail) - Run VS Code as administrator
- Reinstall Kimi Code plug-in
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No source file or test is named. Start by reproducing kimi.exe login --json on the reported Windows 11 environment, then follow the requests to auth.kimi.com and api.kimi.com; done means login and model retrieval succeed with certificate verification enabled.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, vscode
- Domain
- authentication, cli, security
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100