fastapi-development

Pass

Audited by Gen Agent Trust Hub on Sep 15, 2026

Risk Level: SAFEINDIRECT_PROMPT_INJECTION
Full Analysis
  • [INDIRECT_PROMPT_INJECTION]: The file upload demonstration in EXAMPLES.md contains a directory traversal vulnerability due to unsafe handling of user-supplied filenames.
  • Ingestion points: The upload_file and upload_multiple_files endpoints in EXAMPLES.md accept UploadFile objects containing user-controlled filenames.
  • Boundary markers: The instructions do not include boundary markers or warnings advising the user to sanitize or ignore instructions embedded within external file metadata.
  • Capability inventory: The skill includes file system write capabilities via shutil.copyfileobj and directory operations in EXAMPLES.md.
  • Sanitization: The code lacks sanitization for the file.filename attribute; it directly concatenates this untrusted string to the UPLOAD_DIR path (UPLOAD_DIR / file.filename). This allows a malicious actor to provide a filename containing traversal sequences (e.g., ../../etc/passwd) to write files to arbitrary locations on the server.
Audit Metadata
Risk Level
SAFE
Analyzed
Sep 15, 2026, 09:23 AM
Security Audit — agent-trust-hub — fastapi-development