Logit Leakage through Floating-Point Bias Addition
Shaomin Chen, Xiaorui Gong
Abstract
Language model APIs can expose token-specific biases while withholding logits and token probabilities. Existing bias-based extraction recovers relative logits, leaving a common additive component undetermined in ideal arithmetic. We identify a numerical side channel in floating-point bias addition that exposes information about this component through token identities alone. The channel distinguishes score vectors with identical complete unperturbed log probabilities. Our method exploits changes in representable spacing at binary exponent boundaries. Under the stated binary32 arithmetic assumptions and a known reachable score interval, it recovers a logit pair and its unknown tie-breaking priority exactly in at most 52 token queries. Given complete relative logits, one recovered anchor determines the original logit vector. We evaluate recovery across 11 public checkpoints from seven model families and extend the local method with adaptive interval search and anchor selection. In end-to-end experiments with vLLM, SGLang, and llama.cpp, adaptive recovery succeeds on all 128 Qwen3-0.6B inputs per system, including 64 held-out inputs. A separate token-only experiment extracts a pretrained small model's complete output-head representation up to an invertible hidden-basis transformation. We also establish a sufficient condition for suppressing common-shift disclosure by subtracting the maximum before bias addition. In controlled experiments, this mitigation eliminates all observed distinctions between common-shift variants and preserves token decisions under the tested random biases.
Create a lesson
Related papers
CWE-bench: Refocusing Agentic Security from Exploitation to Defense
Gonzalo Gonzalez-Pumariega, Ajay Jagannath, Adit Jain et al.
Security and robustness analysis of encrypted communications for local home automation: ESPHome Native API and MQTT over TLS 1.3
Carlos Roberto Gonzalez-Escarpeta, Juan Eduardo Garcia Sanchez, José Antonio Hernandez Reyes et al.
Toward Realistic Privacy Risk in FL-Enabled OT Intrusion Detection Systems
Assunta Imperatrice, Luigi ROmano
Beyond User-Side Defenses: Image Protection in Open-Weight Diffusion Models
Jihye Kang, Jiwon Park, Namhyuk Ahn
StableJudge: A Lightweight Adversarial Defense Framework for LLM-as-a-Judge
Anning Hu, Yangyu Li, Yuqi Huang et al.
PrivacyGuard: Source-Linked Sanitization and Locally Resolvable PII References for Cloud GUI Agents
Zian Yuan, Wei Li