Venice AI Strips Secrets From LLMs to Halt Agent Data Leaks

How Secrets Leak Through AI Agents (and How to Stop It) — Venice AI — AI Engineer

AI Engineer

Language models inevitably leak stored credentials through logging and tool calls unless developers shift authentication entirely to a deterministic execution runtime.

AI-assisted summary of How Secrets Leak Through AI Agents (and How to Stop It) — Venice AI — original source. Check the original for full context.

Source published:

Key ideas

  • Privacy in an AI agent system is dictated by its surrounding orchestration harness and logging pipelines rather than the model's data-use terms, as default telemetry frequently dumps raw prompts and credentials into plain-text storage. (4:12)
  • Feeding authentication credentials directly into an LLM's reasoning context exposes them to prompt injection, caching, and exfiltration via untrusted tool calls; security requires isolating secrets strictly within a deterministic execution runtime. (5:56)
  • Data breaches are operational certainties whose financial and reputational damage scales directly with stored user telemetry, making zero-retention architectures the most effective way to cap an organization's blast radius. (1:42)
  • Hardware-enforced Trusted Execution Environments (TEEs) provide mathematically verifiable cryptographic attestations for private inference, though extending full confidentiality to external tool calls remains an unresolved engineering frontier. (13:13)

Detailed notes

## Background Published on YouTube by the AI Engineer channel on October 11, 2026, this conference talk features Joshua Mo, lead developer relations engineer at Venice AI and former lead maintainer of Rig. Based on the page description, the session explores why a private model does not make a private product, detailing how agentic scaffolding leaks sensitive information through logs and tool calls and providing defensive patterns like split-key custody, scoped handles, and confidential compute.

## TL;DR Joshua Mo demonstrates that privacy in AI systems is fundamentally about minimizing data blast radius rather than relying solely on model provider promises. Naive agent architectures routinely expose sensitive data through verbose observability logging and by injecting vault credentials directly into non-deterministic LLM contexts where tool calls can exfiltrate them. To prevent leaks, Mo presents proven architectural patterns: tracking users via salted cryptographic hashes, using split-key encrypted custody, and wiring secrets exclusively into deterministic execution layers rather than the reasoning model. He highlights hardware-enforced Trusted Execution Environments (TEEs) with verifiable attestations as the foundation for private inference, while noting confidential tool calling remains an unsolved industry challenge.

## Atmosphere & style The talk has the focused, pragmatic feel of an insider engineering briefing, delivered with steady technical authority rather than alarmist hype. Mo speaks directly from low-level systems experience, methodically dissecting architectural diagrams and failure points with dry, analytical precision. The atmosphere is grounded and candid, balancing serious warnings about catastrophic enterprise data loss with lighthearted, self-aware humility when acknowledging the messy developer-experience hurdles of confidential tool execution.

## Bulletin - [04:12](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=252s) Privacy in an AI agent system is dictated by its surrounding orchestration harness and logging pipelines rather than the model's data-use terms, as default telemetry frequently dumps raw prompts and credentials into plain-text storage. - [05:56](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=356s) Feeding authentication credentials directly into an LLM's reasoning context exposes them to prompt injection, caching, and exfiltration via untrusted tool calls; security requires isolating secrets strictly within a deterministic execution runtime. - [01:42](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=102s) Data breaches are operational certainties whose financial and reputational damage scales directly with stored user telemetry, making zero-retention architectures the most effective way to cap an organization's blast radius. - [13:13](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=793s) Hardware-enforced Trusted Execution Environments (TEEs) provide mathematically verifiable cryptographic attestations for private inference, though extending full confidentiality to external tool calls remains an unresolved engineering frontier.

## Key takeaways - [01:42](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=102s) Data breaches must be treated as inevitable operational milestones rather than edge cases, meaning preserving trust and limiting blast radius are existential priorities for AI platforms. - [01:42](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=102s) The potential damage of a security incident is strictly proportional to the volume of persisted unencrypted data; minimizing telemetry and prompt storage directly caps adversary impact. - [02:37](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=157s) Venice AI maintains a zero-retention policy for open-source model inference by preserving conversational state exclusively in client-side storage. - [04:12](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=252s) Standard observability pipelines (metrics, traces, and logs) are major sources of silent leaks when debuggers routinely persist unscrubbed prompts, session contexts, and environment variables. - [05:56](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=356s) Naive agent architectures fetch secrets from vaults and inject them into prompt context, allowing non-deterministic models to echo passwords or pass them into external tool arguments. - [06:52](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=412s) Identity tracking for rate limits and session continuity should utilize deterministic, salted cryptographic hashes rather than personal data like email addresses or raw IPs. - [06:52](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=412s) Split-key custody divides encryption keys into separate read and write halves, ensuring compromised administrative credentials or database breaches cannot unilaterally decrypt sensitive payloads. - [06:52](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=412s) Persistent master credentials should be replaced with temporary, revocable handles and short-lived tokens restricted to specific connection pools. - [08:40](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=520s) Exposing broad Model Context Protocol (MCP) tool suites bloats the context window—degrading reasoning performance—while unnecessarily expanding the blast radius of prompt injection attacks. - [08:40](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=520s) Pre-execution classification layers using auxiliary models, in-memory rules, or vector search against attack embeddings can intercept prompt injections before requests hit the agent runtime. - [10:46](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=646s) Hardened architectures decouple reasoning from execution: the LLM outputs abstract, parameterized plans without seeing secrets, while the deterministic runtime injects vault credentials at network dispatch. - [12:06](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=726s) Compute sandboxing via microVMs or isolated VPCs protects host infrastructure but cannot prevent data exfiltration if an agent retains unrestricted internet egress access. - [12:06](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=726s) Engineering teams should own and implement custom agent runtimes to maintain full authority over execution boundaries, context hygiene, and credential injection. - [13:13](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=793s) Confidential compute utilizes silicon-level Trusted Execution Environments (TEEs) to encrypt memory during inference, preventing host operators, hypervisors, and cloud providers from intercepting execution state. - [13:34](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=814s) Cryptographic attestations generated within TEEs allow clients to independently validate that prompt processing executed untampered code inside an isolated hardware enclave. - [13:56](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=836s) Achieving truly confidential tool calls remains an open industry challenge due to the architectural friction between developer-friendly API ergonomics and strict end-to-end payload encryption.

## Detailed walkthrough ### [00:12](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=12s) Introduction: From Rig to Venice AI

Joshua Mo introduces himself as the lead developer relations engineer at Venice AI, where his day-to-day responsibilities span developer documentation, community outreach, partnerships, and hands-on software engineering. Before joining Venice, Mo served as the lead maintainer for Rig, recognized as the premier open-source library for building LLM applications and agentic workflows in Rust. His background in low-level systems and AI engineering sets the stage for examining the architectural trade-offs between system functionality and user privacy.

He outlines the mission and product surface of Venice, describing it as an unrestricted, privacy-preserving AI platform built to deliver top-tier open-source intelligence without digital surveillance. The platform provides full drop-in compatibility with the OpenAI API specification, hosts cutting-edge open models, and operates consumer interfaces alongside an API. In addition to conversational chat, Venice supports a creative studio suite tailored for content creators, covering image generation, audio synthesis, transcription, and video generation.

- Venice AI is engineered as an unrestricted and private alternative to closed API providers, offering complete OpenAI API endpoint compatibility. - Venice hosts the latest open-source language models alongside a dedicated content creation studio that handles video, audio, image generation, and transcription tasks. - The company maintains a strict zero-retention policy for model inputs, storing no user prompts or conversation histories on its servers.

---

[01:42](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=102s) Why Privacy Matters: Blast Radius and Reputational Risk

Mo dives into the economic and operational realities of data protection, arguing that cybersecurity incidents are no longer hypothetical edge cases but inevitable milestones in a company's lifecycle. In an ecosystem where foundational models are commoditized, trust becomes the primary differentiator. A single catastrophic leak of conversational data or proprietary intellectual property can instantly dissolve user confidence, driving end users and commercial partners into the arms of competitors. For B2B platforms, the stakes are existential: leaking confidential data can wipe out anchor enterprise accounts that provide the vast majority of top-line revenue.

Beyond immediate churn, Mo highlights the concept of the data "blast radius." Every piece of customer telemetry, conversational context, and unencrypted prompt cached in persistent storage expands the total exposure surface of an infrastructure breach. If an adversary compromises an internal database or an administrative account, the severity of the incident is directly proportional to how much unencrypted data sits waiting to be harvested. Storing less data fundamentally caps the maximum harm an attacker can inflict. As Joshua Mo puts it: “You only need one data breach before your users stop trusting you and they move on to another provider.”

- Data breaches should be treated as inevitable operational events rather than unlikely anomalies, making corporate reputational risk the central threat vector. - Losing enterprise customer trust during an incident can instantly jeopardize accounts responsible for up to 90% of a company's annual recurring revenue. - The volume of stored user telemetry and conversation logs dictates the blast radius; minimizing persistence directly shrinks the potential damage of any system breach.

---

[02:37](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=157s) Venice's Multi-Tiered Privacy Architecture

To demonstrate that zero-retention is achievable in production, Mo details the privacy controls Venice enforces across its stack. When users interact with supported open-source models, all conversation state remains strictly on the client device. The server acts as a transient execution pipeline without writing user dialogue to disk or caching history in a backend database. When users opt to query proprietary closed providers such as OpenAI or Anthropic through Venice, the platform actively scrubs and anonymizes the request payload, stripping network fingerprints and user identifiers so upstream vendors cannot link prompts back to specific individuals.

For sensitive computational workloads, Venice runs models inside hardware-enforced Trusted Execution Environments (TEEs), providing cryptographically verifiable attestations that inference execution occurred inside an isolated enclave impenetrable to host operators. Where asynchronous polling is unavoidable—such as long-running video generation workflows where a client must repeatedly query an endpoint for rendering status—Venice implements split-key custody. The stored payload is encrypted such that neither an external attacker compromising the database nor an internal employee with administrative credentials can decrypt the media without the complementary client key. Explaining this defensive posture, Joshua Mo emphasizes: “We store the results in a totally encrypted payload using split key custody, meaning that attackers can't access your data and neither can the team should their accounts be compromised.”

- Open-source model inference runs without conversational persistence on Venice infrastructure, maintaining chat history exclusively in the client's local storage. - External calls routed to third-party providers like OpenAI and Claude undergo identity anonymization, preventing upstream tracking of user prompts. - Compute workloads deployed within Trusted Execution Environments (TEEs) allow developers to mathematically verify that inference executed inside an isolated, private enclave. - Asynchronous polling endpoints store intermediate artifacts inside encrypted payloads protected by split-key custody, preventing rogue internal access or external data theft.

---

[04:12](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=252s) The Observability and Logging Trap

Addressing a common misconception across the industry, Mo warns that slapping a private model onto an existing pipeline does not make an application secure. Many engineering teams tout that their systems respect user confidentiality simply because their downstream LLM provider pledges not to train on API inputs. However, an LLM is merely one component of a modern agentic workflow. The scaffolding wrapped around the model—the orchestration loops, retrieval mechanisms, tool runners, and system monitors—introduces substantial attack vectors and accidental leaks. As Joshua Mo observes: “While models are a very important part of an agentic system, in fact, they're a vital part of the system, they are still only one part.”

Mo singles out standard observability pipelines as one of the most pervasive sources of silent leaks. Production systems depend on telemetry across three standard pillars: traces (spans capturing execution latency over time), metrics (quantitative counters and gauges), and logs (unstructured text records). During routine development and debugging, engineers frequently configure logging utilities to print raw request inputs, incoming payloads, and exception stack traces. Unchecked log aggregators quietly capture full prompts, personal data, and environment variables, persisting them in plain text across log storage systems where access controls are notoriously loose.

```mermaid flowchart TD accTitle: Accidental Leaks in Agent Observability Pipelines accDescr: Diagram illustrating how user prompts, personal data, and secrets bypass the model and leak into log aggregation systems.

subgraph UserInteraction["Client Layer"] U["User Prompt with Sensitive Data"] end

subgraph AgentOrchestration["Agent Scaffolding"] R["Agent Runtime / Orchestrator"] L["Verbose Loggers / Tracing Hooks"] end

subgraph DataLeakage["Persistent Exposure"] LOGS[("Centralized Log Aggregator\n(Plaintext Prompts & Secrets)")] end

U --> R R --> L L -->|"Unsanitized telemetry"| LOGS ```

- An AI system's privacy stance is determined by its surrounding operational harness, not solely by the underlying model's data-use terms. - Modern observability relies on metrics (counters and gauges), traces (execution spans over time), and logs (descriptive text messages). - Default debugging practices often dump entire raw prompts, user session contexts, and embedded credentials directly into centralized log aggregation clusters.

---

[05:56](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=356s) How Secrets Leak Through Traditional Agents

Mo walks through a common architectural failure pattern in modern autonomous agents. In a standard setup, a user dispatches a complex query to an agent runtime. Recognizing that it requires external authorization to complete the task, the runtime queries a secret management system, such as a 1Password vault or a HashiCorp Vault cluster, to retrieve an API token or service credential. In naive agent designs, this plain-text secret is fed straight into the LLM's conversational reasoning context so the model can construct the downstream HTTP payload or CLI command.

Once a secret enters the non-deterministic reasoning layer, security guarantees break down. The language model places the secret into its active working memory, increasing the probability that the credential will be echoed back to the user, leaked in debugging traces, or incorporated into vendor training corpora. Worse still, if the agent is tricked into calling an attacker-controlled endpoint via an untrusted tool call, it may hand the plain-text secret over directly in the tool arguments. Highlighting this design flaw, Joshua Mo warns: “However, due to the way that it's architected, the secrets get fed directly to the LLM, which means it then may get used in training data.”

```mermaid flowchart LR accTitle: Secret Exfiltration Flow in Naive Agent Architecture accDescr: Sequence showing how an agent passes raw credentials from a vault into an LLM reasoning context and risks exfiltration.

subgraph SecretStorage["Vault"] V["1Password / HashiCorp Vault"] end

subgraph VulnerablePipeline["Vulnerable Architecture"] U["User Request"] --> RT["Agent Runtime"] V -->|"Raw Secret"| RT RT -->|"Secret in Prompt Context"| LLM["LLM Reasoning Layer"] LLM -->|"Tool Call with Secret"| EXT["External API / Bad Actor"] end ```

- Naive agent systems fetch raw credentials from secrets managers and inject them directly into the LLM prompt context. - Feeding authentication secrets into the reasoning layer risks permanent retention in model training pipelines and provider prompt caches. - Non-deterministic model behavior can lead an agent to emit raw credentials inside tool-call arguments sent to external or untrusted servers.

---

[06:52](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=412s) Defense Patterns: Hashed Identifiers, Split-Key Custody, and Revocable Handles

To combat systemic data leaks, Mo presents engineering patterns deployed at Venice to enforce strict isolation. The first principle involves replacing direct user identifiers with cryptographic hashes. When an agent system needs to track identity—such as enforcing API rate limits, abuse quotas, or session continuity—it should never process or persist raw email addresses, IP addresses, or database primary keys. Instead, the runtime computes a deterministic hash of the user footprint, allowing infrastructure to manage quotas without retaining personal data.

When long-term persistence cannot be avoided, Venice relies on split-key custody inside isolated computing enclaves. Under this scheme, cryptographic keys are fractured into distinct halves—a read half and a write half. An attacker who gains read access to the database or compromises an administrative account cannot decrypt stored payloads because completing the cryptographic operation requires both distinct key halves. Mo also advocates for capability-based handles over raw authentication tokens. Rather than providing an agent with persistent credentials like master API keys or long-lived database passwords, the runtime issues revocable, scope-limited handles (such as short-lived session keys or scoped JWTs) tied to managed connection pools. Summarizing the strength of fragmented keys, Joshua Mo explains: “By splitting these, the attacker cannot access the data due to needing both halves for the decryption to complete.”

- Identity tracking for rate-limiting and session management should use salted cryptographic hashes instead of raw user identifiers or IPs. - Split-key custody divides encryption keys into separate read and write halves, ensuring compromised administrative credentials alone cannot decrypt data. - Systems should avoid exposing persistent credentials to agents, instead issuing temporary, revocable handles and short-lived tokens to access database pools. - Development teams utilizing coding harnesses such as Cursor and Claude Code should structure prompt instructions to maintain explicit privacy guardrails around sensitive codebases.

---

[08:40](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=520s) Narrowing Tool Scope and Guarding Against Prompt Injection

Mo examines the security vulnerabilities introduced by open-ended tool interfaces, particularly Model Context Protocol (MCP) servers. A developer might connect an agent to an enterprise MCP server exposing fifteen or twenty discrete administrative tools. In practice, the agent's immediate task may require only a single capability, such as querying a status endpoint. Exposing all twenty tools along with broad API keys creates a severe attack surface: if the agent encounters adversarial content, an untrusted instruction can manipulate it into exfiltrating the credentials via an unused tool call to an external endpoint.

To mitigate this, Mo urges engineers to enforce narrow agent scoping, provisioning only the exact tools and permissions required for the immediate task. Restricting the toolset not only curbs exfiltration risks but also prevents context window degradation. As context windows fill up with extensive tool schemas and API documentation, reasoning accuracy deteriorates significantly. To stop malicious commands before they hit the agent, Mo recommends deploying dedicated classification layers in front of the runtime. These screen incoming prompts for injection attacks using lightweight auxiliary LLMs, semantic vector search against known attack embeddings (via engines like Qdrant or LanceDB), or low-latency in-memory validation routines. Emphasizing the operational cost of bloated contexts, Joshua Mo notes: “It's well known that when you fill your context window, by doing so, when you reach near the limit of your context window, performance can actually degrade considerably.”

- Exposing broad MCP toolsets grants excessive capabilities to agents, increasing the blast radius if an untrusted instruction triggers unintended tool execution. - Narrow agent scoping restricts tool availability to the exact functions needed for the immediate execution loop. - Saturated context windows filled with excessive tool definitions cause significant model performance and reasoning degradation. - Pre-execution classification guards detect prompt injection attempts using specialized auxiliary models, vector similarity search via Qdrant or LanceDB, or in-memory rules.

---

[10:46](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=646s) Moving Credentials from the Reasoning Layer to the Execution Layer

Mo presents the core architectural solution for securing secrets in agentic environments: decoupling the non-deterministic reasoning layer from the deterministic execution layer. In an insecure agent, credentials pass through the LLM. In a secure architecture, the user prompt enters the LLM reasoning layer, which outputs abstract, parameterized action plans without knowing or touching underlying credentials. The LLM then hands these non-deterministic plans off to a separate, deterministic agent execution runtime.

This deterministic runtime connects directly to the credential vault (such as 1Password or HashiCorp Vault). When an action requires authentication—such as an automated browser agent logging into a corporate SaaS portal or calling a restricted REST endpoint—the execution layer injects the credentials at runtime inside its deterministic boundary. The LLM never observes the password, cannot output it in text completions, and cannot be socially engineered into leaking it through tool arguments. Defending this decoupled paradigm, Joshua Mo argues: “With this software architecture, it's much more reasonable to say that it's private and secure rather than feeding your password directly into the reasoning layer as well as calling external APIs.”

```mermaid flowchart TD accTitle: Decoupled Agent Architecture Isolating Secrets from the LLM accDescr: Architecture diagram showing how credentials flow exclusively into a deterministic execution runtime rather than the LLM reasoning layer.

subgraph UserLayer["User Input"] REQ["User Request"] end

subgraph ReasoningLayer["Reasoning (Non-Deterministic)"] LLM["LLM Planning Layer\n(Never Sees Credentials)"] end

subgraph SecureExecution["Execution Layer (Deterministic)"] RT["Agent Execution Runtime"] VAULT[("Secret Vault\n(HashiCorp / 1Password)")] TOOL["Target Tool / External API"] end

REQ --> LLM LLM -->|"Structured Action Plan"| RT VAULT -->|"Injects Auth Token"| RT RT -->|"Authenticated Execution"| TOOL ```

- In a hardened architecture, the LLM functions purely as a planning engine generating abstract, parameterized task plans. - Secret vaults integrate strictly with the deterministic execution runtime, completely bypassing the model's prompt context. - Browser automation agents and API runners inject authentication tokens at the point of network dispatch, preventing models from seeing raw passwords.

---

[12:06](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=726s) Sandboxing Limitations and Owning the Agentic Runtime

While virtualization and isolated runtimes are essential baselines, Mo cautions against viewing sandboxes as a silver bullet. Packaging an agent inside a microVM like AWS Firecracker or running an isolated Amazon EC2 instance within a private VPC prevents unauthorized access to the host operating system. However, if the sandboxed agent is granted egress internet access to call external APIs, an attacker who successfully injects instructions into the reasoning loop can still order the agent to transmit internal memory contents across network boundaries. Network boundaries and runtime permissions must be actively monitored and restricted rather than assumed secure.

Because off-the-shelf agent harnesses often introduce hidden telemetry hooks, loose prompt construction, and opaque tool-invocation pipelines, Mo strongly advises engineering teams to build and own their proprietary agent runtimes. By implementing custom orchestration harnesses, developers maintain granular control over execution stages, observability hooks, credential injection boundaries, and context hygiene. Stressing that isolation alone cannot guarantee data safety, Joshua Mo states: “However this doesn't act as a cure-all for your agentic systems.” He reinforces the vulnerability: “If you have internet access enabled for your agent, it can still accidentally exfiltrate data through external API access if you're not careful and therefore monitoring permissions is essential.”

- MicroVM sandboxes (such as Firecracker) and VPC-isolated instances safeguard host environments but do not stop network-based data exfiltration. - Sandboxed agents equipped with unrestricted internet connectivity remain vulnerable to leaking internal context via unauthorized external API calls. - Continuous permission auditing and strict network egress policies are required alongside compute-level sandboxing. - Engineering teams should design custom agent runtimes to maintain full authority over execution boundaries, telemetry capture, and tool permissions.

---

[13:13](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=793s) Confidential Compute at the Hardware Level

Mo turns to hardware-enforced guarantees, introducing confidential compute as the foundation of end-to-end private artificial intelligence. While software-level controls and runtime sandboxes block common leakage vectors, they still require users to trust the cloud provider and host OS administrators. Confidential compute addresses this limitation by running the model inference pipeline within hardware-enforced Trusted Execution Environments (TEEs) directly on the CPU or GPU.

Inside a TEE, running memory is cryptographically encrypted at the silicon level, rendering it unreadable to host operating systems, hypervisors, cloud infrastructure operators, and memory-dump utilities. The enclave issues verifiable cryptographic attestations that prove the exact, untampered model code was executed in isolation without external interference. When a client dispatches an inference request to Venice under this model, privacy shifts from an unverified policy claim into a mathematically verifiable execution guarantee. Describing this paradigm, Joshua Mo explains: “In terms of this, there's something I like to call confidential compute where a trusted execution environment essentially at the hardware level enables the inference process to be run privately.”

- Confidential compute leverages silicon-level Trusted Execution Environments (TEEs) to protect inference workloads in memory. - Hardware-enforced enclaves prevent host machine administrators, hypervisors, and infrastructure providers from reading execution state. - Remote cryptographic attestations allow clients to mathematically verify that requests are processed by untampered model binaries inside an isolated enclave.

[13:34](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=814s) Verifiable Attestations and Cryptographic Isolation

Joshua Mo details how confidential compute achieves verifiable security when executing models. When an agent sends a prompt into Venice AI's trusted execution environment (TEE), the system processes the request, returns a response, and generates a cryptographic attestation alongside it. Users do not simply have to take the infrastructure provider's word on trust; they can independently validate this signature against an attestation verifier to confirm that the code and environment have not been tampered with or intercepted.

This architectural pattern changes the trust boundaries of agentic systems by introducing verifiable isolation. Instead of relying on promises from cloud hosts, developers can mathematically guarantee that the reasoning process remained untainted. As Joshua Mo emphasizes: “So in terms this what this actually means is that you can fully isolate an agent at the reasoning layer cryptographically and prove it.”

```mermaid flowchart LR accTitle: Cryptographic Attestation Flow accDescr: An agent queries an LLM in a TEE, receiving an attestation that is verified independently.

subgraph UserEnv["User / Client Environment"] Agent["AI Agent"] Verifier["Attestation Verifier"] end

subgraph SecureTEE["Trusted Execution Environment (TEE)"] LLM["Model Reasoning Layer"] end

Agent -->|"Send prompt"| LLM LLM -->|"Return response + attestation"| Agent Agent -->|"Verify cryptographic proof"| Verifier ```

[13:56](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=836s) The Open Challenge of Confidential Tool Calls

Turning to the bleeding edge of agent privacy, Joshua Mo addresses the unresolved problem of confidential tool calls. While trusted execution environments provide strong guarantees for the model's core reasoning and Venice AI offers end-to-end encryption, extending full confidentiality to external tool calls introduces significant architectural tension. The core friction lies in developer experience: teams must balance building an ergonomic API experience that developers actually want to use against the strict requirement of allowing users to return and process completely encrypted tool executions.

Joshua Mo notes that one reliable architecture to solve this is allowing providers to own the compute layer where the tool calls themselves execute, keeping the data inside the protected boundary. However, he pauses and chuckles as he acknowledges the sheer complexity of making this seamless in practice, candidly admitting that it remains an active area of development across the industry. Recapping the frontier of privacy-preserving agent architecture, Joshua Mo summarizes: “So in terms of confidential tool calls um yeah there's definitely some work to be done.”

- **TEE Utility:** Trusted execution environments remain highly effective for securing tool execution, though practical end-to-end encrypted integration remains non-trivial. - **API Ergonomics vs. Privacy:** Designing interfaces that preserve full payload encryption during external tool roundtrips without degrading developer usability is an ongoing challenge. - **Provider-Owned Compute:** Hosting both tool execution and model reasoning within the same controlled compute perimeter offers a viable pathway toward truly confidential agentic workflows.

## Notable quotes > [01:42](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=102s) You only need one data breach before your users stop trusting you and they move on to another provider. — Joshua Mo

> [12:06](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=726s) If you have internet access enabled for your agent, it can still accidentally exfiltrate data through external API access if you're not careful and therefore monitoring permissions is essential. — Joshua Mo

> [04:12](https://www.youtube.com/watch?v=xn8EsW0wxyc&t=252s) While models are a very important part of an agentic system, in fact, they're a vital part of the system, they are still only one part. — Joshua Mo

## Mentioned 1Password, Amazon EC2, Anthropic, AWS Firecracker, Claude, Claude Code, Cursor, HashiCorp Vault, Joshua Mo, LanceDB, Model Context Protocol, OpenAI, Qdrant, Rig, Rust, Trusted Execution Environments, Venice AI

## Video description A private model doesn't make a private product. The leaks happen in everything you build around it.

Joshua Mo, lead developer relations engineer at Venice AI and previously lead maintainer of the Rust AI framework Rig, explains why privacy matters (one breach and users leave, and less stored data means a smaller blast radius) and how Venice approaches it: no stored prompts, anonymized requests to closed providers, models in trusted execution environments, and split-key encrypted storage. Then he shows where agent systems leak: logs that quietly capture prompts and secrets, and secrets fetched from a vault straight into the reasoning layer, where a tool call can exfiltrate them. His patterns: hashed IDs instead of personal data, split-key custody, revocable handles, narrow agent scope, a classifier in front of the agent to catch prompt injection, wiring the vault to the execution layer instead of the LLM, sandboxes plus permission monitoring, and confidential compute with verifiable attestations. He closes on the open problem of confidential tool calls.

In this talk: • Why privacy is about blast radius, not just the model • How logs and secrets leak through a typical agent • Keeping credentials in the execution layer, never the LLM • Hashes, split keys, handles, narrow scope and confidential compute

SPEAKER Joshua Mo, Lead DevRel Engineer, Venice AI LinkedIn: https://www.linkedin.com/in/joshua-mo-4146aa220/ X: https://x.com/joshmo_dev GitHub: https://github.com/joshua-mo-143 Website: https://joshmo.ooo

LINKS Venice AI: https://venice.ai Venice API docs: https://docs.venice.ai Rig (Rust AI framework): https://github.com/0xPlaygrounds/rig

CHAPTERS 0:00 Intro 0:55 What Venice is 1:40 Why privacy matters 2:35 How Venice handles privacy 4:15 Not all systems are private 5:05 The logging trap 5:54 How secrets leak through an agent 6:49 Patterns that work 7:54 Revocable handles 8:39 Narrow agent scope 9:29 Screening for prompt injection 10:44 Keep secrets out of the model 12:04 Sandboxes aren't a cure-all 12:54 Own your runtime 13:09 Confidential compute 14:49 Confidential tool calls

Recorded at the AI Engineer World's Fair 2026 in San Francisco. Subscribe for more talks from the engineers building with AI.

AI Engineer: https://ai.engineer YouTube: https://www.youtube.com/@aiDotEngineer X: https://x.com/aiDotEngineer LinkedIn: https://www.linkedin.com/company/aidotengineer/

#AIPrivacy #AISecurity #AIEngineer

[Source](https://www.youtube.com/watch?v=xn8EsW0wxyc)

Reading summary

Securing AI agents requires addressing leaks across scaffolding, telemetry, and execution rather than merely relying on private models, according to Venice AI developer relations engineer Joshua Mo. Minimizing the data blast radius and decoupling non-deterministic model reasoning from deterministic credential handling are essential to preventing systemic data exposure. Blast Radius and the Telemetry Trap (1:42) Mo argues that data breaches are inevitable operational milestones rather than anomalous events. Because foundational models are commoditized, trust serves as the core differentiator, and a single breach can instantly jeopardize enterprise accounts that drive up to 90% of annual recurring revenue. The severity of any incident depends directly on the data blast radius—the volume of unencrypted prompts, telemetry, and conversational logs retained in persistent storage. Capping persistence fundamentally limits the harm an adversary can inflict during an infrastructure compromise. A central misconception across the industry is that using an LLM provider with a zero-retention policy makes an entire application secure. In practice, the scaffolding surrounding the model—orchestrators, retrieval pipelines, and observability systems—introduces massive exposure. Standard monitoring pipelines capturing metrics, execution traces, and logs frequently record raw request payloads and stack traces during routine debugging. These unsanitized logs quietly persist plain-text prompts, user credentials, and environment variables inside centralized logging aggregators where access controls are often weak. Decoupling Reasoning from Execution Layers (5:56) A critical architectural vulnerability in naive agent systems is fetching credentials from vaults (such as HashiCorp Vault or 1Password) and passing them directly into the LLM's prompt context. Once a secret enters the non-deterministic reasoning layer, it risks being echoed back in user completions, exposed in debug traces, retained in prompt caches or training sets, or exfiltrated via untrusted tool-call arguments. To resolve this, Mo advocates decoupling the non-deterministic planning layer from the deterministic execution runtime. The language model should function strictly as an abstract planner that outputs structured, parameterized action plans without ever observing raw credentials. When an action requires authentication—such as an automated browser logging into a SaaS portal—the separate deterministic execution layer injects the necessary tokens directly at the point of network dispatch. The model never views the secret, preventing extraction through prompt injection or social engineering. Enforcing Scoping and Sandbox Limits (8:40) Open-ended integrations like Model Context Protocol (MCP) servers often expose dozens of administrative tools when a task requires only one. Granting broad capabilities expands the attack surface, allowing adversarial instructions to manipulate the agent into invoking unused tools to exfiltrate data. Bloated tool schemas also consume context windows, which Mo notes degrades model reasoning performance. Defenses include narrow agent scoping, pre-execution prompt classification via auxiliary models or vector search (using engines like Qdrant or LanceDB), and replacing direct user identifiers with salted cryptographic hashes for rate limiting. While compute isolation through microVMs like AWS Firecracker or private VPC instances protects the underlying host, Mo cautions that sandboxing is not a complete solution. An isolated agent with unrestricted outbound internet access can still transmit internal context to external endpoints if injected with malicious instructions. Engineering teams must enforce strict network egress controls and ideally build proprietary orchestration runtimes to maintain full oversight of telemetry, context hygiene, and credential boundaries. Hardware Isolation and Verifiable Attestation (13:13) To eliminate the need to trust cloud providers or host administrators, Venice AI implements confidential compute using silicon-level Trusted Execution Environments (TEEs). Running inference inside a hardware enclave keeps memory encrypted at the chip level, preventing hypervisors, cloud operators, and memory-dump tools from inspecting executing workloads. Enclaves generate cryptographic attestations that allow clients to independently verify that their requests were processed by untampered model binaries. For asynchronous operations where intermediate artifacts must persist, such as video rendering workflows, Mo points to split-key custody. Encryption keys are divided into separate read and write halves so that neither a database breach nor compromised administrative credentials alone can decrypt stored payloads without the client's complementary key half. Extending confidentiality to external tool calls remains an unresolved engineering frontier. Preserving end-to-end encryption across external tool roundtrips while maintaining an ergonomic developer experience creates significant friction. While executing tool logic inside the provider's owned compute perimeter offers a viable path forward, Mo acknowledges that making confidential tool calls seamless in production remains an active, ongoing challenge.

Source quotes

[1:42] Joshua Mo: You only need one data breach before your users stop trusting you and they move on to another provider. [12:06] Joshua Mo: If you have internet access enabled for your agent, it can still accidentally exfiltrate data through external API access if you're not careful and therefore monitoring permissions is essential. [4:12] Joshua Mo: While models are a very important part of an agentic system, in fact, they're a vital part of the system, they are still only one part.

Original transcript

[0:12] Hi everyone. Uh, welcome to my talk. I'm [0:15] Joshua Mo and today we're going to be [0:17] talking about some of the challenges of [0:20] building a privacy respecting AI system. [0:26] So just for an introduction as to who I [0:29] am, I'm currently the lead developer [0:31] relations engineer at Venice AI. So [0:35] currently I handle partnerships, [0:37] documentation, talking to developers, [0:40] um some engineering and other things [0:44] other things as well. [0:48] Uh so prior to this I was actually the [0:50] lead maintainer for rig which is the [0:54] leading AI framework in Rust. [0:58] Um so what is Venice? So Venice is a [1:03] private and unrestricted AI platform. Uh [1:08] so we host all the latest open-source [1:10] models. We're 100% open AI compatible. [1:15] We don't store any prompts or [1:17] conversations [1:19] and we also have a web app that you can [1:22] use to talk to our models as well. We [1:26] also have a studio offering that is um a [1:32] offering for our content creators that [1:35] includes video, audio, image generation [1:38] and transcription. [1:42] So why does privacy matter? So let's d [1:46] deep dive into this. So as we know data [1:50] breaches are increasingly becoming an [1:54] eventuality which means that essentially [1:58] reputational risk matters. You only need [2:01] one data breach before your users stop [2:04] trusting you and they move on to another [2:06] provider. Or if you're enterprise, maybe [2:10] you lose the enterprise customer who's [2:12] been fueling almost 90% of your annual [2:16] revenue. [2:18] So in this case, sensitive data can [2:20] severely increase the impact of any [2:23] security incident. As well as that, [2:26] storing less use uh user data directly [2:30] reduces the blast radius of a security [2:33] security incident that happens. [2:37] So, how does Venice do privacy today? [2:40] Well, there's a few ways. The first way [2:43] is that we don't store any prompt [2:45] conversations, of course, as we [2:46] mentioned previously, which means that [2:48] any digital footprint incurred in your [2:50] side is is essentially reduced to zero. [2:54] So, when you use models like GLM 5.2 and [2:57] Kimmy 2.7, you can guarantee that none [3:00] of your conversations will be saved on [3:02] our side. It will be all stored locally. [3:05] We also have predefined tiers of [3:07] privacy. So private by default means [3:10] that the affforementioned uh measures [3:14] apply for providers like open AI and [3:19] claude. Uh we anonymize your user [3:22] footprint so that none of well they [3:25] can't identify you from your [3:29] simply from your prompt or your request. [3:32] We also have models hosted in trusted [3:35] execution environments, meaning that you [3:37] can verifiably prove that your inference [3:42] was run in a totally private process. [3:46] As well as that, we also use a privacy [3:49] first software architecture. So for [3:52] endpoints like video uh generation where [3:55] you have to pull the endpoints, we store [3:58] the results in a totally encrypted [4:00] payload using split key custody, meaning [4:04] that attackers can't access your data [4:07] and neither can the team should their [4:09] accounts be compromised. [4:12] So I just want to introduce you to the [4:14] guys the uh the idea that not all [4:16] systems are made equal. So, not all [4:20] systems are made private. Some companies [4:22] may claim their systems are private, but [4:25] they're not really. Uh, you guys know [4:27] how it goes. [4:29] So, while models are a very important [4:33] part of an aentic system, in fact, [4:36] they're a vital part of the system. Um, [4:38] they are still only one part. And in [4:41] fact to create a complete system to [4:45] accompany an LLM in doing a task you [4:48] have to build an entire process around [4:50] it. However, these systems are also much [4:53] more prone to data leakage and breaches. [4:56] So the real question is how can we [4:58] optimize for this kind of problem. [5:02] So one example I just wanted to bring up [5:04] was observability logging. So [5:06] observability as many of you know is a [5:09] core part of any serious production [5:12] system today. So just to break it down [5:14] quickly, observability can be broken [5:16] down into metrics, logs and traces. So [5:20] traces are simply a span of work uh done [5:23] over a unit of time. Metrics as are [5:26] simply numbers like counters, gauges for [5:29] instance and logs are the actual [5:31] messages. So logging, as we all know, is [5:34] actually pretty great for debugging, [5:36] especially in production or dem dev [5:39] environments. But you can also [5:41] accidentally store prompts and secrets [5:44] by default if you're not careful, which [5:47] can also hold personal information. [5:50] However, when you use Venice, you don't [5:52] need to worry about any of that. [5:56] So let's talk about how secrets can flow [5:58] through a regular agent. So for example, [6:01] let's say you're you're using open claw. [6:04] You send a user request that gets sent [6:06] to an agent runtime. The runtime might [6:09] need a secret that it will fetch from a [6:12] one password vault for instance or hashc [6:15] vault. The secret will then get sent to [6:19] the LLM reasoning layer. [6:24] Um, [6:26] oh my god. [6:31] So the reasoning layer will then make an [6:35] API request through a tool call which [6:38] will then return the answer back to the [6:40] user. [6:42] However, due to this the way that it's [6:45] architected, the secrets get fed [6:47] directly to the LLM, which means it then [6:49] may get used in training data. [6:52] So in terms of privacy preserving [6:55] patterns that work, one thing that we've [6:57] used at Venice is storing hashes that [7:00] rep represent ids that we need as [7:04] opposed to direct data. So for example, [7:07] if you need to identify a user for rate [7:09] limiting purposes, you might not want to [7:12] use their direct user footprint [7:14] directly. You might want to, you know, [7:16] store it as a hash for instance, just so [7:18] you can identify them without directly [7:21] using any of their personal data. [7:24] As well as that, we encrypt data and [7:27] store it in an inaccessible enclave [7:29] using split key custody. So for context, [7:33] encryption keys are stored in two [7:35] halves, a read half and a write half. By [7:38] splitting these, the attacker cannot [7:42] access the data due to needing both [7:45] halves for the decryption to complete. [7:49] Additionally, you can use design [7:51] patterns like handles that can be easily [7:53] revoked. So a handle is simply an object [7:57] that grants you access to something. So [8:00] for example, let's say you have a [8:02] database pool using a handle. So when [8:06] you have the handle, you can access the [8:08] database pool. When you don't, then you [8:11] can't access it. This is very important [8:14] especially when you're using [8:16] authorization like JSON web tokens or [8:20] session keys [8:22] that may be uh a core part of your [8:25] authorization system. As well as that, [8:27] of course, engineering your prompts with [8:29] privacy in mind can be uh very helpful [8:32] for engineering teams who are using [8:35] coding harnesses like cursor and clawed [8:38] code [8:40] in terms of protecting agent handle [8:42] data. So essentially ensuring narrow [8:45] agent scope to to decrease risk. So for [8:49] example, let's say you pull tools from [8:51] an NCP server that may have 15 20 [8:54] different tools. you don't really want [8:56] to use all of them. You actually only [8:57] really need one, but you also need an [9:00] API key to handle that uh API call. So [9:05] if you pull that API key in from you [9:09] know your your password vault and then [9:12] you send it as part of the agent um what [9:15] can happen is that it gets exfiltrated [9:18] through through the agent uh on a tool [9:21] hall to whatever you know web server is [9:24] being hosted by a bad actor for [9:25] instance. As well as that [9:29] um we also have a classification layer [9:33] in front of an agent to check for prompt [9:35] injection for example. [9:37] So there's a couple of ways you can do [9:39] this. So you can either use an LLM based [9:43] uh layer to do this or you can [9:46] alternatively [9:47] use a semantic [9:50] um search layer for example using vector [9:54] search uh via something like quadrant [9:57] lance db or additionally you can use an [10:01] in-memory process. [10:05] It should also be noted that tight [10:07] context loops caused by narrow agent [10:10] scope can also improve context window [10:13] performance. So for example, because you [10:16] don't have as many tools, uh your agents [10:19] may be able to perform much better. It's [10:22] well known that when you fill your [10:24] context window, by doing so, when you [10:27] reach near the limit of your context [10:30] window, performance can actually degrade [10:33] uh considerably. [10:35] By keeping an empty or near empty [10:38] context window, we can make sure that [10:41] the agent is performing at its best. [10:46] So let's look at keeping secrets out of [10:49] the model. So here we have a user [10:52] request that gets sent to the reasoning [10:55] layer. This reasoning layer is actually [10:58] then uh formulating a series of [11:01] non-deterministic inputs for an agentic [11:04] runtime. [11:06] So by tying the password vault to the [11:09] agentic runtime instead of the reasoning [11:11] layer, what happens then is that the run [11:14] the agent runtime is essentially turned [11:17] into an execution layer which then we [11:20] can you know we can consider it [11:22] deterministic. We can do all kinds of [11:25] things that you normally wouldn't be [11:28] able to do for privacy and security [11:30] reasons at the LLN layer. Uh so for [11:33] example, let's say you want to use a uh [11:36] browser user tool and you need to log [11:38] into a into a website that requires your [11:42] credentials. [11:45] With this uh software architecture, it's [11:48] much more reasonable to say that it's [11:51] private and secure rather than feeding [11:54] your password see uh directly into the [12:00] reasoning layer as well as you know [12:03] calling external APIs. [12:06] So in terms of sandboxing your agents um [12:08] it it's a very well-known fact that [12:11] using sandboxes and VMs for example [12:14] firecracker [12:15] um and you know AWS EC2 in a VPC can [12:20] significantly upgrade the security of [12:23] your agent. [12:26] However this doesn't act as a cure all [12:30] for your agentic systems. Uh so for [12:33] example, if you have internet access [12:35] enabled for your agent, it can still [12:38] accidentally exfiltrate data through [12:41] external API access if you're not [12:43] careful and therefore monitoring [12:45] permissions is essential. [12:49] So my personal suggestion is [12:54] building your own agentic runtime. So [12:57] essentially building your own coding [12:59] harnesses where you can add your own [13:01] steps, your own observability, [13:04] uh your own tools, things of that [13:06] nature. Essentially owning the execution [13:09] layer and reasoning layer. [13:13] So let's talk about privacy at the [13:14] hardware level very quickly. So in terms [13:17] of this um there's something I like to [13:19] call confidential compute where a [13:22] trusted execution environment [13:24] essentially uh at the hardware level [13:26] enables the inference process to be run [13:29] privately. So with Venice, how this [13:31] works is that when you send a request, [13:34] uh you get a response and then we [13:36] actually return an attestation that you [13:40] can then um verify with our atestation [13:44] verifier. [13:47] So in terms this what this actually [13:48] means is that you can fully isolate an [13:51] agent at the reasoning layer [13:53] cryptographically and prove it [13:56] in terms of oh confidential tool calls [14:00] there is still some work to be done um [14:02] tees are still great for tool calls [14:05] however we also offer end to end [14:07] encryption um but there's also you know [14:10] some work to be done there because of uh [14:13] the need to provide an ergonomic API I [14:17] experience while still allowing users to [14:20] return entirely encrypted tool calls. [14:23] This is still kind of an ongoing [14:24] challenge. Um in terms of this, a very [14:28] reliable solution would be to allow [14:30] providers to own the computes layer at [14:33] which your tool calls being run. [14:35] However, um [laughter] [14:40] sorry, just give me a sec. [14:51] So in terms of confidential tool calls [14:54] um yeah there's definitely some work to [14:56] be done. [15:02] Um yeah that's it. Thank you for [15:04] listening.