instruction
stringlengths
15
30k
How have the authors performed uniform random sampling for the secret values s1 and s2 in dilithium?
Let's say I have the following equation to be arithmetised in PLONK $x^3 + x + 5 = 35$ and the witness is $x = 3$ $3 * 3 = 9$ $9 * 3 = 27$ $27 + 3 = 30$ $30 + 5 = 35$ Now the 4th gate can be expressed as 1) $Q_l\cdot 30 + Q_r\cdot 5 + Q_m(30\cdot 5) + Q_c + Q_o\cdot(35)$ with $Q_l = 1, Q_r = 1...
How do we represent a Gate involving a constant in left or right vectors in PLONK?
How do we represent a Gate involving a constant to the left or right of the operator in PLONK?
Let's say I have the following equation to be arithmetised in PLONK $x^3 + x + 5 = 35$ and the witness is $x = 3$ $3 * 3 = 9$ $9 * 3 = 27$ $27 + 3 = 30$ $30 + 5 = 35$ Now the 4th gate can be expressed as 1) $Q_l\cdot 30 + Q_r\cdot 5 + Q_m(30\cdot 5) + Q_c + Q_o\cdot(35)$ with $Q_l = 1, Q_r = 1...
There is a json array like this: [ { "date": "28.08.23 10:52", "type": "text", "data": "card number including expiration date and CVC" }, { "date": "29.08.23 10:52", "type": "text", "data": "bank password in the form admin:password" ...
What is the probability of decrypting AES-128-ECB if some of the information is available?
> Does this knowledge make hacking easier in any way? Depends on definition of hacking. It does not help towards recovering the AES-128 key, which would effortlessly allow decryption. The fact that AES-ECB is used does allow some attacks on confidentiality. Like depending on the length of the "data" field and ...
I am inquiring about the feasibility of calculating the point difference between two distinct secp256k1 elliptic curve points. Given the nature of secp256k1, which is widely used in cryptographic applications such as blockchain technology, I am interested in understanding the process and potential challenges involved i...
> Does this knowledge make hacking easier in any way? Depends on definition of hacking. It does not help towards recovering the AES-128 key, which would effortlessly allow decryption. The fact that AES-ECB is used does allow some attacks on confidentiality. Like depending on the length of the "data" field and ...
> Does this knowledge make hacking easier in any way? Depends on definition of hacking. It does not help towards recovering the AES-128 key, which would effortlessly allow decryption. The fact that AES-ECB is used does allow some attacks on confidentiality. Like depending on the length of the "data" field and ...
I am inquiring about the feasibility of calculating the point difference between two distinct secp256k1 elliptic curve points. Given the nature of secp256k1, which is widely used in cryptographic applications such as blockchain technology, I am interested in understanding the process and potential challenges involved i...
There is a JSON array like this: [ { "date": "28.08.23 10:52", "type": "text", "data": "card number including expiration date and CVC" }, { "date": "29.08.23 10:52", "type": "text", "data": "bank password in the form admin:password" ...
> This array is then subjected to JSON.stringify(json) and encrypted with the AES-128-ECB algorithm. That is: what's shown it's stripped from whitespace except in strings, leading to ≈274 characters encoded per ASCII into as many bytes. This then is encrypted with the AES-128-[ECB][1] algorithm and some [padding][2]...
> This array is then subjected to JSON.stringify(json) and encrypted with the AES-128-ECB algorithm. That is: what's shown it's stripped from whitespace except in strings, leading to ≈274 characters encoded per ASCII into as many bytes. This then is encrypted with the AES-128-[ECB][1] algorithm and some [padding][2]...
> This array is then subjected to JSON.stringify(json) and encrypted with the AES-128-ECB algorithm. That is: what's shown it's stripped from whitespace except in strings, leading to ≈274 characters encoded per ASCII into as many bytes. This then is encrypted with the AES-128-[ECB][1] algorithm and some [padding][2]...
> This array is then subjected to JSON.stringify(json) and encrypted with the AES-128-ECB algorithm. That is: what's shown it's stripped from [whitespace][1] except in strings, leading to ≈274 characters encoded per ASCII into as many bytes. This then is encrypted with the AES-128-[ECB][2] algorithm and some [paddin...
> This array is then subjected to JSON.stringify(json) and encrypted with the AES-128-ECB algorithm. That is: what's shown it's stripped from [whitespace][1] except in strings, leading to ≈274 characters encoded per ASCII into as many bytes. This then is encrypted with the AES-128-[ECB][2] algorithm and some [paddin...
How to generate n unique numbers from the output of a hash function?
Consider a BLS signature verification using BLS12-381 where signatures are in $G_1$ and public keys are in $G_2$. Verification is performed by checking that $e(sig, G2) = e(H(m), pk)$ or equivalently (by taking advantage of the bilinearity property to avoid one of the final exponentiations) that $e(sig, -G2) *...
What are the implications of BLS signature verification without checking the elements are in the prime subgroup?
Hello I am new to lattice cryptography I am reading the paper [More Efficient Commitments from Structured Lattice Assumptions][1] <br/> They define bound B in page 3 <br/> [![enter image description here][3]][3] <br/> Then In figure 1 in page 9 <br/> [![enter image description here][2]][2] <br/> <br/> Can ...
In TLS 1.2 and TLS 1.3, does the EC curve used to generate the ephemeral keys at the client side, does it need to be the same as that on the and server sides? For example can I use secp521r1 at the client side and secp256r1 at the server side, and visa-versa? I am asking this question, since in TLS 1.2 you can us...
In TLS 1.2 and TLS 1.3, does the EC curve used to generate the ephemeral keys be the same on both client and server sides?
In yet another twist that is the terminology around *key establishment* I found out that ECIES is often denoted as *key encapsulation* followed by *data encapsulation*. I'm wondering how the term "key encapsulation" can be applied to ECIES. ECIES consists of the following: 1. key agreement using ECDH, giving the m...
Why does ECIES use "Key Encapsulation"? Does it?
Does TLS1.3 support DHE_EXPORT cipher suite?
I have a question regarding the operations performed on an elliptic curve, specifically related to point doubling and point addition. I am trying to understand whether it is possible to determine the order in which these calculations were performed in order to obtain the x and y values of a public key. To provide so...
I have many questions about the details of using zk-SNARK technology in zk-rollup: 1. How can the validity of signatures in layer-2 transactions be proven in zk-rollup? 2. In zk-rollup, is a single large zero-knowledge proof circuit used to prove the validity of signatures for a batch of transactions, or is it separa...
How can the validity of signatures in layer-2 transactions be proven in zk-rollup?
Why are my Curve25519 points so different than standard?
Obsidian.md [claims][1] > End-to-end encryption means that the data is encrypted from the moment it leaves your device, and can only be decrypted using your encryption key once it's back on one of your devices. > > We can't read your data. Neither can any potential eavesdroppers, such as your internet service pro...
[Obsidian.md][1] [claims][2] > End-to-end encryption means that the data is encrypted from the moment it leaves your device, and can only be decrypted using your encryption key once it's back on one of your devices. > > We can't read your data. Neither can any potential eavesdroppers, such as your internet servic...
[Obsidian.md][1] [claims][2] > End-to-end encryption means that the data is encrypted from the moment it leaves your device, and can only be decrypted using your encryption key once it's back on one of your devices. > > We can't read your data. Neither can any potential eavesdroppers, such as your internet servic...
[Obsidian.md][1] [claims][2] > End-to-end encryption means that the data is encrypted from the moment it leaves your device, and can only be decrypted using your encryption key once it's back on one of your devices. > > We can't read your data. Neither can any potential eavesdroppers, such as your internet servic...
I've been thinking about creating strong and unique passwords for my online accounts, but I also want them to be memorable. I've come across the idea of using a memorable passphrase as the basis for a complex password generation. Specifically, I'm considering hashing the passphrase to generate the complex password, suc...
I've been thinking about creating strong and unique passwords for my online accounts, but I also want them to be memorable. I've come across the idea of using a memorable passphrase as the basis for a complex password generation. Specifically, I'm considering hashing the passphrase to generate the complex password, suc...
> That gives entropy of 210 bit. No. Suppose the enemy knows or can usefully assume that Alice sends only `0` or `1` after flipping a fair coin, and such a flip is channel-encoded in ASCII as either - `0`: cb530c5177b16f897d9e1f1ee1ff5a0d5e1b7aae8b313746d61d21b7 or - `1`: a5d8adf6032b5f333d9cd6696dd0c520b4dca...
> That gives entropy of 210 bit. No. Suppose the enemy knows or can usefully assume that Alice sends only `0` or `1` after flipping a fair coin, and such a flip is channel-encoded in ASCII as either - `0`: cb530c5177b16f897d9e1f1ee1ff5a0d5e1b7aae8b313746d61d21b7 or - `1`: a5d8adf6032b5f333d9cd6696dd0c520b4dca...
Can someone explain in simple terms how coding part and the algorithm itself, of dilithium pqc signature algorithm resemble here?
> That gives entropy of 210 bit. Yet, the input is extremely poor. **Not quite.** Hashing won't confer any additional entropy than what is present in the inputs. --- > Is it a good idea for creating strong passwords that are also easy to remember in such a way having a scheme? **Usually**, to a memorable ro...
> That gives entropy of 210 bit. Yet, the input is extremely poor. **Not quite.** Hashing won't confer any additional entropy than what is present in the inputs. --- > Is it a good idea for creating strong passwords that are also easy to remember in such a way having a scheme? **Usually**, to a memorable ro...
> That gives entropy of 210 bit. Yet, the input is extremely poor. **Not quite.** Hashing won't confer any additional entropy than what is present in the inputs. --- > Is it a good idea for creating strong passwords that are also easy to remember in such a way having a scheme? **Usually**, to a memorable ro...
When one is computing $E(x) \equiv x^e \pmod N$ (where $N = pq$) in RSA, what is the precedent for which number in the residue class of $x^e$ to have as the result of this computation? Does this mean that we compute $x^e$ and then apply the mod function %$N$ to this, such that $E(x)$ is always in $\{0,1,. . .,N-1\}$? O...
RSA: in $E(x) \equiv x^e \pmod N$, do we apply the mod function to $x^e$?
The GOC (Générateur d'Octets Chiffrants, Ciphering Byte Generator) is a PseudoRandom Generator that was used during the 20<sup>th</sup> century for content encryption in pre-internet [Videotex][1] terminals, mostly in France. One application was encrypting sensitive data (e.g. banking details) while in transit to a [Mi...
The GOC (Générateur d'Octets Chiffrants, Ciphering Byte Generator) is a PseudoRandom Generator that was used during the 20<sup>th</sup> century for content encryption in pre-internet [Videotex][1] terminals, mostly in France. One application was encrypting sensitive data (e.g. banking details) while in transit to a [Mi...
The GOC (Générateur d'Octets Chiffrants, Ciphering Byte Generator) is a PseudoRandom Generator that was used during the 20<sup>th</sup> century for content encryption in pre-internet [Videotex][1] terminals, mostly in France. One application was encrypting sensitive data (e.g. banking details) while in transit to a [Mi...
$E(x) \equiv x^e \pmod N$ as in the question means that $E(x)$ is congruent to $x^e$ modulo $N$, equivalently that $x^e-E(x)$ is a multiple of $N$. But it gives not bound for $E(x)$, thus does not uniquely define it. In particular it allows $E(x)=x^e$, and using that function for encryption would be totally insecure. ...
$E(x) \equiv x^e \pmod N$ as in the question means that $E(x)$ is congruent to $x^e$ modulo $N$, equivalently that $x^e-E(x)$ is a multiple of $N$. But it gives not bound for $E(x)$, thus does not uniquely define it. In particular it allows $E(x)=x^e$, and using that function for encryption would be totally insecure. ...
The GOC (Générateur d'Octets Chiffrants, Ciphering Byte Generator) is a PseudoRandom Generator that was used during the 20<sup>th</sup> century for content encryption in pre-internet [Videotex][1] terminals, mostly in France. One application was encrypting sensitive data (e.g. banking details) while in transit to a [Mi...
The source code to which the question links is in this [repository][1]. The [README][2] says: > Reverse engineered obsidian sync server (NOT OFFICIAL). This repository is quite [active][3], and the developers have been engaging with questions from people fairly consistently. Therefore, as @fgrieu said, the best...
As indicated [in an earlier Q / A](https://crypto.stackexchange.com/q/107813/1172), KEM's do not necessarily directly encrypt a pre-generated random value. However, it is clear that some KEM's do actually do this, with RSA-KEM being an obvious example. Is there a name for the property of a KEM that it relies on both...
The GOC (Générateur d'Octets Chiffrants, Ciphering Byte Generator) is a PseudoRandom Generator that was used during the late 20<sup>th</sup> century for content encryption in pre-internet [Videotex][1] terminals, mostly in France. One application was encrypting sensitive data (e.g. banking details) while in transit to ...
Have any good 8-bit S-boxes made using ARX principles been found yet? I found [Alzette](https://eprint.iacr.org/2019/1378), but it's a huge S-box at 64 bits.
In constructing a SHVZK simulator for a sigma protocol I am working on I have encountered some fairly basic questions, but ones which are not often discussed in textbooks and papers - consider the two following probability distributions: 1. $X_n$ - The uniform distribution on $\{1, \dots n\}=[n]$ 2. $Y_n$ - The u...
I am trying to implement [Pei10](https://eprint.iacr.org/2010/088.pdf) and [BB13](https://eprint.iacr.org/2013/297.pdf), but I am confused about what concrete parameters to use. In Pei10, **Algorithm 1** takes a rounding parameter $r = \omega(\sqrt{\log n})$ as parameter, but it does not specify how to choose it con...
Is there any formula for deriveing the y-coordinate using the x-coordinate and the slope in secp256k1 elliptic curve? # Example $Calculate$ $the$ $slope$ ``` slope = 75359724952757581356787150982223137069297282952438962440225639443485944634025 ``` $Calculate$ $the$ $new$ $x-coordinates$ ``` x = 1127116604...
Trying to understand the LPN encryption in this paper: https://eprint.iacr.org/2021/120.pdf. From Definitions 4 and 5, ciphertext is $c=C\cdot s\oplus e\oplus G\cdot m$ and the paper says the LPN encryption scheme is both message homomorphic and key homomorphic, where $s$ is the secret key, $C$ and $G$ are two matrices...
We are doing symmetric Needham-Schroeder protocol in university. We were provided a modified protocol and needed to answer the following questions. **Original protocol:** [![enter image description here][1]][1] **Modified protocol:** [![enter image description here][2]][2] **Task** a) An attacker is an ac...
Can an attacker impersonate any party in a modified Needham-Schroeder protocol?
PKCS#12 contains 2 integrity protection modes: password-based and public-key based. The way this is done in the standard is that data layout wise it appears to be fine to skip integrity protection because the `macData` field (used for the password-based integrity mode) in the outer structure is OPTIONAL to make way for...
Is PKCS#12 structure without integrity protection against the specification?
How does the key generation of a homomorphic secret-sharing protocol works?
Nice question! Firstly, answering it directly: `So if a symmetric encryption algorithm is used, and both the end-user user and Obsidian's server know the symmetric key, how come they wouldn't be able to decrypt the data?` Yes, then server-side can decrypt the data. **But variable $\texttt{keyhash}$ (from files [v...
I've been thinking about creating strong and unique passwords for my online accounts, but I also want them to be memorable. I've come across the idea of using a memorable passphrase as the basis for a complex password generation. Specifically, I'm considering hashing the passphrase to generate the complex password, suc...
Given a point $nP = (x,y)$ on a curve $E$ over a prime $p$ I am interested in constructing the point $(x^{-1},y')$ when it exists where we take the modular inverse of the first coordinate. Here $n$ is a known quantity. Is anything known about this construction? It corresponds to calculating a reflected point $(u,v)...
Given a can we construct the modular inverse of a point on a curve?
Let's say we have a point $nP = (x,y)$ on a curve $E$ over a prime $p$. The corresponding Edwards curve coordinates are $(u,v)$. I want to construct the point corresponding to $(u,-v)$ on the Edwards curve. I can construct $(-u,-v)$ easily, that just amounts to $-nP$, flipping the $y$ coordinate. But I don't know ...
Let's say I have the following equation to be arithmetised in PLONK $x^3 + x + 5 = 35$ and the witness is $x = 3$ $3 * 3 = 9$ $9 * 3 = 27$ $27 + 3 = 30$ $30 + 5 = 35$ Now the 4th gate can be expressed as 1) $Q_l\cdot 30 + Q_r\cdot 5 + Q_m(30\cdot 5) + Q_c + Q_o\cdot(35)$ with $Q_l = 1, Q_r = 1...
I am trying to implement [Pei10](https://eprint.iacr.org/2010/088.pdf) and [BB13](https://eprint.iacr.org/2013/297.pdf), but I am confused about what concrete parameters to use. In Pei10, **Algorithm 1** takes a rounding parameter $r = \omega(\sqrt{\log n})$ as parameter, but it does not specify how to choose it con...
How Ciphers, specifically, Substitution Ciphers and Substitution Ciphers manipulate the Entropy of Plaintext w/wo the aid of Entropy Source? Reversely, how Decryption manipulates the entropy of Ciphertext?
From Entropy's perspective how Encryption affects a Message?
How Ciphers, specifically, Substitution Ciphers and Transposition Ciphers manipulate the Entropy of Plaintext w/wo the aid of Entropy Source? Reversely, how Decryption manipulates the entropy of Ciphertext?
The definition of Benaloh encryption scheme can be found [here][1]. Does exist an elliptic analogue of this scheme? I want to use this scheme but the length of the key is very big(like $2048$). If you can do something similar for elliptic curves it would be great. [1]: https://en.wikipedia.org/wiki/Be...
Does exist an Elliptic analogue of Benaloh encryption scheme?
If $P=(u,v)$ then $-P=(-u,v)$ Now it follows from addition law [here][1] that if we denote $Q=(0,-1)$(Q is some point of order $2$) then $P+Q=(-u,-v)$. It follows that $-(P+Q)=(u,-v).$ Is this what are you looking for? [1]: https://en.wikipedia.org/wiki/Edwards_curve
If $P=(u,v)$ then $-P=(-u,v)$ Now it follows from addition law [here][1] that if we denote $Q=(0,-1)$(Q is some point of order $2$) then $P+Q=(-u,-v)$. It follows that $-(P+Q)=-P+Q=(u,-v).$ Is this what are you looking for? [1]: https://en.wikipedia.org/wiki/Edwards_curve
In python we have: slope = 3*pow(x,2,p)*(2*y)^(-1) (see [this][1]) So > y=pow(3*pow(x,2,p)*pow(2 * slope, -1, p), 1, p) (pow(x, 1, p) is just $x \mod p$) [1]: https://gist.github.com/nlitsme/c9031c7b9bf6bb009e5a?permalink_comment_id=3909029
In python we have (see [this][1]): ``` python slope = pow(3 * pow(x, 2, p) * pow(2 * y, -1, p), 1, p) ``` So ``` python y = pow(3 * pow(x, 2, p) * pow(2 * slope, -1, p), 1, p) ``` pow(x, 1, p) is just $x \mod p$ Example ``` python p = 2**256 - 2**32 - 2**9 - 2**8 - 2**7 - 2**6 - 2**4 - 1 x = 112711660...
In python we have (see [this][1]): ``` python slope = (3 * pow(x, 2, p) * pow(2 * y, -1, p)) % p ``` So ``` python y = (3 * pow(x, 2, p) * pow(2 * slope, -1, p)) % p ``` Example ``` python p = 2 ** 256 - 2 ** 32 - 2 ** 9 - 2 ** 8 - 2 ** 7 - 2 ** 6 - 2 ** 4 - 1 x = 11271166043971060605674865917392967310...
I am trying to implement [Pei10](https://eprint.iacr.org/2010/088.pdf) and [BB13](https://eprint.iacr.org/2013/297.pdf), but I am confused about what concrete parameters to use. In Pei10, **Algorithm 1** takes a rounding parameter $r = \omega(\sqrt{\log n})$ as parameter, but it does not specify how to choose it con...
How Ciphers, specifically, One-time Pad Ciphers and Block Ciphers manipulate the Entropy of Plaintext w/wo the aid of Entropy Source? Reversely, how Decryption manipulates the entropy of Ciphertext?
How Ciphers, specifically, Substitution Ciphers and Transposition Ciphers manipulate the Entropy of Plaintext w/wo the aid of Entropy Source? Reversely, how Decryption manipulates the entropy of Ciphertext?
I would like to get a feeling on how the noise develops in different FHE schemes. So I ran some experiments using HElib for both BGV and CKKS. I wanted to look at the noise of a fresh public key and a fresh secret key ciphertext in both schemes. Curiously, in both schemes the noise I obtained was the same for public ke...
I need to test my server with `curl` 8.2.1 utility.<br/> My server works only with TLS1.3 and cipher 0x1302 - `TLS_AES_256_GCM_SHA384`.<br/> When I run `curl` it proposes many TLS ciphersuites that are not supported by my server (and TLS1.3) - for example (suites list of TLS-handshaking): 0xC028, 0xC027, 0xC014, 0xC0...
I need to test my server with `curl` 8.2.1 utility.<br/> My server works only with TLS1.3 and cipher 0x1302 - `TLS_AES_256_GCM_SHA384`.<br/> When I run `curl` it proposes many TLS ciphersuites that are not supported by my server (and TLS1.3) - for example (suites list of TLS-handshaking): 0xC028, 0xC027, 0xC014, 0xC0...
How Ciphers, specifically, Substitution Ciphers and Transposition Ciphers manipulate the Entropy of Plaintext w/wo the aid of Entropy Source? Reversely, how Decryption manipulates the entropy of Ciphertext? Link: https://crypto.stackexchange.com/questions/107869/from-entropys-perspective-how-a-message-was-affecte...
The most known example cipher reaching perfect secrecy is One-time Pad, which employs modulus addition for encryption and decryption. Is there any other **well-known** cipher **no less practical** than OTP that reachs perfect secrecy? * Note: Practical application is necessary. For extempore constructions, Se...
I have a function that generates a random 16 character length (upper + lower case letters plus numbers) seed password: ``` const crypto = require('crypto'); function generateRandomString() { const charset = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; const length = 16; const rand...
How large should a seed possibility space be to generate a secure ECDSA key pair?
**1. G known - how to decrypt** Referring to this question: https://crypto.stackexchange.com/questions/17708/basic-attacks-on-mceliece-finding-s-and-p (nobody answered) Take a McEliece cryptosystem with public generator matrix G′=SGP where G is a generator of a secret code with known fast decoding (not necessarily ...
It is possible to simply calculate the amount of possibilities and then take the $\log_2$ to get the number of bits that you are using. In this case that means $\log_2(62^{16}) \approx 95$. However, that is assuming that there is no bias in the chosen values. If you choose a value of 0..255 and you then take the mod...
I'm writing a simple small IP hash table on an FPGA for an ARP cache. On the FPGA I need to ensure I can very efficiently calculate the hash due the critical path of the circuit. I have a 32-bit input that I need to reduce to between 2- and 12-bit hash (Compile time configurable). I'm leaning on simply Xoring the bi...
Well, in this use case (rather than cases which need cryptographic hash functions), what you want is a hash function that, given the distribution of IP addresses you see, assigns each hash result about equally (that is, it acts similarly to if the mapping between IP addresses and ARP cache lines were random, even thoug...
I'm writing a simple small IP hash table on an FPGA for an ARP cache. On the FPGA I need to ensure I can very efficiently calculate the hash due the critical path of the circuit. I have a 32-bit input that I need to reduce to between 2- and 12-bit hash (Compile time configurable). I'm leaning on simply Xoring the bi...
It is possible to simply calculate the amount of possibilities and then take the $\log_2$ to get the number of bits that you are using. In this case that means $\log_2(62^{16}) \approx 95$. However, that is assuming that there is no bias in the chosen values. If you choose a value of 0..255 and you then take the mod...
Can this algorithm be called a RNG?
If g(x) if length preserving one way function, is there a scenario where h(x) := g(x)1...|x|−1 . I.e., h returns all bits that g returns, except for the last bit., is not a one way function. I think it has to be one way because the probability of inverse just doubles at most. If the probability of inverse is neglig...
Does removing just last bit from out put of one way function change its one wayness?