Abstract
Recent breakthroughs in AI cryptanalysis suggested that extracting the internal weights of a "black-box" neural network is possible in polynomial time using only final classification labels. This paper identifies a critical scalability flaw in these claims: as networks grow deeper, certain neurons become "persistent" (always active), causing the query complexity of existing attacks to explode exponentially. To address this, we introduce CrossLayer Extraction, a technique that recovers hidden parameters by analyzing how neurons interact across different layers. Our approach successfully extracts weights from deep models where previous methods fail, demonstrating that while the "depth trap" is a significant hurdle, cross-layer information leakage remains a potent threat.
Introduction
Model extraction is the process of stealing the secret weights and biases of a trained model by observing its input-output behavior. While early attacks relied on "logits" (raw numerical scores), recent research (e.g., Carlini et al., 2025) claimed that even "hard-label" settings—where only the final class is visible—could be cracked efficiently.
However, these attacks rely on finding "intersection points" where a neuron's ReLU activation switches state. We show that in deep networks, many neurons are persistent (always "on") or dead (always "off"). If a neuron never switches state within a realistic input range, its boundary cannot be found using traditional search methods. For a 20-layer network, the probability of a neuron switching can be lower than $10^{-9}$, making "polynomial" attacks practically impossible.
The Challenge of Persistent Neurons
The "Depth Trap" refers to the exponential decrease in the probability of a neuron switching states as it resides deeper in the network. "Dead" neurons are irrelevant as they don't influence the output. "Persistent" neurons, however, act as constant linear transformations. If an attacker fails to recover even one persistent neuron in an early layer, the resulting error propagates and scales at $O(d^{-1/2})$ relative to the model width (Theorem 1), making it impossible to extract subsequent layers.
CrossLayer Extraction
To overcome the persistence problem, we propose CrossLayer Extraction. Instead of trying to force a persistent neuron in layer $\ell$ to switch states, we analyze the activation boundaries of neurons in the next layer ($\ell+1$).
The key insight is that a neuron's weights are embedded in the shape of the boundaries of every neuron that follows it. By observing how the decision boundaries of deeper neurons "bend" or "break" when projected back to the input space, we can mathematically reconstruct the weights of the persistent neurons in preceding layers.
Geometric Consistency and Results
We implement a modified consistency check (Algorithm 3) that utilizes multiple intersection spaces simultaneously. This allows the attacker to identify which boundaries belong to the same neuron, even when those boundaries are viewed through the "lens" of a deeper layer.
We validated our findings using 20-layer Multilayer Perceptrons (MLPs) trained on MNIST and Fashion-MNIST (FMNIST). Our Unified Consistent Algorithm reached ~100% accuracy in identifying consistent boundaries using only 4 to 5 intersection point samples. We successfully recovered the "span" of weights for multiple persistent neurons, maintaining a low $L^2$ distance between true and estimated signatures.
Limitations and Conclusion
While CrossLayer Extraction significantly advances the state of hard-label attacks, practical limitations remain. Numerical precision errors (machine epsilon) accumulate in deep networks, potentially limiting the maximum extractable depth. Furthermore, the extracted model is "functionally equivalent"—it mimics the original as long as persistent neurons remain persistent. Future work will explore scaling these techniques to Transformers and Residual Networks.
Summary updated