AI attack surface · Part 11
The model you hold has a name your records don't carry
Ollama keeps a model's weights in a file named by the SHA-256 of its own contents, and in a lab run on 9 November that filename was the one identifier shared by four copies of the same 1.1-billion-parameter TinyLlama weights, and of the three scanners pointed at them, Syft 1.55.0, Trivy 0.76.0 and the AI-specific ai-bom 3.6.0, none read that name from the store, though Syft alone arrived at the same value by hashing the copies whose format it recognized. Syft read the GGUF header of the named copy, typed the file as a model and recorded its SHA-256, and when the file was renamed totally-safe-assistant.gguf it reported the same component name and the same hash, so the copy linked back to the original. Renamed weights.bin, the same bytes dropped out of Syft's output, because its cataloger reads only *.gguf files, while ai-bom picked the file up by a size heuristic, named it after the filename and attributed it to Anthropic, because for a .bin file it guesses the provider from substrings of the directory path, and a folder name in the lab's working directory happened to match. Re-tagged inside Ollama's own store as totally-safe-assistant, the weights were seen by none of the three tools in any of three identical runs, while the blob under the new tag still carried the same SHA-256 in its filename, as the lab's fixture hashes show.
That one run carries the argument of this part of the series, which is about the models an organization holds itself, on laptops through Ollama or LM Studio and on servers through vLLM or llama.cpp. For those models I think the gap worth naming sits in two records security-data teams join on, the inventory and the event, and in each the missing piece is a name for the weights that a join can rely on, the content digest that would say which model actually answered. In the run, no tool gave any model a package URL or CPE a vulnerability matcher could key on, the Ollama store was seen by nothing, and a rename to .bin was enough to lose Syft's detection, though Syft did record a SHA-256 for the model files it recognized; on the event side, OCSF's ai_model object carries a provider, a name, a version and a free-form uid, and nothing for a digest or a base model. Ollama, at least, is less blind than either, since its own API returns a SHA-256 digest for each installed model and its runner process carries the weights blob's hash on its command line, so the weights are named in the store, in the API and in process telemetry, and the name is missing from the two records a security team would join on, the inventory and the event.
Reading time: about 14 minutes. Evidence tier: B for the lab runs (first-party measurement on one host each, each pre-registered, run by an agent session and re-run by a second agent session on the same rig), for what each runtime project documents or ships as a default, read on 16 November 2026; A for NVD, the CISA KEV catalog, MITRE ATLAS and the peer-reviewed backdoor result, and for the CoSAI risk map in the sense of primary files read at a pinned commit, working-group content and not a ratified standard.

Inventory
What the scanners saw
That run, R4 in the lab's numbering, put six AI artifacts in front of five tool configurations: the named GGUF file, the same weights in Ollama's store, a safetensors directory for the small embedding model all-MiniLM-L6-v2, an MCP server from npm, another from PyPI, and a VS Code extension. The grid below is the full discovery result, with each cell saying whether the tool found the artifact as a model, as an ordinary package, as the wrong kind of package or not at all.
R4 discovery · 6 artifacts × 5 tool configurations
| Artifact | Syft | Trivy fs | Trivy rootfs † | ai-bom | cyclonedx-py |
|---|---|---|---|---|---|
| T1 TinyLlama GGUF, named file | model | not found | not found | model | n/a |
| T2 Same weights in Ollama's store | not found | not found | not found | not found | n/a |
| T3 all-MiniLM-L6-v2 safetensors directory | model * | not found | not found | model * | n/a |
| T4 npm MCP server | package | package | package | not found | n/a |
| T5 pip MCP server | package | not found | package | not found | package |
| T6 VS Code extension | not found | not found | wrong package (npm) | not found | n/a |
R4 discovery grid, one host, identical in three runs. "Model" means typed as a model or machine-learning artifact, with no usable package URL in any case. * counts only under a looser rule added after the run (a model component found at the target's path). † Trivy rootfs mode was added after the run was registered.
Read down the model rows and the result is thin. Syft and ai-bom typed the named GGUF as a model, and both typed the safetensors directory as one only under a lenient rule the lab added after the run, because Syft names that directory after its base model (MiniLM-L6-H384-uncased, from config.json) rather than after the artifact. Neither gave a model a package URL a matcher could use, since Syft gives none and ai-bom gives a made-up pkg:pypi/<filename> that files a weights file into the PyPI namespace under its own filename, and no model got a CPE or an advisory, which makes the advisory column for the model rows a structural zero rather than a measured one. Syft's omission is deliberate, since its cataloger source says a package URL is left unset until the package-url spec settles model support, and the Hugging Face type the spec does define names a hub repository at a Git commit, which a renamed file on a laptop no longer carries. Under the pre-registered name match, four of the six artifacts were found by some tool, or three without Trivy's rootfs mode, which was not pre-registered, and one of six was found as an AI artifact; the more generous five of six needs both rootfs and the lenient rule.
The MCP servers are the useful contrast, because they came through well as packages, with a PURL each and every OSV-listed advisory matched (two of two for the npm server and four of four for the PyPI one) through Grype and through Trivy in rootfs mode (the two were picked because they have published advisories, and many MCP servers have none), though no tool marked either as an MCP server, and Trivy's default fs mode missed the PyPI server and its four advisories altogether, which is a mode an operator has to know to change. What the tools you already own can see carries that package-level reading into the incumbent grid. What I take from the model rows is narrower: where a model sits as a named file in a format a cataloger knows, Syft records a hash that surfaces a one-byte change and survives a rename within the same extension, which is the digest-bound identity a programme needs, and it stops there, at named GGUF and safetensors files.
R4 · four copies of one model
The model scanners do not fill the gap either. A second lab run in the same week, T5 in the lab's numbering, put three open scanners that look inside model files, modelscan 0.8.8, picklescan 1.0.5 and fickling 0.1.12, over 118 base files and 123 renamed or repackaged variants, and no output from any of them carried a digest, a package URL, a CPE or a version of the scanned artifact, so the scanner side and the inventory side share no key beyond a file path. The detection counts carry a caution too, because on the 57 unsafe files in picklescan's bypass set, modelscan flagged 3, fickling 55 and picklescan 56 in single-file mode, though that set is picklescan's own suite and its number is closer to an install check, and fickling's breadth came with flags on 11 of 18 benign files, including all six real models in the set, so on this fixture set none of the three both reads the common formats and gives a verdict that survives a rename or a nested archive. These are counts on one host from fixtures mostly drawn from the tools' own test suites, and I'd read them as the reason to treat scanning as a filter at the door.
T5 · what the model scanners flagged
Events
What the event schema carries
A third piece of lab work, R8, compared the AI artifact vocabulary D3FEND is proposing with OCSF's ai_* objects, and the model row was the sharpest mismatch in it. OCSF's ai_model, which arrived in 1.8.0, has five attributes, ai_provider, name, version and uid of its own and uid_numeric inherited from the base entity, which describe an identity, while the D3FEND proposals describe the learned parameters, so the two name different kinds of thing. Re-read at OCSF main and at v1.9.0 on 16 November, the object still has those four attributes, with nothing for a digest of the weights and nothing linking a fine-tune to its base model. The uid is free-form, so a producer could put a digest in it by convention, but nothing in the schema says it should, so a swapped model reusing a name looks the same in an OCSF event as it did to ai-bom, or to all three tools once the weights sat in Ollama's store. The schema does have typed homes for a hash elsewhere, since the file object carries hashes at v1.9.0 and ai_capability on main carries four fingerprint attributes (released in 1.10.0 on 2026-11-20), so the gap is specific to the model object on the inference event. R8 (an agent's reading of the definitions, see Limits) covers only the AI objects and leaves out the other objects an AI event might also carry; OCSF's AI objects takes the rest of that schema in detail.
Ollama already computes what the schema lacks. Its API documents a digest on each model returned by /api/tags ("SHA256 digest identifier of the model contents") and on each running model returned by /api/ps, so a collector that asked the runtime could carry a digest into an event today. A read-only check on the lab host on 16 November (Ollama 0.20.6) found that the /api/tags digest is the SHA-256 of the model's manifest, and the manifest names the weights blob by its own SHA-256, so the API names the weights one step removed. I'd expect a re-tag made with ollama cp, which copies the manifest, to keep that digest and a change to the weights to change it, though the check tested neither, and a model rebuilt from the same weights with a different template or system prompt gets a new manifest and so a new digest. The weights blob's own hash is one call further in, on the FROM line of the Modelfile that /api/show returns, which the same check confirmed for TinyLlama. So for Ollama the gap sits between the runtime and the record, and the other three runtimes in this piece were not checked for an equivalent.
Events · where the name lives
Loading
Why the name matters: loading can run code
A missing name would be an audit nuisance if loading a model were inert, and for several common formats it is not. Python's pickle, still the container behind many PyTorch checkpoints, runs callables when it deserializes, and the safer loading paths have their own bypass history: CVE-2025-32434 was remote code execution in torch.load even with weights_only=True, in PyTorch 2.5.1 and earlier, and GGUF files carry a Jinja chat template in their metadata, which is how llama-cpp-python came to have a server-side template-injection flaw when loading a model (CVE-2024-34359). The scanners meant to catch this have had bypasses too (CVE-2025-1716 and CVE-2025-10155 in picklescan), and Keras models could carry code in layer definitions before 2.13 (CVE-2024-3660). Safetensors was designed as a plain tensor container to remove the code-on-load problem for weights, though the R4 grid is a reminder that a safe format still does not tell you which model it holds.
The frameworks file this in the right places, though the mapping has a gap I'd flag. MITRE ATLAS v2026.10 has AML.T0011.000 User Execution: Unsafe AI Artifacts, rated Realized, and CoSAI's risk map has a dedicated risk, riskMaliciousLoaderDeserialization, which at commit 622605a1 carries no ATLAS mapping and five controls, among them secure-by-default ML tooling, and those controls attach to serving, storage, training and tuning, evaluation, the model itself and input handling, while the component I'd say a loader flaw sits in, componentModelFrameworksAndCode, appears in no control at that commit. That placement is my reading, since CoSAI's risks do not name components.
Behaviour planted in the weights is a harder problem, and the result I'd weigh most on it is a theoretical ceiling on what detection can promise. Goldwasser, Kim, Vaikuntanathan and Zamir (FOCS 2022) showed constructions in which a malicious trainer plants a backdoor in a classifier that no computationally bounded observer can detect without the key, for any model given black-box access, and for random-feature and random-ReLU networks even with the full weights and training data in hand. It does not say every backdoor is undetectable, but it does mean that a vendor promising to prove a model clean is promising something the theory says cannot be assured in general, which is part of why I'd put the effort into which file gets loaded and from where.
Runtimes
How the runtimes ship
The second exposure is the serving process, and each runtime's own documentation or source was re-read on 16 November for this piece, since these defaults move between releases.
Runtime defaults · read 16 November 2026
| Runtime | Default listener | Authentication by default | Read at |
|---|---|---|---|
| Ollama (current v0.40.16; the lab ran 0.20.6) | 127.0.0.1:11434; OLLAMA_HOST changes it | The local API “does not require authentication” | docs.ollama.com FAQ and authentication page |
llama.cpp server (v1.0.0 and master ef3848f9) | 127.0.0.1:9931 | --api-key default none; CORS echoes any Origin with credentials unless --tools or --agent narrows it to localhost | tools/server/README.md |
vllm serve (main as of 16 November, a4910b41, and the current stable release v0.32.0) | All IPv4 interfaces, port 8000, with no --host (source reading, consistent with the project's PR #22823; the quickstart says localhost) | --api-key guards the listed routes; /invocations and five other inference routes, /metrics, and /update_weights where generation is supported, need no key | vLLM security guide and quickstart; source |
| LM Studio | Localhost; “Serve on Local Network” is a switch; 1234 appears in examples only | “By default, LM Studio does not require authentication” | lmstudio.ai developer docs |
Ollama and llama.cpp bind to loopback by default and LM Studio describes its server as running on localhost with network serving behind a switch, and none of the four authenticates by default, so on those three the network exposure is one configuration change away, though loopback is not the same as unreachable, since llama.cpp's server by default echoes any Origin with credentials allowed, which leaves a page in the user's browser able to call it, Ollama's FAQ says it allows cross-origin requests from 127.0.0.1 and 0.0.0.0 by default, and the Ray entry in the next section is that same browser-to-local-service path. The network half is consistent with what one internet scan found in 2025: Cisco Talos researchers queried Shodan for Ollama and found 1,139 exposed instances, 214 of them (about 18.8 percent) answering with a live model, in a point-in-time count whose limits the authors list themselves. vLLM is the one I'd put in front of a platform team, for two reasons, the bind and the keys. Reading the source at main and at v0.32.0, vllm serve started without --host binds the empty address, which on Linux means every IPv4 interface, and a still-open pull request in the project's tracker (#22823) records the same behaviour in its test table, while the quickstart says the server starts "at http://localhost:8000", which is true for a client on the same machine and says nothing about who else can reach it. The Rust frontend's standalone command defaults to 127.0.0.1, though under vllm serve it inherits the Python listener, and inside a container "every interface" means the container's own, so reach depends on how the port is published; I'd confirm with the server's startup line, which prints the listen address. An operator who then sets --api-key will reasonably believe inference is protected, while the project's own security guide says /invocations serves the same inference without a key and that /update_weights is open too wherever the server supports generation; the guide's recommendation is a reverse proxy that allowlists only the intended routes. Its request logging is also off by default since a change merged on 1 August 2025, and turned on it records prompts only at DEBUG, which Rent or own took up as part of the cost of owning a serving tier.
Exploitation
Where the exploited bugs are
It would be easy to read all of this as a forecast of exploited inference engines, and the exploitation record so far points somewhere else. Re-derived from CISA's Known Exploited Vulnerabilities catalog on 23 November (catalog version 2026.11.20, 1,790 entries), the catalog has no entry naming Ollama, vLLM, NVIDIA Triton, TorchServe, llama.cpp, LM Studio, LMDeploy, PyTorch or Hugging Face Transformers. The entries the match did find sit around the engine: GPUStack (CVE-2026-102895, added 9 November 2026), a GPU cluster manager for AI model serving, where an improper-authentication flaw could give an unauthenticated caller administrative access "including user and model changes", which is the swapped-model case this piece is about arriving through a management plane; Ray (CVE-2025-62593, added 17 August 2026), a common distributed serving and training layer; MLflow (CVE-2026-64849, added 19 August 2026), which is a model registry; four LiteLLM entries, which belong to the gateway surface; and six Langflow entries including IBM's. Absence from KEV is weak evidence on its own, since KEV needs reliable proof of exploitation, and an unauthenticated runtime does not need a CVE to be abused, so the Talos count above involves no CVE at all. I'd read the record as saying that the risk from held models so far looks like exposure, authentication failures in the planes around the engine and unvetted files, more than flaws in the engine's own request handling or model loading.
Exploitation · where the KEV entries sit
KEV lists no inference engine, and several planes around one
CISA Known Exploited Vulnerabilities catalog version 2026.11.20, 1,790 entries
Around the engine: entries the match found
- Management planeGPUStack, November 2026
- Serving and training layerRay, August 2026
- Model registryMLflow, August 2026
- GatewayLiteLLM, four entries
- Also matchedLangflow, six entries, including IBM’s
Absence from KEV is weak evidence: KEV needs reliable proof of exploitation, and an unauthenticated runtime needs no CVE to be abused. Matched by product name (Tier A for the catalog).
What to record
Recording the digest yourself
Since neither the inventory tools nor the schema will name the model for you, the practical move is to compute and carry the name yourself, wherever the weights are stored, loaded or logged. These are the checks I'd start with:
- Hash the model stores directly. Hash every model file on approved infrastructure, and read Ollama's blob directory (
~/.ollama/models/blobs, or/usr/share/ollama/.ollama/modelson a Linux service install) and its manifests rather than relying on SBOM output, which in R4 reached named GGUF and safetensors files only. - Ask the runtime. Pull the digest Ollama returns from
/api/tags, and the blob hash on theFROMline from/api/show, into the same store as the inventory, keyed by host, since the first changes with a model's template or parameters and the second names the weights alone. - Read the process table. In the series' workstation run, osquery's
processestable showed Ollama's runner with--modelpointing at a blob path named by its SHA-256, so EDR or osquery process telemetry already says which weights are loaded, on that one Ollama version (0.20.6). - Carry it in the event. Until
ai_modelgrows a digest attribute, asai_capabilityin OCSF 1.10.0 already has fingerprints, carry the store hash infile.hasheson the file event, where the schema already has a place for it, and on the inference event write the digest intoai_model.uidor another documented field by local convention, saying in the mapping notes which one. - Control what loads. Block pickle-format checkpoints where you can, keep PyTorch at 2.6.0 or later so the
weights_onlyfix for CVE-2025-32434 is in, and check that scanner versions post-date their own bypass fixes (picklescan 0.0.31 or later for CVE-2025-10155). For models you publish internally, the Sigstore model-signing project signs a manifest of per-file digests, which is the same name with a signature on it, though public models mostly arrive unsigned. - Treat the runtime as a listener. Alert on a runtime process (
ollama,llama-server, LM Studio'slms, orpythonwithvllmin the command line) holding a listener on anything other than loopback, and use the ports (11434, 9931 or 8080 on older llama.cpp builds, 8000, 1234) as a hint only, since in the series' workstation run a benign file server on 8080 was the one false positive the port rule produced. Put every vLLM server behind a proxy that allowlists its intended routes, confirming from outside the proxy that/invocations,/metricsand/update_weightsfail.
The nearest ATLAS v2026.10 mitigations are AML.M0023 Maintain an AI Bill of Materials, AML.M0014 Verify AI Artifacts, AML.M0011 Restrict Library Loading and AML.M0019 Control Access to AI Models and Data in Production, and none of the checks needs an AI-security product, only ordinary file, process and network telemetry (OCSF File System Activity 1001, Process Activity 1007 and Network Activity 4001) plus the decision to keep a digest next to the name. Finding the runtimes nobody sanctioned in the first place is the subject of Three AI surfaces the network sees and can't name and Finding shadow AI.
Limits
Limits of this evidence
- R4 and T5 are one host each, one fixture set and one version of each tool, each pre-registered and run by an agent session, then re-checked by a second agent session on the same rig (a full re-run for R4, a one-run replay for T5); they show the gap exists and say nothing about how often it bites in a real fleet.
- The Ollama result is for 0.20.6, which the lab ran, while the current release is 0.40.16; the API checks on the lab host read
/api/tagsand/api/showfor one model, and re-tag, rebuild and weight-swap behaviour and/api/pswere not tested, and R4 did not test the Hugging Face cache layout a vLLM tier usually loads from, so nothing here says whether the scanners see that layout. - Newer scanner releases existed and were skipped under the lab's two-week cooldown (Syft 1.57.1, Grype 0.121.3 and Trivy 0.76.2 at the time), and their model support may differ.
- T5's fixtures come mostly from the scanners' own test suites (109 of 118 base files from picklescan's), and its benign set is 18 files, so its numbers are counts and not rates.
- R8's grades are an agent's reading of definitions with no second grader; only the five-attribute fact about
ai_model, which was re-read in the schema itself, is carried here as fact. - The vLLM bind behaviour is a source reading at main and at v0.32.0, consistent with the test table in the project's open PR #22823 but not a run on a host of my own, and the runtime defaults are vendor documentation, which says what a switch does and not how deployments set it.
Falsifiers
What would change my mind
A Syft, Trivy or ai-bom release that reads Ollama's store and reports each model with its blob digest would close the inventory half of this, and since Syft already reads GGUF layers from OCI registries, an Ollama-store reader looks like a small step; any of the three model scanners emitting a SHA-256 of the bytes it scanned would give the scanner side the join key it lacks, and I'd retest on the next release that ships either. On the schema side, a digest and a base-model link on OCSF's ai_model, which is the change R8 points to, would let a producer carry the name without a local convention. And a KEV entry for a flaw in an engine's own request handling or model loading, as opposed to a management plane or gateway in front of it like the GPUStack entry, or a run of incidents where the engine and not its exposure was the way in, would move the weight I put on exposure over exploitation.
Bottom line: for a model the organization holds, the scanners give the weights no identifier a matcher can use and lose them inside Ollama's store, and OCSF's ai_model has no attribute for a weights digest, while Ollama's store, API and runner process already carry one, so the cheapest fix available today is to hash the stores, ask the runtime and carry the digest into the record yourself, and to treat each runtime as an unauthenticated listener until it is configured otherwise. The next part turns to the model the organization trains on its own data, where the weights also become a data store.