Domain Generalization for Document Authentication against Practical Recapturing Attacks

Changsheng Chen, Shuzheng Zhang, Fengbo Lan, Jiwu Huang · DOI

Abstract

Recapturing attacks serve as a potent anti-forensic tool, where forged digital documents are printed and re-imaged to mask editing traces. This paper proposes a robust document authentication scheme using a Siamese network architecture to compare questioned documents against reference samples. By integrating a forensic similarity function with a hybrid loss (triplet and normalized softmax), the model learns to extract distinct forensic features that generalize across diverse printing and imaging devices. Experimental results demonstrate that the proposed method significantly outperforms state-of-the-art approaches, achieving an Attack Presentation Classification Error Rate (APCER) of less than 5.00% even in challenging cross-domain scenarios.

The Challenge of Recapturing Attacks

In digital forensics, a "recapturing attack" involves a physical print-and-scan cycle designed to wipe away digital artifacts like JPEG compression inconsistencies or pixel-level cloning traces. This process makes forgeries appear as legitimate, albeit slightly noisy, originals.

Existing detection methods often struggle with domain shift. A model trained on a specific office scanner often fails when faced with a mobile phone photo or a document printed on high-quality glossy paper. The goal of this research is to achieve "domain generalization," ensuring authentication remains reliable regardless of the hardware or substrate used.

Proposed Methodology

The proposed framework mimics a human expert's approach: comparing a questioned document patch against a known high-quality reference template.

Siamese Architecture and Triplet Selection

At the core of the system is a Siamese network that processes a triplet of image patches: a high-quality Reference, a genuine Positive capture, and a recaptured Negative (forged) document. By ensuring all patches in a triplet come from the same semantic location (e.g., the portrait area of an ID), the network is forced to learn forensic traces—such as halftone patterns and color degradations—rather than document content.

The proposed Siamese network architecture, illustrating the triplet selection process, feature extraction via CNN, and the similarity measurement subnet.

Forensic Similarity and Hybrid Loss

Unlike standard deep learning models that rely on Euclidean distance, this method employs a trainable forensic similarity subnet. This allows the model to weigh specific feature dimensions that are most relevant to identifying recapturing artifacts. The training is guided by a hybrid loss function:

  • Triplet Similarity Loss: Clusters genuine samples near the reference while pushing recaptured samples away.
  • Normalized Softmax Loss: Sharpens the decision boundary by improving the relative distance between positive and negative samples.

Experimental Evaluation

The authors benchmarked the system using five distinct datasets ($D_1$ to $D_5$) covering various combinations of smartphones, scanners, printers, and document types (ID cards and certificates).

Key Insights from Feature Embedding

Visualization of the feature space using t-SNE reveals how the model successfully separates different classes. Notably, the analysis showed that "display-and-capture" attacks (photographing an LCD screen) create distinct feature clusters compared to paper-based recapturing, explaining why generic models often fail to detect screen-based forgeries.

t-SNE visualization of the learned feature embedding, showing the clustering of genuine samples and the separation of various recaptured attack types.

Results and Performance

The proposed method demonstrated exceptional robustness in cross-domain scenarios:

  • Intra-dataset: Achieved a near-perfect Equal Error Rate (EER) of 0.01%.
  • Cross-dataset ($D_1 \to D_2$): While standard ResNet50 models saw error rates climb above 13%, the proposed method maintained an EER as low as 1.30%.
  • Generalization: In the most difficult test—evaluating across different document types and devices—the ResNeXt101-based version achieved an APCER of less than 5.00% at a strict security threshold (5% BPCER).

Conclusion

By combining metric learning with specialized image forensic techniques, this research provides a powerful tool for authenticating documents in the real world. While the current system relies on a reference template, future work aims to reduce this dependency and explore few-shot learning for rapid adaptation to entirely new document types.

Summary updated

BibTeX
@misc{chen2021domain,
  author = {Changsheng Chen and Shuzheng Zhang and Fengbo Lan and Jiwu Huang},
  title = {{Domain Generalization for Document Authentication against Practical Recapturing Attacks}},
  year = {2021},
  eprint = {2101.01404},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2101.01404},
}
Figure