Confidential Error-Correcting Codes

Tianrui Wang, Anyu Wang, Tianshuo Cong, Delong Ran, Xiaoyun WangarXiv 2026

TL;DR

Researchers have introduced Confidential Error-Correcting Codes (CECs), a new cryptographic primitive that simultaneously ensures watermark confidentiality, robustness against image edits, and low false-positive rates. Their practical implementation, CECMark, significantly outperforms existing state-of-the-art watermarking schemes for AI-generated images, providing provable security alongside industry-leading reliability.

What Problem Does This Paper Address?

As AI-generated content (AIGC) becomes ubiquitous, the need for reliable "watermarking"—embedding hidden metadata into images to prove their origin—is critical for safety and governance (e.g., complying with the EU AI Act). However, creating a perfect watermark is a "triple threat" challenge. It must be:

  1. Confidential: Unauthorized parties shouldn't be able to read the hidden data (like user IDs or model specs).
  2. Robust: The watermark must survive common edits like cropping, resizing, or JPEG compression.
  3. Sound: The system shouldn't "hallucinate" watermarks in unwatermarked images (low false positives).

Existing methods often fail one or more of these. Some are robust but leak information; others are theoretically secure but practically vulnerable to "key recovery" attacks that let an adversary strip or forge watermarks. The core difficulty lies in the tension between the randomness needed for security and the structured redundancy needed for error correction.

Methods

The authors propose a new framework called Randomness-Security Separation (RSS). Instead of trying to make a single code do everything, they decouple the tasks:

  • Randomness Pipeline: Uses a "nonce" (a one-time random number) to ensure that even if you embed the same message twice, the resulting watermark looks different.
  • Security Pipeline: Uses a master key and a Pseudorandom Function (PRF)—specifically ChaCha20—to mask the payload. This ensures that without the key, the watermark is mathematically indistinguishable from random noise.
Figure 2: A high-level illustration of the Randomness- Security Separation (RSS) design. The green pipeline pro- vides randomness, while the yellow pipeline ensures security.

For the error-correction piece, they use Conc-CEC, which employs concatenated codes: an internal Reed-Muller code and an external Reed-Solomon code. This combination is much more efficient at fixing errors than the simple "duplicated codes" used by previous state-of-the-art methods.

Finally, they present CECMark, which embeds these codes into the "latent space" of diffusion models (like Stable Diffusion). It intelligently targets high-magnitude coordinates that are less likely to be altered by image processing.

Datasets

The researchers evaluated their work using:

  • Stable Diffusion 2.1-Base: The primary generative model for testing.
  • Stable Diffusion Prompts Dataset: 1,000 diverse text prompts used to generate test images.
  • 56 Image Perturbations: A comprehensive benchmark of edits including rotations, salt-and-pepper noise, Gaussian blur, and various cropping methods to test robustness.

Key Insights and Ideas

  • Separation is Power: The "aha moment" is that you don't need a "cryptographic" error-correcting code. By using the RSS framework, you can use standard, high-performance algebraic codes (like Reed-Solomon) for robustness while letting a standard PRF handle the confidentiality.
  • Concatenation vs. Duplication: Most current watermarks just repeat bits to fix errors. This paper shows that concatenated codes (RM-RS) provide a much sharper "decoding boundary." They stay perfectly accurate up to a high noise threshold and then drop off, whereas simpler codes start failing much earlier.
  • Provable Soundness: Because Conc-CEC uses a restricted decoding region, the authors can mathematically prove a vanishingly low false-positive rate—something many heuristic watermarking schemes lack.

Key Results

CECMark sets a new bar for performance across the board:

  • Security: It achieves a concrete security level of $2^{256}$, dwarfing competitors like PRCMark ($2^{28}$) and T2SMark ($2^{16}$).
  • Robustness: In head-to-head tests across 56 different image attacks, CECMark consistently achieved higher True Positive Rates (TPR). For example, it maintains a stable watermark until nearly 37% of the image's latent signs are flipped, a 10% improvement over previous bests.
  • Soundness: It achieves a theoretical false-positive rate as low as $10^{-17}$, effectively eliminating accidental attributions.
  • Fidelity: Image quality remains high, with FID and CLIP scores showing that the watermark is virtually invisible and doesn't degrade the AI's creative output.
Table 1: Comparison of CECMark against SOTA schemes across security properties.

Limitations and Future Work

While highly effective for images, the authors note that applying CECs to Large Language Models (LLMs) is much harder. Text has much lower "entropy" than images, meaning there's less room to hide a robust watermark without making the text sound robotic or strange.

Future work includes optimizing these codes for the "deletion/insertion" errors common in text editing and extending the framework to video diffusion models, where temporal consistency adds another layer of complexity.

Summary updated

BibTeX
@misc{wang2026confidential,
  author = {Tianrui Wang and Anyu Wang and Tianshuo Cong and Delong Ran and Xiaoyun Wang},
  title = {{Confidential Error-Correcting Codes}},
  year = {2026},
  eprint = {2610.16087},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2610.16087},
}
Figure