gemini-web-research
Fail
Audited by Gen Agent Trust Hub on Nov 9, 2026
Risk Level: HIGHDATA_EXFILTRATIONCOMMAND_EXECUTIONINDIRECT_PROMPT_INJECTION
Full Analysis
- [DATA_EXFILTRATION]: The
scripts/gemini_research.pyscript uses a regular expression (file://(\S+?output\.txt)) to scan the output of research tools. If a matching string is found within text fetched from the web, the script automatically reads the content of that local file and includes it in the research context. This allows a malicious website to trigger unauthorized reads of local files on the system, provided the filename ends with the suffixoutput.txt. - [DATA_EXFILTRATION]: The
scripts/read_page.pyscript, which fetches web content for the research worker, does not perform protocol validation on the URLs it processes. By passing raw URLs tourllib.request.urlopen, it potentially allows the use of thefile://protocol to access local system files. Although the specific use of aRequestobject with custom headers may block this in certain Python configurations, the lack of explicit protocol filtering is a significant security weakness. - [COMMAND_EXECUTION]: The skill uses
subprocess.runto execute theagycommand-line tool and internal Python scripts to orchestrate and perform parallel web research. - [INDIRECT_PROMPT_INJECTION]: The skill is designed to ingest and process arbitrary content from the live web, creating an attack surface for indirect prompt injection. Maliciously crafted web pages could attempt to influence the research worker's output or the final synthesis provided to the user.
- Ingestion points:
scripts/read_page.pyfetches data from external URLs and extracts readable text. - Boundary markers: The system prompt for the Gemini worker includes explicit operational rules (e.g., "Your memory is not a source", "back every claim with a verbatim quote") to minimize the influence of injected or hallucinated content.
- Capability inventory: The worker model has access to web search tools and the ability to execute the page-reading script.
- Sanitization: The
TextExtractorclass inscripts/read_page.pysanitizes HTML content by stripping out dangerous tags such as<script>,<style>, and<svg>.
Recommendations
- AI detected serious security threats
Audit Metadata