StolenEncoder: Stealing Pre-trained Encoders in Self-supervised Learning

Yupei Liu, Jinyuan Jia, Hongbin Liu, Neil Zhenqiang Gong
1/15/2022
cs.CRcs.LG
contrastive-ssl

Official code: liu00222/StolenEncoder (8 stars, Python, MIT, last commit 2025-01-22).

Abstract

Pre-trained encoders are general-purpose feature extractors that can be used for many downstream tasks. Recent progress in self-supervised learning can pre-train highly effective encoders using a large volume of unlabeled data, leading to the emerging encoder as a service (EaaS).

Show full abstract

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.

View on arXivView PDF

Code Implementations(1)

MIT

This repository contains the code for our CCS'22 paper "StolenEncoder: Stealing Pre-Trained Encoders in Self-Supervised Learning"

80PythonJun 26, 20241 years agoMIT

Similar Papers

Cite this paper

@article{liu2022stolenencoder,
  title  = {StolenEncoder: Stealing Pre-trained Encoders in Self-supervised Learning},
  author = {Yupei Liu and Jinyuan Jia and Hongbin Liu and Neil Zhenqiang Gong},
  year   = {2022},
  eprint = {2201.05889},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2201.05889}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2201.05889.svg)](https://codeofpaper.com/paper/2201.05889)

Discussion