qwen_agent/.features/skill/decisions/002-security.md
autobee-sparticle 18bf296aa0
feat: move enable_thinking control from docker-compose to request body (#21)
* add page number

* feat: add skill feature memory

添加 skill 功能的 feature memory,记录技能包管理服务和 Hook 系统的核心信息。

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* feat(skill): add feature memory with changelog and decisions

添加 skill 功能的完整记忆文档:

Changelog:
- 2025-Q4: 初始实现 (GRPC 层 + 内置 skills)
- 2026-Q1: API 完善 (REST API + Hook 系统)

Design Decisions:
- 001: Skill 架构设计 (目录结构、Hook 系统)
- 002: 上传安全措施 (ZipSlip、路径遍历防护)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* soffice sharp 支持

* shell_env support

* feat: move enable_thinking control from docker-compose to request body

Remove DEFAULT_THINKING_ENABLE environment variable from docker-compose
and settings.py. The enable_thinking flag is now solely controlled via
request body (default: false), as felo-mygpt already passes this config
from RobotConfig database.

Closes sparticleinc/felo-mygpt#2473

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: 朱潮 <zhuchaowe@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: zhuchao <zhuchaowe@163.com>
2026-03-26 20:12:39 +09:00

935 B
Raw Blame History

002: Skill 上传安全措施

状态

已采纳 (Accepted)

上下文

用户可以上传 ZIP 格式的技能包,需要防范常见的安全攻击。

决策

安全防护措施

威胁 防护措施
ZipSlip 攻击 检查每个文件的解压路径
路径遍历 验证 bot_idskill_name 格式
Zip 炸弹 压缩比检查(最大 100:1
磁盘空间滥用 上传 50MB解压后最大 500MB
符号链接攻击 禁止解压包含符号链接的文件

限制规则

MAX_UPLOAD_SIZE = 50 * 1024 * 1024      # 50MB
MAX_EXTRACTED_SIZE = 500 * 1024 * 1024  # 500MB
MAX_COMPRESSION_RATIO = 100              # 100:1

结果

  • 完整的上传验证链
  • 防止恶意文件攻击
  • 资源使用可控

替代方案

  1. 使用沙箱容器解压(拒绝:复杂度高)
  2. 仅允许预定义技能(拒绝:限制用户自定义能力)