arXiv:2610.21127cs.CROct 2026

Manuscript Offprint

arXiv:2610.21127

Reaction Attack on CKKS Deployments with Asymptotically Optimal Query Complexity

Song Bian, Hyeongmin Choe, Jiseung Kim, Changmin Lee

Song Bian

Beihang University

sbian@buaa.edu.cn

Hyeongmin Choe

University of Luxembourg

hyeongmin.choe@uni.lu

Jiseung Kim

Jeonbuk National University

jiseungkim@jbnu.ac.kr

Changmin Lee †^{\dagger}

Korea University

changminlee@korea.ac.kr

Abstract—We study a protocol-level reaction leakage in CKKS deployments where public coefficient-to-slot (C2S) evaluation keys are combined with a client's 1-bit validity response. Under this deployment surface, a malicious evaluator can recover a ternary secret key using asymptotically optimal O(H)O(\mathcal{H}) reaction queries, where H\mathcal{H} is the entropy of the secret key.

The attack does not break RLWE or CKKS IND-CPA security. Instead, it exploits the interaction between client-side validity reactions and public homomorphic linear transformations. A shift of a public encryption key yields a ciphertext whose plaintext is a function of the secret key; the public C2S layer then repacks this information to construct a ciphertext whose validity depends strictly on whether a targeted secret coefficient matches a guessed value. Furthermore, each submitted query is independently randomized with a fresh encryption of zero, so that each resulting malicious ciphertext appears entirely distinct, thereby allowing the attack to simply evade trivial detection mechanisms on the client side.

We implemented the full end-to-end attack in Lattigo v6.2.0 and recovered the full secret key across four parameter sets drawn from standard CKKS presets. For uniform ternary secrets, the attack uses O(N)O(N) queries and is within a factor 2/log⁡23<22/\log_2 3 < 2 of the oracle-only entropy lower bound. For sparse ternary secrets, a tailored variant further reduces the number of queries in practice. Our results show that observable validity reactions form a practical key-recovery channel in CKKS deployments exposing this surface, even when the underlying cryptographic assumptions remain intact.

1. Introduction

Fully Homomorphic Encryption (FHE) [41] enables computations to be performed directly on encrypted data. In a typical outsourcing scenario, a client encrypts its input, sends the ciphertext to an untrusted server, and later decrypts the returned ciphertext to obtain the result of the computation, without revealing the underlying data to the server.

This capability makes FHE a natural foundation for secure outsourced computation, including privacy-preserving machine learning and other cloud-based data-processing tasks [3], [29], [52], [53], [57], [64], [71], [73]. Although FHE implementations have grown increasingly practical, the security of these real-world deployments is no longer determined only by the hardness of the underlying cryptographic assumptions. It additionally hinges on how the resulting ciphertexts are returned, checked, and handled by the client.

Attacks on Secure Outsourced Computation. Attacks on secure outsourced computation based on FHE can be broadly divided into two classes. The first class targets the cryptographic primitives themselves, independent of the specific application. This includes the cryptanalysis of the underlying Ring-Learning-With-Errors (RLWE) assumptions, a foundational hardness assumption widely used in lattice-based cryptography, or exploiting the gap in theoretical security notions, most notably, the fact that standard FHE schemes guarantee Indistinguishability under Chosen-Plaintext Attack (IND-CPA) but are inherently vulnerable to Indistinguishability under Chosen-Ciphertext Attack (IND-CCA) attacks.

In contrast, this paper focuses on the second class of attacks, which emerge from the deployment and protocol layers surrounding homomorphic encryption. While much of the applied FHE literature assumes an honest-but-curious server, this assumption is often overly optimistic for practical deployment, where a server might deviate from the protocol. In such scenarios, a malicious evaluator can actively manipulate the computation, submitting adversarially generated ciphertexts to observe how the client reacts—whether they accept, reject, retry, or leak information through decrypted outputs.

Reaction Attacks. This specific vulnerability is exploited by reaction attacks [8], [16], [17], [28], [31], [46], [48], [63], which turn a client's visible behavior—such as acceptance (accept or reject), rejection (retry or not), or error handling—into a one-bit decryption oracle. Although each individual response leaks only a single bit of information, a sequence of adaptively chosen queries can amplify this leakage into substantial information about the secret key.

To illustrate this setting, depicted in Figure 1, consider a client C that outsources a computation Φ\Phi to a server S, typically a cloud service provider. The client encrypts a message m under the Cheon–Kim–Kim–Song (CKKS)

*. Authors are listed in alphabetical order; see https://www.ams.org/profession/leaders/culture/JointResearchandItsPublicationfinal.pdf.

†. Corresponding author.

scheme [26], an FHE scheme specialized for real and complex number vectors, sends the ciphertext Enc(m)\text{Enc}(m) to S, and expects to receive an evaluated ciphertext decrypting to an approximation of Φ(m)\Phi(m). In an idealized model, the client simply decrypts the returned ciphertext to obtain the result. In practice, however, a client seldom accepts the decrypted output unconditionally. In practice, deployments (whether or not they use FHE) often perform application-layer admissibility checks (e.g., range or magnitude tests) before consuming a result. This kind of input validation is a well-established defensive-programming technique [68], and reaction attacks beginning with Bleichenbacher [8] and continuing thereafter have repeatedly demonstrated that the resulting accept/reject behavior can leak secret information. For instance, a machine-learning pipeline might verify whether the decoded class logits, the pre-softmax scores, fall within a valid range, or a protocol might check for arithmetic overflow. Whenever the client's application-level reaction triggered by a failed check (e.g., an implicit retry or an explicit abort) becomes observable to the server, this check effectively transforms into a reaction oracle.

The crucial point is that such an oracle does not reveal plaintexts, nor does it require the adversary to break the underlying RLWE assumption or the IND-CPA security of CKKS. It reveals strictly whether a submitted ciphertext satisfies the client's validity predicate. In this scenario, a malicious server S can submit a manipulated ciphertext (a,b)(a, b) and observes only whether the client-side predicate accepts or rejects the decoded output. For example, if C proceeds without requesting a re-computation, the adversary learns that the predicate was accepted; if C retries or raises an error, the adversary learns it failed. Thus, the validity reaction acts as a one-bit decision oracle on the decoded slot magnitudes. Yet, as we demonstrate, this single bit is sufficient to fully recover the CKKS secret key under a natural deployment surface.

Even such a restricted oracle can leak the secret key. To see this, let ss be the client's secret key, where a valid ciphertext (a,b)(a,b) satisfies the standard decryption relation b−as=m+emod  qb-as = m + e \mod q for a plaintext mm, a small encryption noise ee, and a ciphertext modulus qq. Suppose a malicious server SS attempts to guess the secret key by sampling a candidate ring element uu and a sufficiently large public perturbation tt. The server then sends the modified ciphertext (a′=a+t,b′=b+ut)(a' = a + t, b' = b + ut) to C.

If the guess is correct (i.e., u=su = s), the decryption relation remains unchanged since b′−a′s=emod  qb' - a's = e \mod q, meaning the modified ciphertext stays within the admissible range. If the guess is incorrect (i.e., u≠su \neq s), the decryption residual contains the additional term (t(u−s)+emod  q)(t(u - s) + e \mod q), which exceeds the admissibility threshold with high probability due to the magnitude of tt. A reaction oracle can therefore distinguish whether a guessed ring element matches the secret key.

While this simple example demonstrates why validity reactions leak information about s, it is exponentially inefficient, equivalent to a brute-force search over a secret space (e.g., of size 3N3^{N} for typical uniform ternary secrets, where

Figure

Figure 1: Conceptual Sketch of the Reaction Attack Scenario.

N is the ring dimension).

Crucially, reaction attacks are not captured by standard security notions for FHE, such as IND-CPA, IND-CCA, or the intermediate IND-CPA D^{D} [60], [61], which allows restricted decryption queries. The adversary never obtains the plaintexts themselves, nor does it violate the hardness of the underlying RLWE problem. It merely observes the binary validity outcomes induced by the client's application-level correctness checks.

References (73)