instruction stringlengths 15 30k |
|---|
> Is this usable? Or does the generation of the modulus outweigh any
> gains in the difference in signing time?
Yes, it does work to some extent, and the generation cost isn't too important, because signing any one nonce doesn't help the client sign any other nonce, so you can just use a single key all the time (if... |
> Is this usable? Or does the generation of the modulus outweigh any
> gains in the difference in signing time?
Yes, it does work to some extent, and the generation cost isn't too important, because signing any one nonce doesn't help the client sign any other nonce, so you can just use a single key all the time (if... |
I am trying to get my head around the circumstances under which a cipher is (or is not) semantically secure under a chosen-plaintext attack.
I can't seem to find a good reference explaining this.
I think I am missing a fundamental concept, so If I explain it as I see it perhaps someone can correct me.
Semantic... |
Which categories of cipher are semantically secure under a chosen-plaintext attack? |
what's benefits and disadvantages of CBC vs CTR ? which one is more secure ? |
AES CBC mode or AES CTR mode recommended? |
Suppose I devised the following challenge-response proof-of-work system:
A server generates a 2048-bit RSA modulus, and uses the "public" exponent (usually 65537) to sign a random nonce a fixed number of times, say, 256.
The server then sends the signed nonce to the client, along with the "private" exponent (whic... |
> Is this usable? Or does the generation of the modulus outweigh any
> gains in the difference in signing time?
Yes, it does work to some extent, and the generation cost isn't too important, because signing any one nonce doesn't help the client sign any other nonce, so you can just use a single key all the time (if... |
I am using AES in CBC mode.
For some reasons I have some issues for transmiting the IV. So I am using a fixed IV.
If the first 128bits of the message, change on every message (like a timestamp).
Does that can moderate the issue of having a fixed IV ?
|
If you look at the CBC diagram, you'll see that having a fixed IV is equivalent to having the first ciphertext block become the IV. If your cipher is a good pseudorandom permutation, then what you are doing does work, *if and only if* all timestamps are **unique** such that the "new IV" is unique *and* unpredictable.
... |
I'm trying to find a collision for the following (modified) Merkle-Damgard hash function. Suppose we already have a hash function $h$ for a fixed length bit string, with $h(0\ldots 0)= 0\ldots 0$.
---
The input $x$ (bit string, variable size) is divided into blocks $x_j$ of $n$ bit each, padding the last block wi... |
**Edit:** I just realized that the scheme that was proposed has serious security problems, and should not be used.
The question is rather confused and ambiguous, but there seems to be a serious security problem. If I understand the proposal correctly, you are giving the client the private exponent $d$ and the modul... |
I'm trying to find a collision for the following (modified) Merkle-Damgard hash function. Suppose we already have a hash function $h$ for a fixed length bit string, with $h(0\ldots 0)= 0\ldots 0$.
---
The input $x$ (bit string, variable size) is divided into blocks $x_j$ of $n$ bit each, padding the last block wi... |
Suppose I devised the following challenge-response proof-of-work system:
A server generates a 2048-bit RSA modulus, and uses the "public" exponent (usually 65537) to sign a random nonce a fixed number of times, say, 256.
The server then sends the signed nonce to the client, along with the "private" exponent (whic... |
> Is this usable? Or does the generation of the modulus outweigh any
> gains in the difference in signing time?
**No, it does not work.** The generation cost itself isn't too important, because signing any one nonce doesn't help the client sign any other nonce, so you can just use a single key all the time (if you ... |
How does using salt reduce rainbow table attack? |
I'm trying to find a collision for the following (modified) Merkle-Damgard hash function.
> Suppose we already have a hash function $h : \mathbb{Z}_2^{2·n} \to \mathbb{Z}_2^n$ for fixed length bit strings, with $h(0\ldots 0)= 0\ldots 0$.
> The input $x$ (bit string, variable size) is divided into blocks $x_j$ of ... |
Suppose I have this cryptogram: http://pastebin.com/QpfRMBg1
Clearly it's a Ceasar Cipher which decrypts to: http://pastebin.com/r50heZuU
with a simple shift of 10... OKay, no big deal. Let's take a look at the first line two lines or so:
QUEBEC MIKE OSCAR INDIA VICTOR SIERRA QUEBEC INDIA ... |
How does this Cesar Cipher work? |
At stackoverflow [this](http://stackoverflow.com/questions/9883359/gathering-entropy-in-web-apps-to-create-more-secure-random-numbers/9897411#comment12696984_9897411) question has been asked. It uses additional random entropy and a hash method (among others) to try and create a cryptographically secure pseudo-random nu... |
I wanted to calculate What is the time complexity of this? I'm using a Java program?
Can anyone provide an explanation of the time complexity for the following calculations?
c= a * b mod n
and
m = a ^-1 * b mod n
I need any suggest.
my variable has 256 bits |
Quantum key distribution depends, if I don't err, on (irreversible) damages done by MITM's measurements on qbits. Now news.yale.edu/2013/01/11/new-qubit-control-bodes-well-future-quantum-computing says:
"The Yale physicists successfully devised a new, non-destructive measurement system for observing, tracking and d... |
Any implication of a Yale result to security of quantum cryptology? |
I heard encryption based purely on XOR and Rotation is inherently weak. The paper [Rotational Cryptanalysis of ARX](http://www.skein-hash.info/sites/default/files/axr.pdf) says:
> It is also easy to prove that omitting addition or rotation is devastating, and such systems (XR and AX) can always be broken.
But I a... |
How to break arbitrary XOR and Rotation based encryption? |
I'm doing modular arithmetic in a Java program, and I want to calculate the time complexity of the individual operations.
$$ c= a · b \bmod n $$
$$ m = a^{-1} · b \bmod n $$
How do I get an approximation of the time complexity here, for example for 256-bit numbers? |
How can I calculate the time complexity of modular arithmetic? |
I heard encryption based purely on XOR and Rotation is inherently weak. The paper [Rotational Cryptanalysis of ARX](http://www.skein-hash.info/sites/default/files/axr.pdf) says:
> It is also easy to prove that omitting addition or rotation is devastating, and such systems (XR and AX) can always be broken.
But I a... |
How to break an arbitrary XOR and Rotation based encryption? |
I heard encryption based purely on XOR and Rotation is inherently weak. The paper [Rotational Cryptanalysis of ARX](http://www.skein-hash.info/sites/default/files/axr.pdf) says:
> It is also easy to prove that omitting addition or rotation is devastating, and such systems (XR and AX) can always be broken.
But I a... |
If you look at the CBC diagram, you'll see that having a fixed IV is equivalent to having the first ciphertext block become the IV. If your cipher is a good pseudorandom permutation, then what you are doing does work, *if and only if* all timestamps are **unique** such that the "new IV" is unique *and* unpredictable.
... |
I sometimes read in papers that a (sub-)group generator $g$ is taken from $QR(n)$ instead of $Z^*_n$, where $n = p*q$ and $p$ and $q$ are prim. Is there a reason for this? What properties has $QR(n)$? Is it an especially big sub group??? |
Why work in a subgroup $QR(n)$ of an RSA group $Z^*_n$? |
I sometimes read in papers that a (sub-)group generator $g$ is taken from $\mathrm{QR}(n)$ instead of $\mathbb{Z}^*_n$, where $n = p \cdot q$ and $p$ and $q$ are prime. Is there a reason for this? What properties does $\mathrm{QR}(n)$ have? Is it an especially big subgroup?
|
Why work in a subgroup QR(n) of an RSA group Z*_n? |
I want to implement a point multiplication ($k \cdot P$) operation on FPGA. I have a BN curve $y^2=x^3+2$, and a scalar value $k$. The $x$ and $y$ coordinates of point $P$ are of 256 bits. In the double and add formulas, there are three main operations: addition, multiplication, and division. Each of these are mod oper... |
Why work in a subgroup QR(n) of an RSA group $Z^*_n$? |
I'd like to use AES-GCM instead of HMAC for authentication and privacy in a token used in a web application, but I'm unsure how to securely tag each token with an IV. Is it safe for me to prepend the IV in front of the AES-GCM data, or do I need to protect it somehow? |
Any efficient text-based steganographic schemes? |
I have some code that takes a list of credit-card numbers, splits the number into two chunks, one chunk is 8 characters long, the other chunk is the remainder.
Each series of chunks is saved into individual files, for example my test data looks like (these are test CC numbers):
378282246310005
4111111111... |
The curve $E(\mathbb{F}_{47}):y^2=x^3+x+38$ has order $61$ and $61|47^3-1$ so the embedding degree of $E$ is $3$ and therefore the MOV attack, presumably using some sort of distortion map and a suitable pairing can be used to find discrete logarithms. Exactly how is this done in this case?
If a larger example would be... |
Suppose that I have an AES key $K$, and I'm instructed to find a plaintext such that the first 32 bits of the plaintext are some string of bits $S_1$, and the last 32 bits of the ciphertext once the plaintext has been encrypted with $K$ are another string of bits $S_2$.
Is this difficult? Is there a known attack aga... |
Is it hard to find a pair of plaintext and ciphertext that each follow a certain condition, given an AES key? |
Suppose that I have an AES key $K$, and I'm instructed to find a plaintext such that the first 32 bits of the plaintext are some string of bits $S_1$, and the last 32 bits of the ciphertext once the plaintext has been encrypted with $K$ are another string of bits $S_2$.
Is this difficult? Is there a known attack aga... |
Does it make an encrypted string more secure if I use SHA256(x) instead of x as the secret key for AES-128 encryption? I do know that SHA-256 produces 64 characters of hashed string regardless of what the input is.
Will it still be accepted in AES as a key or it will cut it off to 32 characters?
Also is it true tha... |
I understand that for a stream cipher to be useful, there must be a way to verify that the message was not tampered with (bits were flipped by an attacker).
So, instead of using some cryptographic hash function, like SHA-2, with HMAC, what if I used a much simpler (and faster) hash function, like FNV hash algorithm,... |
If I understand you correctly, you want to use $C = \mathrm{Enc}_{K,N}(m || \mathrm{hash}(m))$ as authenticated encryption. This is a bad idea, even for cryptographically secure hashes.
Consider an attacker who knows your plaintext $m$ and wants to replace it by $m^\prime$. He calculates $C^\prime = C \oplus (m || \... |
Assuming I'm using bcrypt to digest passwords, is any additional security gained by either encrypting or HMACing the resulting digests? By requiring a key to compare password hashes, I would expect that this would prevent any attempt at brute forcing sans the key.
The keys for this operation are actually stored some... |
There are a few posts that I've come across that seem to infer that using regular encryption and a MAC might be better than using the newer AEAD (ie: AES/GCM) modes.
http://www.daemonology.net/blog/2009-06-24-encrypt-then-mac.html
http://blog.cryptographyengineering.com/2011/12/matt-green-smackdown-watch-are-aead... |
Is Encrypt+HMAC stronger than AEAD? |
There are a few posts that I've come across that seem to infer that using regular encryption and a MAC might be better than using the newer AEAD (ie: AES/GCM) modes.
http://www.daemonology.net/blog/2009-06-24-encrypt-then-mac.html
http://blog.cryptographyengineering.com/2011/12/matt-green-smackdown-watch-are-aead... |
Does it take brute force to find a pair of plaintext and ciphertext that each follow a certain condition, given an AES encryption key? |
I have a scheme that, long story short, uses AES in CBC mode to encrypt third-party credentials for user accounts with a password-derived key. It's been mentioned that the use of CBC mode is a vulnerability because it is susceptible to "padding oracle attacks"; the cipher, after being initialized by the legitimate user... |
Understanding padding oracles - is an attack plausible in my scenario? |
First off, many block modes of operation require a message to be padded so that its length is evenly divisible by the block size of the cipher. CBC mode (Cipher Block Chaining), for instance, typically pads a message either with an entire block of zeroes if it happens to be exactly divisible by the block size, or with ... |
The most famous text based steganographic scheme is using the first letters of words / sentences. If the mean sentence length is 15-20 words and mean word length is 5 letters, then efficiency is ~1%. You could use shorter than average sentences and/or words to increase the efficiency to within your bounds of >2%.
Ob... |
My application requires an AES-256 key `K` for some secure operation. In order to avoid saving this key in application, I have implemented following scheme:
1. There are 5 individuals who enters their passwords in application. Lets call them `PW1..PW5`
2. Using these passwords, I have generated the key as:
... |
How to generate a key using any m passwords out of total n? |
> **Possible Duplicate:**
> [Using CBC with fixed IV](http://crypto.stackexchange.com/questions/5421/using-cbc-with-fixed-iv)
<!-- End of automatically inserted text -->
I am using AES in CBC mode.
For some reasons I have some issues for transmiting the IV. So I am using a fixed IV.
If the first 128bits of ... |
> **Possible Duplicate:**
> [Using CBC with fixed IV](http://crypto.stackexchange.com/questions/5421/using-cbc-with-fixed-iv)
<!-- End of automatically inserted text -->
Forgive me if this has been asked before, I looked but haven't seen any answers that suit.
Is there any danger in using CBC, encrypting a mes... |
I've been trying to reverse engineer Mega's (mega.co.nz) API calls. And stopped on the step where client needs to decrypt session id with provided RSA key. I can get key data, but I have no idea how to convert this data into actual key.
Here is my Base64 encoded private key:
BACLkf9qj1yTiX+Jrc7nlp8GMbTh9Xnksd... |
What if, instead of using CBC mode in the normal way with a random IV, I used this approach:
1. Use a fixed IV (like a block of 0's).
2. Before encrypting, generate a random block and prepend it to the plaintext.
3. After decrypting, ignore the first block.
Is this exactly the same in terms of security as using... |
Or, is there a cryptosystem that is both order-perserving and additive homomorphic? |
Let's assume that we have a secure PRNG. Is it "safe" to initialize it with password, or seed based on a password like SHA256(password).
If yes, is it "safe" to generate as RSA or DSA key from it? If no, why?
so the idea behind this is to initialize the PRNG with a password, for that, you will always find the sam... |
Let's assume that we have a secure PRNG. Is it "safe" to initialize it with password, or seed based on a password like SHA256(password).
If yes, is it "safe" to generate as RSA or DSA key from it? If no, why?
so the idea behind this is to initialize the PRNG with a password, for that, you will always find the sam... |
A cryptographic PRNG doesn't care what you feed it as entropy, as long as you provide enough. Furthermore, the PRNG will not reveal anything about its internal state, including what was fed to it as entropy. So in this sense it's safe to use a password as entropy: the PRNG will not expose it.
The problem with a pass... |
Let's assume that we have a secure PRNG. Is it "safe" to initialize it with password, or seed based on a password like SHA256(password).
If yes, is it "safe" to generate as RSA or DSA key from it? If no, why?
so the idea behind this is to initialize the PRNG with a password, for that, you will always find the sam... |
A cryptographic PRNG doesn't care what you feed it as entropy, as long as you provide enough. Furthermore, the PRNG will not reveal anything about its internal state, including what was fed to it as entropy. So in this sense it's safe to use a password as entropy: the PRNG will not expose it.
The problem with a pass... |
I was wondering if hashing a password with the password would be a good way of encrypting the password. So, the user must know his/her password to get the same result as the one in the database. Also, this would prevent decrypting of the password without the password... right?
I've read articles and other SO questio... |
Hashing a password with the password? |
Let's assume that we have a secure PRNG. Is it "safe" to initialize it with password, or seed based on a password like SHA256(password).
If yes, is it "safe" to generate as RSA or DSA key from it? If no, why?
so the idea behind this is to initialize the PRNG with a password, for that, you will always find the sam... |
Having taken [The Design of Rijndael][1] from the library just yesterday, I had a look on this problem, too. Fixee wrote in a comment:
> However, my question is not so much about security implications, but rather
> "how does omissions of MixColumns make the inverse cipher similar to the cipher?"
> and "how does th... |
Let's assume that the plaintexts consist only of spaces and ASCII letters. Given the hint, that seems like a reasonable assumption to start with, even if it might turn out to be only mostly correct.
Now, take one of the ciphertexts and XOR it with each of the others. Of course, the XOR operation cancels out the ke... |
From Wikipedia:
> For a 256-bit block, the first row is unchanged and the shifting for the second, third and fourth row is 1 byte, 3 bytes and 4 bytes respectively.
Why the change? Is there any difference than in using 0, 1, 2, 3 like the other keysizes? |
Why does AES-256 require the bottom two rows to be shifted one more space? |
Why does Rijndael with 256-bit block require the bottom two rows to be shifted one more space? |
Why does Rijndael with a 256-bit block require the bottom two rows to be shifted one more space than usual? |
Same Size Crypto Algorithm? |
I am a beginner in cryptography I read about block cipher. but I do not understand exactly. what is mean? Is a way to send data or Is a way to encrypt data.
If it's method to send data rather is divide data into multiply block before send data. If that's right.Is partition data before encryption process or after? I a... |
What is means block cipher? |
I am wondering how can I secure communications between multiple peers over a public channel, like an IRC channel. With two peers it is easy - they exchange their encryption keys and decrypt the secret messages using their private keys, but how would this work with multiple peers without creating excessive duplication o... |
Is there any cryptographic primitive bijective (one-to-one and onto) function for creating cryptographic tools like symmetric encryption/decryption, Hash code generator, MAC, HMAC and Random number generator? |
What is the most paranoid way to exchange messages? |
What is the most secure way to let Alice "input" her private key, transfer it to the server and decrypt the message? (Then destroy the private key on the server)
Every connection is using SSL.
Exmeple:
Alice log on the website. She have a new "email" from Bob. (Everything is stored in a database, it's not an a... |
What is the most secure way to let Alice "input" her private key, transfer it to the server and decrypt the message? |
My understanding is that the three most popular approaches to "steganography using text as a cover" are:
1 Generate a completely new text by picking one word at a time from a dictionary, using the ciphertext bits to select which word.
* Pick words in ways that, at first glance, look like real English sentences, u... |
Is this even possible? The RSA group is not cyclic, so usually you wouldn't find a generator for accessing all group elements.
What happens if you use the RSA group in a scenario where you want that the discrete log problem is difficult. If you cannot find a generator, you want at least find an element with a high ord... |
How to find an element of high-order in an RSA group? |
**No**, its not safe to seed a PRNG with the hash of a password, and generate a key from it. It is especially bad with DSA and shared parameters $(p,q,g)$, and only slightly less unsafe for RSA, or DSA with per-key parameters $(p,q,g)$. **Two essentials things are missing: a slow step, and _salt_.**
If the proposed ... |
When constructing a PRF that has n bit input using the GGM PRG, why do we always have to recursively run the PRG using its previous output as a seed key n times. Instead, why don't we run the PRG n times, and use that as the output.
Any answers would be great. My assumptions is that it has something do with producin... |
Let $$(g,h=g^s,q)$$ be a tuple such that $g$ is a generator for a group $\mathbb{G}$ of ord $q$ and $s$ is uniformly random in $\mathbb{Z}_q$.
The KEA1 Assumption saies that for any adversary $\mathcal{A}(g,h,q)$ that outputs a value $(C,Y)$ such that $C^s \equiv Y$ then there exists a **extractor** $\mathcal{B}$ th... |
How much do we trust KEA1 Assumption? |
Given a database where we have usernames and passwords, we want to secure users' passwords by hashing them. We should not use only username and passwords in this hash, as someone having data from other sites that uses the same hashing function can come to the same results and thus know our passwords. If we try hashing ... |
Hashing passwords with a salt - why use different salt for everyone? |
@wikipedia it says AES key size is min 128 , 192 , and max 256 bit. but we use for example different length passwords on trucrypt or other crypto softwares which sometimes is less than 128 bit and sometimes more than 256 bit. how you can explain it ? |
What is AES key size limitation? |
Anecdotally, most factoring algorithms have a corresponding variant algorithm that can be used to attack the discrete log problem using similar ideas.
Is there an analog of the elliptic curve (ECM) factoring algorithm, but for discrete logs? Something that uses similar ideas, but can be used to compute discrete log... |
Discrete log analog of ECM factoring algorithm? |
Let's pretend that all digits of pi are known and arbitrarily long sequences of digits are trivial to get. Further, some mathematician proves that there are no patterns in pi. We could create a stream cipher by grabbing a piece of pi as long as our plaintext and combining the two with some function (such as XOR or modu... |
**No**, its not safe to seed a PRNG with the hash of a password, and generate a key from it. That is especially bad with DSA and shared parameters $(p,q,g)$, and only slightly less unsafe for RSA, or DSA with per-key parameters $(p,q,g)$. **Two essentials things are missing: some _slow step_, and _salt_.**
If the pr... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.