OWASP Top 10 for LLM Apps: Three Risks Tested in Code
A planted page reached the top three results for four of five questions, and a filter missed two leaks.
Video #93 ยท AI security and governance
Steps in the video
Files
- budget.py (15 lines)
- compare.py (18 lines)
- leaks.py (19 lines)
- poisoned.py (39 lines)
Tested with
Python 3.12.15 | ollama==0.6.3
What this does not show
Three of the ten risks, with small made-up examples. The first test only ranks pages with one small embedding model (all-minilm); no prompt is built and no model answers. The filter has three patterns. The token counts for the flood are made up. A source check only helps if the source label cannot be faked.
Sources
Learning IT by Example.