instruction stringlengths 15 30k |
|---|
Quote from Wiki:
> e <the public key exponent> having a short bit-length and small Hamming weight results in more efficient encryption – most commonly 216 + 1 = 65,537. However, much smaller values of e (such as 3) have been shown to be less secure in some settings.
Does this mean that it is secure to choose the ... |
Quote from Wiki:
> $e$ having a short bit-length and small Hamming weight results in more efficient encryption — most commonly $2^{16} + 1 = 65537$. However, much smaller values of $e$ (such as $3$) have been shown to be less secure in some settings.
Does this mean that it is secure to choose the smallest possibl... |
The current way of implementing a (symmetric) cryptographic algorithm as a white-box is to implement it as a network of encoded lookup tables (a good white-box will also have so called 'external encodings' applied, but I'll skip these for now).
In this case however, a network of tables is not required (one table wil... |
If a wise person was unsure about which commercial cryptography standards are [truly secure][1] from [the fascist powers that be][2], it would seem the obvious option for companies and individuals is to now use two independent algorithms to encrypt. To be clear I am not talking about a cascade cipher in CBC mode e.g. $... |
This question is a follow-up/variant on a previous [question](http://crypto.stackexchange.com/questions/22404/how-bad-would-it-be-to-reuse-the-random-blinding-factor-in-a-scheme-like-paillie).
Supposing that we are trying to generate a *large* number of (indistinguishable) ciphertexts of a given plaintext and want t... |
I am exploring the use of Windows CNG to replace some OpenSSL-based code that takes advantage of AES in counter mode. From the outside, everything should look the same after the switch.
The section `BCRYPT_CHAINING_MODE` in [this piece of CNG documentation](http://msdn.microsoft.com/en-us/library/windows/desktop/aa3... |
Can AES in CCM or GCM counter mode interoperate with AES in "plain" counter mode (CTR)? |
I have been reading around protocol specification and there is either too much technical detail or too bad articles on various sites.
I need you to explain in simple words how encryption in bitmessage works and what are main security flaws of bitmessage and why?
To be more detailed with with my question I want to... |
How does bitmessage encryption work? |
I am trying to encrypt big files using NaCL (actually PyNaCL) -
After reading some docs, I came up with this prototype :
- generate a random nonce that will be used for every encryption
- read the file chunk by chunk (size: 4096 bytes)
- for each chunk, update an SHA256 hash **
- encrypt the chunk using c... |
http://eprint.iacr.org/2015/030 present several attacks of ASCON but does not have a conclusion section.
I'm having troubles estimating what are the consequences on the use of ASCON. What's your opinion about it ? |
Is ASCON cipher broken? |
I need some help with hash value calculation.
I am a bit confused by this statement that I found on w3 website on calculation of a DigestValue for xmldsig ( http://www.w3.org/TR/2002/REC-xmlenc-core-20021210/Overview.html#sha256 ):
> A SHA-256 digest is a 256-bit string. The content of the DigestValue
> element s... |
I'm new to cryptography and am most intrigued by mathematically based pseudo random number generators. With reference to the Blum Micali algorithm:
Xi+1 = G^Xi % P
can security be reduced to a simple stated seed size? I've seen claims that a 20 digit seed was sufficient to pass diehard test.
I've also read ana... |
Do you want to know the answer or do you want to know the process? I can give you both. Also, I have to post this as an answer because I don't have enough repuation to comment. I will edit this answer with your response. |
Pollard's Rho is usually constructed using a function $f:G \rightarrow G$ which behaves 'random enough' in order to detect a collision with Floyd's cycle detection trick. It is easy enough to observe, however, that a uniformly random distribution on $\mathbb{Z}/n\mathbb{Z} \times \mathbb{Z}/n\mathbb{Z}$ induces a unifo... |
Im curious about the security of rsa signing with same public private key pair when the same message is sent multiple times. Its my understanding that once you generate the hash of the message you wish to send, that you then sign this message with your rsa private key, then transfer both this signed hash and the origin... |
Two semi-honest parties are computing F with Yao's garbled circuit. Sender garbles it with his inputs baked in then sends it to the receiver. At this point the receiver must use OT to get his keys. What happens if OT breaks and the receiver gets both keys for every wire? It's not clear to me that this would break the s... |
What if OT breaks in Yao's garbled circuit? |
I am exploring the use of Windows CNG to replace some OpenSSL-based code that takes advantage of AES in counter mode. From the outside, everything should look the same after the switch.
The section `BCRYPT_CHAINING_MODE` in [this piece of CNG documentation](http://msdn.microsoft.com/en-us/library/windows/desktop/aa3... |
I was reading http://blog.zorinaq.com/?e=74 which is about a Windows kernel developer. The developer proves that he is an actual developer by posting the SHA1 hash of a particular revision of a file. The actual hash values have been redacted, but I would like to know how knowledge of the hash would prove this. |
I am trying to figure out how the HMAC SHA-256 hashing algorithm works. I know that we have to use the following:
H (K ^ opad)|| H ((K ^ ipad)|| text)).
The problem that I am facing is I think of basic understanding of the above. As far as I know, SHA-256 takes in **character input**. The key that I am using is o... |
I'm trying to make my way in Functional Encryption used for access control.
I read a lot of papers such as ["How to Run Turing Machines on Encrypted Data"][1], ["Functional Encryption: New Perspectives and Lower Bounds"][2], or ["Attribute-based encryption for circuits"][3] and I ended up with a feeling of uncertain... |
In Laravel (a PHP framework) I can see that they calculate [a HMAC with a random key over the final HMAC before comparison](https://github.com/laravel/framework/blob/v4.2.16/src/Illuminate/Encryption/Encrypter.php#L158). This additional HMAC calculation is of course performed for both the calculated MAC and the receive... |
I am trying to figure out how the HMAC SHA-256 hashing algorithm works. I know that we have to use the following:
H (K ^ opad)|| H ((K ^ ipad)|| text)).
The problem that I am facing is I think of basic understanding of the above. As far as I know, SHA-256 takes in **character input**. The key that I am using ... |
In Laravel (a PHP framework) I can see that they calculate [a HMAC with a random key over the final HMAC before comparison](https://github.com/laravel/framework/blob/v4.2.16/src/Illuminate/Encryption/Encrypter.php#L158). This additional HMAC calculation is of course performed for both the calculated MAC and the receive... |
For Bitcoin's ECDSA k1 curve (which I'm most familiar with, where a=0, b=7), why can't the generator point be x=0?
Ie y^2 = (0)^3 + 7
|
I am trying to encrypt big files using NaCL (actually PyNaCL) - see http://nacl.cr.yp.to/box.html
After reading some docs, I came up with this prototype :
Bob wants to send a big file to Sarah. They both have a public/private key pair.
- set "position" to 0
- for each 256ko file chunk
- generate a ra... |
I'm new to cryptography and am most intrigued by mathematically based pseudo random number generators. With reference to the Blum Micali algorithm:
$X_{i+1} = G^{X_i} \bmod P$
can security be reduced to a simple stated seed size? I've seen claims that a 20 digit seed was sufficient to pass diehard test.
I've a... |
I'm curious about the security of RSA signing with the same public private key pair when the same message is sent multiple times. It's my understanding that once you generate the hash of the message you wish to send, that you then sign this message with your RSA private key, then transfer both this signed hash and the ... |
For Bitcoin's ECDSA curve (secp256k1, where $a=0$, $b=7$), why can't the generator point's first coordinate be $x=0$?
That is, the point on the curve would be $(0,y)$ where $y$ satisfies $y^2 = 0^3 + 7=7$.
Are there any elements other than $0$ which can't be used as a generator point's $x$ coordinate?
|
Why are some $x$ coordinates unsuitable for an ECDSA generator point? |
So I have two examples and I don't understand why one would be chosen over the other.
Example 1.
A sends `EPUb[r1]` to B (asks B to prove knowledge of `PRb`)
B replies with `r1, EPUa[r2]` (asks A to prove knowledge of `PRa`)
A replies with `r2` to prove it
Example 2.
A sends `r1` to B (asks B to prove knowled... |
Why should I use X.509 Authentication over PKC based Authentication? |
This is something with which I am struggling to get my head around.
In Feldman's VSSS, I am aware that the Dealer broadcasts exponentials $a_{1},...,a_{t-1}$ of the secret $K$ and the coefficients in the secret polynomial of Shamir's SSS. The users can then combine this information with their knowledge of the publi... |
In differential privacy solutions and more specifically for queries that they do entail counting the proposed solutions define the laplace distribution that is best calibrated for low error. Other solutions for non-numerical queries propose exponential distribution. However it is not clear why noise from laplacian dist... |
There are two ways for key change:
- *Key update*, and;
- *Re-keying*.
Which of these methods use **KDF** (Key Derivation Function) for getting new keys? |
There are two ways for key change: key update, and Re-keying.
Which of these methods use a KDF (Key Derivation Function) for getting new keys? |
The AEAD construction for chacha20-poly1305 described in the IETF proposal [1] encodes message lengths into the text that is to be hashed. The newer proposal [2] goes further and pads associated data and plaintext to multiples of 16 bytes.
Can anyone explain what the purpose of that is? The chacha20-poly1305 impleme... |
As per [Wikipedia][1], RSA keygen goes like this:
- Choose two distinct prime numbers p and q.
- Compute n = pq.
- Compute φ(n) = (p − 1)(q − 1)
- Choose an integer e such that 1 < e < φ(n) and e and φ(n) are coprime. e is released as the public key exponent.
- Determine d as d ≡ e^−1 (mod φ(n)); i.e., d is th... |
RSA Key generation: How is multiplicative inverse computed? |
If I implement EMSA-PKCS1-v1_5 in the following two non-standard ways, what kind of things could go wrong?
The padding structure will be referred as (00|01|PS|00|DER(Digest Algo)|Digest), where | is concatenation and DER is DER encoding of an ASN.1 value of type DigestInfo:
DigestInfo ::= SEQUENCE {
d... |
I'm a little bit confused about the design of a RSA module in VHDL. My question isn't directly related to hardware design. I've read a lot of publications and I bought also a book. In one publications I've found 2 different Montgomery algorithms. The first works in $GF(p)$, where $p$ is the module ( so the inputs have... |
I'm a little bit confused about the design of a RSA module in VHDL. My question isn't directly related to hardware design. I've read a lot of publications and I bought also a book. In one publications I've found 2 different Montgomery algorithms. The first works in $GF(\hspace{.04 in}p)$, where $p$ is the modulus (so ... |
In the [Bernstein _et al._ paper about EdDSA](http://ed25519.cr.yp.to/ed25519-20110926.pdf), the authors claim EdDSA is resilient against collisions (i.e. it can still be secure even if the hash function used isn't collision-resistant), drawing on a [result](http://www.neven.org/papers/schnorr.pdf) from Neven _et al._ ... |
As per [Wikipedia][1], RSA keygen goes like this:
- Choose two distinct prime numbers p and q.
- Compute $n = pq$.
- Compute $\phi(n) = (p − 1)(q − 1)$
- Choose an integer e such that $1 < e < \phi(n)$ and $e$ and $\phi(n)$ are coprime. $e$ is released as the public key exponent.
- Determine $d$ as $d \equiv e... |
As per [Wikipedia][1], RSA keygen goes like this:
- Choose two distinct prime numbers p and q.
- Compute $n = pq$.
- Compute $\varphi(n) = (p − 1)(q − 1)$.
- Choose an integer e such that $1 < e < \varphi(n)$ and $e$ and $\varphi(n)$ are coprime. $e$ is released as the public key exponent.
- Determine $d$ as $... |
I've allready replied to the question posted some days before. Montgomery multiplication is another way to perform modular multiplication in the residue system representation. The operation induced is in fact a group morphism.
In GF(p), p prime, or in the multiplicative group $Z/nZ$, the transformation allows to perfo... |
In context of [Groth-Sahai NIZK proof system][1], I have a couple of doubts on Hiding and Binding keys.
![enter image description here][2]
1. In case of hiding keys (highlighted in red), how is it ensured that $\tau(A) \subseteq \langle u_1,...u_m \rangle$?
2. In case of binding keys (highlighted in green), ho... |
Currently I am designing a RSA based application, and I am thinking of how long should the key be in order to be secure against attacks. I know that RSA 4096 bit key can be recovered using [enter link description here][1] but it is not practical. Brute Force is impossible unless if quantum computer is available with th... |
I am wondering if Windows provides an equivalent of /dev/urandom from linux ? Or any kind of system entropy pool ? |
Is there a kind of OS entropy pool on Windows systems? |
I'm wondering if it is still secure.
I know TrueCrypt closed its doors but I continue using it because the cryptoaudit didn't find any huge bugs or security issues in TrueCrypt.
But I have a bad feeling about Brute Force and Ripemd-160. I've read that it only uses 3000 Iterations. So I ask myself: How long would ... |
In the first decade of the 21th century, and counting, on a given $\text{year}$, no RSA key bigger than $(\text{year} - 2000) \cdot 32 + 512$ bits has been openly factored other than by exploitation of a flaw of the key generator (a pitfall [observed][1] in poorly implemented devices [including Smart Cards][2]). This l... |
In the first decade of the 21th century, and counting, on a given $\text{year}$, no RSA key bigger than $(\text{year} - 2000) \cdot 32 + 512$ bits has been openly factored other than by exploitation of a flaw of the key generator (a pitfall [observed][1] in poorly implemented devices [including Smart Cards][2]). This l... |
In the first decade of the 21th century, and counting, on a given $\text{year}$, no RSA key bigger than $(\text{year} - 2000) \cdot 32 + 512$ bits has been openly factored other than by exploitation of a flaw of the key generator (a pitfall [observed][1] in poorly implemented devices [including Smart Cards][2]). This l... |
Currently I am designing an RSA based application, and I am thinking of how long should the key be in order to be secure against attacks. I know that RSA 4096 bit key can be recovered using [Sound Pattern attack][1] yet it is not practical. Brute Force is impossible unless if a quantum computer is available with the cl... |
I understand that ECB does not hide data patterns well. BUt my understanding is that it cannot be bronken to "know" the underlying message. If that was the case, why cant ECB be used with some obfuscation technique like say XORing with the address? I am talking about data stored in DDR - and assume it is not an image d... |
I understand that BEAST is a CPA using javascript injected onto the browser's webpage. Apparently the thing that BEAST exploits is the fact that the IVs are predictable. What I'm confused about is why this is a problem when IVs are public anyway?
i'm looking at the first answer here:
http://crypto.stackexchange.co... |
IN NETWORK SECURITY ENCRYPTION AND INTEGRITY DONE BY SAME ALGORITHM THAT IS AES-CCM ALGORITHM IN THAT MIC GENERATE BY CBC-MAC AND ENCRYPTION DONE BY CTR MODE.SO SUPPOSE I WANT TO DO ENCRYPTION WITH ANY STREAM CIPHER ALGORITHM AND FOR INTEGRITY PURPOSE SOME HASHING MECHANISHAM LIKE H-MAC CAN WE USED SEPERATELY? |
> Aren't $IV_1$ and $IV_2$ public in TLS 1.2 as well?
$IV_1$ certainly is (as that's just the ciphertext block in front of the block we're attacking); however the IV that the TLS 1.2 sender will use for the next message ($IV_2$) is not. In fact, the sender might not know it yet, as it might not have not picked it y... |
In network security, encryption and integrity done by the same algorithm that is AES-CCM in that MIC generated by CBC-MAC and encryption done by CTR mode. So suppose I want to do encryption with any stream cipher algorithm, can I use some hashing mechanism like HMAC separately for integrity purposes? |
I need to encrypt transmission between my device (with AVR processor) and base. I create packet data - it will be encrypted into string:
PacketData {
int packetN;
string data;
CRC16 checksum;
string nextKey;
}
As you can see, key will be changing after each packet.
First,... |
Is RC4 +XOR secure for small data? |
I am looking for a way to securely encrypt files on Mac and Debian. OpenSSL comes pre-installed on Mac OSX and Debian/Ubuntu. Therefore, is this a safe/recommended way of encrypting individual files? (or gzipped folders?)
openssl aes-256-cbc -a -e -salt -in "$2" -out "$2.aes"
and then decrypting them later:
... |
Secure way to encrypt and decrypt a folder on Mac or Linux? |
I am looking for a way to securely encrypt files on Mac and Debian. OpenSSL comes pre-installed on Mac OSX and Debian/Ubuntu. Therefore, is this a safe/recommended way of encrypting individual files? (or gzipped folders?)
openssl aes-256-cbc -a -e -salt -in "foo" -out "foo.aes"
and then decrypting them later:... |
I know that I need to analyse bigrams etc and have worked out th, he, er, in and have worked out where th and he correspond to in my grid, but now I am stumped!
Can I get any advice please? I have looked at the Solution to Polygraphic Substitution Systems field manual that is supposed to help me according to my goog... |
I am looking for a way to securely encrypt files on Mac and Debian. OpenSSL comes pre-installed on Mac OSX and Debian/Ubuntu. Therefore, is this a safe/recommended way of encrypting individual files? (or gzipped folders?)
openssl aes-256-cbc -a -e -salt -in "foo" -out "foo.aes"
and then decrypting them later:... |
Consider a bilinear pairing $e: G_1 \times G_2 \rightarrow G_T$. Let's assume, $G_1 = G_2 = G_T = (\mathbb{Z}_n,+)$, i.e. additive group of integer modulo $n$ and $e(x,y) = xy$ mod $n$. Isn't it an example of bilinear map?
$G_1 = G_2 = G_T = (\mathbb{Z}_n,\ast)$, i.e. multiplicative group of integer modulo $n$ and $... |
Is it an example of bilinear pairing? |
In RFC 1320, It is stated that "A 64-bit representation of b (the length of the message before the padding bits were added) is appended to the result of the previous step. In the unlikely event that b is greater than 2^64, then only the low-order 64 bits of b are used. (These bits are appended as two 32-bit words and a... |
Why the data length is shifted 3-bit in MD4 Java implementation? |
Have you tried [eCryptfs](http://ecryptfs.org)? It's the default encryption method of home folder in Ubuntu. You should give a try! |
Consider a bilinear pairing $e: G_1 \times G_2 \rightarrow G_T$. Let's assume, $G_1 = G_2 = G_T = (\mathbb{Z}_n,+)$, i.e. additive group of integer modulo $n$ and $e(x,y) = xy$ mod $n$. Isn't it an example of bilinear map?
$G_1 = G_2 = G_T = (\mathbb{Z}_n,\ast)$, i.e. multiplicative group of integer modulo $n$ and $... |
I have a set of Playfair-enciphered data that I'm trying to crack without the key. I know I need to analyse bigrams; I've currently worked out what decrypts to `th`, `er`, `in`, and `he`, and have figured out where `th` and `he` are in the grid. However, now I'm stumped.
I've looked at the "Solution to Polygraphic S... |
How does cryptanalysis of the Playfair cipher work? |
Commonly, one uses multiplicative groups. When recall definition of a pairing, it must be bilinear, non degenerate, and easily computable.
Note that the definition of e(x,y)=x.y can be interpreted as a external product. (x.y = y+...+y: n-times) and not as the internal group law.
I agree with Maeher's answer. The fi... |
I've read everywhere online and people say plain text RSA is very unsafe. To make it safe you pad it but no examples are shown anywhere on how to do it. It's explained that random data is added to the encryption process to change up the final encryption so it can't be guessed at random by comparison to similar looking ... |
How does RSA padding work exactly? |
I understand that by definition one-time-pad keys cannot be reused but I was thinking about the case where it is used to send random data and couldn't find anything on the subject so here is my idea:
Sending y-bits of data using x-bits of random data as a key where y > x.
Step 1: Both parties agree on a x-bits ke... |
I used to figure that message authentication codes function like digital signatures: a hash of a message is calculated and then encrypted with a secret key. To verify the authenticity of a message, the recipient calculates the hash of the message, decrypts the MAC with the secret key, and compares the two. I have not s... |
is it a good idea to use global values as nonce / additional data? What problems
can occur?
What should be take in account when we deal with such parameters for encryption.
Thanks |
Security aspects of using a global values as nonce and additional data for AES? |
On wikipedia there is an example of a picture encrypted with ECB:
http://en.wikipedia.org/wiki/Block_cipher_mode_of_operation#Electronic_codebook_.28ECB.29
I just wanted to know how an encrypted file could be displayed as a picture ? |
[This answer](http://stackoverflow.com/a/10290712/195130) recommends authenticating the IV with HMAC when using AES and then HMAC.
Since AES-GCM provides authentication too, should the external nonce passed to GCM be authenticated separately when passing over network? If not, why not? If it should be what is the rec... |
Should the nonce passed to GCM be authenticated? |
What are the main security issues for integrating AAA and OTP services. In our organization with about 1000 clients, we want to integrate the services. What are the main security issues about the protocols used? In fact, we must choose between a number of suggested proposals. |
Note: I have now answered this by my own research and can generate random fields up to G(2^9) in reasonable time. I would need to find more speedups for larger fields. At this time G(2^8) takes a few seconds and G(2^9) takes a few hours (it varies widely depending on my generation options). If anyone is interested I wi... |
Modular inverse can be computed with Extended Euclidian Algorithm, as other answers suggest.
I will answer your second question - why an attacker can't get private key? The problem here is that private exponend is modular inverse of public one, but modulo $\phi(n)$, not $n$:
$d \equiv e^{-1} \pmod{\phi(n)}$
At... |
This question is not really well defined. If by "Would this actually work?" you mean "Will this be as good as using a one time pad of length y" then the short answer is **No**. Anything susceptible to a brute force attack is not as secure as a one time pad.
What are you trying to achieve? If you already agreed on a ... |
> Should the external nonce passed to GCM be authenticated separately when passing over network?
No, that is not necessary; it is implicitly authenticated by GCM itself, pretty much as the AAD is also authenticated. That is, if someone in the middle modifies the nonce, then that will alter the authentication tag th... |
Assume an ideal hash function of output size `n` bits, detecting one collision requires approximately `2^(n/2)` evaluations of the hash function using a birthday attack.
However, how many evaluations are required to produce two or more collisions? |
How much work is required to detect multiple collisions for a hash function? |
Here's something that is bugging me recently: suppose that me and my friend establish an OTR session and - as a result of that - DH key exchange is performed. My friend verifies my key, but I cannot verify his fingerprint. Despite that, we have a secure channel over which he can send me one bit of information - whether... |
Is it possible to perform one-way Diffie-Hellman MITM? |
Wikipedia lists the following conditions for a prime to be strong:
$p-1$ has large prime factors. That is, $p = a_1 q_1 + 1$ for some integer $a_1$ and large prime $q_1$.
$q_1-1$ has large prime factors. That is, $q_1 = a_2 q_2 + 1$ for some integer $a_2$ and large prime $q_2$.
$p+1$ has large prime factors. T... |
Assume an ideal hash function of output size `n` bits, detecting one collision requires approximately `2^(n/2)` evaluations of the hash function using a birthday attack.
However, how many evaluations are required to produce two or more collisions?
*Note* I am talking about distinct collisions i.e. $H(A)=H(B)$, $H... |
Such a block cipher would be completely unusable in any of the standard modes of operation, presuming you want at least IND-CPA security. Say, for instance, that you are using it in CTR mode. A chosen plain text adversary looking at a cipher text consisting of only two blocks (i.e. 2 times 32 bits), would have a non-ne... |
Such a block cipher would be completely unusable in any of the standard modes of operation, presuming you want at least IND-CPA security. Say, for instance, that you are using it in CTR mode. A chosen plain text adversary looking at a cipher text consisting of only two blocks (i.e. 2 times 32 bits), would have a non-ne... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.