Abstract
Homomorphic encryption allows for computations on encrypted data without exposing the underlying plaintext, enabling secure and private data processing in various applications such as cloud computing and machine learning. This article presents a comprehensive mathematical foundation for three prominent homomorphic encryption schemes: Brakerski–Gentry–Vaikuntanathan (BGV), Brakerski–Fan-Vercauteren (BFV), and Cheon–Kim–Kim–Song (CKKS), all based on the ring learning with errors (RLWE) problem. We align our discussion with the functionalities proposed in the recent homomorphic encryption standard, providing detailed algorithms and correctness proofs for each scheme. In addition, we propose improvements to the current schemes focusing on noise management and optimization of public key encryption and leveled homomorphic computation. Our modifications ensure that the noise bound remains within a fixed function for all levels of computation, guaranteeing correct decryption and maintaining efficiency comparable to existing methods. The proposed enhancements reduce ciphertext expansion and storage requirements, making these schemes more practical for real-world applications.
1 Introduction
Homomorphic encryption describes encryption schemes that allow for addition and multiplication operations to be performed on ciphertexts without needing or leaking any information about the secret key or user messages. Furthermore, the operations in the ciphertext space correspond to performing the same operations on the original messages, which can be performed by any third party with knowledge of only the public information. Homomorphic encryption has several modern applications, such as secure cloud computing and private machine learning. With Craig Gentry’s work in 2009 [1], secure homomorphic encryption became viable using ideal lattices. This construction closely relates to the commonly used learning with errors (LWE) problem, with the hardness of LWE being a result proved by Regev in 2005 [2].
Three of the most common modern homomorphic encryption schemes are based on a ring version of LWE problems, known as the ring learning with error (RLWE) problems [3]. These schemes are the Brakerski–Gentry–Vaikuntanathan (BGV) scheme [4,5], the Brakerski–Fan–Vercauteren (BFV) scheme [6], and the Cheon–Kim–Kim–Song (CKKS) scheme [7]. BGV and BFV allow for homomorphic computation for exact arithmetic, while CKKS provides homomorphic computation for numerical computation with certain accuracy. With recent efforts to standardize homomorphic encryption schemes and security [8,9], it is desirable to have concrete and mathematically solid discussions on encryption schemes and homomorphic computing protocols that match the functionalities proposed in the standard, including parameter specifications for efficiency and security.
We should mention that Chillotti et al. [10,11] present a fully homomorphic encryption scheme that can perform one bit operation in less than 0.1 s, while Gao [12] and Case et al. [13] present a fully homomorphic encryption scheme with similar running time but a much smaller ciphertext expansion (
Our contributions. This article has two main goals. The first goal is to present detailed algorithms for the functionalities proposed in the homomorphic encryption standard [8,9] for each of the BFV, BGV, and CKKS schemes, and to present a detailed correctness proof for all the functionalities. This lays a rigorous mathematical foundation for homomorphic encryption schemes. The second goal is to improve the current schemes for BFV, BGV, and CKKS. We present modified schemes for each of the three schemes, especially in public key encryption and leveled homomorphic computing, and focus on noise control and the worst-case noise bounds, thereby reducing ciphertext expansion and storage expenses. In particular, under the modified schemes, the noise bound for ciphertexts from public key encryption and from homomorphic computing at each level is always bounded by a fixed function
Organization of this article. In Section 2, we describe notations and necessary background. We then introduce LWE and RLWE problems. We present and prove two variations of modulus reduction, which is later applied to RLWE-based encryption schemes. In Section 3, we outline three RLWE-based homomorphic encryption schemes: BFV, BGV, and CKKS. For these three schemes, we provide modified encryption to better control noise and conduct a thorough worst-case theoretical noise analysis. In Section 4, we discuss leveled schemes and present techniques in choosing parameters to guarantee homomorphic operations. We also outline operations in RNS here. In Section 5, we give a brief discussion of attack techniques for LWE problems. In Section 6, we provide concluding remarks and further potential research topics. Appendix A contains the proofs of the lemmas on correctness of functionalities for all the algorithms.
2 Notations and preliminaries
2.1 Notations
For a positive integer
where
power of two. For an integer
where
For a vector or polynomial
where
2.2 Noise distributions and learning with errors problems
For a set
LWE problems. For any secret
When drawing elements from distributions on
Most leveled homomorphic encryption schemes use RLWE as opposed to LWE. The ciphertexts of homomorphic encryption schemes discussed will all essentially take the form of a modified RLWE sample. Regev originally showed the hardness of the LWE problem [2], which serves as foundation for the security of homomorphic encryption schemes. We discuss more specifics on security in Section 5.
We remark that, in our schemes, we use noise size
2.3 Modulus reductions
Let
Algorithm 1. BFV modulus reduction
| BFV.Modreduce (
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | Compute
|
| Step 2. | Return
|
Lemma 2.1
Suppose the input
and
What will be more useful than a modulus reduction for a generic RLWE sample will be a modulus reduction for a “modified” RLWE sample that takes the form of a standard BFV ciphertext, hence the algorithm name BFV.Modreduce. By a BFV ciphertext, we mean that our input for Algorithm 1
for some noise term
Lemma 2.2
Suppose the input of Algorithm 1 is a BFV ciphertext such that
and
The final reformulation essentially states that if
for some noise term
Algorithm 2. BGV modulus reduction
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | Compute |
|
|
|
| Step 2. | Compute |
|
|
|
| Step 3. | Return
|
Lemma 2.3
Suppose the input of Algorithm 2 is a BGV ciphertext such that
and
3 Homomorphic encryption schemes and noise bounds
Most homomorphic encryption schemes in the literature use a modified version of RLWE to hide messages. In this section, we will cover three main schemes: BFV [6], BGV [4,5], and CKKS [7]. For these three schemes, we present modified versions where the noise sizes are improved and always controlled by a fixed bound, namely
Overview of specifications. Before outlining our specific algorithms, we first provide an overview of specifications for parameters and spaces. Although there are variations between the schemes, the parameter choices outlined below work for all of BFV, BGV, and CKKS (when applicable). These parameter conditions ensure proper functionality regarding homomorphic computation for each scheme. Further caution must be taken when choosing parameters in practice to ensure security, which is discussed in Section 5.
Specifications for homomorphic encryption schemes
We want to emphasize that each coefficient of the distribution
The bound
Remark on message encoding and choice of
3.1 Modified BFV scheme
BFV key generation. The key generation process we use is slightly different from the standard BFV scheme [6] in that the public key and evaluation key are generated in a larger modulus [6,14,16,19], which will be useful for reducing the noise size in ciphertexts. Algorithm 3 gives the key generation for the BFV keys needed, which is the secret key sk, the public key pk, and the evaluation key ek. Here, sk is kept secret, while pk and ek are published. The public key
for noise term
for noise term
Algorithm 3. BFV key generation.
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
|
|
|
|
|
|
| Step 1. | Choose randomly
|
| Step 2. | Sample
|
| Compute
|
|
| Step 3. | Sample
|
| Compute
|
|
| Step 4. | Return
|
BFV encryption and decryption. We encrypt a message
for some message
Algorithm 4. Modified BFV encryption
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | Sample
|
| Step 2. | Compute
|
|
|
|
|
|
|
| Step 3. | Compute |
|
|
|
|
|
|
| Step 4. | Return
|
Lemma 3.1 provides correctness and the corresponding noise bound resulting from encryption. The bounds in Lemma 3.1 are assuming that
Lemma 3.1
Let
We argue that when
This technique of encryption with a built-in modulus reduction in Step 3 was first mentioned in [19], but is overall not especially well outlined in the literature. Implementations do often reduce the modulus immediately after encryption to reduce noise. For instance, Microsoft SEAL [28] chooses
Algorithm 5 provides for the decryption of a BFV ciphertext, which is the standard BFV decryption.
Algorithm 5. BFV decryption
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Compute
|
| Step 2. | Compute
|
| Step 3. | Return
|
Lemma 3.2
If the input
BFV additions and linear combinations. We allow for linear combinations of ciphertexts with scalars from
Algorithm 6. Linear combinations
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Set
|
| For
|
|
|
|
|
| Step 2. | Return
|
Lemma 3.3
Suppose the inputs of Algorithm 6 are BFV ciphertexts each with noise bounded by E and suppose
We remark that we allow for inputs of Algorithm 6 to also be in
for some
BFV multiplication. As expected, multiplication incurs much bigger increase in ciphertext noise and more tedious noise analysis. The procedure is again standard for the BFV scheme as in the study by Fan and Vercauteren [6]. The proof is similar to that presented in the study by Fan and Vercauteren [6], but we give a simpler worst-case noise bound with Lemma 3.4.
Algorithm 7. BFV multiplication
|
|
|
|---|---|
| Input: |
|
| Output: |
|
| Step 1. | Compute |
|
|
|
| Step 2. | Compute |
|
|
|
| Step 3. | Return
|
Lemma 3.4
Suppose the inputs of Algorithm 7 are BFV ciphertexts for messages
with
The simple bound provided in Lemma 3.4 will allow us to choose parameters easily and stack moduli as we will do in Section 4, while having minimal influence on functionality.
Comparison to current bounds. As mentioned earlier, we can see that our bound is on the order of
Classic BFV [6]:
Improved BFV [16]:
Our BFV variant:
In the study by Kim et al. [16], the dominant noise term is
BFV relinearization. To convert a returned ciphertext from Algorithm 7 back to the proper form of a BFV ciphertext, we can employ a relinearization (or keyswitch) algorithm [6]. The algorithm converts a linear form in
Algorithm 8. BFV Relinearization
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Compute
|
| Step 2. | Compute
|
| Step 3. | Compute
|
| Step 4. | Return
|
Lemma 3.5
Let
Alternate relinearization technique. Algorithm 8 is not the only option for relinearizing a ciphertext. Another technique [6,14,27,29] involves generating the evaluation key differently, by expanding
Let
To obtain a new relinearized ciphertext from
where
Using
3.2 Modified BGV scheme
BGV key generation. As we did with BFV, we use a slightly different key generation process from the standard BGV scheme [4,5] by generating the public key and evaluation key in a larger modulus to reduce noise sizes in ciphertexts. Algorithm 9 gives the key generation for the BGV keys. Just like BFV, sk is kept secret, while pk and ek are published.
Algorithm 9. BGV key generation
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
|
|
|
|
|
|
| Step 1. | Choose randomly
|
| Step 2. | Sample
|
| Compute
|
|
| Step 3. | Sample
|
| Compute
|
|
| Step 4. | Return
|
BGV encryption and decryption. We define the BGV public key encryption in Algorithm 10. Decryption of a BGV ciphertext is given in Algorithm 11. When we refer to a “BGV ciphertext” in these algorithms and lemmas, we mean an ordered pair
for some noise term
Algorithm 10. Modified BGV encryption
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Sample
|
| Step 2. | Compute
|
|
|
|
|
|
|
| Step 3. | Compute |
|
|
|
|
|
|
| Step 4. | Return
|
Lemma 3.6
Let
Algorithm 11. BGV decryption
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Compute
|
| Step 2. | Compute
|
| Step 3. | Return
|
Just as with BFV, the condition on
Regarding decryption, the proof of correctness for Algorithm 11 is straightforward. Simply observe that
BGV additions and linear combinations. Additions and linear combinations for BGV can be done using Algorithm 6. The argument is similar to Lemma 3.3 for BFV ciphertexts and results in the same noise bound of
BGV multiplication. Again, multiplication incurs large noise increase during homomorphic computation. Unlike BFV, there is no requirement that
Algorithm 12. BGV multiplication
|
|
|
|---|---|
| Input: |
|
| Output: |
|
| Step 1. | Compute |
|
|
|
|
|
|
|
|
|
| Step 2. | Return
|
Lemma 3.7
Suppose the inputs of Algorithm 12 are BGV ciphertexts for messages
with
BGV relinearization. We can relinearize a BGV ciphertext to rewrite the left hand side of equation (2) as a linear form in only
Lemma 3.8
Let
Algorithm 13. BGV relinearization.
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Compute
|
| Step 2. | Compute
|
| Step 3. | Compute
|
| Step 4. | Compute
|
| Step 5. | Return
|
3.3 Modified CKKS scheme
In this section, we will discuss the CKKS scheme [7]. CKKS allows for homomorphic encryption for arithmetic of approximate numbers rather than arithmetic exactly as BFV and BGV do. This is done by first taking in data as some vector over
Message encoding and decoding. Recall that
Here,
That is,
The purpose of these mappings is that given a message vector
It is worth noting that most texts use a technique called coordinate-wise random rounding instead of rounding to the nearest integer [25]. However, we will use the closest integer rounding. As we will see, this step of rounding causes accuracy loss in the message. To avoid this, we scale by some positive integer
for any message
for any polynomial
The encryption and decryption procedures for CKKS then map between

Note the scaling factor
The remainder of Section 3.3 is devoted to the homomorphic computation in
CKKS rescaling. Regarding modulus reduction in CKKS, a similar procedure known as rescaling occurs. The rescaling procedure is identical to the modulus reduction for BFV outlined in Algorithm 1. That is,
The main difference is the purpose of the procedure. Rather than using modulus reduction as a form of noise control, it is used here to control precision. For two message encodings
for some noise term
Lemma 3.9
Suppose the input of Algorithm 1 is a CKKS ciphertext with noise bounded by E. Let
and
A notable difference in CKKS rescaling is that the algorithm returns an encryption of
CKKS key generation. For CKKS, the keys used are generated in the same way that the BFV keys are generated. In this case, we refer the reader to Algorithm 3 for generation of the CKKS keys, which again includes the secret key sk, the public key pk, and the evaluation key ek.
CKKS encryption and decryption. The encryption algorithm is given by Algorithm 14, and decryption by Algorithm 15. Note that CKKS encryption in Algorithm 14 uses Algorithm 1 as a subroutine, which is the rescaling. From Step 2 of Algorithm 15, we obtain
Algorithm 14. Modified CKKS encryption
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | Encode
|
| Step 2. | Compute
|
| Step 3. | Return
|
Algorithm 15. CKKS decryption
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Compute
|
| Step 2. | Decode
|
| Step 3. | Return
|
Lemma 3.10
Let
CKKS additions and linear combinations. We can perform additions and linear combinations with CKKS ciphertexts using Algorithm 6. The resulting ciphertext obtained from Algorithm 6 has a slightly different noise bound than BFV and BGV. The reason for this is that the encoded messages which the ciphertexts represent are in
Lemma 3.11
Suppose the inputs of Algorithm 6 are CKKS ciphertexts each with noise bounded by E and suppose
CKKS multiplication. Multiplication in CKKS follows the same process as BGV, which is given in Algorithm 12. Thus,
The difference is only a slightly different noise bound, due to the plaintexts not being in
Lemma 3.12
Suppose the inputs of Algorithm 12 are CKKS ciphertexts for messages
with
CKKS relinearization. As with the other schemes, full multiplication can then be achieved by including the relinearization process discussed in Algorithm 8, so
The proof is almost identical to the proof in Lemma 3.5. The result for CKKS is given in Lemma 3.13.
Lemma 3.13
Let
Note on BFV versus CKKS. Initially, the formatting of ciphertexts in BFV and CKKS seem very similar. For a message
3.4 Comparison to other noise bound analyses
Our noise analysis differs from previous works [6,7,16,17] in that we derive worst-case bounds based on worst-case bound assumptions on the error distribution. As a result, our correctness guarantees are deterministic; there is no probability of decryption error. In addition, we simplify the derived bounds into clean, closed-form expressions that will be useful for subsequent sections. This simplification comes at the cost of slightly looser bounds overall, with the effect being most pronounced in BFV multiplication. A detailed comparison of BFV multiplication appears near the end of Section 3.1.
For most operations, our bounds are very close to the worst-case results presented in the study by Kim et al. [16], though with a few important distinctions. First, in all of our modulus reduction lemmas, we explicitly bound the ratio
In addition, under basic assumptions on
For concrete estimates, many works adopt
4 Leveled schemes and RNS variants
For practical computation, we employ a leveled homomorphic encryption scheme rather than a fully homomorphic one. Unlike fully homomorphic schemes – which support an unlimited number of operations via costly bootstrapping – a leveled scheme supports a predetermined number of homomorphic operations, making it more efficient for realistic workloads. In this section, we outline leveled versions of the BFV, BGV, and CKKS schemes. The core idea is to carry out computations at decreasing modulus levels: perform a fixed number of operations at a given modulus, then reduce both the modulus and the noise to enable further computation.
Let
We refer to
Section 4.2 details how ciphertext operations are performed in the RNS. By the Chinese remainder theorem, any polynomial
where
All ciphertexts, public keys, and evaluation keys are stored in RNS form with respect to appropriate modulus bases. A key advantage of RNS is that addition and multiplication of polynomials can be performed component-wise, independently across the
4.1 Budgeted operations at each level
For a collection of ciphertexts, we want to know how much homomorphic computation we can perform before ciphertext noise becomes too big to the point that no further computation can be performed. To do this, we introduce the concept of a depth-1 multiplication computation.
Definition 4.1
(Depth-1 multiplication) Suppose we have a collection of messages. For fixed
Figure 1 shows an arbitrary depth-1 multiplication with

Plaintext depth-1 multiplication.
Algorithm 16. Depth-1 multiplication
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | For
|
|
|
|
| Step 2. | Initialize
|
| For
|
|
|
|
|
| Step 3. | Compute
|
| Step 4. | Compute
|
| Step 5. | Return
|
In Algorithm 16, we remark that Multiply, Relinearize, and Modreduce call the respective algorithms for the inputted ciphertext type. For example, if each
To guarantee the amount of computation we can perform, we want to choose
Lemma 4.1
For any
Lemma 4.2
For any
For a similar depth-1 result in CKKS, we must use caution when finding conditions for
Lemma 4.3
Let i be such that
One special case of a depth-1 multiplication is the inner product of vectors. That is, given vectors of messages
Remark. Algorithm 16 also works for groups of ciphertext inputs of size less than
so long as
then Lemmas 4.1, 4.2, and 4.3 still apply.
4.2 Operations in the residue number system
Implementations of homomorphic encryption [28,31–33] take advantage of the RNS variants of schemes [19,21–23]. In our modified leveled homomorphic schemes, we would require that each
Basis conversion in RNS. Suppose
as two arbitrary ordered sets which we call bases. For an element
where
One can check that
Algorithm 17. Fast basis conversion
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | For
|
| Step 2. | For
|
|
|
|
| Step 3. | Return
|
Lemma 4.4
([21–23]) Suppose the input of Algorithm 17 is the RNS representation in basis
for some
We note that the bound on
Modulus reduction in RNS. Let
Suppose
By the Chinese remainder theorem, the solution
This is true even if
Define
where the coefficients of
Note that
The first sum has integer coefficients, and we only need to round the second sum. Let
Then
where
This gives us the Algorithm 18 that matches Algorithm 1.
Algorithm 18. RNS BFV modulus reduction (v1)
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | For
|
|
|
|
| Step 2. | Compute |
|
|
|
| Step 3. | For
|
|
|
|
| Step 4. | Return
|
The
satisfies
where
Algorithm 19. RNS BFV modulus reduction (v2)
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | Let
|
|
|
|
| Step 2. | For
|
|
|
|
| Step 3. | Return
|
Lemma 4.5
Let the RNS representation of
for some
Next, we show a BGV modulus reduction in RNS that matches Algorithm 2. When
Algorithm 20 describes the above procedure for reduction of one polynomial, while Lemma 4.6 shows the noise bound. We exclude the proof of Lemma 4.6, since it is clear from the discussion and the proof of Lemma 2.3.
Algorithm 20. RNS BGV modulus reduction
|
|
|
|---|---|
| Input: |
|
|
|
|
|
|
|
| Output: |
|
| Step 1. | For
|
|
|
|
| Step 2. | Let
|
|
|
|
| Step 3. | For
|
|
|
|
| Step 4. | Return
|
Lemma 4.6
Let the RNS representation of
for some
For the CKKS rescaling procedure in RNS, we can again use the same procedure as the fast BFV modulus reduction in Algorithm 19. Said otherwise,
Note here that we specifically use (v2) of the RNS BFV Modulus reduction for RNS CKKS. Likewise, we can also use Lemma 4.5 for RNS CKKS when discussing the noise bound after performing
Relinearization in RNS. For the rest of this section, fix
The goal of our relinearization algorithms in RNS will again be to closely match the previously outlined relinearizations for the classic variants in Algorithms 8 and 13. We first introduce the evaluation key generations for the three schemes, followed by their relinearization procedures. We should note that we only discuss the evaluation key generation here. The generations of other keys (secret and public encryption keys) are similarly RNS versions of Algorithms 3 and 10.
We begin with RNS BFV. The procedure for evaluation key generation is given in Algorithm 21. Observe that this evaluation key generation is the same as the evaluation key generation in Algorithm 3, only computed in RNS.
Algorithm 21. RNS BFV evaluation key generation
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Sample
|
| Step 2. | For
|
|
|
|
| Step 3. | For
|
|
|
|
| Step 4. | Return
|
For the RNS BGV scheme, the evaluation key generation is again a similar approach to the original evaluation key generation from Algorithm 9. Algorithm 22 gives the procedure for RNS BGV.
Algorithm 22. RNS BGV evaluation key generation
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Sample
|
| Step 2. | For
|
|
|
|
| Step 3. | For
|
|
|
|
| Step 4. | Return
|
For the RNS CKKS scheme, the evaluation key generation is exactly the same as the evaluation key generation for RNS BFV:
We are now ready to discuss the full RNS realinearization procedures. In these algorithms, we assume that we have obtained a vector of components
For all three schemes, the RNS linearization procedure is given in Algorithm 23. Here,
Algorithm 23. RNS relinearization
|
|
|
|---|---|
| Input: |
|
|
|
|
| Output: |
|
| Step 1. | Compute
|
| Step 2. | For
|
|
|
|
|
|
|
| Step 3. | For
|
|
|
|
|
|
|
| Step 4. | Compute |
|
|
|
|
|
|
| Step 5. | For
|
|
|
|
|
|
|
| Step 6. | Return
|
Lemma 4.7
Let
for
Lemma 4.8
Let
for
Lemma 4.9
Let
for
In addition to the relinearization technique we opt for, we should also mention that there exists versions of the alternate relinearization technique from Section 3.1 in RNS [22,23]. In the RNS version, the element
5 Lattices, security, and attacks
The security of homomorphic encryption schemes is based on the LWE problem over finite fields, which can be reduced to lattice problems. In this section, we will give an overview of these lattice problems as well as various attacks on LWE. As this article is more focused on noise reduction in homomorphic encryption schemes, we only provide a brief overview of security and attacks. For a more in-depth discussion on security, we refer the reader to various sources [24,30,35]. Decision-RLWE can be shown to be as hard as many worst-case lattice problems [36]. There is also a brief mention of security reductions from RLWE to LWE in [30]. We will discuss attacks on classic LWE rather than RLWE, since RLWE problems can be easily converted into LWE problems. Furthermore, all the best attack algorithms are for LWE instead of RLWE.
5.1 Lattices and lattice problems
Let m ≥ 1. A subset
Here,
which can be proved to be independent of the choice of basis. Let
Definitions 5.1, 5.2, and 5.3 describe a few instances of well-studied lattice problems for a lattice
Definition 5.1
(SVP) The shortest vector problem (SVP) is as follows: given a basis
Definition 5.2
(
Definition 5.3
(
These lattice problems are examples of NP-hard problems in the worst case. Regev [24] provides a reduction from an instance of
It is also worth mentioning that although the matrix
where
Then
To obtain a lattice basis for
Then, a basis for
The volume of this lattice is
Gaussian heuristic. By the Gaussian Heuristic, for a lattice
on average [24,37], where
on average. Similarly for
on average.
5.2 LWE attack strategies
First, recall the LWE problems outlined in Section 2.2. Fix
where
Dual attacks via SVP. To solve Decision-LWE, we employ a dual attack. Let
Primal attacks via SVP. A common attack strategy for Search-LWE is with SVP. Let
and let
since the entries of
Lattice basis reduction algorithms. Several algorithms employ these strategies, as well as others, to solve LWE. Algorithms in practice for solving lattice problems include algorithms such as LLL [41], BKW [42], and BKZ [43], which are discussed thoroughly in previous studies [8] and [24]. We will primarily discuss BKZ, as it seems to currently be the best algorithm for lattice reduction. The basic idea behind BKZ is to solve SVP for sublattices of dimension
Let
We call
In practice, the limiting factor from equation (10) is used to estimate
Our goal is to obtain a basis with a specific target size for
for use in lattice reduction algorithms to obtain the best result.
The study by van de Pol and Smart [45] introduces a technique which does not rely on first knowing
Note that in all these techniques, the dual
After deciding on the block size k and optimal dimension
In summary, to estimate the total cost of attack, an appropriate block size k and lattice dimension m must first be determined based on parameters n, q, and the standard deviation of the chosen error sampling distribution
6 Conclusion
We have presented a detailed mathematical foundation for the BGV, BFV, and CKKS homomorphic encryption schemes, aligning our work with the functionalities proposed in recent homomorphic encryption standards. By providing protocol algorithms and correctness proofs, we have ensured that these schemes are not only theoretically sound but also practical for implementation. Our proposed improvements, particularly in noise management and leveled homomorphic computation, enhance the efficiency and applicability of these schemes by reducing ciphertext expansion and storage requirements. In future works, we plan to further analyze the impacts of these noise bounds on precision accuracy in CKKS.
-
Funding information: This work was based upon the work supported by the National Center for Transportation Cybersecurity and Resiliency (TraCR) (a U.S. Department of Transportation National University Transportation Center) headquartered at Clemson University, Clemson, South Carolina, USA. Any opinions, findings, conclusions and recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of TraCR, and the U.S. Government assumes no liability for the contents or use thereof.
-
Author contributions: Both authors contributed equally to the content, writing, and editing of this article. Both authors have accepted responsibility for the entire content of this manuscript and consented to its submission to the journal, reviewed all the results and approved the final version of the manuscript.
-
Conflict of interest: The authors state no conflict of interest.
Appendix A Proofs of Lemmas
Proof of Lemma 2.1
By assumption,
Since
Let
Proof of Lemma 2.2
By assumption, we first note that
Note that as
Let
By assumption
Proof of Lemma 2.3
First, note that
where
By assumption
Proof of Lemma 3.1
By assumption, the public key
for some noise
Let
Since
with
Proof of Lemma 3.2
By assumption,
Then,
The last equality follows from the fact that
Proof of Lemma 3.3
By assumption, each
with
Since
with
Let
So,
Proof of Lemma 3.4
By assumption, we have for
with
where
On the one hand,
with
Let
Let
We now turn to the noise bound for
To simplify the noise analysis for
Then,
For
The bound on
By assumption,
Proof of Lemma 3.5
Notice that as
for some
for some
Then,
for some
Let
Let
Now, we turn to the noise bounds on
By Lemma 7, we have that
Proof of Lemma 3.6
By assumption, the public key
for some noise
Let
with
Proof of Lemma 3.7
By assumption, we have for
with
Let
with
Proof of Lemma 3.8
First, observe that both
so
Let
where
Then, note that
The bound on
Proof of Lemma 3.9
By assumption, we first note that
Therefore, there is some integer
Let
By assumption
Proof of Lemma 3.10
We consider step 2 of Algorithm 14, in which we compute
for
with
Let
Proof of Lemma 3.11
By assumption, each
for some noise term
Let
So,
Proof of Lemma 3.12
By assumption, we have for
with
The bound on
Proof of Lemma 3.13
It is clear from the proof of Lemma 3.5 that
Let
Proof of Lemma 4.1
Suppose we have a collection of BFV ciphertexts, each with noise bounded by
results in BFV ciphertexts
By Lemma 3.4, each
Summing all
by an equivalent argument to Lemma 3.3 with polynomial triples as the input. Notice,
By the proof of Lemma 3.5, BFV.Relinearize introduces additional noise of at most
So, a worst-case noise bound for a depth-1 multiplication is given by
As
Proof of Lemma 4.2
Suppose we have a collection of BGV ciphertexts, each with noise bounded by
results in BGV ciphertexts
By Lemma 3.7, each
Then,
Summing all
Notice,
By the proof of Lemma 3.8, BGV.Relinearize introduces additional noise of at most
So, a worst-case noise bound for a depth-1 multiplication is given by
As
Proof of Lemma 4.3
Suppose we have a collection of CKKS ciphertexts, each with noise bounded by
results in CKKS ciphertexts
By Lemma 3.12, each
Summing all
by an equivalent argument to Lemma 3.11 with polynomial triples as the input. By the proof of Lemma 3.13, CKKS.Relinearize introduces additional noise of at most
So, a worst-case noise bound for a depth-1 multiplication is given by
Proof of Lemma 4.7
By assumption the input of Algorithm 23 is the RNS representation in basis
for
for
By Lemma 4.5, Step 4 returns the RNS representation of some
with
for
Proof of Lemma 4.8
By assumption the input of Algorithm 23 is the RNS representation in basis
for
is the RNS representation of some
for
By Lemma 4.6, Step 4 returns the RNS representation of some
with
for
Proof of Lemma 4.9
By assumption the input of Algorithm 23 is the RNS representation in basis
for
with
References
[1] Gentry C. A fully homomorphic encryption scheme. PhD thesis. Stanford, CA: Stanford University; 2009. https://crypto.stanford.edu/craig/craig-thesis.pdf. Suche in Google Scholar
[2] Regev O. On lattices, learning with errors, random linear codes, and cryptography. J ACM. 2009;56(6):1–40. 10.1145/1568318.1568324Suche in Google Scholar
[3] Lyubashevsky V, Peikert C, Regev O. On ideal lattices and learning with errors over rings. In: Gilbert H, editor.Advances in Cryptology – EUROCRYPT 2010. Berlin, Heidelberg: Springer Berlin Heidelberg; 2010. p. 1–23. 10.1007/978-3-642-13190-5_1Suche in Google Scholar
[4] Brakerski Z, Gentry C, Vaikuntanathan V. Fully homomorphic encryption without bootstrapping. 2011. Cryptology ePrint Archive, Report 2011/277. https://ia.cr/2011/277. Suche in Google Scholar
[5] Brakerski Z, Gentry C, Vaikuntanathan V. (Leveled) fully homomorphic encryption without bootstrapping. ACM Trans Comput Theory. 2014;6(3):1–36. 10.1145/2633600Suche in Google Scholar
[6] Fan J, Vercauteren F. Somewhat practical fully homomorphic encryption. 2012. Cryptology ePrint Archive, Report 2012/144. https://ia.cr/2012/144. Suche in Google Scholar
[7] Cheon JH, Kim A, Kim M, Song Y. Homomorphic encryption for arithmetic of approximate numbers. In: Takagi T, Peyrin T, editors. Advances in Cryptology - ASIACRYPT 2017. Cham: Springer International Publishing; 2017. p. 409–37. 10.1007/978-3-319-70694-8_15Suche in Google Scholar
[8] Albrecht M, Chase M, Chen H, Ding J, Goldwasser S, Gorbunov S, et al. Homomorphic encryption standard. 2019. Cryptology ePrint Archive, Paper 2019/939. https://eprint.iacr.org/2019/939. Suche in Google Scholar
[9] Bossuat JP, Cammarota R, Chillotti I, Curtis BR, Dai W, Gong H et al. Security guidelines for implementing homomorphic encryption; 2024. IACR Commun Cryptol. 2025;1(4). 10.62056/anxra69p1.Suche in Google Scholar
[10] Chillotti I, Gama N, Georgieva M, Izabachène M. Faster fully homomorphic encryption: Bootstrapping in less than 0.1 seconds. In: Cheon JH, Takagi T, editors. Advances in cryptology - ASIACRYPT 2016. Berlin, Heidelberg: Springer Berlin Heidelberg; 2016. p. 3–33. 10.1007/978-3-662-53887-6_1Suche in Google Scholar
[11] Chillotti I, Gama N, Georgieva M, Izabachène M. Faster packed homomorphic operations and efficient circuit bootstrapping for TFHE. In: Takagi T, Peyrin T, editors. Advances in cryptology - ASIACRYPT 2017. Cham: Springer International Publishing; 2017. p. 377–408. 10.1007/978-3-319-70694-8_14Suche in Google Scholar
[12] Gao S. Efficient fully homomorphic encryption scheme. 2018. Cryptology ePrint Archive, Paper 2018/637. https://eprint.iacr.org/2018/637. Suche in Google Scholar
[13] Case BM, Gao S, Hu G, Xu Q. Fully homomorphic encryption with k-bit arithmetic operations. 2019. Cryptology ePrint Archive, Paper 2019/521. https://eprint.iacr.org/2019/521. Suche in Google Scholar
[14] Costache A, Smart NP. Which ring based somewhat homomorphic encryption scheme is best? In: Proceedings of the RSA Conference on Topics in Cryptology - CT-RSA 2016 - Volume 9610. Berlin, Heidelberg: Springer-Verlag; 2016. p. 325–40. 10.1007/978-3-319-29485-8_19Suche in Google Scholar
[15] Bos JW, Lauter K, Loftus J, Naehrig M. Improved security for a ring-based fully homomorphic encryption scheme. In: Stam M, editor. Cryptography and Coding. Berlin, Heidelberg: Springer Berlin Heidelberg; 2013. p. 45–64. 10.1007/978-3-642-45239-0_4Suche in Google Scholar
[16] Kim A, Polyakov Y, Zucca V. Revisiting homomorphic encryption schemes for finite fields. In: Tibouchi M, Wang H, editors. Advances in cryptology - ASIACRYPT 2021. Cham: Springer International Publishing; 2021. p. 608–39. 10.1007/978-3-030-92078-4_21Suche in Google Scholar
[17] Costache A, Curtis BR, Hales E, Murphy S, Ogilvie T, Player R. On the precision loss in approximate homomorphic encryption. In: Selected Areas in Cryptography - SAC 2023: 30th International Conference, Fredericton, Canada, August 14–18, 2023, Revised Selected Papers. Berlin, Heidelberg: Springer-Verlag; 2024. p. 325–45. 10.1007/978-3-031-53368-6_16Suche in Google Scholar
[18] Costache A, Laine K, Player R. Evaluating the effectiveness of heuristic worst-case noise analysis in FHE. In: Computer Security - ESORICS 2020: 25th European Symposium on Research in Computer Security, ESORICS 2020, Guildford, UK, September 14-18, 2020, Proceedings, Part II. Berlin, Heidelberg: Springer-Verlag; 2020. p. 546–65. 10.1007/978-3-030-59013-0_27Suche in Google Scholar
[19] Gentry C, Halevi S, Smart NP. Homomorphic evaluation of the AES circuit. In: Safavi-Naini R, Canetti R, editors.Advances in Cryptology – CRYPTO 2012. Berlin, Heidelberg: Springer Berlin Heidelberg; 2012. 850–67. 10.1007/978-3-642-32009-5_49Suche in Google Scholar
[20] Costache A, Nürnberger L, Player R. Optimisations and tradeoffs for HElib. In: Rosulek M, editor. Topics in cryptology - CT-RSA 2023. Cham: Springer International Publishing; 2023. p. 29–53. 10.1007/978-3-031-30872-7_2Suche in Google Scholar
[21] Cheon JH, Han K, Kim A, Kim M, Song Y. A full RNS variant of approximate homomorphic encryption. Selected areas in cryptography: annual international workshop. SAC proceedings SAC. 2018;11349:347–68. 10.1007/978-3-030-10970-7_16Suche in Google Scholar PubMed PubMed Central
[22] Halevi S, Polyakov Y, Shoup V. An improved RNS variant of the BFV homomorphic encryption scheme. In: Matsui M, editor. Topics in Cryptology - CT-RSA 2019. Cham: Springer International Publishing; 2019. p. 83–105. 10.1007/978-3-030-12612-4_5Suche in Google Scholar
[23] Bajard JC, Eynard J, Hasan MA, Zucca V. A full RNS variant of FV like somewhat homomorphic encryption schemes. In: Avanzi R, Heys H, editors. Selected Areas in Cryptography - SAC 2016. Cham: Springer International Publishing; 2017. p. 423–42. 10.1007/978-3-319-69453-5_23Suche in Google Scholar
[24] Albrecht MR, Player R, Scott S. On the concrete hardness of learning with errors. J Math Cryptol. 2015;9(3):169–203. 10.1515/jmc-2015-0016Suche in Google Scholar
[25] Lyubashevsky V, Peikert C, Regev O. A toolkit for ring-LWE cryptography. In: Johansson T, Nguyen PQ, editors. Advances in cryptology – EUROCRYPT 2013. Berlin, Heidelberg: Springer Berlin Heidelberg; 2013. p. 35–54. 10.1007/978-3-642-38348-9_3Suche in Google Scholar
[26] Albrecht MR. On dual lattice attacks against small-secret LWE and parameter choices in HElib and SEAL. In: Coron JS, Nielsen JB, editors. Advances in Cryptology - EUROCRYPT 2017. Cham: Springer International Publishing; 2017.p. 103–29. 10.1007/978-3-319-56614-6_4Suche in Google Scholar
[27] Case B. Homomorphic encryption and cryptanalysis of lattice cryptography. PhD Thesis. Clemson, SC: Clemson University; 2020. https://tigerprints.clemson.edu/all_dissertations/2635. Suche in Google Scholar
[28] Microsoft SEAL (release 4.1); 2023. Microsoft Research, Redmond, WA, https://github.com/Microsoft/SEAL. Suche in Google Scholar
[29] Yates K. Efficiency of homomorphic encryption schemes, MS Thesis. Clemson, SC: Clemson University; 2022. https://tigerprints.clemson.edu/all_theses/3868. Suche in Google Scholar
[30] Player R. Parameter selection in lattice-based cryptography. PhD thesis. Royal Holloway: University of London; 2018. https://pure.royalholloway.ac.uk/ws/portalfiles/portal/29983580/2018playerrphd.pdf. Suche in Google Scholar
[31] Al Badawi A, Bates J, Bergamaschi F, Cousins DB, Erabelli S, Genise N, et al. OpenFHE: open-source fully homomorphic encryption library. In: Proceedings of the 10th Workshop on Encrypted Computing & Applied Homomorphic Cryptography. WAHC’22. New York, NY, USA: Association for Computing Machinery; 2022. p. 53–63. 10.1145/3560827.3563379Suche in Google Scholar
[32] HElib homomorphic encryption library; 2013. https://github.com/homenc/HElib. Suche in Google Scholar
[33] Halevi S, Shoup V. Design and implementation of HElib: a homomorphic encryption library; 2020. Cryptology ePrint Archive, Paper 2020/1481. https://eprint.iacr.org/2020/1481. Suche in Google Scholar
[34] Han K, Ki D. Better bootstrapping for approximate homomorphic encryption. In: Jarecki S, editor. Topics in cryptology - CT-RSA 2020. Cham: Springer International Publishing; 2020. p. 364–90. 10.1007/978-3-030-40186-3_16Suche in Google Scholar
[35] Peikert C. A decade of lattice cryptography. Found Trends Theor Comput Sci. 2016 mar;10(4):283–424. 10.1561/0400000074Suche in Google Scholar
[36] Peikert C, Regev O, Stephens-Davidowitz N. Pseudorandomness of ring-LWE for any ring and modulus. In: Proceedings of the 49th Annual ACM SIGACT Symposium on Theory of Computing. STOC 2017. New York, NY, USA: Association for Computing Machinery; 2017. p. 461–73. 10.1145/3055399.3055489Suche in Google Scholar
[37] Ducas L. Shortest vector from lattice sieving: a few dimensions for free. 2017. Cryptology ePrint Archive, Paper 2017/999. https://eprint.iacr.org/2017/999. Suche in Google Scholar
[38] Ajtai M. Generating hard instances of lattice problems (extended abstract). In: Proceedings of the Twenty-Eighth Annual ACM Symposium on Theory of Computing. STOC ’96. New York, NY, USA: Association for Computing Machinery; 1996. p. 99–108. 10.1145/237814.237838Suche in Google Scholar
[39] Lindner R, Peikert C. Better key sizes (and attacks) for LWE-based encryption. In: Kiayias A, editor. Topics in Cryptology - CT-RSA 2011. Berlin, Heidelberg: Springer Berlin Heidelberg; 2011. p. 319–39. 10.1007/978-3-642-19074-2_21Suche in Google Scholar
[40] Lyubashevsky V, Micciancio D. On bounded distance decoding, unique shortest vectors, and the minimum distance problem. In: Halevi S, editor. Advances in Cryptology - CRYPTO 2009. Berlin, Heidelberg: Springer Berlin Heidelberg; 2009. p. 577–94. 10.1007/978-3-642-03356-8_34Suche in Google Scholar
[41] Lenstra AK, Lenstra HW, Lovász LM. Factoring polynomials with rational coefficients. Math Ann. 1982;261:515–34. 10.1007/BF01457454Suche in Google Scholar
[42] Blum A, Kalai A, Wasserman H. Noise-tolerant learning, the parity problem, and the statistical query model. J ACM. 2000 May;50:435–40. 10.1145/335305.335355Suche in Google Scholar
[43] Schnorr C, Euchner M. Lattice basis reduction: improved practical algorithms and solving subset sum problems. Math Program. 1994 Aug;66:181–99. 10.1007/BF01581144Suche in Google Scholar
[44] Chen Y. Réduction de réseau et sécurité concrète du chiffrement complètement homomorphe. PhD thesis. Paris Diderot University; 2013. Suche in Google Scholar
[45] van de Pol J, Smart NP. Estimating key sizes for high dimensional lattice-based systems. In: Stam M, editorsCryptography and coding. Berlin, Heidelberg: Springer Berlin Heidelberg; 2013. p. 290–303. 10.1007/978-3-642-45239-0_17Suche in Google Scholar
[46] Micciancio D, Regev O. In: Bernstein DJ, Buchmann J, Dahmen E, editorsLattice-based cryptography. Berlin, Heidelberg: Springer Berlin Heidelberg; 2009. p. 147–91. Suche in Google Scholar
[47] Becker A, Ducas L, Gama N, Laarhoven T. New directions in nearest neighbor searching with applications to lattice sieving. In: Proceedings of the Twenty-Seventh Annual ACM-SIAM Symposium on Discrete Algorithms. SODA ’16. USA: Society for Industrial and Applied Mathematics; 2016. p. 10–24. 10.1137/1.9781611974331.ch2Suche in Google Scholar
[48] Laarhoven T. Search problems in cryptography: from fingerprinting to lattice sieving. PhD thesis. Eindhoven University of Technology; 2016. Suche in Google Scholar
[49] Lepoint T, Naehrig M. A comparison of the homomorphic encryption schemes FV and YASHE. In: Pointcheval D, Vergnaud D, editors. Progress in Cryptology - AFRICACRYPT 2014. Cham: Springer International Publishing; 2014. p. 318–35. 10.1007/978-3-319-06734-6_20Suche in Google Scholar
© 2025 the author(s), published by De Gruyter
This work is licensed under the Creative Commons Attribution 4.0 International License.
Artikel in diesem Heft
- A McEliece cryptosystem using permutation codes
- Research Articles
- The condition number associated with ideal lattices from odd prime degree cyclic number fields
- A small serving of mash: (Quantum) algorithms for SPDH-Sign with small parameters
- The least primitive roots mod p
- On the independence heuristic in the dual attack
- Sherlock Holmes zero-knowledge protocols secure against active attackers
- Inner product functional encryption based on the UOV scheme
- Review Article
- Leveled homomorphic encryption schemes for homomorphic encryption standard
- Special Issue based on CIFRIS24
- Modern techniques in somewhat homomorphic encryption
- Investigation of metabelian platform groups for protocols based on (simultaneous) conjugacy search problem
- Smaller public keys for MinRank-based schemes
- Application of Mordell–Weil lattices with large kissing numbers to acceleration of multiscalar multiplication on elliptic curves
- First-degree prime ideals of composite extensions
- Dynamic-FROST: Schnorr threshold signatures with a flexible committee
- BTLE: Atomic swaps with time-lock puzzles
- Security analysis of ZKPoK based on MQ problem in the multi-instance setting
Artikel in diesem Heft
- A McEliece cryptosystem using permutation codes
- Research Articles
- The condition number associated with ideal lattices from odd prime degree cyclic number fields
- A small serving of mash: (Quantum) algorithms for SPDH-Sign with small parameters
- The least primitive roots mod p
- On the independence heuristic in the dual attack
- Sherlock Holmes zero-knowledge protocols secure against active attackers
- Inner product functional encryption based on the UOV scheme
- Review Article
- Leveled homomorphic encryption schemes for homomorphic encryption standard
- Special Issue based on CIFRIS24
- Modern techniques in somewhat homomorphic encryption
- Investigation of metabelian platform groups for protocols based on (simultaneous) conjugacy search problem
- Smaller public keys for MinRank-based schemes
- Application of Mordell–Weil lattices with large kissing numbers to acceleration of multiscalar multiplication on elliptic curves
- First-degree prime ideals of composite extensions
- Dynamic-FROST: Schnorr threshold signatures with a flexible committee
- BTLE: Atomic swaps with time-lock puzzles
- Security analysis of ZKPoK based on MQ problem in the multi-instance setting