instruction stringlengths 15 30k |
|---|
For all $c_0\leftarrow m_0 \oplus k$ there exists a $k'$ such that $c_1 \leftarrow m_1 \oplus k'$, where $m_0 \neq m_1$ and $c_0 = c_1$.
Assuming a truly random $k$, the first assignment is a one-time pad. If we were to repeat the process over all $m \in M$, we would create a Stirling set of the first kind.
To ... |
Are you trying to prove this for a specific encryption scheme or for any scheme?
If you have a specific scheme in mind, you can consider using [rejection sampling](http://en.wikipedia.org/wiki/Rejection_sampling).
In your case, it would be quite straightforward to use :
Let's say each key $k\in \{0,1\}^n$ is out... |
For all $c_0\leftarrow m_0 \oplus k$ there exists a $k'$ such that $c_1 \leftarrow m_1 \oplus k'$, where $m_0 \neq m_1$ and $c_0 = c_1$.
Assuming a truly random $k$, the first assignment is a one-time pad. If we were to repeat the process over all $m \in M$, we would create a Stirling set of the first kind.
To ... |
I'm reading a [paper][1] here say:
> As we know, in hybrid PKE schemes XOR alone cannot perfectly hide
challenge bit to the CCA2 adversary
1.- the author not define hybrid PKE schemes, Could anybody with this definition?
2.-Why XOR alone cannot perfectly hide challenge bit to the CCA2 adversary in hybrid PKE ... |
I understand and have implemented elliptic curve signatures in Python without the use of libraries like Sage, and would like to implement the MOV attack against certain weak types of elliptic curves.
Even though I understand the mathematical notation and terms of group theory, I'm a programmer by trade, not a mathem... |
How can I implement the elliptic curve MOV attack myself? |
I understand and have implemented elliptic curve signatures in Python without the use of libraries like Sage, and would like to implement the MOV attack against certain weak types of elliptic curves.
Even though I understand the mathematical notation and terms of group theory, I'm a programmer by trade, not a mathem... |
I am having difficulty solving part (ii) of Excercise 5.17 from Becker's *Cipher Systems*.
> Exercise 5.17
$\quad$If $f(x),g(x)$ are any two polynomials over $GF(2)$ with $f(0)=g(0)=1$ show that
>
> 1. $\Omega(f)\cap\Omega(g)=\Omega((f,g))$
> 2. $\Omega(f)+\Omega(g)=\Omega([f,g])$.
It is easy to prove that ... |
How to prove this LFSR equation? |
When using Curve25519, the private key always seems to have a fixed bit set at position 2^254.
Why is that? Is there any good reason to use a fixed positioned most-significant-bit in the private key? |
When using Curve25519, why does the private key always have a fixed bit at 2^254? |
Did you take a look at DjB's [paper](http://cr.yp.to/ecdh/curve25519-20060209.pdf)?
One of his design criterias in order to improve performance is *"Use a fixed position for the leading 1 in the secret key"*.
The set of secret keys is defined to be $\{\underline{n} : n \in 2^{254} + 8\{0, 1, 2, 3,\ldots, 2^{251... |
Did you take a look at DjB's [paper](http://cr.yp.to/ecdh/curve25519-20060209.pdf)?
One of his design criterias in order to improve performance is *"Use a fixed position for the leading 1 in the secret key"*.
The set of secret keys is defined to be $\{\underline{n} : n \in 2^{254} + 8\{0, 1, 2, 3,\ldots, 2^{251... |
I'm reading a [paper][1] here say:
> As we know, in hybrid PKE schemes XOR alone cannot perfectly hide
challenge bit to the CCA2 adversary
1. The author does not define hybrid PKE schemes. What is their definition?
2. *Why* is it that XOR alone cannot perfectly hide challenge bit to the CCA2 adversary in hybr... |
I am having difficulty solving part (ii) of Excercise 5.17 from Becker's *Cipher Systems*.
> Exercise 5.17
$\quad$If $f(x),g(x)$ are any two polynomials over $GF(2)$ with $f(0)=g(0)=1$ show that
>
> 1. $\Omega(f)\cap\Omega(g)=\Omega((f,g))$
> 2. $\Omega(f)+\Omega(g)=\Omega([f,g])$.
It is easy to prove that ... |
I am having difficulty solving part (ii) of Excercise 5.17 from Becker's *Cipher Systems*.
> Exercise 5.17
$\quad$If $f(x),g(x)$ are any two polynomials over $GF(2)$ with $f(0)=g(0)=1$ show that
>
> 1. $\Omega(f)\cap\Omega(g)=\Omega((f,g))$
> 2. $\Omega(f)+\Omega(g)=\Omega([f,g])$.
It is easy to prove that ... |
I am having difficulty solving part (ii) of Excercise 5.17 from Becker's *Cipher Systems*.
> Exercise 5.17
$\quad$If $f(x),g(x)$ are any two polynomials over $GF(2)$ with $f(0)=g(0)=1$ show that
>
> (i) $\Omega(f)\cap\Omega(g)=\Omega((f,g))$
> (ii) $\Omega(f)+\Omega(g)=\Omega([f,g])$.
It is easy to prove ... |
I'm reading [Merkle tree signatures][1] and I like know if the security of the that scheme depends, also, of the high of the tree or only depends that hash function is resistant to collision?
[1]: http://en.wikipedia.org/wiki/Merkle_signature_scheme |
Does CBC encryption mode is vulnerable to reorder attack? |
I know that if using a CBC-MAC in a way that the tag is a concatenation of **all** the blocks' output (and not just the last one) it's insecure under CPA for the simplest case of 2 blocks CBC-MAC where:
message $m=m_1||m_2$ (where $|m_1|=|m_2|=$ blocksize),the tag $t=t_1||t_2$ such that:
$t_1 = F_k(m_1), t_2=F_k... |
Are you trying to prove this for a specific encryption scheme or for any scheme?
If you have a specific scheme in mind, you can consider using [rejection sampling](http://en.wikipedia.org/wiki/Rejection_sampling).
In your case, it would be quite straightforward to use :
Let's say each key $k\in \{0,1\}^n$ is out... |
I know that, if CBC-MAC is used in such a way that the tag is the concatenation of **all** the blocks' outputs (and not just the last one), it's insecure under CPA for the simplest case of 2 blocks CBC-MAC where:
* the message is $m=m_1\mathbin\|m_2$, where $|m_1|=|m_2|$ equals the block size of the cipher, and
* t... |
Is CBC mode encryption vulnerable to a reordering attack? |
Let:
- M be a message to encrypt
- R some fixed-length random data
- O a reversible random oracle *(meaning one can retrieve M if he knows O(M) by simply applying O^(-1))*
- K the secret key
- C the encrypted message
- || the concatenation operator
**Design:**
![draft][1]
**Encryption:**
- Pad M if ... |
Is the following symmetric design secure? |
Let:
- M be a message to encrypt
- R some fixed-length random data
- O a reversible random oracle on a finite set *(meaning one can retrieve M if he knows O(M) by simply applying O^(-1))*
- K the secret key
- C the encrypted message
- || the concatenation operator
**Design:**
![draft][1]
**Encryption:*... |
How does the length of the plaintext affect the cipher strength? |
I was given an encrypted file with it being encrypted with 128 bits AES and also this following parameters. And was to attack on the encryption file which has the following numbers
Encrypted file : 75524754087294054349005883401806206099062390114100949206213279097243496688139365482191804747436917319063449488005053930... |
Is it possible to perform RSA decryption if one only knows $N$ and $e$?
Failing that, what is the maximum key length where brute-force is still practically feasible? |
Is it possible to decrypt an RSA ciphertext with only $N$ and $e$? |
can someone help me with hill cipher
when i have to use :
1- 1x3 plain text matrix (p1, p2, p3) * 3x3 key matrix
2- 3x3 key matrix * 3x1 plain text matrix
Or they are both correct?
i tried to search but nothing usefull
thank you |
I study differential analysis and I got one question that haunts me. I look on very simple cypher. Plaintext (P1) xor with K1 then result goes to S-BOX then output of S-BOX xor with K2. This case is very simple. Using the main property of XOR we can get differential that independent from KEY. But how we can get such di... |
how to truncate a PRF on n bits to PRF on t bits where t < n? |
Can someone help me with a Hill cipher?
When do I have to use:
1. 1x3 plain text matrix (p1, p2, p3) * 3x3 key matrix
2. 3x3 key matrix * 3x1 plain text matrix
Or they are both correct?
I tried to search the internet, but found nothing useful. |
I am studying differential analysis and I got one question that haunts me.
Consider the following simple cipher:
$$c_1 = S(m_1 \oplus k_1) \oplus k_2$$
(Plaintext $m_1$ xor with key $K_1$, then result goes into an S-BOX, the output of which is xor'd with $K_2$). This case is very simple. Using the main property of... |
I am studying differential analysis and have a question.
Consider the following simple cipher:
$$c_1 = S(m_1 \oplus k_1) \oplus k_2$$
(Plaintext $m_1$ xor with key $K_1$, then result goes into an S-BOX, the output of which is xor'd with $K_2$). This case is very simple. Using the main property of XOR we can get di... |
Let the block length 64-bit, 256-bit key, cipher text accordingly - 64 bits. What is the strength of the block cipher, if any unknown attacks, which could reduce its strength. We can only brute force.
M - plaintexts, C- ciphertexts, K - keys
m є M, k є K, c є C; |M|=64, |C| = 64, |K| = 256
We get for some fix m є ... |
I've been reading Brakerski and Vaikuntanathan's [Efficient Fully Homomorphic Encryption from (Standard) LWE][1].
When the authors discuss a small modulus p used for the transition from (n, log q) to (k, log p), how 'small' are they talking about?
If a database has two data types - TEXT (character arrays) and INT... |
Let the block length 64-bit, 256-bit key, cipher text accordingly - 64 bits. What is the strength of the block cipher, if any unknown attacks, which could reduce its strength. We can only brute force.
Let $M=\{0,1\}^{64}$ be the plaintext space, $C=\{0,1\}^{64}$ be the ciphertext space and $K=\{0,1\}^{256}$ be the ... |
Let the block length 64-bit, 256-bit key, cipher text accordingly - 64 bits. What is the strength of the block cipher, if any unknown attacks, which could reduce its strength. We can only brute force.
Let $M=\{0,1\}^{64}$ be the plaintext space, $C=\{0,1\}^{64}$ be the ciphertext space and $K=\{0,1\}^{256}$ be the ... |
Let:
- O a reversible random permutation oracle on a finite set and O^(-1) the reverse permutation. Here, the attacker can call both O and O^(-1) on any input
- M be a fixed-length message to encrypt
- R some fixed-length random data, and is large enough that the number of oracle queries by the adversary must be m... |
Let:
- O a reversible random permutation oracle on a finite set and O^(-1) the reverse permutation. Here, the attacker can call both O and O^(-1) on any input
- M be a fixed-length message to encrypt
- R some fixed-length random data, and is large enough that the number of oracle queries by the adversary must be m... |
I'm looking for a function or set of function that can produce a unique hash of an index.
Given a set of $M$ values in range $0..M-1$, where $M$ is positive integer,
I need a function $I' = F(K,M,I)$, where $I$ is a value in range $0..M-1$, $K$ a key (to be determined) and $I'$ a value in range $0..M-1$.
For each ... |
I'm still a little unsure what your question is, but I'll try and answer what I think you're asking. If it isn't, please clarify your question or comment below.
Let us assume that $E_k$ is an ideal block cipher$^{[1]}$, and so acts like a random permutation of $2^{64}$ elements.
> Given $(m,c)\in M\times C$ fin... |
I'm still a little unsure what your question is, but I'll try and answer what I think you're asking. If it isn't, please clarify your question or comment below.
Let us assume that $E_k$ is an ideal block cipher$^{[1]}$, and so acts like a random permutation of $2^{64}$ elements.
> Given $(m,c)\in M\times C$ fin... |
I'm still a little unsure what your question is, but I'll try and answer what I think you're asking. If it isn't, please clarify your question or comment below.
Let us assume that $E_k$ is an ideal block cipher$^{[1]}$, and so acts like a random permutation of $2^{64}$ elements.
> Given $(m,c)\in M\times C$ fin... |
I'm looking for a function or set of function that can produce a unique hash of an index.
Given a set of $M$ values in range $0..M-1$, where $M$ is positive integer,
I need a function $I' = F(K,M,I)$, where $I$ is a value in range $0..M-1$, $K$ a key (to be determined) and $I'$ a value in range $0..M-1$.
For each ... |
Let:
- $O$ be a reversible random permutation oracle on a finite set and $O^{-1}$ the inverse permutation. Here, the attacker can call both $O$ and $O^{-1}$ on any input
- $M$ be a fixed-length message to encrypt
- $R$ some fixed-length random data, and is large enough that the number of oracle queries by the adve... |
**Assume:**
- $O$ be a reversible random permutation oracle on a finite set and $O^{-1}$ the inverse permutation. Here, the attacker can call both $O$ and $O^{-1}$ on any input
- $M$ be a fixed-length message to encrypt
- $R$ some fixed-length random data, and is large enough that the number of oracle queries by t... |
I'm looking for a function or set of functions that can produce a pseudo-random permutation on an input set of arbitrary size.
Given a set of $M$ values in range $0..M-1$, where $M$ is positive integer,
I need a function $I' = F(K,M,I)$, where $I$ is a value in range $0..M-1$, $K$ a key (to be determined) and $I'$ ... |
I'd like some advice on cryptography best practices. I need to store on my web app the users' credentials (login & password) for 3rd-party sites.
I'm using AES-256 with random key and initialization vector (provided by the Net 4.5 framework, if that's relevant), and store the encrypted data in completely different... |
Encoding multiple fields with same AES key and vector? |
I am wondering if it's possible to have a scheme as follows.
Here is the scenario:
- we have a set of objects (e.g. strings) {O1, O2, ..., On}
- we have a set of users {U1, U2, ..., Um}
- each user asks to compute a function over a subset of the objects
- we have an intermediate component A that must be ab... |
**Assume:**
- $O$ be a reversible random permutation oracle on a finite set and $O^{-1}$ the inverse permutation. Here, the attacker can call both $O$ and $O^{-1}$ on any input
- $M$ be a fixed-length message to encrypt
- $R$ some fixed-length random data. A new $R$ is generated every time you want to send a messa... |
I am wondering if it's possible to have a scheme as follows.
Here is the scenario:
- we have a set of objects (e.g. strings) {O1, O2, ..., On}
- we have a set of users {U1, U2, ..., Um}
- each user asks to compute a function over a subset of the objects
- we have an intermediate component A that must be ab... |
What scheme will allow merging and splitting the result of a function? |
**Assume:**
- $O$ be a reversible random permutation oracle on a finite set and $O^{-1}$ the inverse permutation. Here, the attacker can call both $O$ and $O^{-1}$ on any input
- $M$ be a fixed-length message to encrypt
- $R$ some fixed-length random data. A new $R$ is generated every time you want to send a messa... |
For a padded message, M, using the El Gamal encryption schema, how can we determine the random number $r$, when we are given $p$, the prime number, $g$ which is the primitive root of $p$, $b$ and $x$ which is the private key.
So the public key is $(g,b,p)$ where $b=g^x$ $mod$ $p$.
To encrypt, we compute: $y_1 = ... |
**No.**
You cannot use the same key and IV for more than one vector (with the most AES modes of operation). The only AES mode of operation which is (somewhat) resistant for IV reuse is [SIV][1].
For usual modes of operation like CBC, CTR, GCM, etc. reuse of Key+IV pair is a bad mistake. It is important to acknowle... |
I'm doing a code review for a crypto solution that reuses the same key with a constant IV. I want to demonstrate that this is not the right way to do things by figuring out the key and decrypting all of their test data.
* I have access to lots of ciphertext.
* I know the same key is used.
* I know the same IV is ... |
How to break AES/CBC/PKCS5 when key and IV are reused? |
I am wondering if it's possible to have a scheme as follows.
Here is the scenario:
- we have a set of objects (e.g. strings) {O1, O2, ..., On}
- we have a set of users {U1, U2, ..., Um}
- each user asks to compute a function over a subset of the objects
- we have an intermediate (trusted) component A that ... |
Suppose we are given $p$, the large prime, $g$ which is the primitive root for $p$, $b$ which is calculated as $b=g^x$ mod $p$ where $x$ is the private key and $0<x<p-1$.
Also suppose we know $y=g^r$ mod $p$ where $r$ is some random number and $0<r<p-1$ and is the discrete log of $y$. We also know $s=(M-x^y)(r^{-1})... |
I am wondering if it's possible to have a scheme as follows.
Here is the scenario:
- we have a set of objects (e.g. strings) {O1, O2, ..., On}
- we have a set of users {U1, U2, ..., Um}
- each user asks to compute a function over a subset of the objects
- we have an intermediate (trusted) component A that ... |
Merkle signature use than public key (to verify) the root of the Merkle Tree and than private key (to sign) the set of pre-images of the $g(Y_i)$ where $Y_i$ is the verification key of a choose One Time Signature. My question is What's is a trapdoor between these two keys? |
Why is a Trapdoor in Merkle Signature? |
Despite the fact that Marsaglia's MWC PRNG (multiply-with-carry random number generator) is considered to be *"the mother of all RNGs"*, it does not seem to be considered to be a CSPRNG (cryptographically secure pseudo-random number generator) even though it passes several statistical randomness tests, including *ENT* ... |
What is a Trapdoor in Merkle Signature? |
In his [writeup][1] of the Solitaire keystream generator algorithm, Bruce Schneier warns not to use the same key for two different messages:
> The first rule of an output-feedback mode stream cipher, any of them,
> is that you should never use the same key to encrypt two different
> messages. Repeat after me: NEVE... |
I'll do this backwards
>If a database has two data types - TEXT (character arrays) and INTEGER (4 or 8 byte integral values), will 'p' ever be 'small' enough to transform an INTEGER value in-situ or in place?
No. Homomorphic ciphertexts are still way to big to be stored in a 32 or 64 bit integer. You would likely... |
I started to implement some MAC since last week with the specifications given [here][1]. I'm currently testing the OMAC (one-key CBC) with [test vectors][2]. In the [OMAC specifications][3] at page 4, they explain how the padding works. Just below that, they said :
> [...] Where the empty string counts as one block.... |
I'm doing research about "Cryptographic attack methods in Web Application" so I have some questions to ask you guys:
1. Block Cipher vs Stream Cipher, which is more common used in Web Application?
2. How and Where is Stream Cipher implemented in Web Application?
Hope to get your response soon :) |
I know it sounds strange.. but, are there any ways in practice to put the hash of a PDF file in the PDF file? And after geting the hash in the PDF file - if someone would do a hash check of the PDF file, the hash would be the same as the one that is already in the PDF file? :) maybe with MD5, since it's known to have w... |
How to put the hash of a PDF file in the PDF file? |
I am wondering if it's possible to have a scheme as follows.
Here is the scenario:
- we have a set of objects (e.g. strings) {O1, O2, ..., On}
- we have a set of users {U1, U2, ..., Um}
- each user asks to compute a function over a subset of the objects
- we have an intermediate (trusted) component A that ... |
I think that it's more proper for your title to be named "Why hashing the shared value to get session key?" Next I'll answer your question in my understanding.
The basic problem is to establish a shared key between Lecturer and undergraduate office securely. In the original Diffie-Hellman key-exchange protocol, Al... |
Simple question: we have AES 128 encryption and a key. How can we calculate the key check value (KCV)?
One example: key is 48C3B4286FF421A4A328E68AD9E542A4 and KCV should be 77DC84.
I am trying it out in C#, but there are just to many 'unknowns' for a newbie in cryptography... |
Assume sender want to share his ephemeral/long-term public key with intended receiver only and both share symmetric key.
Is it ok to encrypt (full/partial) public key (of RSA, ECC) with shared symmetric key?
Is there any chance of finding symmetric key from encrypted public key?
If not why? |
is encrypting public key with symmetric key (password) safe? |
[Merkle signature][1] (pag. 40) use than public key (verification key) the root of the Merkle Tree and than private key (to sign) the set of pre-images of the $g(Y_i)$ where $Y_i$ is the verification key of a choose One Time Signature. My question is What's is a trapdoor between these two keys?
[1]: http://www.e... |
> Is there any chance of finding symmetric key from encrypted public key?
The answer is **no**, assuming the symmetric key has sufficient entropy and a secure encryption algorithm and mode is used correctly.
Modern ciphers like AES with proper secret keys are not vulnerable to known plaintext attacks.
Why?
... |
In the past year or so we have seen production of ASIC devices designed for mining of cryptocurrencies. These devices can perform SHA256 hashing at rates much higher than was seen in the past and are continually advancing in power. Can such devices be used to perform cryptanalysis instead of mining? Does this develop... |
Can cryptocurrency mining devices be used for cryptanalysis? |
Assume the sender wants to share their ephemeral/long-term public key with intended receiver only and both share symmetric key.
Is it secure to encrypt the (full/partial) public key (of RSA, ECC) with the shared symmetric key?
Is there any chance of finding symmetric key from encrypted public key?
If not why? |
Is encrypting a public key with a symmetric key safe? |
**Practicality:** Using a bitcoin miner for cryptanalysis would at the very least require you to write very low-level custom code. Indeed, depending on the precise hardware/software split used by the miner, it might well require modifying the actual hardware to facilitate your cryptanalytic attack. Anyway, let's suppos... |
**Practicality:** Using a bitcoin miner for cryptanalysis would at the very least require you to write very low-level custom code. Indeed, depending on the precise hardware/software split used by the miner, it might well require modifying the actual hardware to facilitate your cryptanalytic attack. Anyway, let's suppos... |
There has been lately a question on KCV (key check value), value provided by many CRYPTOKI (PKCS#11) implementations. I don't particularly like KCV, but I decided to ask about proper use of KCV.
This "KCV" (also known as CKA_CHECK_VALUE object attribute) value is derived as follows:
- For most objects: first th... |
**Practicality:** Using a bitcoin miner for cryptanalysis would at the very least require you to write very low-level custom code. Indeed, depending on the precise hardware/software split used by the miner, it might well require modifying the actual hardware to facilitate your cryptanalytic attack. Anyway, let's suppos... |
**Practicality:** Using a bitcoin miner for cryptanalysis would at the very least require you to write very low-level custom code. Indeed, depending on the precise hardware/software split used by the miner, it might well require modifying the actual hardware to facilitate your cryptanalytic attack. Anyway, let's suppos... |
> Is there any chance of finding symmetric key from encrypted public key?
The answer is **no**, assuming the symmetric key has sufficient entropy and a secure encryption algorithm and mode is used correctly.
Modern ciphers like AES with proper secret keys are not vulnerable to known plaintext attacks.
Why?
... |
I'm looking for a cryptographic technique that instead of permuting a cleartext, would add noise to the cleartext to obfuscate the true text among a bunch of garbage. For example, a list of 10 numbers would be combined with a list of 90 random ones with the goal of making the true set of numbers difficult to recover.... |
Is there a cryptographic method to add noise to a plaintext instead of actually encrypting it? |
**Assume**
- $S$ be a finite set
- $O$ be a random oracle from $S$ to $S$, such that $O$ is bijective
- $f$ be a random permutation of $S$
Is there is difference between $O$ and $f$?
Does it makes any difference if $S$ is not finite? |
What is the difference between a bijective random oracle and a random permutation? |
**Assume**
- $S$ be a finite set
- $O$ be a random oracle from $S$ to $S$, such that $O$ is bijective
- $f$ be a random permutation of $S$
Is there any difference between $O$ and $f$?
Does it makes any difference if $S$ is not finite? |
[By definition][1] - $q(n)$ is a negligible function if for every positive integer $c>0$ there exist an integer $N_c$ such that for all $x>N_c$ :
- $q(n)<1/x^c$
So for the function $1/x$, if we take the positive integer $c=1$ then we need to find some $N_c$ such that for every $x>N_c$:
- $1/x<1/x$
$=>$ D... |
Is $q(n)=1/n$ a negligible function? |
What is the impact of the distinguisher for the high-rate Goppa codes (published [here](http://hal.archives-ouvertes.fr/docs/00/77/60/68/PDF/MAYA2-UPMCINRIA-adist-2.0.pdf)) on the CFS signature scheme and the McEliece/Niederreiter cryptosystems?
It seems that the distinguisher strongly affects the CFS scheme, forcin... |
What is the impact of the distinguisher for the high-rate Goppa codes (as published in "[A Distinguisher for High Rate McEliece Cryptosystems](http://hal.archives-ouvertes.fr/docs/00/77/60/68/PDF/MAYA2-UPMCINRIA-adist-2.0.pdf)") on the CFS signature scheme and the McEliece/Niederreiter cryptosystems?
It seems that t... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.