instruction
stringlengths
15
30k
The bits are not independent from each other, at least within an individual song, so the pad is not truly random, thus this is not a one-time-pad. Perhaps a hash-based approach would fix this, but... ... there are a limited number of songs available, a simple attack would then be to enumerate every song (in the same...
The bits are not independent from each other, at least within an individual song, so the pad is not truly random, thus this is not a one-time-pad. Perhaps a hash-based approach would fix this, but... ... there are a limited number of songs available, a simple attack would then be to enumerate every song (in the same...
OpenSSL private key format, for RSA, follows the ASN.1 syntax given at the end of [PKCS#1][1] (the structure is then encoded with DER, then Base64, and PEM header and footer lines are added). This is easy if you know these formats, but, in practice, you will be happier if using a library which does the encoding for you...
I was reading the paper $[1]$ and came across the scheme that I show below. While I understand the scheme well, I don't understand why they prepend a 0 to the block containing $r$ and a 1 to all other blocks. What is achieved by this? They never explain why they do it. Here is the scheme as presented in the paper: !...
I'm just interested in cryptography, so please don't expect me to be an expert. ;) I recently read about AES cache timing attacks and found it very interesting. I read this (cr.yp.to/antiforgery/cachetiming-20050414.pdf) article, but I don't seem to understand everything. 1. How relevant is this to "real-life" netwo...
IV is called an initialization vector because it is the first vector. The next vectors are the cipher text blocks. And guess what: all of them are send in plain. So what again are you trying to achieve by simply encrypting the very first one? Answer only valid for particular blockcipher encryption modes (most import...
I'm just interested in cryptography, so please don't expect me to be an expert. ;) I recently read about AES cache timing attacks and found it very interesting. I read [this](http://cr.yp.to/antiforgery/cachetiming-20050414.pdf) article (Cache-timing attacks on AES from dr. Bernstein), but I don't seem to understand ev...
I'm just interested in cryptography, so please don't expect me to be an expert. ;) I recently read about AES cache timing attacks and found it very interesting. I read [the article "Cache-timing attacks on AES" from dr. Bernstein](http://cr.yp.to/antiforgery/cachetiming-20050414.pdf), but I don't seem to understand eve...
Ok hypothetical scenario. Lets say I want to generate a lot of key material quickly for a one-time pad. This key material will be divided up and used for many different messages in the future. **1)** I select 50-100+ songs out of a custom playlist of all my music. The music has been converted to basic Waveform Audio...
Does a playlist of songs or movies mixed together contain enough random enough for OTP key material?
In the case of password storage, consider the following: I have an idea that one can exhaust the entropy of input to the MD5 function by using a 128 bit random value as the password. Is this a correct assumption, or is the entropy exhausted at 123.4 bit, this being the best attack to date? Or does this only apply to...
In the case of password storage, consider the following: I have an idea that one can exhaust the entropy of input to the MD5 function by using a 128 bit random value as the password (indeed, any hash function, using the output length as input). Is this a correct assumption, or is the entropy exhausted at 123.4 bit, ...
I read [the article "Cache-timing attacks on AES" from dr. Bernstein](http://cr.yp.to/antiforgery/cachetiming-20050414.pdf), but I don't seem to understand everything. The author dedicates a long section on how to prevent the OS to interrupt an AES computation. But how does this leak any information? Yes, the calculati...
I'm designing a messaging system where the sender *A* sends a message *m* with a signature *s* to *n* Receivers. A Receiver *Ri* should then be able to prove to a Verifier *V* that he is one of the receivers of the message without disclosing *m* and the identity of the other receivers. He will however disclose *A* ...
I'm designing a messaging system where the sender *A* sends a message *m* with a signature *s* to *n* Receivers. A Receiver *Ri* should then be able to prove to a Verifier *V* that he is one of the receivers of the message without disclosing *m* and the identity of the other receivers. He will however disclose *A* ...
I'm trying to figure out block ciphers and this is the first time I've encountered the term "oracle adversary". It appears in the context of defining a PRP and a PRF. Can someone please explain what an "oracle adversary" can/cannot do? Or maybe help out with a link or something (I've tried looking it up myself, but I c...
What is an oracle adversary?
I need to generate a 1024 bit ElGamal key on Android, and key generation takes forever (~10 minutes on a Galaxy Nexus), I suspect because it take so long to generate a safe prime. Is it dangerous for me to use the same safe prime p for all devices using my app? Where can I find a list of 1024 bit and 2048 bit saf...
What's a good P to use in ElGamal key generation?
I read the paper [Cache-timing attacks on AES](http://cr.yp.to/antiforgery/cachetiming-20050414.pdf) (by Daniel J. Bernstein), but I don't seem to understand everything. The author dedicates a long section on how to prevent the OS to interrupt an AES computation. But how does this leak any information? Yes, the calcula...
Stopping timing attacks on AES: Why is it important to prevent the OS from interrupting the AES computation?
I'm just interested in cryptography, so please don't expect me to be an expert. ;) I recently read about AES cache timing attacks and found it very interesting. I read the article [Cache-timing attacks on AES](http://cr.yp.to/antiforgery/cachetiming-20050414.pdf) by Daniel Bernstein, but I don't seem to understand ever...
The paper explains why. This is part of the defense against cache-based timing attacks. Let me sketch the argument for you: * The early part of the paper explains that if the time is variable, then it introduces a risk of timing attacks. Sections 3-6 demonstrate that such an attack is practically feasible. * T...
The paper explains why. Preventing the OS from interrupting the AES computation is part of Bernstein's proposed method of defense against cache-based timing attacks. Let me sketch the argument for you: * The early part of the paper explains that if the time is variable, then it introduces a risk of timing attacks....
I know that you can use for example CBC-MAC to verify data integrity and thus the password upon decryption. But would there be security implications of just adding a constant string to the plaintext and if the first block is identical upon decryption we know the key was correct?
Security implications of using constant string to verify AES key?
In Alice/Bob/Cindy terms: Alice and Bob have each securely obtained half of an RSA keypair from a trusted third party. Alice has one half, Bob has the other. The RSA algorithm technically does not care which of the two keys is used to encrypt and which to decrypt; therefore, Alice uses her half to encrypt a message ...
Weakness in using only one RSA key pair for two-way communication?
In Alice/Bob/Cindy terms: Alice and Bob have each securely obtained one key of an RSA keypair from a trusted third party. Alice has one key, Bob has the other. The RSA algorithm technically does not care which of the two keys is used to encrypt and which to decrypt; therefore, Alice uses her key to encrypt a message...
The question and comments seem to be asking the following: If an implementation of RSA is used in the following way, is it still secure? An RSA modulus $N = pq$ and exponent $e$ are generated, and (N,e) is given to Party $A$ and $(p,q,e)$ is given to Party $B$. Then, the parties encrypt their communication where Par...
I have a question about random number generators. I have read from a real random number generator, based on a webcam ("randcam"). My problem is, that I do not really understand how the generation of the random numbers works. Has anyone heard of this principle before and can give some hints how it could be implement...
The paper explains why. Preventing the OS from interrupting the AES computation is part of Bernstein's proposed method of defense against cache-based timing attacks. Let me sketch the argument for you: * The early part of the paper explains that if the time is variable, then it introduces a risk of timing attacks....
Here is one way for a Receiver Ri to prove to Verifier V that it received some message m from Alice, and is therefore a member of a the set of people who directly received that message m from Alice, without disclosing the message m or the identity of any other Receiver. Alice and R7 ------------ Alice composes...
I read briefly over the TSL/SSL key exchange protocol. I have to wonder about the whole pre-master-key procedure. Wouldn't it be sufficient if the client or server encrypted a generated session key with the other sides public key? Why the extra work?
You could try this : 1. Of your first login, the client can send to the server E(hash(password),n) with ku [public key of server] The server can decrypt and store the nth hash of the hash value. 2. From then on, the client can generate the (n-1)th hash of the password and send it, along with a tag encrypted wit...
I need to generate a 1024 bit ElGamal key on Android, and key generation takes forever (~10 minutes on a Galaxy Nexus), I suspect because it take so long to generate a safe prime. Is it dangerous for me to use the same safe prime p for all devices using my app? Where can I find a list of 1024 bit and 2048 bit saf...
Ok hypothetical scenario. Lets say I want to generate a lot of key material quickly for a one-time pad. This key material will be divided up and used for many different messages in the future. **1)** I select 50-100+ songs out of a custom playlist of all my music. The music has been converted to basic Waveform Audio...
No. As far as I can tell, this does not appear to produce a bent sequence. (Or, if it does, that fact requires proof/justification.) According to Wikipedia, a "bent sequence" is a sequence of the form $(-1)^{f(x_0)}, \dots, (-1)^{f(x_{2^n-1})}$ where $x_0,\dots,x_{2^n-1}$ is the sequence of $n$-bit values in lexic...
I'm designing a messaging system where the sender *A* sends a message *m* with a signature *s* to *n* Receivers. A Receiver *Ri* should then be able to prove to a Verifier *V* that he is one of the receivers of the message without disclosing *m* and the identity of the other receivers. He will however disclose *A* ...
Authentication protocols often rely on humans dealing with large numbers correctly. For example, when a user logs into a remote machine using SSH for the first time, she is prompted to confirm that the fingerprint of the server is the expected fingerprint. The user can phone the owner of the server, and confirm that th...
Is there any research on the problem of making a number more memorable to humans?
Here is one way for a Receiver Ri to prove to Verifier V that it received some message m from Alice, and is therefore a member of a the set of people who directly received that message m from Alice, without disclosing the message m or the identity of any other Receiver. Alice and R7 ------------ Alice composes...
Lets say an application is using CBC mode without authentication. The application is generating cipher text. This cipher text can be manipulated by the attacker and then transmitted back to the application. Without looking at the code. What is an easy method of proving that a Padding Oracle or Decryption Oracle ...
What is an easy method of proving that a cryptographic oracle is present?
A quick web search showed me this german page [Zufallszahlen aus der Webcam][1] ("random numbers from the web cam). (All other hits on the first Google result page are about an unrelated [Pistonless rotary engine][2]). This page speaks about a program available from the same site, which tries to gather entropy from ...
Lets say an application is using CBC mode without authentication. The application is generating cipher text. This cipher text can be manipulated by the attacker and then transmitted back to the application. Without looking at the code. What is an easy method for the attacker to prove that a Padding Oracle or Dec...
In Alice/Bob/Cindy terms (EDIT: and with a little more detail): Alice and Bob have each securely obtained one key of an RSA keypair from a trusted third party. Alice has one key ($e$ and $n$), Bob has the other ($d$ and $n$, where $d\equiv e^{-1} (mod\ \phi(n))$). The RSA algorithm technically does not care whic...
So if I want to encrypt all the files in a folder with AES (same password) I take each file and generate the key schedule using PBKDF2. As the PBKDF2 algorithm takes in a salt then this salt should change (and thus the keyschedule) for each new file being encrypted. Now if I want to decrypt then I load the plaintext sa...
I look forward to seeing more research on ways of representing cryptographically significant numbers in ways that are easier for humans to memorize or use in other ways. memorizing and typing ---------- There are several ways to bidirectionally convert a series of completely random bits into a series of English ...
The _Input Parameter_ in the question is called a _Label_ in [PKCS#1v2.1][1]; this [standard][2] states it might be empty, or be expressed in some specified syntax. I borrow Victor Shoup's explanation from Remark 3 in this [paper][3]: > A _label_ is a byte string that is effectively bound to the ciphertext > in a n...
My question relates to the original KP-ABE paper: http://research.microsoft.com/en-us/um/people/vipul/abe.pdf I'm having trouble understanding the proof (pages 10–13) that the scheme is secure in the Selective Set Model: >Proof: Suppose there exists a polynomial-time adversary A, that can attack our scheme i...
I am a novice programmer and am just finishing up an RSA encryption program that I am writing for practice. Currently I have the program generate a relatively small random value for the public key e. When adding the finishing touches, I realized that there was no point for e to be random. Is this thinking correct?
In RSA encryption, does the value of e need to be random?
RSA-OAEP is IND-CCA2 secure. Does it also have the INT-CTXT & INT-PTXT properties ? I don't believe that IND-CCA2 implies this. Is it true for RSA-OAEP though ? Thanks.
RSA-OAEP is IND-CCA2 secure. Does it also mean it has the integrity and authenticity properties?
RSA-OAEP is IND-CCA2 secure (indistinguishable under an adaptive chosen ciphertext attack). Does it also have the INT-CTXT (integrity of ciphertext) and INT-PTXT (integrity of plaintext) properties? I don't believe that IND-CCA2 implies these. Are they true for RSA-OAEP though?
Does RSA-OEAP has integrity and authenticity properties?
Given an authenticated mode of encryption, when comparing a plaintext string against the contents of a ciphertext, which approach is typically considered safer? 1. Encrypt the plaintext and compare against the ciphertext, or 2. Decrypt the ciphertext and compare against the plaintext in $O(n)$ The former appea...
Does RSA-OEAP have integrity and authenticity properties?
I'd like to understand a bit more about the AES key schedule if anyone would mind explaining that. For instance, why is the way the schedule generated (with recursive xors and occasional substitutions) more secure than say, using pbkdf2 on the key, then using it on the result, and on until there is enough data? The ...
How can I add more rounds to AES?
I have a client-server application, which is transferring data between its components in a secure way. I currently use AES algorithm with CBC mode to transfer data and file. This is the scenario: Client ask for data(file or plaintext), server takes the request and encrypt data with a iv/key pair and sends encrypted dat...
In a Non-Interactive $Zero-Knowledge-Proof$, the challenge is chosen by the Prover. I am trying to find a Non-Interactive Zero-Knowledge-Proof based on the following problem: DISCRETE LOGARITHM Input: Prime number $p$, generator $g$ of $Z^{*}_{p}$ , and $y\in Z^{∗}_{p}$ . Question: Is there $x \in \lbrace1...
Non-Interactive Zero-Knowledge-Proof for discret Logarithm?
In a Non-Interactive $Zero-Knowledge-Proof$, the challenge is chosen by the Prover. I am trying to find a Non-Interactive Zero-Knowledge-Proof based on the following problem: DISCRETE LOGARITHM Input: Prime number $p$, generator $g$ of $Z^{*}_{p}$ , and $y\in Z^{∗}_{p}$ . Question: find $x \in \lbrace1, . ...
I have some problems in understanding the "advantage" of AES-XTS compared to CBC with diffuser. I read something about [FileVault][1], in this paper they mention the two modes of operations XTS and CBC (with diffuser) and the advantages of XTS. Both modes encrypt data units almost the same way. For CBC, the secto...
Suppose there are three messages `A`, `B` and `C` of different length, that are 16 DWORDs in length when combined. I know the plaintext and length of `A` and `C`, and only length of `B`. Is it possible to take any advantage of this knowledge when trying to recover a preimage of `MD5(A || B || C)`? I'm targeting "raw" M...
Is there something special about the AES key expansion algorithm that makes it secure, or it is a compromise between security and speed? For example, say with a key I expand it by taking pbkdf2(key) or scrypt(key) as the next round, and scrypt(scrypt(key)) as the round after that, until I have all of my subkeys. Would ...
**Note that any modification on AES will not be AES anymore.** It is not even **Rijndael** (a larger family of block ciphers with key sizes and block sizes each one of 128, 160, 192, 224 or 256 bits – the ones with block sizes 128 and key sizes of 128, 192 or 256 have been standardized as AES). Rijndael uses a speci...
As D.W. said, the AES key schedule is not a pseudo-random function by itself, and certainly not more secure than something like PBKDF2 (with a hash function or MAC) or any other pseudorandom function. (There is saying that the key schedule is the weakest part in Rijndael/AES.) It is meant to be fast, still a bit non...
**XTS vs. Undiffused CBC.** The issue here is *malleability*. Both XTS and CBC prevent an attacker from learning information about encrypted data. However, neither one completely succeeds in preventing an attacker from *tampering* with encrypted data. However, it's arguably easier to tamper with an (undiffused) CBC ...
To expand on the comments: > There is no obvious (= not requiring cryptanalysis) way other to try every possible 3-byte combination, no. The fact that it was encrypted twice changes nothing > That said, 3*8=24 bits, and 2^24 is only about 16 million tries. Well within range of brute force attacks, if you've got s...
**XTS vs. Undiffused CBC.** The issue here is *malleability*. Both XTS and CBC prevent an attacker from learning information about encrypted data. However, neither one completely succeeds in preventing an attacker from *tampering* with encrypted data. However, it's arguably easier to tamper with an (undiffused) CBC ...
To expand on the comments: > There is no obvious (= not requiring cryptanalysis) way other to try every possible 3-byte combination, no. The fact that it was encrypted twice changes nothing. – Thomas > That said, $3·8=24$ bits, and $2^{24}$ is only about $16$ million tries. Well within range of brute force attack...
Suppose there are three messages `A`, `B` and `C` of different length, that are 16 DWORDs in length when combined. I know the plaintext and length of `A` and `C`, and only length of `B`. Is it possible to take any advantage of this knowledge when trying to recover a preimage of `MD5(A || B || C)`? I'm targeting "raw" M...
Is there something special about the AES key expansion algorithm that makes it secure, or it is a compromise between security and speed? For example, say with a key I expand it by taking pbkdf2(key) or scrypt(key) as the next round, and scrypt(scrypt(key)) as the round after that, until I have all of my subkeys. Would ...
I've been looking at the weakness with plain/textbook RSA, where the same message is encrypted and sent to multiple destinations. In this case, it is possible to recover the message. Given that an attacker then knows the values of m, c, e and n in the following equation, is there any extensions which allows them to ...
RSA Without Padding?
The usual implementation of AES first computes all the Round Keys sequentially starting from the key, and stores them in RAM for later use. When enciphering a single block with a key that will be used for that purpose only, or when or RAM is very sparse, it is advantageous to use the Round Keys a they are generated, ra...
On-the-fly computation of AES Round Keys for decryption?
I've been looking at the weakness with plain/textbook RSA, where the same message is encrypted and sent to multiple destinations. In this case, it is possible to recover the message. Given that an attacker then knows the values of $m$, $c$, $e$ and $n$ in the following equation, is there any extensions which allows ...
The usual implementation of AES first computes all the Round Keys sequentially starting from the key, and stores them in RAM for later uses. However, when enciphering a single block with a key that will be used for that purpose only, or when RAM is very sparse, it is advantageous to use the Round Keys a they are being ...
Strange... `WNZNTNV` is repeated... If i'm counting correct on position 1-6 and 22-27. My guess would be the key length is a divider of 21? 7 seems to be consistent with the other information, but my knowledge of foreign languages is close to none, so i don't recognize anything readable in key or plaintext......
Is this true that whenever you design a protocol using a hash function, you must prove its security under the random oracle? I mean, is it possible to devise a protocol $P$ using a function $H$, and then prove a theorem saying that $P$ is secure in a model $M$ given that $H$ is a collision-resistant function? What ...
In a situation where it is required to generate n number of keys deterministically from a single piece of seed information can we assume that b breached number of keys, no matter what the quantity would not help an attacker discover the previous nor next key in the set without the original seed data? My initial thou...
We can't trust RSA to encrypt our Emails so what is best post-quantum cryptography system as alternative for RSA which provide good security and don't be breakable? because McEliece cryptosystem looks break with 2^60.55 bit operations..
if Alice and bob have a secure channel for key-exchange and mallory don't man-in-the-middle attack them but in the future eavesdrop connection and see the key exchanged, can mallory break it like RSA with a quantum computer ? (because McEliece cryptosystem can break by 2^60.55 bit operations)
Diffie-Hellman is Post-quantum secured?
The usual implementation of AES first computes all the Round Keys sequentially starting from the key, and stores them in RAM for later uses. However, when enciphering a single block with a key that will be used for that purpose only, or when RAM is very sparse, or perhaps in hardware, it is advantageous to use the Roun...
i did a crt challenge yesterday and there`s one problem i was unable to solve, probably due to my lack of understanding advanced crypto math. it`s about RSA. There are ten given pairs of N and E (modulo and exponent). E is always the std exponent 10001. N is a 2048 bit number. The task: factorize all N. Well, ...
If Alice and bob have a secure channel for key-exchange and mallory don't man-in-the-middle attack them but in the future eavesdrop connection and see the key exchanged, can mallory break it like RSA with a quantum computer?
I did a CRT challenge yesterday and there`s one problem I was unable to solve, probably due to my lack of understanding advanced crypto math. It`s about RSA. There are ten given pairs of N and E (modulo and exponent). E is always the standard exponent 10001 (hex). N is a 2048 bit number. The task: factorize all N...
A random oracle is an idealization of a hash function $H$ : if hash functions were perfect they would **be** random oracles. This is why it is always easier to consider a hash function a random oracle when one proves something about a larger scheme. Those are "proofs in the random oracle model". (http://cseweb.ucsd.edu...
A random oracle is an idealization of a hash function $H$ : if hash functions were perfect they would **be** random oracles. This is why it is always easier to consider a hash function a random oracle when one proves something about a larger scheme. Those are "proofs in the random oracle model". [1] That being said ...
is there any benchmark for RSA 4096bit long keys on general computers ? how many encryption decryption possible per second ? all benchmarks only show 1024 and 2048 benchmarks :(
I understand the basics behind public key cryptography, in that each party has two keys - the public one encrypts, and the private one decrypts. What I <em>cannot</em> figure out is, <strong>How does the public key encrypt and not decrypt, but yet the private key <em>can</em> decrypt?</strong><br/>I do understand the p...
Public key cryptography - public key encrypts and cannot decrypt?
is there any benchmark for RSA 4096bit long keys on general computers ? how many encryption decryption possible per second ? all benchmarks only show 1024 and 2048 benchmarks :(
How it works depends on the cipher, but the basic idea is that of a [trapdoor function][1]. >A trapdoor function is a function that is easy to compute in one direction, yet believed to be difficult to compute in the opposite direction (finding its inverse) without special information, called the "trapdoor". Man...
In a situation where it is required to generate n number of keys deterministically from a single piece of seed information can we assume that b breached number of keys, no matter what the quantity would not help an attacker discover the previous nor next key in the set without the original seed data? My initial thou...