{"license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/","attribution":"Credit the site and link to the page the figure came from."},"source":{"name":"Best Secure AI for Business","url":"https://bestsecureaiforbusiness.com/blog/ai-security-risks-by-layer/","home":"https://bestsecureaiforbusiness.com/","method":"https://bestsecureaiforbusiness.com/methodology/","data_month":"Dec 2026","note":"Compiled from public web pages. The page behind each fact is listed in `sources` where a document has one."},"generated_at":"2026-12-03T00:20:00.000Z","site":{"key":"secure","name":"Best Secure AI for Business","domain":"bestsecureaiforbusiness.com"},"slug":"ai-security-risks-by-layer","url":"https://bestsecureaiforbusiness.com/blog/ai-security-risks-by-layer/","json":"https://bestsecureaiforbusiness.com/blog/ai-security-risks-by-layer.json","title":"AI security risks, sorted by where they enter","description":"The main AI security risks grouped by layer (input, output, tools, data, supply chain), mapped to the OWASP LLM list, with controls, owners, a review worksheet and how often listed vendors name each risk.","author":"Editorial desk","published_at":"2026-12-01","updated_at":"2026-12-01","tags":[],"reading_minutes":7,"sources":[{"url":"https://bestsecureaiforbusiness.com/methodology/","title":"Best Secure AI for Business: methodology"},{"url":"https://genai.owasp.org/llm-top-10/","title":"OWASP: Top 10 for LLM applications"},{"url":"https://www.nist.gov/itl/ai-risk-management-framework","title":"NIST: AI Risk Management Framework"},{"url":"https://atlas.mitre.org/","title":"MITRE ATLAS knowledge base"}],"faq":[{"q":"What are the main AI security risks?","a":"Malicious or hidden instructions in input, unchecked output, over-broad access for agents, leakage of sensitive data, and flaws brought in through third-party models, plug-ins and data."},{"q":"Which risk do vendors name most?","a":"Of 119 vendor descriptions, 6 mention data leakage, data loss or DLP, 4 mention red teaming, 3 mention guardrails, 3 mention shadow AI and 2 mention prompt injection."},{"q":"How many vendors cover agents?","a":"96 of the 122 listed vendors list AI agents among their services."},{"q":"Which layer should I secure first?","a":"The one where your system can do the most damage. For agents that is usually tools and permissions; for staff using chat tools it is data entering prompts."},{"q":"Is the OWASP list enough for a review?","a":"It is a strong checklist for applications built on language models. Add MITRE ATLAS for attacks on models themselves and your own data classification for leakage."},{"q":"Who should own each layer?","a":"Usually application owners for input and output, identity teams for tool permissions, data protection for the data layer and platform or procurement teams for the supply chain."}],"body_markdown":"Security teams used to ask where the perimeter is. For AI, a better question is where untrusted content can enter and what the system may do next. Sorting risks by layer makes the controls easier to assign, gives each layer an owner and turns a long list of threats into a short review you can run on any system.\n\n## Contents\n\n- [Five layers](#layers)\n- [Risks and controls in each layer](#detail)\n- [What vendors name](#vendors)\n- [Who owns each layer](#owners)\n- [A one-hour review worksheet](#review)\n- [Where to go next](#next)\n\n<h2 id=\"layers\">Five layers</h2>\n\n| Layer | What goes wrong | OWASP LLM item |\n|---|---|---|\n| Input | Instructions hidden in a prompt, a web page or a file change behavior | Prompt injection |\n| Output | Unchecked output reaches a browser, a database or a shell | Improper output handling |\n| Tools and agents | The agent holds more access than the task needs | Excessive agency |\n| Data | Sensitive data appears in prompts, answers, logs or retrieval results | Sensitive information disclosure |\n| Supply chain | A model, plug-in or data source brings the flaw | Supply chain, data and model poisoning |\n\nThe OWASP project also lists system prompt leakage, vector and embedding weaknesses, misinformation and unbounded consumption. Each of those fits one of the five layers: system prompt leakage and embedding weaknesses sit in the data layer, misinformation in output, and unbounded consumption in tools, where loops and heavy calls run up cost.\n\n<h2 id=\"detail\">Risks and controls in each layer</h2>\n\n### Input\n\nAnything a model reads can steer it. That includes the user's message, but also documents pulled from search, web pages an agent visits, emails it processes and results returned by tools. Direct injection comes from the user. Indirect injection hides in content the system fetched on its own, which makes it harder to spot and more dangerous when the system can act.\n\n| Control | Effort | Limits |\n|---|---|---|\n| Keep system instructions separate from retrieved content in the prompt design | Low | Reduces confusion, does not stop determined attacks |\n| Screen inputs for known attack patterns | Medium | Attackers rephrase; screening misses new forms |\n| Mark retrieved content as untrusted and restrict what it can trigger | Medium | Needs design work in each application |\n| Limit what the system can do if steered (see tools) | Medium | The control that still holds when screening fails |\n\n### Output\n\nModel output is untrusted data. If it is placed into a web page, it can carry script. If it is passed to a database query or a shell, it can run commands. If it is shown to a customer, it can be wrong in ways that cause harm.\n\n- Encode output before rendering it in a browser.\n- Never pass model output directly into queries or commands; use parameters and allow lists.\n- Validate structured output against a schema before acting on it.\n- For customer-facing systems, check outputs for sensitive data and for content your policy forbids.\n\n### Tools and agents\n\nWhen a model can call tools, the question becomes what the worst action is. OWASP calls this excessive agency: too many tools, too much permission or too much autonomy.\n\n| Control | What it limits |\n|---|---|\n| Least privilege per tool, scoped to the records the task needs | Scope of damage |\n| A distinct identity per agent | Untraceable actions |\n| Approval for actions that change state, move money or send data out | Irreversible mistakes |\n| Caps on calls, steps and spend per task | Runaway loops and cost |\n| A log of every call with its arguments and result | Blind spots in investigation |\n\n### Data\n\nData risk runs both ways. Sensitive data goes into prompts, and sensitive data comes out in answers. In between it sits in logs, caches, vector stores and vendor systems.\n\n- Classify which data may enter which AI tools, and enforce it with approved tools.\n- Filter retrieval by the caller's permissions at query time.\n- Set retention for prompts, answers and embeddings, and confirm vendor retention in the contract.\n- Test with planted, distinctive fake secrets to see whether they surface where they should not.\n\nOur post on [AI data leakage controls](/blog/ai-data-leakage-controls/) works through six leakage routes in detail.\n\n### Supply chain\n\nAI systems depend on parts you did not build: base models, fine-tuned models from public hubs, plug-ins, tool servers, datasets and libraries. A flaw in any of them becomes yours.\n\n| Component | Risk | Control |\n|---|---|---|\n| Model files from public hubs | Tampered weights, unsafe file formats | Approved sources, scanning, pinned versions |\n| Plug-ins and tool servers | Broad access, malicious instructions in descriptions | Register with owners, review, least access |\n| Training and retrieval data | Poisoned or manipulated content | Source review, change tracking, spot checks |\n| Libraries and frameworks | Ordinary software vulnerabilities | Your existing dependency scanning |\n\nMITRE ATLAS catalogues attacks on models themselves, such as poisoning and extraction, with case studies. It complements OWASP, which focuses on the application around the model.\n\n### Which layers matter for which kind of system\n\nNot every system carries every risk at the same weight. The table shows where to look first.\n\n| System | Heaviest layers | Lighter layers |\n|---|---|---|\n| Staff using a public chat assistant | Data | Tools, supply chain |\n| Internal search over company documents | Data, input | Tools |\n| Customer-facing assistant | Output, input, data | Supply chain |\n| Agent that updates records or sends messages | Tools, input | Output to browsers |\n| Model you fine-tune and host yourself | Supply chain, data | Tools, unless the model also acts |\n\nA system can move between rows as it gains features. An internal search tool that later learns to file tickets has become an agent, and the tools layer moves to the top.\n\n### Mistakes that recur in reviews\n\n- Treating retrieved documents as trusted because they come from inside the company.\n- Granting an agent a service account with access to a whole system instead of the records it handles.\n- Logging every prompt for debugging and keeping the logs indefinitely.\n- Testing a model once before launch and never again after a model or prompt change.\n- Approving a plug-in or tool server without anyone reading what it can access.\n\n<h2 id=\"vendors\">What vendors name</h2>\n\nThe [AI security vendor list](/ai-security/) holds 122 vendors, and 119 have a description we can read. Few name a specific risk in that text.\n\n| Term in the description | Vendors |\n|---|---|\n| Data leakage, data loss or DLP | 6 |\n| Red teaming | 4 |\n| Guardrails | 3 |\n| Shadow AI | 3 |\n| Prompt injection | 2 |\n| Supply chain or poisoning | 0 |\n\nVendors describe products, not threats, so these counts understate coverage. The services field tells more: 96 vendors list AI agents and 71 list generative AI. The [agent security ranking](/best/ai-agent-security/) and the [LLM security ranking](/best/llm-security/) order those groups by evidence score.\n\nThe gap in supply chain wording is worth noting. No description we hold uses supply chain or poisoning, though some products do cover model scanning. If supply chain is a top risk for you, ask vendors directly and expect to combine an AI tool with your existing dependency scanning.\n\nFor tool-heavy deployments, the [MCP view](/ai-security/using/mcp/) lists the 34 vendors that name the Model Context Protocol. For regulated data, the [finance view](/ai-security/for/finance/) lists 48 vendors.\n\n<h2 id=\"owners\">Who owns each layer</h2>\n\nRisks without owners do not get fixed. A typical split:\n\n| Layer | Usual owner | Supporting team |\n|---|---|---|\n| Input | Application owner | Application security |\n| Output | Application owner | Application security, front-end engineering |\n| Tools and agents | Identity and access management | Platform engineering |\n| Data | Data protection or privacy | Data owners, legal |\n| Supply chain | Platform engineering or procurement | Security architecture |\n\nWrite the owner's name next to each layer for every system that matters. Where two teams each think the other owns a layer, that is the gap an attacker will find.\n\n<h2 id=\"review\">A one-hour review worksheet</h2>\n\nPick one system you run. Fill in this table with the people who build and run it.\n\n| Layer | Worst realistic failure | Control in place | Owner | Gap |\n|---|---|---|---|---|\n| Input | | | | |\n| Output | | | | |\n| Tools and agents | | | | |\n| Data | | | | |\n| Supply chain | | | | |\n\nThen rank the gaps by impact and by how easy they are to close, and fix the high-impact, easy ones first. Repeat for each system, and again whenever a system gains new tools or data sources.\n\n### Review checklist\n\n- [ ] Every source of input the system reads is listed, including retrieved content.\n- [ ] Output never reaches a browser, query or shell without validation.\n- [ ] Each tool and permission is justified by the task.\n- [ ] High-impact actions need a person's approval.\n- [ ] Retrieval respects the caller's permissions.\n- [ ] Retention for prompts, answers and embeddings is set and documented.\n- [ ] Models, plug-ins and tool servers come from approved sources.\n- [ ] An owner is named for each layer.\n\n### How often to repeat the review\n\nRun the worksheet before a system launches, after any change that adds a tool, data source or model, and at least once a year for systems that do not change. Keep each completed worksheet with the system's record so the next reviewer can see what was decided and why. Over time the worksheets become a simple history of how each system's risk has moved, which is useful evidence when auditors or customers ask how you manage AI risk.\n\nThe NIST framework covers this work under its map and measure functions, which ask you to identify context and risks, then assess them with repeatable methods.\n\n<h2 id=\"next\">Where to go next</h2>\n\nStart with the layer where your system can do the most harm, then work outward. The [AI security ranking](/best/ai-security/) lists vendors with the strongest public evidence across all layers. Scoring rules are on the [methodology page](/methodology/)."}