FEAT: Add a converter for indirect prompt injection via hidden HTML/Markdown text
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 70/100
Línea de trabajo
The new converter belongs in pyrit/converter/. Start by examining existing converters like AnsiAttackConverter to understand the base class and SUPPORTED_INPUT_TYPES. The issue lists specific hiding techniques (html_comment, css_display_none, etc.); implement each, ensuring proper escaping. Write unit tests for each technique. Check doc/references.bib for the WASP benchmark citation. Done means the converter passes all tests and can be used with the XPIA workflow.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Summary
I would like to add a new text-to-text converter, HiddenTextConverter, that embeds
the input prompt as hidden or de-emphasized text inside an HTML or Markdown carrier.
Motivation
PyRIT already has the XPIA workflow for indirect prompt injection, but there is no
converter that produces a hidden payload for it to deliver. Systems that summarize or
act on external content (web pages, documents, emails) read the raw source, so text can
be present in the source while staying invisible to a human reviewer. A model that parses
that source may still read and follow it.
This is the same idea as the existing AnsiAttackConverter (terminal escape sequences) and
TransparencyAttackConverter (image layers), applied to HTML and Markdown documents. The
hiding methods are documented injection vectors from the WASP web-agent security benchmark
(arXiv:2504.18575).
Proposed behavior
The converter takes a prompt and wraps it using a chosen technique:
- html_comment
- css_display_none
- css_offscreen
- html_alt_text
- aria_label
- markdown_comment
- markdown_link_title
An optional carrier_text places the hidden payload inside normal looking content. The
converter only formats the text it is given and does not generate any attack content on
its own. Input is escaped so the payload cannot break out of the surrounding markup.
Scope
- New converter in pyrit/converter with SUPPORTED_INPUT_TYPES and SUPPORTED_OUTPUT_TYPES of text
- Unit tests for each technique, escaping, carrier text, and input validation
- Reference added to doc/references.bib
- Intended for use as a request converter with the XPIA workflow
I have a working implementation and would like to take this issue if it fits the project's plans.
- Lenguaje dominante
- Python
- Estrellas
- 4.5k
- Forks
- 896
- Merge medio
- 3 d 8 h
- PR fusionados (30 d)
- 191
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de microsoft/PyRIT
-
Dificultad 3/5 1-2 días Aptitud para principiantes 65/100
-
Bug: triage GUI help wanted
Dificultad 3/5 1-2 días Aptitud para principiantes 65/100
-
bug help wanted
Dificultad 4/5 3-5 días Aptitud para principiantes 68/100
-
not ready yet
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
-
not ready yet
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
Todos los issues de microsoft/PyRIT
Issues similares
-
bug confirmed issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
open-webui/open-webui#30750 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
OpenwaterHealth/openmotion-bloodflow-app#604 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
-
good first issue
Dificultad 1/5 Menos de una hora Aptitud para principiantes 90/100