TLDR: CREST-Search is a novel framework designed to systematically identify safety vulnerabilities in Large Language Models (LLMs) that are integrated with web search. It introduces three unique attack strategies (keyword injection, exaggeration, role play) and leverages a specialized, fine-tuned red-teaming model to generate adversarial queries. The framework is particularly effective at uncovering ‘citation risks,’ where LLMs cite harmful online content even when their own responses appear safe. Experiments demonstrate CREST-Search’s superior risk detection rate and efficiency compared to existing methods, highlighting the critical need for specialized safety assessments in web-search-enabled LLMs.
Large Language Models (LLMs) have transformed how we interact with technology, powering everything from chatbots to complex question-answering systems. However, these powerful AI models have a significant limitation: their knowledge is fixed at their training cutoff date. This means they can’t keep up with new information, evolving events, or rapidly changing facts.
To overcome this, many LLMs are now integrated with web search capabilities. This allows them to access and synthesize information directly from the vast and ever-changing internet. While this integration makes LLMs incredibly versatile and useful, it also introduces new and amplified safety concerns. LLMs are already known to be vulnerable to carefully crafted prompts that can make them generate harmful content. When connected to the untrusted and often unfiltered content of the open web, these risks become even greater, potentially exposing users to severe and diverse safety breaches.
The Challenge of Web-Search LLM Safety
Traditional methods for testing LLM safety, known as ‘red-teaming,’ are often insufficient for models that use web search. This is because the search process adds layers of complexity, involving reasoning, content generation, and the use of external tools. A critical, often overlooked, vulnerability in these systems is ‘citation risk.’ This occurs when an LLM cites external web links that contain harmful content, even if the LLM’s own generated response appears benign. This subtle form of risk is difficult for conventional red-teaming approaches to detect.
Introducing CREST-Search: A New Red-Teaming Framework
To address these challenges, researchers have developed CREST-Search, a novel framework specifically designed for comprehensively red-teaming LLMs with web search. CREST-Search aims to systematically uncover vulnerabilities in these advanced AI services. It operates through a three-stage pipeline:
1. Adversarial Search Query Generation: This stage involves creating initial test search queries that appear harmless but are designed to make the LLM retrieve and cite harmful webpages.
2. Web Search Execution and Risk Evaluation: The generated queries are fed into the target LLM, and the system evaluates the content of the external webpages cited by the LLM for toxicity.
3. Adversarial Search Query Refinement: If an initial query fails to trigger harmful content, it enters a refinement loop. A ‘judgment model’ provides feedback to iteratively improve the query’s adversarial strength, making it more likely to expose risks.
Innovative Attack Strategies and Specialized Training
CREST-Search introduces three pioneering attack strategies tailored for web-search LLMs:
- Keyword Injection: This involves subtly inserting harmful or sensitive keywords into otherwise innocent queries to steer the search engine toward malicious websites.
- Exaggeration: This strategy amplifies certain query elements beyond reasonable limits, pushing the LLM to find fringe or unreliable online sources.
- Role Play: Here, the LLM is instructed to adopt a specific identity or scenario (e.g., “act as a legal advisor”) to bypass safety filters and cause it to fetch and cite harmful sites as seemingly authoritative evidence.
Another significant contribution of CREST-Search is the creation of a specialized harmful dataset called WebSearch-Harm. This dataset is used to fine-tune a base LLM into a dedicated red-teaming model. This fine-tuned model can then generate more effective adversarial queries, reducing the need for extensive iterative refinement and making the process more efficient and cost-effective.
Experimental Validation and Key Findings
Experiments conducted on four commercial LLMs with web search capabilities (including GPT-4o-search-preview and Gemini-2.5-flash-search) demonstrated CREST-Search’s effectiveness. It achieved a significantly higher risk detection rate of 80.5% compared to existing baselines, which struggled to reach 12%. Crucially, the vast majority of risks uncovered by CREST-Search were citation risks (89.3% of total risks), with 74.7% of these cases involving only harmful citations while the LLM’s own response remained benign. This highlights how critical it is to address these often-invisible vulnerabilities.
The study also showed that all three generation strategies were effective, with keyword injection performing particularly well for harassment and sexual content. CREST-Search proved highly transferable, successfully uncovering risks across different black-box LLMs. An ablation study confirmed that both the iterative refinement mechanism and the fine-tuned red-teaming model significantly enhance the framework’s efficiency and risk detection capabilities.
Also Read:
- Beyond Instructions: How AI Agents Are Vulnerable to Misleading Information and How Fact-Checking Can Help
- LatentBreak: A Stealthy New Method for Bypassing LLM Safety Measures
Mitigation and Future Directions
The insights from CREST-Search offer valuable suggestions for developers. One key mitigation is to implement robust safety detection on both the URLs returned by the model and the content of the corresponding webpages *before* citation. Another strategy is to use the adversarial queries generated by CREST-Search to fine-tune LLMs, making them more robust and better aligned with safety standards. The researchers emphasize that continuous integration of automated red-teaming frameworks like CREST-Search into deployment pipelines is essential for proactive and sustainable AI safety management.
This pioneering work underscores the urgent need for specialized solutions to support the development of trustworthy and reliable search-enabled LLMs. For more technical details, you can read the full research paper here.


