T09 · Insecure Skill Coding Practices
- Location
distiller.py:137- Finding
Raw conversation history is transmitted to an external API before local redaction
- Content
View full analysis
= total_lines: continue current_line = last_read_line while current_line < total_lines: chunk_end = min(current_line + CHUNK_SIZE_MESSAGES, total_lines) chunk_lines = lines[current_line:chunk_end] conversation_text = "" for i, line in enumerate(chunk_lines): try: data = json.loads(line) role = data.get("message", {}).get("role", "unknown").upper() content_list = data.get("message", {}).get("content", []) text = "".join([ c.get("text", "") for c in content_list if c.get("type") == "text" ]) if text.strip(): conversation_text += ( f"[{current_line + i + 1}] {role}: {text}\n" ) except: continue if conversation_text.strip(): existing_topics = get_existing_topics() results = distill_chunk( session_id, current_line + 1, chunk_end, conversation_text, existing_topics ) ``` ### Technical Analysis The skill reads every nonempty JSONL session b ...[truncated 1596 chars]- Remediation
View remediation
