《计算机应用》唯一官方网站 ›› 2025, Vol. 45 ›› Issue (3): 904-910.DOI: 10.11772/j.issn.1001-9081.2024030364

• 网络空间安全 • 上一篇    下一篇

基于注意力掩码与特征提取的人脸伪造主动防御

王瑜, 方贤进(), 杨高明, 丁一峰, 杨新露   

  1. 安徽理工大学 计算机科学与工程学院,安徽 淮南 232001
  • 收稿日期:2024-04-02 修回日期:2024-06-25 接受日期:2024-06-26 发布日期:2024-08-13 出版日期:2025-03-10
  • 通讯作者: 方贤进
  • 作者简介:王瑜(1999—),女,安徽宿州人,硕士研究生,主要研究方向:主动防御、伪造人脸检测
    杨高明(1974—),男,安徽临泉人,教授,博士生导师,博士,主要研究方向:隐私保护、机器学习、伪造人脸检测
    丁一峰(1999—),男,安徽芜湖人,硕士研究生,主要研究方向:计算机视觉、图像处理、知识蒸馏
    杨新露(1998—),女,山东滨州人,硕士,主要研究方向:深度伪造检测与防御。
  • 基金资助:
    国家自然科学基金资助项目(52374155);安徽省科技重大专项(18030901025);安徽省自然科学基金资助项目(2308085MF218);安徽省高等学校自然科学研究项目(2022AH040113)

Active defense against face forgery based on attention mask and feature extraction

Yu WANG, Xianjin FANG(), Gaoming YANG, Yifeng DING, Xinlu YANG   

  1. School of Computer Science and Engineering,Anhui University of Science and Technology,Huainan Anhui 232001,China
  • Received:2024-04-02 Revised:2024-06-25 Accepted:2024-06-26 Online:2024-08-13 Published:2025-03-10
  • Contact: Xianjin FANG
  • About author:WANG Yu, born in 1999, M. S. candidate. Her research interests include active defense, fake face detection.
    YANG Gaoming, born in 1974, Ph. D., professor. His research interests include privacy protection, machine learning, fake face detection.
    DING Yifeng, born in 1999, M. S. candidate. His research interests include computer vision, image processing, knowledge distillation.
    YANG Xinlu, born in 1998, M. S. Her research interests include deepfake detection and defense.
  • Supported by:
    National Natural Science Foundation of China(52374155);Anhui Provincial Major Science and Technology Project(18030901025);Anhui Provincial Natural Science Foundation(2308085MF218);Natural Science Research Project of Colleges and Universities in Anhui Province(2022AH040113)

摘要:

为了解决人脸图像在未经授权情况下被伪造或篡改的问题,提出一种基于注意力掩码与特征提取的人脸伪造主动防御方法。该方法旨在采取攻击性措施,向图像中加入可干扰伪造模型的对抗样本,从源头上预防图像被伪造,同时提高被保护图像的视觉质量。首先,采用改进的梯度下降法生成对抗扰动并将这些扰动添加至原始图像,使原始图像在经过伪造处理后生成模糊的虚假图像;同时,在生成器中增添注意力掩码,以增强关键特征通道,从而降低复杂背景和光照带来的影响;其次,使用VGG16预训练网络提取图像特征,在特征图层面提升对抗图像的视觉质量。在名人人脸属性(CelebA)数据集和Radboud面孔数据库(RaFD)数据集上的实验结果表明:对StarGAN,所提方法的防御成功率分别达到99.80%和99.63%,生成的对抗图像的视觉质量相较于基于扩频对抗攻击的基准方法在结构相似性(SSIM)上分别提升了30.86%和26.63%,在峰值信噪比(PSNR)上分别提高了34.80%和36.15%。可见,所提方法可有效防御人脸伪造,同时提升对抗图像的视觉质量。

关键词: 人脸伪造, 主动防御, 注意力掩码, 对抗样本, 特征提取

Abstract:

To address the issue of unauthorized forgery or tampering of facial images, an active defense method based on attention mask and feature extraction was proposed. This method was designed to take offensive measures to interfere with forgery models by adding adversarial examples into the image, so that the image was prevented forgery from the source and the visual quality of the protected image was enhanced. Firstly, an improved gradient descent method was employed to generate and add adversarial perturbations to the original image, resulting in the generation of a blurred false image after forgery processing the original image. At the same time, the attention mask was incorporated into the generator to enhance key feature channels, thereby reducing the influence of complex backgrounds and lighting. Additionally, the VGG16 pre-trained network was utilized to extract image features, thereby improving the visual quality of adversarial images at feature map level. Experimental results on CelebFaces Attributes (CelebA) dataset and Radboud Faces Database (RaFD) dataset show that, for StarGAN, the defense success rates of the proposed model are 99.80% and 99.63% respectively. Compared with the baseline method based on spread-spectrum adversarial attack, the proposed method has the visual quality of generated adversarial images improved by 30.86% and 26.63% respectively on Structure Similarity Index Measure (SSIM), and the Peak Signal-to-Noise Ratio (PSNR) improved by 34.80% and 36.15% respectively. The above indicates that the proposed method defends against face image forgery effectively while enhancing the visual quality of adversarial images.

Key words: face forgery, active defense, attention mask, adversarial example, feature extraction

中图分类号: