Skip to content

docs: add SVG detection test corpus#74

Merged
cdot65 merged 2 commits into
mainfrom
cdot65/svg-detection-corpus
May 21, 2026
Merged

docs: add SVG detection test corpus#74
cdot65 merged 2 commits into
mainfrom
cdot65/svg-detection-corpus

Conversation

@cdot65

@cdot65 cdot65 commented May 21, 2026

Copy link
Copy Markdown
Owner

Summary

Extends docs/dlp-detection/ with an SVG set — SVG is XML text, so it carries both DLP payloads and AI-prompt attacks.

  • 2 benign controls (logo, bar chart) that must NOT flag.
  • 5 malicious, each a valid benign-looking image with the payload hidden in markup (<title>/<desc>, <metadata>, XML comments, off-canvas/opacity-0 <text>, CDATA <script>, javascript: hrefs, onerror):
    • svg_mal_1_dlp — sensitive data (synthetic markers)
    • svg_mal_2_prompt_injection — instruction override
    • svg_mal_3_system_prompt — system-prompt extraction / jailbreak
    • svg_mal_4_exfil_injection — indirect injection + exfil to example.com
    • svg_mal_5_script_xss — active content / script

Adds scripts/build_svg_corpus.py, extends catalog.md with an SVG section, and adds SVG rows to the results matrix.

Safety

  • All values synthetic; all URLs use reserved example.com. Each malicious file verified to render as a harmless image via rsvg-convert.

Test plan

  • mkdocs build clean (no warnings/broken links)
  • Submit each SVG to the scanner and fill in the results matrix

cdot65 added 2 commits May 21, 2026 11:01
2 benign controls + 5 malicious SVGs by AI-security category: DLP (sensitive
data), prompt injection, system-prompt extraction, indirect injection + exfil,
active-content/script-XSS. Payloads in title/desc/metadata/comment/hidden text/
CDATA script; each malicious file renders as a benign-looking image. Synthetic
data, example.com URLs. Extends dlp-detection catalog + results matrix.
AIRS (profile "AI Gateway - Dev - Strict") skips DLP inspection entirely when
input is classified as a valid SVG (svg root + SVG namespace) — same PII as
plaintext is blocked. Injection/toxic/code detectors still fire on SVG.
Adds svg-dlp-bypass.md (evidence, scan IDs, probe matrix, repro, recommendation)
and updates the results matrix with measured outcomes.
@cdot65 cdot65 merged commit 297c0f5 into main May 21, 2026
4 checks passed
@cdot65 cdot65 deleted the cdot65/svg-detection-corpus branch May 21, 2026 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant