instruction
stringlengths
32
27.2k
In a threshold cryptosystem, is there any guarantee that all $m$ peers participating in retrieving a plain-text will all retrieve it? If not, is it possible to provide such a guarantee? For instance if the $m$ peers are hostile to each other, is there a way to either have none of them get the plain text, or all of them...
I am studying the theory of authenticated data structures, like Merkle Trees and I have a doubt: Why use them? For example, to be sure that a cloud provider didn't modify my files, why do I have to ask for a particular data block and have the cloud reply with a hash path from the leaf to the root to authenticate all th...
Zhe Liu, Johann Großschädl, and Ilya Kizhvatov. "Efficient and Side-Channel Resistant RSA Implementation for 8-bit AVR Microcontrollers" describes a fast implementation, but only contains a sketch of the algorithm with partial pseudo-code. Is there a worked implementation publicly available? If not, what is a good fa...
As a follow up to the Q/A session: Small Quantum Signatures - Reality check needed I have implemented the discussed idea for a new short-quantum-safe signature system using fast-forwarding hash. It creates 32 byte public keys and 129 byte signatures. It is as good as I could get it in the little time I had available....
if two communicating parties share a (symmetric) session key, k. When one of the party wants to send a message 'm' to other, is it okay use {m}k as a digital signature?
This December, $N$ friends play secret santa: they select a random permutation $\sigma$ of $N$ (without fixed point). For Santa Claus, everyone has to bring a gift to the next person in the permutation. To preserve the magical spirit of the game, each participant should only know the strict necessary (i.e. their image ...
I'm trying to write an encryption decryption program using Openssl-RSA. There are only two operations. User stores the data and retrieves it whenever he needs. To decrypt something, we need the keypair that was generated during the encryption. Where and how do I store this keypair so that I can access it whenever the u...
Suppose that attacker creates domain parameters $(p,q,g)$ where $q$ is not prime number (but $q$ still divides $p-1$) and that signer generates new key pair using these domain parameters. How exactly can an attacker take advantage of this situation?
I am designing protocol to share a random generated n long password between k parties using Shamir's Secret Sharing. I know that share alone does not reveal much information about the original password to the attacker except for the size of password. My solution now is to extend each password to 512 bits using constant...
First let me be clear upfront that am not Crypto expert. I'm having a problem where I will have to use NFC card. Now given the limitation of NFC cards memory sizes, I will need to constraint my system to generate encoded data up to X amount of character. Is there a way to limit character of AES encrypted data to not ex...
I am trying to use Intel's optimized AES-128-GCM implementation (from the Intel white paper “Fast Multi-buffer IPsec Implementations on Intel Architecture Processors”, you can find the code here). The aesni_precomp_* functions take an argument described as the “Hash sub key”. I have researched the role of the “sub key”...
I am interested in analyzing how adding a salt to our hashed passwords affects the three types of attacks we can use. The three types of attacks against hashes are as follows: We have the hashed output and we are looking for a matching input (pre-image). We have an input (and implicitly the output) and we want to find...
I was doing research on this attack and I am wondering, why is Diffie-Hellman always associated with such an attack? ​ Aren't other public key cryptography schemes vulnerable to the same kind of attack? ​ To be more specific, is RSA vulnerable to such an attack? If so, which versions and how can they be carried out?...
What is the likelihood of 2 bcrypt hashes colliding if they use the same work-factor and input? Are bcrypt's salts large enough to prevent this from happening?
This problem is about setting up cryptographic keys on an IoT device. I don't want my devices to be set up with any cryptographic keys pre-baked, but actual communication have to be based on TLS. Now I need a way to inject an SSL certificate and its corresponding private key from the device the user is using. Can this ...
I am working on an exercise that encrypts a message using only the first $n$ bits of a pseudorandom generator's output $G(k)$, i.e. $F_k(m) := G(k)_{0...n−1} \oplus m$. $k$ is chosen uniformly at random and $k, m \in \{0, 1\}^n$. My task is to decide whether an encryption scheme based on $F_k$ can be secure against a ...
I'm implementing point addition and point doubling of elliptic curve cryptography. The formula that I'm using for slope is Point addition: $S = \frac{(P_y-Q_y)}{(P_x-Q_x)}$ where $P$ and $Q$ are the two points. Point doubling: $S = \frac{(3P_x)^2+a}{2P_y}$ where $P$ and $Q$ are the two points and $a$ is one of the para...
I'm implementing point addition and point doubling operations for elliptic curve cryptography. I have implemented extended euclidean algorithm to perform modulo division. It appears the that extended euclidean algorithm takes almost 90% of the computation time for the whole operation. It is slowing down the entire ope...
At the end of this Wikipedia section, you can see that $$\gcd(|r-s|,n)=q$$ or $$\gcd(|r-s|,n)=p$$ holds. I don't understand why.
The company I work for needs to develop a simple system where, for each client, we encrypt a token on our server, which is then transmitted to the client. The decryption is performed by the server itself when the client transmits the token (thus the only machine that performs crypto is the server). The token is for an ...
The Bulletin of the Atomic Scientists recently ran an article about an alleged near miss with rockets in 1962, which raises some interesting cryptographic questions: After the usual time-check and weather update came the usual string of code. Normally the first portion of the string did not match the numbers the ...
We learned in class that if Alice wants to send a small message $m$, such that $m < N^{\frac{1}{e}}$, so we can break the system using $e$-th square of $m^e$. But what if Alice knows this flaw and decides to sent $2^{100}\cdot m$ as her message. Is an attacker can still break the system (I assume that the attacker know...
2 questions about nonce usage in GCM: Is it safe to use non-random nonce in GCM? Say I use 0x1 for m1, 0x2 for m2, so on. How much should a nonce increased for a file? Say I use 0x1000 as a nonce to encrypt a 1000x block size file (128,000bits). Then should the next safe nonce to use for the next file be simply 0x1001...
I have two prime numbers: p = 37 q = 41 And I need to find whether any of these prime numbers, 5, 7 or 11, can be used as a valid encryption key e? My working so far: Computer their product: n = p * q = 1517 Compute Euler totient: m = (p - 1)(q - 1) = 1440 Find greatest common divisor: a = 41 b = 37 r = 41 mod 37 =...
As per my understanding, in Elliptical curve cryptography, the EC PrivateKey is nothing but a bigInteger value. If you know the curve specs and you have this private BigInteger value (which I am referring as raw private key), then you can re-create PrivateKey and use it for generating the signature. Now, my question is...
I want to know if there exists an algorithm i can use where the input is a string of data and the output is a scrambled version of the same but in a 2 D array ie given something like: |1 2 3 4 5 6 7 8 9| I want an output somewhat like: |2 8 * 3 | |7 9 4 1 | |* 5 * 6 | The scrambling would ideally be on the basis ...
My idea is to generate a RSA 2048 bit key and use RC4 with the private RSA key to encrypt a stream of data. RC4 is weak because RC4 keys are small, 256-bit. But when we use RC4 with private RSA 2048 key, how much stronger will it be?
Andy is going to connect to a server Selma over TLS. Later, Andy would like to be able to publish everything (the ciphertexts, the plaintexts, all his keys) and prove to a mediator what data he sent to Selma over TLS; or prove what data Selma sent to him over TLS. Is there any way I can do this? More specifically: We...
The RSA-2048 Crypto Ransom Virus has devastated me, I tried the backup method, the previous version, the Shadow Explorer, it deleted all my restore points, Its took out 5 HDs and my USB pen that happened to be plugged in, everything is encrypted, all my kids pictures and videos, spreadsheets, PDF's, Music and more. I n...
I am working on this exercise but can't work out the answer to the question b. I have solved the question (a) by decrypting the ciphertext $C = 2$ using the formula: $$ M = C^d \bmod n = 2^{17} \bmod 21 = 11 $$ Alice and Bob agree to communicate using the RSA cryptosystem. Alice has a private key ($n = 21$, $d = 17$)...
Many introductory courses on cryptography have their treatment of secret-key crypto start with OTP, then block ciphers, and for public-key cryptography revolve around RSA with no notion of padding (some even have matching exercises showcasing insecure practices, beyond using artificially small parameters). It is all to...
I need to calculate 256-bit hash in my code, using BLAKE2. I know I can set BLAKE2 to generate itself a 256-bits hash for any data but I´m curious to know what can be safer and faster: 1- Create the 256-bit using Blake2Config module; or 2- Truncate the normal 512-bit result getting the leftmost 32 bytes (256 bits). In...
My question is about Key-Policy ABE (KP-ABE). What does it mean when a "Ciphertext is Labeled with set of attribute"? How is it labeled?
a) Alice just generated a new pair of public and private RSA keys (pkA , skA ) = ((N, e), d) and would like to start a private conversation with Bob. How can Alice interact with Bob and exchange a symmetric key? Describe a key exchange protocol between them which is secure against an eavesdropper adversary. b) Fully s...
Consider the DSA key generation: A large prime $p$ is chosen; A smaller modulus $q$ is chosen such that $p - 1$ is a multiple of $q$; A generator $g$ s.t. $\operatorname{ord}_p(g) = q$ is chosen. My question is -- why do we require that $p - 1$ be a multiple of $q$? Is there any underlying mathematics I'm missing? ...
DES has 8 different S-boxes, and AES has only 1. What are the negative consequences of such choices?
While Email encryption can protect the content of an email, the metadata are still readable and can be used to gather important information about the sender and the receiver. There were several news articles about the Darkmail project, which aims to increase privacy in email communication. The initiative is developing ...
In the private key CPA game, the attacker has access to an encryption oracle anytime during the attack. However, I have seen this statement in lecture notes I downloaded "You can prove that for every polynomial time attacker that uses the encryption oracle after receiving the challenge cyphertext, you can construct an...
I have studied Sharmir's scheme as well as the multiple assignment scheme proposed by M. Ito. My question is if anyone can tell me if the following scheme is theoretically secure: Terms: P = set of participants B = Access structure A = Access set (authorised set within access structure) t = cardinality of Access struct...
Currently I am learning about Hybrid Encryption but I was not able to find any good study material. Below is my understanding: One of the reason why we use Hybrid Encryption because public-key cryptosystems often rely on complicated mathematical computations and are thus generally much more inefficient than comparable...
Wiki definition : A cryptosystem is considered secure in terms of indistinguishability if no adversary, given an encryption of a message randomly chosen from a two-element message space determined by the adversary, can identify the message choice with probability significantly better than that of random guess...
I read this question a while back (In RSA, why is it important to choose e so that it is coprime to φ(n)?). I was wondering whether there is a proof that shows that a public key exponent e that is coprime with the totient of the modulus N will result in a unique answer when the cipher text is decrypted. Please help.
I was working on affine coordinates and struggling with the computation time taken for operations and then I was advised to use projective coordinates so that mul-inverse operation can be avoided Can somebody tell me how to compute 'z'?...I read at some places that z can be assumed as (1,1). If so then can it be used f...
The string (32 ASCII characters) is entered by a human, and considered truly random. Should a key derive from this string, or it is secure to use this string as a key directly? In other words, does deriving a key from this string makes the encryption more secure?
Bob and Alice, both generate a temporary public key pair each using X algorithm on their individual PC. After being authenticated by a third party, they use the DHE to come to get a common symmetric key; This key is used for the encryption of messages sent between them for that session. After the session is over, all t...
Imagine such protocol. Client and server initially share secret K[0]. When client wants to contact server she sends server K[0] and her ID. Server accepts request, and generated new random K[1] and sends it to client which should use this in next communication. Again, if client wants to authenticate with server now, s...
I want to ask you a question. I have WPA-2 (enterprise) network. Also called as 802.1x. I use the Linux Zeroshell distribution, which is optimized for these services. Linux Zeroshell is provides a radius server. I also have a router. I have entered accounts to Zeroshell, which can access the network. Each human, who wa...
Are there any (recent) estimates of cost of attack on DSA by solving the discrete logarithm? I'm especially interested in attacks that use Pollard's rho algorithm. Are there any optimized implementations of Pollard's rho algorithm that can be used to estimate such costs?
I'm a hobby programmer and very new to this field. I opened a bank account recently and got two pins. One for the girocard and the other for a creditcard. And I needed two more pins for the online banking account, that I could choose by myself. Just for fun I tried to come up with an algorithm, that generates each pin ...
I am trying to decrypt a RSA encrypted text file. I have a 2048 bit public key. Analyzing the public key with openssl reveals the exponent used is 3. openssl rsa -pubin -inform PEM -text -noout < publickey.pub Public-Key: (2048 bit) Modulus: [..snipped..] Exponent: 3 (0x3) After some googling, I found out that the...
I need to know the execution time for HMAC -MD5 for a 160 bit data using 128 bit key on a 3 Ghz CPU, kindly specify other parameters of the machine like RAM, operating system used etc
On a related note of building my own RNG, as someone suggested to use several commericial solutions how can I check if it is rigged against me? (although I am still strongly biased to a homebrew solution that is designed to be hard to subvert, taking the shortest possible route from a quantum random source to the ADC)
I'm trying to learn how RSA works. From what I found online, I'm supposed to generate private key using Extended Euclidean algorithm. I've managed to generate the public key, but don't know how to use EEA to generate the private key. How should I exactly input into EEA, and how to process the output?
I would be very grateful if someone has an implementation of the Satoh algorithm (Fast Elliptic Curve Point Counting). Can someone point me to practical algorithm implementations or provide some examples? Everything I can find is just an article.
Can someone help me implement linear cryptanalysis of the PRESENT block cipher? How should I start with 64 bits of plaintext and 80 bits of key?
I would like to know which method can provide better security: using identity based signature or hashing the identities and message (using SHA-1) for authentication?
We know that it's possible to create a hash using a stream cipher (for instance, RC4 or AES in Counter Mode). As stated here: "A Pseudo Random Generator (PRG) and a hash function are both Pseudo Random Functions (PRFs), but they have different security considerations". Whether or not it's advisable to do so, is there a...
I have two secret values $a$ and $b$ (i.e. they are arbitrary values). I mask them as follow: $v_1=r_1a+r_2$ $v_2=r_1(b-a)$ where $r_1$ and $r_2$ are uniformly random values. I send $v_1$ and $v_2$ to a malicious server, and ask him to compute $v_1+v_2=r_1b+r_2$ Question: Given $v_1$ and $v_2$, can the server learn an...
I am doing a DES problem by hand and I want to know how you calculate the inverse of the initial permutation. I know what the permutation is, but how do you find it based off the given initial permutation?
Is it safe to XOR parameters like domain, length of the message or block counter into sponge's capacity or that gives attacker control over capacity? For example NORX XORs domain into capacity. Does this break sponge security proofs? What about adding bit into capacity to denote that there was no padding since message ...
I've been learning about RSA and wrote my own implementation. I don't pretend to have intuitive understanding of RSA or that I understand why it works, but I believe to have some basic understanding of how it works, and believe that my implementation is valid. Due to time penalty of key generation, I set extremely low ...
In regular ElGamal and DSA, we choose large primes $p$ and $q$ such that $p\equiv 1\pmod{q}$, and a group element $g$ of order $q$ by computing $a^{(p-1)/q}$ for some random $a$. This is to prevent smooth group order which can then be factorized, and the discrete log problem can be solved by Pohlig-Hellman algorithm. H...
Are textbook RSA signatures secure if an Adversary does not have access to ask signing oracle queries?
I am self-studying cryptography from a book and have come across a really difficult question that's doing my head in. I would be very grateful if somebody can help me out here with this difficult question. NOTE : This is not homework, as I am self-studying. It would be great if someone can take the time to explain a s...
In Diffie-Hellman key agreement between Alice and Bob, Alice computes and sends $g^a$ to Bob, and Bob computes and sends $g^b$ to Alice. Alice then computes $(g^b)^a$, and Bob computes $(g^a)^b$; $g^{ab}$ is their shared key. But this is vulnerable to man-in-the-middle attack. To overcome the man-in-the-middle, suppose...
I'm an embedded systems researcher, and new in the crypto field. Actually, I need to know if there are any lightweight asymmetric encryption algorithm especially considering the time needed for key generation. I found that NTRU is considered one of the most lightweight asymmetric crypto systems, is this correct?
I am looking for a modern cipher to encode morse code, ie. input is [A-Z 0-9] (base36 as I learned in the comments below) and output is the same, one character at a time. The old enigma does a good job at doing this, but is obviously broken. The cipher doesn't necessarily have to be usable "by hand" (as the "classic ci...
I'm a student and I don't know how to solve the following problem : Alice is proposing a 10 questions list to Bob. Bob choose only 1 question and wants to know the answer without Alice knowing the question. Alice wants that Bob can only have 1 correct answer. Is it possible ? If yes how ? In my mind it should begin...
I am looking for AES-128 keys such that the last round key is exactly the first round key (which is simply the key). Any pointer to a proof that they exist or that they don't would be welcome. In the same line, I am looking for last round keys which are the bitwise inverse of the key or some similarly simple relation w...
Given: F is a pseudorandom function, G is a pseudorandom generator with $l(n) = n+1$. The following schemes should be classified as being insecure, IND-COA secure, IND-CPA secure. To encrypt $m \in \{0, 1\}^{n+1}$ choose a random $r \leftarrow \{0, 1\}^n$ and output $[r, G(r) \oplus m]$ To encrypt $m \in \{0, 1\}^{n}$...
I know it's hard to find the $e$th root of a number mod $n=p_1*p_2$, and if it would be possible we could break RSA. But how hard it is to take an $e$th root mod $p$ where $p$ is a prime and $\gcd(e,p-1)=1$?
When thinking about a pairing-based cryptographic scheme, I encountered the following problem. Let $e \colon G_1, G_2 \to G_T$ be a Type 3 pairing. Then: Given $P, zP \in G_1$ and $Q, zQ \in G_2$, compute $z$. I haven't found this problem in the literature anywhere, so I am not aware of any name of it. It clearly imp...
I am supposed to implement ECC over binary field (in C++) for equations of the type - $y^2 + xy = x^3 + ax + b$, as my project. I wish to include the following features : The user will enter a prime number $m$, which will serve as the order of the binary field as $2^m$. For the given $m$, the irreducible polynomial wi...
As I understand, for RSA $n = p \cdot q$. For the key to be safe enough from getting factored, $p$ and $q$ have to be far from each other. How far do they have to be? For example, if I have two $1024$-bit primes that both start with a 1 and the difference between them $(p-q)$ is ~$1022$-$1023$ bits, is that good enough...
I am working on the following exercise question: Consider the following construction of a “keyed” hash function from Katz & Lindell (ex. 7.22 (1st ed.)/ 8.21(2nd ed.)). Gen : On input $1^n$ , generate a cyclic group $\mathcal{G}$ of order $q$, where $q$ is an $n$-bit prime, and a generator $h_1$. Then select $h_2, \ld...
Can anyone explain to me (or send a link to somewhere) how round keys are added in AES-256? I understand that the round keys is added to the state matrix for each round and how XOR works. But since the state matrix is always 128 bits, how do you add an 256 bit round key? I might be confused on a higher level right now....
Suppose a client (Alice) goes to an HTTPS website (Bob) over TLS 1.2. Alice sends Client Hello with some random number $r_a$. Bob sends Server Hello with another random number $r_b$. Suppose they settle on some cipher suite (e.g. RSA, DHE, AES, and SHA1) Bob sends server certificate Bob signs and sends server key exch...
I am working on a UDP based file transfer protocol. Congestion Control, Resending of packages and other UDP challenges are dealt with - speedtests shows that the protocol is up to 10 times faster than e.g. HTTP for transferring large files when the latency/rtt is > 100 ms (e.g. between Europe and the US). The protocol ...
There are articles floating around the topic of SHA-1 deprecation. The gist of it is that in (mostly) developing countries, people are still using mobile/computing devices that are 5 years old (or older) and do not support SHA-2. As a consequence, the deprecation of SHA-1 would result in their being "cut off from the I...
I am a junior in high school and I am currently studying algebra 2. Where can I go to learn about the mathematics behind cryptography? I have a very basic knowledge of cryptography, but I am really interested in things like, why is a 2^256 bit cipher so secure? I would really like to learn about things like that so I c...
One of the drawbacks of OTP is that it can require an inconveniently long key. Besides that, it doesn’t provide data authentication. Therefore, I have been working on an algorithm idea, which I hope to be more powerful and efficient than OTP: Encrypt plaintext with a block cipher (something with strong avalanche effec...
Most modern symmetric ciphers require a nonce/IV. If the nonce is reused, security is lost. If the nonce is large enough, it can be generated securely by using a CSPRNG. This avoids needing to keep state between encryptions. I am looking for algorithms that have a large IV — specifically, one large enough that usin...
I'm currently in a course in Cryptography, and was wondering why pseudorandom function families exist at all. If there existed one pseudorandom function f(x), based on its definition, could that not be used in all cases where a pseudorandom function is needed? Why would pseudorandom functions ever need to be sampled fr...
I just started to study lattice Cryptography. I'm now studying worst-case to average-case reduction for SIS. In previous question, "worst means any and average means random". And I wonder why the Shortest Independent Vectors Problem(SIVP) is the worst-case problem. And, does SIVP means that "For 'any' given lattice ba...
I was thinking of how to create an IV for a block cipher that doesn't require stored state, and I came up with the idea of using an HMAC of the (padded) plaintext and a (possibly distinct) key as the IV. This seems to be secure: The IV will only be reused if there is an HMAC collision or if the plaintext and key are t...
I am working on a multiplayer game. I have a central server which handles all data transmission and coordinates all games. Clients which involved in a single session send requests to do actions to the server, those actions are checked and the consequences are pushed to all clients. I am looking for a way for the server...
Is there any MPC scheme that allows a function with several secret inputs to be computed, while the output can only become known to one specific party? If not, is this even possible?
Well, I know it's easy to tell CCA1 from CCA2, but I failed to find the difference between RCCA and CCA2. What is the difference?
If the base is same and exponents are different, for example: $R_1=b^x\bmod{p}$; $R_2=b^y\bmod{p}$; $R_3=b^z\bmod{p}$; ($p$ is large prime (2048 bit); $x$, $y$ and $z$ - 160 bit integers)) To calculate $R_1$, $R_2$ and $R_3$ at the same time, then my question is: Does the calculation finish in around one exponentiat...
What do the numbers stand for in the names of cryptographic functions, for example AES-256, RSA-1024 or SHA-256? Do they always refer to key sizes, or is it a different measure for every algorithm? Is there some convention about this?
I'm encrypting a file and I'm using an initialisation vector. Given that the IV doesn't need to be a secret, is it secure if I add it to the encrypted file's name?
I am studying the Lamport signature scheme, and I found that in many sources (eg: Hash-based Digital Signature Schemes) the input and output bitstring of the OWF and the message digest have the same size, generally 256. As the minimal requirement for the OWF is to be pre-image resistant, it seems that 128 bits for the...
Bitcoin's HD (Hierarchical Deterministic) Keys as described in BIP32 allow for a master key to be created (a private key and a chain code) such that a tree of both public and private keys can be derived from a master key, each which can have additional keys derived from it. In addition, some of hierarchy can be 'harden...
I am assuming none of these padding algorithms are "the best"... But what are the advantages and disadvantages of using them? PKCS7 is certainly the most commonly used one, but I am interested in seeing what the others offer.
This is really a follow up question to a comment made regarding How to roll a HWRNG In the situation of whitening a hardware generated random bit stream, "XORing the two bitstreams should be fine for mixing, by the piling-up lemma" was said. The other bit stream was suggested to be one from a PRNG. In signal sampl...
From https://en.wikipedia.org/wiki/Decisional_Diffie%E2%80%93Hellman_assumption: Importantly, the DDH assumption does not hold in the multiplicative group $\mathbb {Z} _{p}^{*}$, where $p$ is prime. This is because given $g^{a}$ and $g^{b}$, one can efficiently compute the Legendre symbol of $g^{ab}$, giving a success...
My clients have to exchange public keys. To ensure security they are exchanging fingerprints and typing them into the computer by hands. I want the fingerprints to be as short as possible. I am using libsodium for encryption, which uses Curve25519. What is the shortest fingerprint I can generate which would still ensur...
For achieving stateless authentication tokens (like JWT), is there a compromise between the performance of HMAC, and public key distribution of Digital Signature? Scenario: Sender is a centralized authentication server. Receiver is an distributed/elastic pool of stateless web services. The issue I have with HMAC alon...
Scenario: Assume I encrypt message $m$ using Paillier encryption, so I would get $c=E(m)$. I give the identical $c$ to two different parties, parties $D$ and $E$. Party $D$ computes: $c_{D}= E(m)^{h_1}=E(m \cdot h_1)$ Party $E$ computes: $c_{E}= E(m)^{h_2}=E(m \cdot h_2)$ Values $c, c_{D}$ and $c_{E}$ are given to a ...
I have two secret values $L_1$, $L_2$, and two Pedersen commitments $C_1 = C(L_1)$, $C_2=C(L_2)$. The commitments $C_1$, $C_2$ are public. Given a challenge $c$, I want to output $d = c*L_1+L_2$ and prove in zero-knowledge that $d$ is formed correctly. What should the zero-knowledge proof look like?