Skip to content

Concrete Cryptanalysis of the Permuted Reed--Solomon Pseudorandom Code for LLM Watermarking

Shuiyin Liu, Amin Sakzad

cs.CR

Abstract

Pseudorandom error-correcting codes (PRCs) give undetectable and robust watermarks for large language models (LLMs). To our knowledge, the permuted Reed--Solomon code (PRSC) is the most robust PRC against worst-case edits, and its security rests on an asymptotic conjecture that has not been tested at deployable sizes. We give a keyless distinguisher for PRSC that counts the symbols at which two responses agree, a count that the secret permutations leave unchanged. We derive the exact distribution of the agreement count and the resulting sample cost T≈6/DT\approx 6/\sqrt{D}, where DD is the information per pair of responses. The cost TT grows as 2Θ(klog⁡k)2^{Θ(k\log k)} in the message dimension kk, which is superpolynomial in the code length nn, so it does not contradict the conjecture, which requires T=poly(n)T=\mathrm{poly}(n). Expressed in tokens, the cost depends on the language model only through its mean bit-flip probability pˉ\bar{p} and its embedded bits per token κκ. Under an i.i.d. symbol model, we show that no dimension k≥2k\geq 2 is decodable within the Guruswami--Sudan radius once pˉ≥1−1/2\bar{p}\geq 1-1/\sqrt{2}. With measured GPT-2 and Llama-2-7B statistics at gate τ=0.2τ=0.2, this translates to the fact that a 300-word response gives a cost between 2292^{29} and 2582^{58} (extra channel noise η=0.1η=0.1 or 0.20.2), and 21282^{128} needs about 1000--1600 words for GPT-2 and 3500--4400 for Llama-2-7B. Our end-to-end experiments on both models, at code length 1717, agree with the predicted cost within about 0.30.3 bit in most settings.

Create a lesson

Metadata

Categories
cs.CR, cs.IT, math.IT
Comments
12 pages, 7 tables, 1 figure