skills/badhope/skill/langchain/Gen Agent Trust Hub

langchain

Fail

Audited by Gen Agent Trust Hub on Mar 31, 2026

Risk Level: HIGHCOMMAND_EXECUTIONREMOTE_CODE_EXECUTIONPROMPT_INJECTION
Full Analysis
  • [COMMAND_EXECUTION]: The skill defines a calculate tool that uses the built-in Python eval() function to evaluate user-provided expressions. This is a critical security risk as it allows for arbitrary code execution if an attacker or a subverted agent passes malicious Python strings.
  • [REMOTE_CODE_EXECUTION]: The agent configuration includes the PythonREPLTool from the langchain_experimental package. This tool provides the AI agent with a persistent Python shell, enabling it to execute any code it generates. This capability can be easily abused to perform unauthorized file system operations, network scanning, or data exfiltration.
  • [PROMPT_INJECTION]: The skill implements Retrieval-Augmented Generation (RAG) using PyPDFLoader and WebBaseLoader to ingest external content.
  • Ingestion points: External data is loaded from document.pdf and web sources into the agent context.
  • Boundary markers: The prompt templates for the RAG chain and Agent do not employ delimiters or 'ignore' instructions to prevent the agent from obeying malicious instructions embedded within the retrieved text.
  • Capability inventory: The agent possesses powerful capabilities including arbitrary code execution (eval, PythonREPLTool) and network access (requests, DuckDuckGoSearchRun).
  • Sanitization: No sanitization or validation of the retrieved context is performed before it is interpolated into the LLM prompt.
Recommendations
  • AI detected serious security threats
Audit Metadata
Risk Level
HIGH
Analyzed
Mar 31, 2026, 06:59 AM