Menu
Cloudflare Blog·July 27, 2026

Debugging Oblivious HTTP: Cloudflare's pvcli for Privacy-Preserving Protocols

Cloudflare open-sourced pvcli, a command-line interface tool designed to simplify debugging privacy-preserving protocols like Oblivious HTTP (OHTTP). The article highlights the architectural complexity of OHTTP, which involves multiple parties and binary encodings, making manual debugging prone to errors and time-consuming. pvcli streamlines this process by abstracting away the low-level details and providing clear, step-by-step visibility into the protocol flow.

Read original on Cloudflare Blog

The Challenge of Debugging Privacy Protocols

Debugging complex privacy-preserving protocols such as Oblivious HTTP (OHTTP) presents significant architectural and operational challenges. OHTTP involves multiple distinct parties (client, relay, gateway, origin) and intricate binary encoding schemes, leading to a distributed system where each step is a potential point of failure. Cloudflare's experience operating these protocols at scale revealed a critical need for better tooling to diagnose issues efficiently, especially when coordinating with external customer systems.

Oblivious HTTP (OHTTP) Architecture

ℹ️

What is Oblivious HTTP?

OHTTP provides a strong privacy guarantee: no single entity can know both who initiated a request and what content was requested. It achieves this by routing encrypted requests through two non-colluding servers: a relay (often operated by the client's provider) and a gateway (operated by the service provider).

  1. Client obtains a public key from the gateway.
  2. Client encrypts the request and sends it to the relay.
  3. Relay forwards the encrypted request to the gateway, anonymizing the client's identity.
  4. Gateway decrypts the request and sends it to the target origin.
  5. Target processes the request and sends an encrypted response to the gateway.
  6. Gateway encrypts the response and sends it back to the relay.
  7. Relay forwards the encrypted response to the client.
  8. Client decrypts the response to get the plaintext.

This multi-hop, encrypted flow introduces complexities for system designers and operators. Debugging without specialized tools requires manually parsing binary HTTP, meticulously crafting encrypted requests, and coordinating logs across disparate systems, making incident response slow and error-prone.

How pvcli Simplifies Debugging

Cloudflare's open-source `pvcli` tool streamlines the debugging process by encapsulating the complexities of OHTTP. It handles public key retrieval, binary HTTP encoding, request encryption, and multi-hop routing automatically. This abstraction significantly reduces the operational overhead and potential for human error previously associated with validating OHTTP deployments or pinpointing failure points.

bash
pvcli --ohttp \  --first-hop https://relay.ohttp.info \  --proxy https://ohttp.info \  https://target.ohttp.info/request-echo/content

`pvcli` provides detailed logs, allowing engineers to inspect each stage of the protocol without needing to understand the underlying binary formats or refer to RFCs constantly. This improves developer velocity and incident response times for services leveraging OHTTP and other privacy-preserving protocols. The tool is designed to be extensible, supporting future protocols beyond OHTTP, CONNECT proxying, and MASQUE.

Oblivious HTTPOHTTPPrivacy ProtocolsDebugging ToolsCloudflareDistributed TracingAPI ProxiesSecurity Protocols

Comments

Loading comments...