Nearly Tight Black-Box Auditing of Differentially Private Machine Learning

Meenatchi Sundaram Muthu Selva Annamalai, Emiliano De Cristofaro

Abstract

This paper presents an auditing procedure for the Differentially Private Stochastic Gradient Descent (DP-SGD) algorithm in the black-box threat model that is substantially tighter than prior work. The main intuition is to craft worst-case initial model parameters, as DP-SGD's privacy analysis is agnostic to the choice of the initial model parameters. For models trained on MNIST and CIFAR-10 at theoretical $\varepsilon=10.0$, our auditing procedure yields empirical estimates of $\varepsilon_{emp} = 7.21$ and $6.95$, respectively, on a 1,000-record sample and $\varepsilon_{emp}= 6.48$ and $4.96$ on the full datasets. By contrast, previous audits were only (relatively) tight in stronger white-box models, where the adversary can access the model's inner parameters and insert arbitrary gradients. Overall, our auditing procedure can offer valuable insight into how the privacy analysis of DP-SGD could be improved and detect bugs and DP violations in real-world implementations.

Introduction

Differential Privacy (DP) provides a mathematical framework to bound the privacy leakage of individual records in a dataset. DP-SGD is the standard algorithm for training machine learning models with these guarantees. However, real-world implementations are complex and prone to bugs. Auditing—empirically estimating privacy leakage ($\varepsilon_{emp}$) through membership inference attacks—is crucial for verifying these guarantees.

Historically, researchers faced a trade-off: white-box audits (where the attacker sees intermediate gradients) provide tight estimates but are unrealistic, while black-box audits (where only the final model is visible) are realistic but have been significantly "loose." This paper addresses this gap, demonstrating that black-box audits can be nearly tight by strategically selecting the starting point of training.

Methodology: Worst-Case Initialization

The core innovation of this work is the use of worst-case initial model parameters. Standard DP analysis is initialization-agnostic; it must hold for any starting point $\theta_0$. Prior black-box audits typically used random or "average-case" initializations, which often failed to highlight the influence of a single "canary" sample.

The proposed procedure involves pre-training a model on an auxiliary dataset to find a starting point $\theta_0$ where the gradients of "normal" samples are minimized. When a target record (canary) is inserted into the training set, its gradient becomes significantly more detectable against the near-zero background gradients of the other samples.

Figure 3: Relationship between average gradient norm of normal data and empirical epsilon as a function of pre-training epochs.

As shown in Figure 3, increasing the number of pre-training epochs reduces the average gradient norm of the background data, which directly correlates with an increase in the empirical privacy leakage ($\varepsilon_{emp}$) detected by the audit.

Experimental Results

The authors evaluated their method on MNIST and CIFAR-10. By using worst-case initialization, they achieved a roughly 3x improvement over previous state-of-the-art black-box audits.

Figure 2: Comparison of empirical epsilon for average-case vs. worst-case initialization across MNIST and CIFAR-10.

As illustrated in Figure 2, the worst-case initialization (blue bars) consistently yields higher $\varepsilon_{emp}$ values than average-case initialization (orange bars), significantly narrowing the gap to the theoretical upper bound (red dashed lines). For a theoretical $\varepsilon = 10.0$, the audit reached $\varepsilon_{emp} = 7.21$ for MNIST and $6.95$ for CIFAR-10 on 1,000-record samples.

Sensitivity to Hyperparameters

  • Dataset Size: Audits are generally tighter on smaller datasets. In larger datasets, the cumulative noise added over many steps tends to mask the canary's signal.
  • Clipping Norm ($C$): The audit is most effective when the gradient clipping norm is small. High clipping norms lead to higher noise levels that can overwhelm the audit signal.
  • Fine-Tuning: In the "fine-tune the last layer" regime, the audit is even more effective, reaching $\varepsilon_{emp} = 9.33$ for a theoretical $\varepsilon = 10.0$, demonstrating that black-box audits can be nearly perfectly tight in certain practical scenarios.

Conclusion

This work demonstrates that the perceived "looseness" of black-box DP auditing was largely due to sub-optimal initialization rather than inherent limitations of the threat model. By crafting worst-case starting parameters, auditors can provide much stronger evidence of privacy leakage or implementation correctness. Future work includes reducing the high computational cost of these audits and extending the methodology to more complex scenarios like DP-SGD with Poisson sub-sampling.

Summary updated

BibTeX
@inproceedings{annamalai2024nearly,
  author = {Meenatchi Sundaram Muthu Selva Annamalai and Emiliano De Cristofaro},
  title = {{Nearly Tight Black-Box Auditing of Differentially Private Machine Learning}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=cCDMXXiamP},
}
Figure