Vulnerable Student Assistant: Workshop App Demonstrating Prompt Injection Risks

Repositorysnyk-workshops/vulnerable-student-assistantDemo

A demonstration repository by Snyk Workshops featuring an intentionally vulnerable AI chat application built with FastAPI and the Gemini 2.5 Flash model. It is designed for testing and learning about prompt injection and sensitive data exposure.

Key points

  1. Intentionally vulnerable demo app intended for security workshops and testing
  2. Backend built with Python, FastAPI, Uvicorn, and the google-generativeai SDK
  3. Powered by the gemini-2.5-flash model for chat interactions
  4. Local JSON mock database contains student data including confidential grades
  5. System prompt instructs the assistant never to reveal grades, presenting a bypass target
  6. Minimalist frontend using plain HTML, CSS, and vanilla JavaScript without frameworks

Why it matters

Many generative AI systems attempt to enforce authorization rules solely via prompt instructions. This workshop app provides a hands-on environment for developers and security professionals to see why prompt-level access controls fail against injection attacks.

Analysis

Published under the Apache-2.0 licence, this repository from Snyk Workshops is a lightweight learning resource with minimal maturity (4 stars, 5 forks). It features instructions to run the FastAPI app directly or generate the codebase using prompts via the Gemini CLI. The application deliberately feeds sensitive mock grade records directly into the LLM's context while relying entirely on soft system instructions to restrict output. This cleanly isolates a fundamental security anti-pattern in LLM engineering for training purposes.

Found in

Summary generated by AI (Gemini 3.8 Flash, 12 October 2026). It may contain errors – the original source is authoritative.

Similar in content, found by the AI search.

  • Video

    Video:CURT

    AI Security Engineer Foundations: Securing LLMs, Agents, and MCP Tools

    In this workshop, Snyk Developer Advocate Javier Garza breaks down foundational AI security practices. Walking through the OWASP Top 10 for LLMs, he demonstrates direct and indirect prompt injection attacks, sensitive data disclosure, and supply chain risks, while detailing defensive architectures including system prompts, human approvals, database views, and MCP security scans.

    AI & LLMs· Talk

  • Repository:nealbridges/VulnHunter

    VulnHunter: Agentic AI Security Scanner for Exploitable Vulnerabilities

    VulnHunter is an open-source, agentic AI security scanner that inspects source code from an attacker's perspective, confirms exploitability, and generates fixes. This maintained fork of Capital One's original project decouples the tool from Claude Code to support arbitrary agent harnesses and open-weight models.

    223starsPython

    AI & LLMs· Tool

  • Link:Snyk

    Snyk Launches AI Security Engineer Foundations & Certification

    Snyk has introduced a six-module training curriculum titled AI Security Engineer Foundations. Delivered online and in person, the half-hour sessions address security across agentic workflows, MCP architectures, and AI-assisted development.

    AI & LLMs· Resource

  • Repository:NVIDIA/SkillSpector

    SkillSpector: Security Scanner for AI Agent Skills by NVIDIA

    SkillSpector is an open-source security scanner from NVIDIA designed to inspect extensions and skills for AI agents (such as Claude Code, Codex CLI, and MCP) for vulnerabilities and malicious patterns before installation.

    15.9kstarsPython

    AI & LLMs· Tool

  • Repository:ShenSeanChen/launch-agentic-rag

    launch-agentic-rag: FastAPI Backend for Agentic RAG with Tool Calling

    An open-source repository providing a reference implementation of Agentic RAG using FastAPI. The project extends standard retrieval workflows with autonomous reasoning loops and external tool execution, such as calendar scheduling and email dispatch.

    43starsPython

    AI & LLMs· Tool

Let's talk about your project

Locations

  • Mattersburg
    Johann Nepomuk Bergerstraße 7/2/14
    7210 Mattersburg, Austria
  • Vienna
    Ungargasse 64-66/3/404
    1030 Wien, Austria

Parts of this content were created with the assistance of AI.