Guided security lab

Search Result Prompt Injection

A guided search-layer trust exercise: separate result titles, snippets and rank from application-recorded provenance, then apply scope, egress and source policy to a model proposal.

Conceptual simulationIntermediate15 minutes2026-09-26
Conceptual simulation

This exercise uses authored, deterministic examples with fictional domains. It runs no search, fetches nothing, calls no model or tools and does not predict how any real model behaves.

3/6

Learning objectives

  • Recognize that result titles, snippets and metadata can be model-visible before any page is opened.
  • Explain why rank, relevance, citations and familiar domains are not trust or instruction authority.
  • Treat generated or reformulated search queries as outbound data flows that policy must check.
  • Distinguish a displayed result URL from the resolved final URL and keep redirect provenance outside model text.
  • Keep provenance attached when search-derived content is stored as a note and retrieved later.

Prerequisites

  • Website Prompt Injection lab (recommended)
  • Search Result Prompt Injection attack article (optional)
Choose a scenario

Each fictional scenario shows search-derived content the model sees and provenance the application recorded separately. Security decisions belong to the second column.

Search path and trust flow

Result content passes through application components before the model sees it. Components are system; titles, snippets, queries, notes and the model's proposal stay variable.

  1. User taskVariable content->
  2. Search toolSystem component->
  3. Titles and snippetsVariable content->
  4. Context assemblySystem component->
  5. ModelSystem component->
  6. ProposalVariable content->
  7. Task policySystem component

Model-visible search content

Search-derived text the model reads. Bracketed text is a neutral placeholder, not a real instruction.

  1. Result 1 snippet

    Overview of fictional heat pump models with efficiency ratings.

  2. Result 2 snippet

    [synthetic instruction-like text attempting to redirect the assistant]

Application-side provenance and policy

Recorded by the search and fetch pipeline and the application outside model text.

Which fact may the application rely on for a security decision?