StolenEncoder: Stealing Pre-trained Encoders in Self-supervised Learning
Yupei Liu, Jinyuan Jia, Hongbin Liu, Neil Zhenqiang Gong
Abstract
Pre-trained encoders are general-purpose feature extractors that can be used for many downstream tasks. Recent progress in selfsupervised learning can pre-train highly effective encoders using a large volume of unlabeled data, leading to the emerging encoder as a service (EaaS). A pre-trained encoder may be deemed confidential because its training requires lots of data and computation resources as well as its public release may facilitate misuse of AI, e.g., for deepfakes generation. In this paper, we propose the first attack called StolenEncoder to steal pre-trained image encoders. We evaluate StolenEncoder on multiple target encoders pre-trained by ourselves and three real-world target encoders including the ImageNet encoder pre-trained by Google, CLIP encoder pre-trained by OpenAI, and Clarifai's General Embedding encoder deployed as a paid EaaS. Our results show that our stolen encoders have similar functionality with the target encoders. In particular, the downstream classifiers built upon a target encoder and a stolen one have similar accuracy. Moreover, stealing a target encoder using StolenEncoder requires much less data and computation resources than pre-training it from scratch. We also explore three defenses that perturb feature vectors produced by a target encoder. Our results show these defenses are not enough to mitigate StolenEncoder. CCS CONCEPTS • Security and privacy; • Computing methodologies → Machine learning;
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 63b87b6f-d35b-45a8-8305-278fe7356408Cited by top-tier papers19
- Are You Copying My Model? Protecting the Copyright of Large Language Models for EaaS via Backdoor WatermarkWenjun Peng, Jingwei Yi, Fangzhao Wu, Shangxi Wu et al.ACL 2023 · 39 citations
- MEA-Defender: A Robust Watermark against Model Extraction AttackPeizhuo Lv, Hualong Ma, Kai Chen, Jiachen Zhou et al.S&P 2024 · 22 citations
- "Get in Researchers; We're Measuring Reproducibility": A Reproducibility Study of Machine Learning Papers in Tier 1 Security ConferencesDaniel Olszewski, Allison Lu, Carson Stillman, Kevin Warren et al.CCS 2023 · 19 citations
- Bucks for Buckets (B4B): Active Defenses Against Stealing EncodersJan Dubinski, Stanislaw Pawlak, Franziska Boenisch, Tomasz Trzcinski et al.NeurIPS 2023 · 12 citations
- DIAGNOSIS: Detecting Unauthorized Data Usages in Text-to-image Diffusion ModelsZhenting Wang, Chen Chen, Lingjuan Lyu, Dimitris N. Metaxas et al.ICLR 2024 · 12 citations
Builds on30
- Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
- Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh et al.ICML 2021 · 47,906 citations
- A Simple Framework for Contrastive Learning of Visual RepresentationsTing Chen, Simon Kornblith, Mohammad Norouzi, Geoffrey E. HintonICML 2020 · 24,064 citations
- Membership Inference Attacks Against Machine Learning ModelsReza Shokri, Marco Stronati, Congzheng Song, Vitaly ShmatikovS&P 2017 · 5,137 citations
- Extracting Training Data from Large Language ModelsNicholas Carlini, Florian Tramèr, Eric Wallace, Matthew Jagielski et al.USENIX Security 2021 · 2,866 citations
Related papers
- Downstream-agnostic Adversarial ExamplesZiqi Zhou, Shengshan Hu, Ruizhi Zhao, Qian Wang et al.ICCV 2023 · 45 citations
- BadEncoder: Backdoor Attacks to Pre-trained Encoders in Self-Supervised LearningJinyuan Jia, Yupei Liu, Neil Zhenqiang GongS&P 2022 · 200 citations
- Detecting Backdoors in Pre-trained EncodersShiwei Feng, Guanhong Tao, Siyuan Cheng, Guangyu Shen et al.CVPR 2023
- TrojanDec: Data-free Detection of Trojan Inputs in Self-supervised LearningYupei Liu, Yanting Wang, Jinyuan JiaAAAI 2025
- Dataset Inference for Self-Supervised ModelsAdam Dziedzic, Haonan Duan, Muhammad Ahmad Kaleem, Nikita Dhawan et al.NeurIPS 2022 · 59 citations
