instruction stringlengths 15 30k |
|---|
I've a couple of questions about this, the scenario is embedding a key pair in a hardware device which will speak with other hardware devices over tls. computing resources are an issue so i want to make intelligent choices about where they go on. We're using TLS to authenticate one device to another, and to ensure in... |
RSA key length choice for TLS when confidentiality not important? |
Consider a KPA attack, where the attacker gets known plain text and the corresponding cipher text. Since the encryption algorithm is known, he can brute force all possibilities of key bits. **What is the implication of having additional tweak on brute forcing the algorithm**?
Is this correct to say that now the atta... |
In a sense, you are correct in not understanding where the equations in DSA and ElGamal signatures come from. To a certain extent, they are just (distinct) choices from a family of equations that all seem to work, and all for the same-ish reasons. See e.g. Meta-ElGamal signature schemes by Patrick Horster, Holger Peter... |
In a sense, you are correct in not understanding where the equations in DSA and ElGamal signatures come from. To a certain extent, they are just (distinct) choices from a family of equations that all seem to work, and all for the same-ish reasons. See e.g. Meta-ElGamal signature schemes by Patrick Horster, Holger Peter... |
So I have a very beginner-esque knowledge of ECDSA and I'm trying to write something in python to take a private key and output the public key (Basically from what I understand just trying to do the point multiplication k number of times on the basepoint) to get a better understanding.
These are my two main resource... |
The arithmetic done during a point addition is done using the addition and multiplication operations in the field; when you are using a prime field, that is equivalent to doing addition and multiplication modulo the prime (23 in this case).
Now, because we're doing the arithmetic modulo 23, we get to notice that $14... |
1.
To clarify: The critical time period here is one year (after wich the certs are changed). With the cracked RSA key the attacker can decrypt the traffic and do nan-in-the-middle attacks, posing as a valid hardware device.
Let us take the numbers determined [by experts][1]. In their paper on cracking the 768-bit R... |
Here is the protocol outline I am looking at ([source][1])
>$$
\begin{array}{ccl}
1.& A \to S \colon& A,B,N_a
\\ 2.& S \to A \colon&
\left\{ N_a,B,K_{ab},\{K_{ab},A\}_{K_{bs}} \right\}_{K_{as}}
\\ 3.& A \to B \colon&
\{K_{ab},A\}_{K_{bs}}
\\ 4.& B \to A \colon&
\{N_... |
Why have Nonce and why encrypt everything in step 2 for Needham-Schroeder? |
Here is the protocol outline I am looking at ([source][1])
>$$
\begin{array}{ccl}
1.& A \to S \colon& A,B,N_a
\\ 2.& S \to A \colon&
\left\{ N_a,B,K_{ab},\{K_{ab},A\}_{K_{bs}} \right\}_{K_{as}}
\\ 3.& A \to B \colon&
\{K_{ab},A\}_{K_{bs}}
\\ 4.& B \to A \colon&
\{N_... |
I've been exploring around, trying to understand if such thing is even possible. I have some RC4 ciphertext which I know it's plaintext and I would like to extract the key just from cipher and plaintext. While reading through "RC4 Stream Cipher and it's variants" by Goutam Paul I came a cross (4.1.1) PRGAreverse algori... |
Say I hashed the output from a random number generator (with nonce), would the resulting SHA256 hash be as random as the inputted number?
And If I used the first 5 hex characters, and then used the first 5 ignoring the very first character and so on repeating removal of the first character, would each number be just... |
Are the SHA family hash outputs practically random? |
Recently I started studying ECC and I just loved it. I want to transfer some big data (like 3KB), What is the best method, ECDSA, ECIES, or ECDH (and why)?
I am confused, how should I choose between ECDSA, ECIES and ECDH?
Appreciate your help.
Thanks.
|
I am researching some concepts of practical 2 party computation and was curious if anyone could point me to a research paper that is focused on private set intersection where one party has a very large set and the other has a comparatively small set.
I found this [paper][1] that appears to be a breakthrough in perfo... |
So I have a very beginner-esque knowledge of ECDSA and I'm trying to write something in python to take a private key and output the public key (Basically from what I understand just trying to do the point multiplication k number of times on the basepoint) to get a better understanding.
My two main resources are the ... |
There's a classical method to efficiently test if a [LFSR][1] with $n$ bits is maximal-length (or equivalently, if the feedback polynomial is [primitive][2]), when the factorization of $2^n-1$ is known.
Do we have an efficient method working when that factorization is unknown? E.g. for $n=2991$ ($2^{2991}-1$ is the ... |
Maximal-length LFSR with $n$ bits when the factorization of $2^n-1$ is unknown? |
Here is the protocol outline I am looking at ([source][1])
>$$
\begin{array}{ccl}
1.& A \to S \colon& A,B,N_a
\\ 2.& S \to A \colon&
\left\{ N_a,B,K_{ab},\{K_{ab},A\}_{K_{bs}} \right\}_{K_{as}}
\\ 3.& A \to B \colon&
\{K_{ab},A\}_{K_{bs}}
\\ 4.& B \to A \colon&
\{N_... |
I am researching some concepts of practical 2 party computation and was curious if anyone could point me to a research paper that is focused on private set intersection where one party has a very large set and the other has a comparatively small set. Specifically, a user has a small set and the server has a large set.... |
I don't have much background in cryptography, so forgive me if I'm using the wrong mathematical terms to explain my needs.
Following [this question](http://crypto.stackexchange.com/questions/8087/sha256-hmac-brute-force-with-chosen-plaintext-attacks), I learned that taking a random secret 16-bytes `password` and som... |
> Say I hashed the output from a random number generator (with nonce), would the resulting SHA256 hash be as random as the inputted number?
Let's suppose you flipped a perfectly fair coin. You flip it 1024 times to create a bit string of 1024-bits.
Because the coin is perfectly fair, this means that each strings... |
I am researching some concepts of practical 2 party computation and was curious if anyone could point me to a research paper that is focused on private set intersection where one party has a very large set and the other has a comparatively small set. Specifically, a user has a small set and the server has a large set.... |
For observe who has not seen the inputs to SHA-256, the output should appear uniformly random sequence.
Quite a few random number generators, for example ANSI X9.31's RNG and NIST SP 800-90 Hash_DRBG use SHA family hash functions for the reason that resulting sequence is hard to distinguish from random.
----
>... |
I don't have much background in cryptography, so forgive me if I'm using the wrong mathematical terms to explain my needs.
Following [this question](http://crypto.stackexchange.com/questions/8087/sha256-hmac-brute-force-with-chosen-plaintext-attacks), I learned that taking a random secret 16-bytes `password` and som... |
I don't have much background in cryptography, so forgive me if I'm using the wrong mathematical terms to explain my needs.
Following [this question](http://crypto.stackexchange.com/questions/8087/sha256-hmac-brute-force-with-chosen-plaintext-attacks), I learned that taking a random secret 16-bytes `password` and som... |
> I assume AESCrypt uses AES.
AEScrypt uses AES-256 in CBC mode. However, the program also uses SHA-256.
> When a file is encrypted with AEScrypt, there is no limit to the length of the password.
The Linux implementation of AEScrypt limits password to 1024 characters. This means: it is practically unlimited, ... |
I don't have much background in cryptography, so forgive me if I'm using the wrong mathematical terms to explain my needs.
Following [this question](http://crypto.stackexchange.com/questions/8087/sha256-hmac-brute-force-with-chosen-plaintext-attacks), I learned that taking a random secret 16-bytes `password` and som... |
I don't have much background in cryptography, so forgive me if I'm using the wrong mathematical terms to explain my needs.
Following [this question](http://crypto.stackexchange.com/questions/8087/sha256-hmac-brute-force-with-chosen-plaintext-attacks), I learned that taking a random secret 16-bytes `password` and som... |
It is very hard to estimate time it takes for attacker to brute-force password.
This is because HMAC-SHA256 can be calculated billions of times per second on some devices, and there are some devices existing which take millisecond to calculate one HMAC.
BTW, I understood that password is actually a 128-bit cryptog... |
It is very hard to estimate time it takes for attacker to brute-force password.
This is because HMAC-SHA256 can be calculated billions of times per second on some devices, and there are some devices existing which take millisecond to calculate one HMAC.
BTW, I understood that password is actually a 128-bit cryptog... |
It is very hard to estimate time it takes for attacker to brute-force password.
This is because HMAC-SHA256 can be calculated billions of times per second on some devices, and there are some devices existing which take millisecond to calculate one HMAC.
BTW, I understood that password is actually a 128-bit cryptog... |
For example: for secure PRG `G` if I have a `G'` s.t. `G'(k) = G(k)||0`, is `G'` necessarily secure? This question is not for the above example only but for any other possibilities as well. My thinking is that since `G` is secure (ADV is negligible and PRG is unpredictable), then no matter what I do with `G` to make `G... |
If G is a secure PRG and G' is a function of G, is G' secure? |
Hint: Consider the function $G'(k) = f(G(k))$, where $f(x) = 0$ for all $x$. Clearly, $G'$ is a function of $G$. Is $G'$ a secure PRG? |
There's a classical method to efficiently test if a [LFSR][1] with $n$ bits is maximal-length (or equivalently, if the feedback polynomial is [primitive][2]), when the factorization of $2^n-1$ is available.
Do we have an efficient method working when that factorization is unavailable, e.g. because we do not want to ... |
Maximal-length LFSR with $n$ bits when the factorization of $2^n-1$ is unavailable? |
I have some difficulties to understand why we are using finite fields in cryptography.
finite fields are used a lot on cryptography but i don't really know why?
why do we use field? why not ring or group?
is that really necessary that the field is finite? why not real field?
thank you |
is it possible to use other structure that finite fields? |
One does not always use finite fields in cryptography. [RSA](http://en.wikipedia.org/wiki/RSA_(algorithm)) for instance is based on
residue class rings, [discrete logartihm](http://en.wikipedia.org/wiki/Discrete_logarithm) based cryptosystems work on suitable
additive/multiplicative groups.
Why one uses finite fi... |
One does not always use finite fields in cryptography. [RSA](http://en.wikipedia.org/wiki/RSA_(algorithm)) for instance is based on
residue class rings, [discrete logartihm](http://en.wikipedia.org/wiki/Discrete_logarithm) based cryptosystems work on suitable
additive/multiplicative groups but these are also finite r... |
I'm trying to use a [java implementation of ed25519][1] for transaction and block signatures of an open source cryptocurrency that I'm currently writing.
In the code, I can't find any functions that generate keys.
My experience with cryptography is limited to about three weeks of asking questions on stack.
Doe... |
I'm trying to use a [java implementation of ed25519][1] for transaction and block signatures of an open source cryptocurrency that I'm currently writing.
In the code, I can't find any functions that generate keys.
My experience with cryptography is limited to about three weeks of asking questions on stack.
Doe... |
I have some difficulties to understand why we are using finite fields in cryptography. Finite fields are used a lot on cryptography but I don't really know why.
Why do we use field? Why not ring or group? Is that really necessary that the field is finite? Why not real field?
|
I have some difficulties to understand why we are using finite fields in cryptography.
Why do we use field? Why not ring or group? Is that really necessary that the field is finite? Why not real field?
|
Is it possible to use structures other than finite fields? |
My question is barely simple I guess but I didn't found out the answer so far.
What is the difference between a CBC-MAC and a CMAC ?
Thank you in advance for your help. |
According to [Wikipedia](//en.wikipedia.org/wiki/CMAC), CMAC is based on a variation of CBC-MAC and fixes some security deficiencies in it. However, I could not find a simple and clear explanation of what the differences between the two algorithms actually are, so I thought I'd ask here:
How does CMAC differ from C... |
I am researching some concepts of practical 2 party computation and was curious if anyone could point me to a research paper that is focused on private set intersection where one party has a very large set and the other has a comparatively small set. Specifically, a user has a small set and the server has a large set.... |
Is there way to make encryption scheme ASIC and GPU resistant, besides using a lot of *memory*?
And what is there ciphers or modes of use for such purpose? Including public keys algorithms maybe too, if there is any methods for them.
Or it's only worth to defend *key derivation function*? (Like *scrypt*, but it o... |
Methods of making ASIC/GPU resistant encryption? |
Is there way to make encryption scheme ASIC and GPU **resistant**, besides using a lot of *memory*?
And what is there ciphers or modes of use for such purpose? Including public keys algorithms maybe too, if there is any methods for them.
Or it's only worth to defend *key derivation function*? (Like *scrypt*, but ... |
Cascading cipher gives a sense of security; and one that is technically justified with respect to the possibility that a weakness in one of the cipher would allow recovering the encrypted data. That's Bruce Schneier's argument, and it made sense in an era where DES, the then leading cipher, was a closed design, clearly... |
Cascading cipher gives a sense of security; and one that is technically justified with respect to the possibility that a weakness in one of the cipher would allow recovering the encrypted data. That's Bruce Schneier's argument, and it made sense in an era where DES, the then leading cipher, was a closed design, clearly... |
For what kind of usage should we prefer using Diffie Hellman in order to exchange keys instead of Elgmal, and most important why should we use one or the other ? I do not see a clear difference between these two algorithms. What are their respective advantages ? |
This might be a quite stupid question: since a naive brutal force algorithm to solve discrete logarithm problem will only take ```O(n)``` time for Group G with order n. Why is it assumed to be hard to solve? Doesn't hard mean no polynomial algorithm to solve in the context of cryptography? |
Why discrete logarithm problem is assumed to be hard? |
Is there way to make encryption scheme ASIC and GPU **resistant**, besides using a lot of *memory*?
And what is there ciphers or modes of use for such purpose? Including public keys algorithms maybe too, if there is any methods for them.
Or it's only worth to defend *key derivation function*? (Like [*scrypt*](htt... |
Is there way to make encryption scheme ASIC and GPU **resistant**, besides using a lot of *memory*?
And what is there ciphers or modes of use for such purpose? Including public keys algorithms maybe too, if there is any methods for them.
Or it's only worth to defend *key derivation function*? (Like [*scrypt*](htt... |
Is there way to make encryption scheme ASIC and GPU **resistant**, besides using a lot of *memory*?
And what is there ciphers or modes of use for such purpose? Including public keys algorithms maybe too, if there is any methods for them.
Or it's only worth to defend *key derivation function*? (Like [*scrypt*](htt... |
[Diffie Hellman](http://en.wikipedia.org/wiki/Diffie-Hellman_key_exchange) is a key exchange protocol. It is an **interactive** protocol with the aim that two parties can compute a common secret which can then be used to derive a secret key used for some symmetric encryption scheme.
I take the notation from the lin... |
A recent paper by Göloğlu, Granger, McGuire, and Zumbrägel: [Solving a 6120-bit DLP on a Desktop Computer][1] seems to "demonstrate a practical [DLP][2] break in the finite field of $2^{6120}$ elements, using just a single core-month". They credit a 2012 paper by Antoine Joux: [Faster index calculus for the medium prim... |
If we want to establish secret symmetric key between two entities, why use Needham-Schroeder if we have Diffie-Hellman? With DH we don't need to have any trusted party, so what's the point of NS? |
Why use Needham-Schroeder if we have Diffie-Hellman? |
Am studying AES. I have a lots of doubts in "mixcolumn" stage.
i read about finite field, still i don't know
1) how to construct GF(2^8)?
2)01010011 * 11001010 = 10001110 -> this is the original answer which i saw in a text. i multiplied both numbers then i got 011111101111110 . Now i know i should divide it w... |
At the beginning of [OCB's white paper](http://www.cs.ucdavis.edu/~rogaway/papers/ocb-full.pdf) [pdf], OCB is compared to other modes, and non-malleability is one of the properties advertised.
At the end of the paper, it is mentioned the MAC length can be chosen by users according to their needs.
Was long MACs as... |
Is OCB with short MAC malleable? |
I'm studying AES. I have a lots of doubts in "mixcolumn" stage.
I read about finite field, still i don't know
1. how to construct $GF(2^8)$?
2. `01010011 * 11001010 = 10001110` -> this is the original answer which i saw in a text. i multiplied both numbers then i got `011111101111110` . Now I know I should div... |
This might be a quite stupid question: since a naive brute force algorithm to solve discrete logarithm problem will only take ```O(n)``` time for a group G with order n, why is it assumed to be hard to solve? Doesn't hard mean no polynomial algorithm to solve in the context of cryptography? |
Why is the discrete logarithm problem is assumed to be hard? |
This might be a quite stupid question: since a naive brute force algorithm to solve the discrete logarithm problem will only take ```O(n)``` time for a group G with order n, why is it assumed to be hard to solve? Doesn't hard mean no polynomial algorithm to solve in the context of cryptography? |
Why is the discrete logarithm problem assumed to be hard? |
[Diffie Hellman](http://en.wikipedia.org/wiki/Diffie-Hellman_key_exchange) is a key exchange protocol. It is an **interactive** protocol with the aim that two parties can compute a common secret which can then be used to derive a secret key used for some symmetric encryption scheme.
I take the notation from the lin... |
For what kind of usage should we prefer using Diffie-Hellman in order to exchange
<br>
keys instead of Elgamal, and most important why should we use one or the other?
<br>
I do not see a clear difference between these two algorithms. What are their respective advantages? |
When I want to encrypt chat messages (in ascii) before sending, whether it brings some bit of security if I add some extra bytes to the message or shuffle it in some way? I can even try to make data to look like uniform distribution.
Because chat messages consist only of letters and even words, but don't contain bin... |
Do I need to prepare plain text before encryption? |
I assume you've read [this section](http://en.wikipedia.org/wiki/Finite_field_arithmetic#Rijndael.27s_finite_field), and hopefully had a look at the 'C Example' just below it, which has comments to walk you through the maths.
---------------
### What is Rijndael's finite field?
Rijndaels finite field is $F=\ma... |
### What is Rijndael's finite field?
Rijndaels finite field is $F=\mathrm{GF}(2^8)$ with minimal polynomial $f(x)=x^8 + x^4 + x^3 + x + 1$. Formally, we have $F=\mathbb F_2[x] / (f)$ but don't worry about that. So what does this mean?
Well, elements of $F$ should be thought of as polynomials over $\mathbb{F}_2$, ... |
### What is Rijndael's finite field?
Rijndaels finite field is $F=\mathrm{GF}(2^8)$ with minimal polynomial $f(x)=x^8 + x^4 + x^3 + x + 1$. Formally, we have $F=\mathbb F_2[x] / (f)$ but don't worry about that. So what does this mean?
Well, elements of $F$ should be thought of as polynomials over $\mathbb{F}_2$, ... |
### What is Rijndael's finite field?
Rijndaels finite field is $F=\mathrm{GF}(2^8)$ with minimal polynomial $f(x)=x^8 + x^4 + x^3 + x + 1$. Formally, we have $F=\mathbb F_2[x] / (f)$ but don't worry about that. So what does this mean?
Well, elements of $F$ should be thought of as polynomials over $\mathbb{F}_2$, ... |
### What is Rijndael's finite field?
Rijndaels finite field is $F=\mathrm{GF}(2^8)$ with minimal polynomial $f(x)=x^8 + x^4 + x^3 + x + 1$. Formally, we have $F=\mathbb F_2[x] / (f)$ but don't worry about that. So what does this mean?
Well, elements of $F$ should be thought of as polynomials over $\mathbb{F}_2$, ... |
I'm studying AES, and am having problems with the "mixcolumn" stage.
I read about finite fields, but I still don't know.
1. How do I construct $GF(2^8)$?
2. `01010011 * 11001010 = 10001110` -> this is the original answer which i saw in a text. i multiplied both numbers then i got `011111101111110` . Now I know... |
As Stephen already said in his answer, if you use a modern secure encryption scheme, then you do not have to worry about the confidentiality of the messages.
However, as you say your application is a chat the following part of your question
> if I add some extra bytes to the message
seems to be a valid (althou... |
I was just thinking about my own chance and the way chance can defeat even the most advanced algorithm.
My thought was : you can make a strong session id, but what if by chance, a hacker set this exact match up ?
hypothetical : 454{à"_çé89)hjdsHHKZmdsjYds"#
just try to imagine that someone, by typing a nonsens... |
<i>So what can crypto propose against chance ?</i>
Nothing, an infinite number of monkeys typing at random at a keyboard in infinite time will retrieve any password. See http://en.wikipedia.org/wiki/Infinite_monkey_theorem. So surely there's a chance, practically negligible but not impossible. |
The Arduino employs an 8-bit ATmega series microcontroller whereas the Raspberry Pi is based around a 32-bit ARM processor, and the Arduino is typically clocked at between 8-16MHz and with 2-8kB of RAM available, and in contrast the Raspberry Pi can be clocked at up to 1GHz and may have up to 512MB of RAM.
This clea... |
The probability of someone 'getting lucky' with a guess at a key for a decent cryptosystem is crazily low, but yes: it is possible. However, there are methods that can 'survive' even this.
For example, consider the [one time pad](http://en.wikipedia.org/wiki/One-time_pad). In this system the key and plaintext are x... |
The probability of someone 'getting lucky' with a guess at a key for a decent cryptosystem is crazily low, but yes: it is possible. However, there are methods that can 'survive' even this.
For example, consider the [one time pad](http://en.wikipedia.org/wiki/One-time_pad). In this system the key and plaintext are x... |
What is the time to complexity to solve
Discrete log problem now in $Z_p$?
Initially for $n$ bit prime $p$, it was $Exp(n^{1/3})$. |
The NIST elliptic curves P-192, P-224, P-256, P-384, and P-521, prescribed in [FIPS 186-4][1] appendix D.1.2, are generated according to a well defined process, but using an arbitrary random-looking seed value of 160 bits. For this reason [a page of DJB's website][2] calls them
> **Manipulatable**: The curve-generat... |
Is there a feasible method by which NIST ECC curves over prime fields could be intentionally rigged? |
In principle, it is theoretically possible to calculate the time it takes a machine to run some known algorithm.
It used to be fairly commonplace, but there are apparently very few people who have ever done it -- the sorts of things that used to require isochronous code are now-a-days generally done in other ways.
... |
This has been basically asked already: [Should we trust the NIST recommended ECC parameters?][1]
History
-----
Once it was found that NSA allegedly had inserted backdoor to a cryptographic standard, people started thinking what standard it was.
The most common guess is that the Dual EC DRBG is the backdoored ... |
It is possible to check $a \in \mathrm{QR}_p \text{ iff } a(p-1)/2 = 1\ (\bmod\ p)$ if $p$ is a prime.
$n$ is a large RSA modulus. Is it also possible to check if $a \in \mathrm{QR}_n$ if the factorization of $n$ is unknown?
|
Posssible to check if $\in \mathrm{QR}_n$? |
It is possible to check $a \in \mathrm{QR}_p \text{ iff } a^{(p-1)/2} \equiv 1\ (\bmod\ p)$ if $p$ is a prime.
$n$ is a large RSA modulus. Is it also possible to check if $a \in \mathrm{QR}_n$ if the factorization of $n$ is unknown?
|
> It is possible to check $a \in \mathrm{QR}_p \text{ iff } a^{(p-1)/2} \equiv 1\ (\bmod\ p)$ if $p$ is a prime.
Yes, you have already written down the check, which is known as [Euler's criterion](http://en.wikipedia.org/wiki/Euler's_criterion).
> $n$ is a large RSA modulus. Is it also possible to check if $a \in... |
> It is possible to check $a \in \mathrm{QR}_p \text{ iff } a^{(p-1)/2} \equiv 1\ (\bmod\ p)$ if $p$ is a prime.
Yes, you have already written down the check, which is known as [Euler's criterion](http://en.wikipedia.org/wiki/Euler's_criterion).
> $n$ is a large RSA modulus. Is it also possible to check if $a \in... |
> When I want to encrypt chat messages (in ascii) before sending,
> whether it brings some bit of security if I add some extra bytes to
> the message or shuffle it in some way? I can even try to make data to
> look like uniform distribution.
I recommend to encode your plaintext with base64 before encrypting it. T... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.