T09 · Insecure Skill Coding Practices
- Location
scripts/summarize.py:91- Finding
Prompt Injection Through Untrusted Meeting Transcript
- Content
View full analysis
Dict[str, Any]: """ 生成结构化会议纪要 Args: transcript: 会议转录文本 context: 会议上下文/类型 Returns: 结构化纪要数据 """ if not self.client: # 无API时返回基础结构 return self._fallback_summary(transcript) prompt = f"""请分析以下会议记录,生成结构化的会议纪要。 会议类型:{context} 会议记录: {transcript} 请按以下JSON格式输出(不要添加markdown代码块标记): {{ "meeting_summary": {{ "topic": "会议主题", "date": "会议日期(如未提及则填今天)", "participants": ["参与人列表"], "key_points": ["讨论要点1", "讨论要点2"], "decisions": ["决策事项1", "决策事项2"], "next_steps": ["下一步计划"] }}, "action_items": [ {{ "task": "待办事项描述", "owner": "负责人", "priority": "high/medium/low", "due_date": "截止日期(如未提及则填待定)" }} ], "customer_insights": {{ "budget": "预算情况分析", "decision_makers": ["决策链关键人物"], "competitors": ["竞品情况"], "pain_points": ["痛点需求"], "buying_signals": ["购买信号"], "concerns": ["顾虑点"] }}, "follow_up_suggestions": ["后续跟进建议"] }} """ try: response = self.client.chat.completions.create( model="gpt-4o-mini", messages=[ {"role": "system", "content": "你是一个专业的销售会议分析师,擅长提取关键信息和洞察。"}, {"role": "user", "content": prompt} ], temperature=0.3, response_format={"type": "json_object"} ) ``` ### Technical Analysis The `transcript` and `context` values are treated as untrusted input, but they are interpolated directly into the same user message that contains the summarization instructions and required output schema. The applicatio ...[truncated 2601 chars]- Remediation
View remediation
