Skip to content

Reveal and understand hidden dependencies in the LLM API resale ecosystem through a prefix-cache side channelUncovering and Understanding Hidden Dependencies in the LLM API Reseller Ecosystem via Prefix-Cache Side Channels

arXiv· arXiv:2608.20732· Zimo Ji, Xin Wei, Congying Xu, Wenyuan Jiang, Xin Yang, Zongjie Li, Yudong Gao, Shuai WangHong Kong University of Science and Technology; ETH Zürich; Zhejiang UniversityIndexed by this site · 12 days ago· Originally publishedSelected AttacksSelectedAttention39

Quick read

Analysis and theory

Based on the paper PDF (AI-generated); refer to the original

The authors propose CACHE TRACER, using prefix-cache reuse as a side channel to measure hidden dependencies among LLM API resellers; 37.1% of 636 pairs across 39 endpoints share cache reach.

Questions
Multi-level resale of LLM APIs forms an opaque supply chain: requests may pass through undisclosed upstream resellers, and each link can view or modify prompts and responses; existing audits look only at a single reseller and cannot see hidden dependencies across resellers.
Methods
The authors propose CACHE TRACER: treating prefix-cache reuse as a side channel, using FLOOD to fill the cache of a new prefix through one endpoint, then using PROVE to probe with a prefix ladder whether another endpoint can reuse it; after bidirectional measurement, classify and assemble into a global cache-reach structure, requiring only ordinary paid APIs.
Experiments and results
Measurements on 39 real reseller endpoints, 636 pairs and about 1.1×10^6 requests show: 37.1% of endpoint pairs share cache reach, containment levels reach 7, and one node's cache reach is contained by at least 31 other nodes; the structure is model-dependent (in a gpt-5.1 retest only 2/22 preserved containment); in a controlled evaluation, 8/8 topologies were exactly recovered.
Limitations and future work
The authors state that the results are a one-sided under-approximation: unreported relationships are unknown rather than nonexistent; cache-reach containment does not imply a commercial supply relationship, and the number of levels does not equal the number of commercial hops; latent witnesses are not identifiable; the measurement covers only 39 endpoints and two models, and endpoint identities are concealed.
Experimental setupgpt-5-nano-2025-08-07、gpt-5.1 · 39 个真实转售端点(FOFA 扫描、社区中转目录、TokenAPI Scan 三个来源筛选)、8 个受控拓扑 T1–T8(自有凭证搭建) · shared cache reach 占比、cache-reach containment 层级数 et al.
Threat model
The measurer is an ordinary paid user who holds only low-privilege credentials for each candidate endpoint and sends chat-completion requests, observing response bodies, usage metadata, errors and end-to-end latency; they do not control the network, reseller software, provider scheduling, model weights or other tenants, nor can they see other customers' data.
Evaluated models
gpt-5-nano-2025-08-07gpt-5.1
Benchmarks
39 个真实转售端点(FOFA 扫描、社区中转目录、TokenAPI Scan 三个来源筛选)8 个受控拓扑 T1–T8(自有凭证搭建)
Metrics
shared cache reach 占比cache-reach containment 层级数coverage c(vx, vy)false-hit rate预测与实测命中概率的中位绝对偏差
AI summaryand selection rationaleResearchers from HKUST and other institutions propose CacheTracer, which treats prefix-cache reuse as a side channel and measures hidden dependencies among LLM API resellers using only ordinary API access. The researchers sent about 1.1 million requests across 636 endpoint pairs of 39 real reseller endpoints (over 7.2 hours, with model gpt-5-nano-2025-08-07), finding that 37.1% (236/636) of endpoint pairs have a shared cache reach, containment spans seven levels, and one node's cache reach is contained by at least 31 other nodes. In a retest on gpt-5.1, only 2 of the 22 endpoint pairs with decisive results reproduced the original containment relationship, indicating that the structure depends on the specific model. Validation showed only 3 false positives among 5,059 cold-prompt observations, and in controlled experiments all 8 configuration topologies were exactly recovered. The paper notes that a confidentiality or integrity failure on a shared upstream path may affect users of multiple downstream resellers, but cache-reach containment is only indirect evidence of supply-chain exposure and is not equivalent to a confirmed provider relationship.

Researchers from HKUST and other institutions propose CacheTracer, which treats prefix-cache reuse as a side channel and measures hidden dependencies among LLM API resellers using only ordinary API access. The researchers sent about 1.1 million requests across 636 endpoint pairs of 39 real reseller endpoints (over 7.2 hours, with model gpt-5-nano-2025-08-07), finding that 37.1% (236/636) of endpoint pairs have a shared cache reach, containment spans seven levels, and one node's cache reach is contained by at least 31 other nodes. In a retest on gpt-5.1, only 2 of the 22 endpoint pairs with decisive results reproduced the original containment relationship, indicating that the structure depends on the specific model. Validation showed only 3 false positives among 5,059 cold-prompt observations, and in controlled experiments all 8 configuration topologies were exactly recovered. The paper notes that a confidentiality or integrity failure on a shared upstream path may affect users of multiple downstream resellers, but cache-reach containment is only indirect evidence of supply-chain exposure and is not equivalent to a confirmed provider relationship.

Why it was selectedReal-world measurements of 39 resale endpoints show that 37.1% of endpoint pairs share cache reach; a confidentiality or integrity failure on a shared upstream path could affect users of multiple downstream resellers.

Paper analysis

6 questions; open one to read the full answer

  1. What problem does this paper attempt to solve?

    Multi-level resale makes the LLM API supply chain opaque; the authors use a prefix-cache side channel to measure externally observable hidden dependencies among resellers.

    Core problem: multi-level resale of LLM APIs forms an opaque supply chain; user requests may pass through undisclosed upstream resellers, and existing audits cannot see hidden dependencies across resellers.

    • Scenario and importance: resellers occupy a privileged position on the request path, can receive user prompts and model responses in plaintext, and can modify them before forwarding; the authors state that multi-level resale extends a user's trust boundary beyond the reseller they directly chose.
    • Gaps in existing work: prior studies audit the behavior of individual resellers (code injection, model substitution, price violations, etc.), but the authors argue they lack visibility into hidden dependencies across resellers; ordinary users can only observe black-box API behavior, and resellers' internal routing is not public.
    • Core observation: serving systems cache the KV state of prompt prefixes and reuse it for subsequent requests with the same prefix; if a new prefix cached only through endpoint A can later be reused through endpoint B, the two endpoints can reach a common cache domain; multi-level resale also makes this signal directional (P(vu) ⊆ P(vd)).
    • What the paper proposes: CACHE TRACER—the authors describe it as the first API-only measurement of such hidden dependencies, using the two primitives FLOOD and PROVE to measure cache-reach relationships, with real-world measurements on 39 endpoints. The authors state explicitly: hidden dependencies refer to cache-reach relationships, not verified supply edges.
    • Threat model:
      • The measurer is an ordinary paying customer holding low-privilege credentials for each candidate endpoint, sending chat-completion requests.
      • It can observe only response bodies, usage metadata, errors, and end-to-end latency.
      • It does not control the network, reseller software, provider scheduling, model weights, or other tenants, and cannot see other customers' data.
      • The victims are users and agents using resale endpoints; the risk comes from intermediaries on the path that can read and write prompts and responses.
  2. What related research exists?

    Related work falls into four groups: cloud co-tenancy detection, LLM supply chain measurement, prefix-cache and inference-side channels, and network tomography.

    Cloud co-residency detection

    • Ristenpart et al. (2009), Zhang et al. (2012), Inci et al. (2015), Varadarajan et al. (2015)—use cloud side channels to infer co-residency, extract keys, and study multi-tenant placement vulnerabilities. The authors state that this paper moves this type of structure from hardware resources and the hypervisor to the prefix cache and commercial intermediaries.
    • Kashaf et al. (2020)—analyzes third-party dependencies of modern web services; the authors state that it inspired this paper's framing of the concentration problem.

    LLM supply chain measurement

    • Liu et al. (2026)—measures malicious man-in-the-middle attacks on the LLM supply chain: measurement of 428 third-party routes found 9 injecting malicious code into agent responses, 17 using researcher-controlled AWS canary credentials, and 1 stealing ETH with a researcher-controlled private key.
    • Cai et al. (2025), Zhang et al. (2026), Lin et al. (2026)—audit model substitution, false model claims by shadow APIs, and the behavioral consistency and transparency of API gateways, respectively.
    • FrugalGPT (2023), RouteLLM (2024)—perform efficient routing selection across multiple backends; Xu et al. (2024)—cooperatively identify models using instruction fingerprints. The authors state that unlike these works, this paper infers hidden dependencies between endpoints.

    Prefix cache and inference side channels

    • Gu et al. (2025)—audits prompt caching in language model APIs, supporting providers' claims of per-tenant cache isolation.
    • InputSnatch (2024), Song et al. (2025), Luo et al. (2026), Pang et al. (2024)—steal inputs via timing side channels, leak information, analyze KV-cache privacy risks, and mitigate timing side channels with cache partitioning. The authors state that this paper repurposes real cache reuse as a relational infrastructure signal rather than content leakage.
    • Dutta et al. (2023), Carlini et al. (2024), Tramèr et al. (2016), and others—broader side channels reveal architecture, identity, or activity.

    Network tomography

    • Vardi (1996), Castro et al. (2004), and others—infer hidden topologies from end-to-end observations. The authors state that this paper substitutes implanted prefix state for packet-path correlation but retains its identifiability limits: without additional assumptions or observation points, external traces can determine only an equivalence class (Remark III-E, Appendix E).

    Positioning: the authors state that this paper differs from the above work in that it does not audit the behavior of individual resellers, but formalizes dependency visibility as an API-only measurement problem, measuring cache-reach relationships observable across endpoints while distinguishing observable relationships from unverified supply edges.

  3. How does the paper address this problem?

    CACHE TRACER uses FLOOD to fill one endpoint's cache, PROVE to probe another endpoint with a prefix ladder, and after bidirectional classification prunes and assembles the global structure.

    Overall idea: turn prefix-cache reuse into an externally observable directional signal. CACHE TRACER consists of five primitives (PROFILE, FLOOD, PROVE, CLASSIFY, BUILD GRAPH) and requires only an ordinary paid API key, with no reseller cooperation or internal access (Figure 3).

    Problem setting and assumptions

    • Measurement target: under a fixed model, the cache reach of endpoint v is the set P(v) of cache domains reachable by its requests; overlapping cache reach between two endpoints is shared cache reach; A's cache reach being contained in B's is cache-reach containment.
    • Two assumptions: Assumption 1 (cache telemetry integrity)—the reported cached_tokens reflects real reuse; Assumption 2 (routing consistency)—successful requests within the measurement window are independent samples from a fixed routing distribution πv, and changing the prompt prefix does not systematically change that distribution.
    • Resolution: at δ = 0.05, c(vx, vy) ≥ 1 − δ is recorded as vy ⪯ vx; the authors state that 0.05 was chosen because in preliminary experiments at δ = 0.01, production effects (requests being spread across more cache domains, cache expiration) frequently caused transient misses, making it difficult to reliably distinguish 99% coverage from full containment.

    PROFILE and FLOOD

    • PROFILE: sends one short streaming request to each endpoint and records TTFT; after sorting by TTFT, candidate pairs are constructed with increasing step size so that possibly similar relationships are tested first, facilitating later pruning; TTFT serves only as a coarse proxy for path length.
    • FLOOD (Algorithm 1): repeatedly sends the same new prompt to endpoint A until Nflood = 59 consecutive hits (solved from (1−δ)n ≤ α, δ = α = 0.05), supporting less than 5% uncovered routing mass; aborts after 1000 attempts or 8 consecutive transport errors; then starts w = 2 low-rate keep-warm workers to prevent cache expiration.

    PROVE: directional test

    • Prefix ladder: PROVE probes B with nested prefixes P[1] ⊂ … ⊂ P[Lprobe] to avoid self-hits—a miss seeds the cache itself, so after a miss it advances to a longer unqueried prefix, and a hit requires cached_tokens to exceed the previous prefix length; the prefix step is larger than the provider's cache-chunk length bB.
    • Thresholds: among Nprove = 181 successful probes, miss ≤ Mcontain = 4 is judged CONTAINED; all misses in the first Mnohit = 59 is judged NO OBSERVED; after a hit, Mpartial = 15 cumulative misses is judged PARTIAL; the rest (ladder exhausted, Eabort = 8 consecutive errors) is judged INCONCLUSIVE. Lprobe = 59.

    CLASSIFY and BUILD GRAPH

    • CLASSIFY (Algorithm 3): performs one FLOOD–PROVE in each direction. Double CONTAINED is judged equivalent (CLONE); single CONTAINED is judged strict containment; PARTIAL on either side with no containment is judged non-directional sharing; double NO OBSERVED is judged no sharing; INCONCLUSIVE on either side leaves the pair undecided.
    • BUILD GRAPH (Algorithm 4): processes candidate pairs in PROFILE order, skipping pairs already implied by paths in the existing containment graph (implication pruning); for PARTIAL pairs not explained by observed endpoints, SHADOW INSERT enumerates maximal cliques on an auxiliary graph and introduces one latent witness per clique (an explanatory placeholder only, not an identified company; Appendix E argues it is not identifiable).
    • Output properties: the authors state that the result is a one-sided under-approximation—every reported relationship is supported by positive cache evidence, and unreported relationships are unknown rather than nonexistent; containment and supply relationships satisfy supply ⇒ containment, but not the converse.
  4. What experiments did the paper conduct?

    636 measured pairs across 39 real endpoints: 37.1% share cache reach, 7-layer containment, model-dependent structure; assumption checks and 8 controlled topologies all support the method.

    Experimental setup

    • Subjects: 39 real resale endpoints, drawn from FOFA scans of New API deployments, community relay directories, and TokenAPI Scan's analysis of relay domains embedded in Claude Code; after deduplication, registration, top-up verification, and screening for availability of the cached_tokens field, 39 were retained (listed in masked form in Appendix B).
    • Models tested: gpt-5-nano-2025-08-07 (main measurement); gpt-5.1 (cross-model retest). The low-cost model was chosen to reduce the risk that different endpoints serve different underlying models and to reduce measurement cost (the authors' stated rationale).
    • Prompt construction: fixed text plus a nonce; the main measurement uses a 16,384-token prompt body, with a prefix ladder starting at 1,536 tokens and a step of 256 tokens (exceeding the measured 1,024-token cache admission threshold and 64-token cache-chunk length).
    • Scale: 39 endpoints yield 741 unordered candidate pairs; 636 pairs were measured and 105 pruned (14.2%), totaling approximately 1.1×10^6 requests over 7.2 hours, averaging about 1,730 requests per pair.
    • Controlled evaluation: 8 topologies T1–T8 built with the authors' own credentials, cache-chunk 32 tokens, prompt 3,481 tokens, step 32 tokens, keep-warm concurrency 4; T8 uses 12 isolated domains, with a minimum terminal routing probability of 3/35 ≈ 8.57%.
    • Decision method: HIT/MISS determined by a cached_tokens threshold; statistical thresholds δ = α = 0.05; no LLM judging.

    Main results

    According to Table I (636 measured endpoint pairs, model gpt-5-nano-2025-08-07):

    Measurement resultPairsShare
    Shared cache reach23637.1%
    of which: non-directional (PARTIAL)168—
    of which: directional containment62—
    of which: equivalent reach (CLONE)6—
    No relationship observed at 5% resolution25339.8%
    Inconclusive14723.1%
    • The authors report that 236/636 (37.1%) of endpoint pairs produced at least one genuine cross-endpoint hit, direct evidence that the two endpoints can reach a common cache domain (Finding 1).
    • The 6 CLONE decisions merge 9 endpoints into 4 equivalence classes, leaving 34 nodes; the 62 endpoint-level containment relations collapse to 58 relations; the graph is acyclic and spans 7 layers, the longest chain contains 6 containment relations, and the transitive closure contains 115 ordered node pairs (Fig. 6). The authors state that if each strict containment corresponds to one resale, the longest chain is consistent with up to 6 resale steps, but they do not measure commercial hops (Finding 2).
    • E2's cache reach is directly contained in 24 of the other 33 nodes, and 31 when indirect paths are included; Table II gives directional evidence: among 26 direct containment relations, flooding the counterpart and probing E2 satisfied containment in all cases (24 pairs at 178/3, 2 pairs at 177/4), while flooding E2 and probing the counterpart gave 0/59 in all 26 pairs. The authors state that this pattern is consistent with both the narrow-supplier and co-tenant explanations (Finding 3).

    Cross-model retest (RQ1 model dependence)

    • Of the 44 pairs with containment on gpt-5-nano-2025-08-07, after recalibration and retesting on gpt-5.1: 22 pairs yielded decisive judgments, of which only 2 reproduced containment, 12 still shared but did not satisfy containment, and 8 showed no sharing at 5% resolution; the remaining 22 pairs were inconclusive (Appendix D Fig. 9 shows the two reproduced relationships).
    • The authors state that the cache-containment topology is model-dependent and should be indexed by model rather than treated as a model-agnostic graph (Finding 5); they cite industry reports for a possible explanation: different models are procured through different channels, and upstream pools are assembled independently.

    Assumption checks (RQ2)

    • Telemetry integrity: 5,997 cold-prompt requests were sent to the 39 endpoints, yielding 5,059 usable observations, with insufficient telemetry at 3 endpoints; 3 false hits were observed, a rate of 5.9×10−4 (95% CI: [1.2×10−4, 1.7×10−3]); after 1,660 additional observations, the false-hit rates at two endpoints were 1/603 and 2/1270, and the PARTIAL judgments for these two endpoints were excluded from the aggregate results (Finding 6).
    • Routing stability: for the 21 recovered A ≺ B ≺ C chains, the three hit probabilities were measured independently and the multiplicative relationship tested; the median absolute deviation between predicted and measured was 0.084, with 14/21 chains within 0.10; after random shuffling the median deviation rose to 0.449 (Fig. 7). The authors state that this provides empirical support for stable routing and prefix-invariant selection, but the 7 larger deviations show that the assumption is an approximation rather than an invariant (Finding 7).

    Controlled evaluation (RQ3)

    • All 8 topologies with known ground truth were recovered exactly (8/8): T1–T4 distinguish all four pairwise relationship classes; T5 recovers two adjacent containments and correctly prunes the transitive pair; T6 recovers fan-in; T7 distinguishes a hidden shared upstream from a common downstream; T8 recovers all 6 direct containments and two latent explanations (S1 → {B, C, D}, S2 → {C, G}) and prunes 8 long-range pairs (Fig. 8, Appendix C Table IV).
    • The authors state that in this evaluation each configuration's supply edges were deliberately aligned with a strict containment, so exactly recovering the containment topology also recovers the configuration's supply graph (Finding 8).

    Other ablations and analyses

    • Measurement cost: approximately 1.1×10^6 requests / 7.2 hours, averaging about 42 requests/s, about 1 request/s per endpoint; 105/741 pairs (14.2%) avoided direct measurement via implication pruning.
    • Appendix A: without pruning, the foreground request complexity is O(N + C(N,2)(Bf + Nprove)), with Bf = 1000; in the chain case it can be reduced to O(N(Bf + Nprove)).
    • Negative results: in the cross-model retest, 22 pairs were inconclusive and 8 lost sharing; in RQ2, 7 chains deviated substantially, which the authors attribute to temporary routing changes, quotas, or alternative paths.
  5. What are some points that can be further explored?

    The authors discuss boundaries such as under-approximation, topology not equaling the supply chain, and latent witnesses being unidentifiable, and propose an end-to-end context protocol as a future direction.

    Limitations and future directions noted by the authors

    • One-sided under-approximation (§V): the recovered structure is an under-approximation—unreported relationships are unknown rather than nonexistent; true containment may remain unobservable because it falls below the resolution δ, because of routing changes within the measurement window, or for other reasons.
    • Topology is not the supply chain (§V, §III-E): containment chains are consistent with multi-level resale, but their length should not be interpreted as the number of commercial intermediaries a request passes through; a highly contained cache reach does not identify the operators, contracts, or specific forwarding paths that cause the concentration.
    • Latent witnesses are not identifiable (Appendix E): observed traces cannot determine the number of hidden forwarding nodes or their internal connections, nor whether two latent witnesses correspond to the same underlying system; their number and labels should not be interpreted as the number or identity of hidden commercial entities.
    • The assumptions are approximations (§IV-C2): the larger deviations on 7 chains show that temporary routing changes, quotas, or alternative paths can make relationships unobservable or make measured probabilities inconsistent.
    • Future direction: an end-to-end context protocol (§V): the authors propose the idea of making resellers pure forwarders—establishing an authenticated encrypted session similar to SSH/TLS between the client and the final serving backend, with signatures binding the request identifier, model, response, and tool-call parameters; the authors state that implementation requires provider cooperation and support for dynamic routing, streaming, caching, and billing, and leave its design and deployment to future work.
    • Scope of the measurement conclusions (§IV-A2): the authors state that the findings apply only to the 39-endpoint niche that was screened.

    Experimental coverage

    • The real-world measurement covers 39 resale endpoints, 636 measured pairs (105 of 741 candidate pairs pruned), approximately 1.1×10^6 requests, and 7.2 hours (§IV-B).
    • The models tested are gpt-5-nano-2025-08-07 (main measurement) and gpt-5.1 (retested only on the 44 pairs with containment), 2 in total (§IV-B1, §IV-B5).
    • The controlled evaluation covers 8 self-built topologies T1–T8, with the deepest endpoint reaching 10 domains and a minimum terminal routing probability of 8.57% (§IV-D).
    • Endpoint identities are withheld per the paper's stated policy; Appendix B lists nodes only as masked domains (Ethics, Appendix B).
    • The paper does not report the operator or geographic distribution of each endpoint, nor measurements of models other than gpt-5-nano-2025-08-07 and gpt-5.1.
  6. Summarize the main content of the paper

    CACHE TRACER measures 39 resale endpoints via a prefix-cache side channel; the authors report that 37.1% of endpoint pairs share cache reach, with a 7-layer model-dependent containment structure.

    A measurement paper on the LLM API resale ecosystem: the authors formalize the hidden dependencies caused by multi-level resale as an API-only measurement problem, and use prefix-cache reuse as a side channel to give a measurement method and empirical results.

    • Problem: resellers can view and modify prompts and responses in plaintext, and multi-level resale pushes the trust boundary beyond the reseller the user directly chooses; existing audits look only at a single reseller and cannot see cross-reseller dependencies.
    • Method: CACHE TRACER uses FLOOD to fill the cache reach of a new prefix through endpoint A (stopping at 59 consecutive hits), and PROVE probes endpoint B's reuse with a prefix ladder and rules out self-hits (181 probes, miss thresholds 4/15/59); after bidirectional CLASSIFY, BUILD GRAPH prunes and assembles the global structure; it requires only ordinary paid APIs, and the output is a one-sided under-approximation.
    • Measurements: 39 endpoints, 636 pairs, about 1.1×10^6 requests: 236/636 (37.1%) share cache reach; after contraction to 34 nodes, containment spans 7 levels with a longest chain of 6 hops; E2's cache reach is contained by at least 31/33 other nodes (Table I, Fig. 6, Table II).
    • Model dependence: in a gpt-5.1 retest, 22 of 44 pairs were decisive, and only 2 pairs reproduced containment; the authors state the topology should be indexed by model.
    • Validity: across 5,059 cold-prompt observations there were only 3 false hits (rate 5.9×10−4); among 21 three-node chains, 14 had hit probabilities within 0.10 of the multiplicative prediction; in a controlled environment, 8/8 topologies were exactly recovered.
    • Authors' conclusion: seemingly independent resellers may depend on a common hidden upstream, and a confidentiality or integrity failure at one upstream may affect multiple downstream endpoints, forming correlated exposure across resellers; the authors also emphasize that cache-reach relationships are not verified supply edges, and propose an end-to-end context protocol as a future mitigation direction.
Read originalarxiv.org