instruction stringlengths 15 30k |
|---|
I'll take the question as: how can one make a chain of RSA encryptions with _distinct_ public keys $(N_j,e_j)$, that is $D_{j+1}=\operatorname{RSA-encrypt}((N_j,e_j),D_j)$, without having the ciphertext size growing at each encryption?
I'll use two facts:
1. When plaintext $x$ behaves to an adversary about as a u... |
I have been working on a project implementing LT codes with Homomorphic hashing (inspired from http://blog.notdot.net/2012/08/Damn-Cool-Algorithms-Homomorphic-Hashing and http://blog.notdot.net/2012/01/Damn-Cool-Algorithms-Fountain-Codes)
Here's what I have understood from those links.
Suppose the message to be s... |
I could not find any evidence pointing towards homomorphic encryption. What I could find were different combinations of deterministic and format preserving encryption. There is probably also a variant that preserves order, but I couldn't find any material depicting it.
This post is based on material published on the... |
I take the question as: how to make a chain of RSA encryptions with _distinct_ public keys $(N_j,e_j)$, that is $D_{j+1}=\operatorname{RSA-encrypt}((N_j,e_j),D_j)$, without having the ciphertext size growing at each encryption?
I'll use two facts:
1. When plaintext $x$ behaves to an adversary about as a uniform n... |
Have you considered using [Shamir's Secret Sharing][1] algorithm?
First, Bob encrypts the message with a symmetric algorithm. Then, he divides the secret key into four parts using SSA such that it requires three parts to decrypt (a $(3,4)$ threshold). Bob then distributes one part each to Alice and Mark, and two... |
For example in my situation the hash 486e9638177faf1f34e49910491b77af = 20
I also know all the hashes from 0 to 20
Is it possible to work out the algorithm used to hash these values?
Thanks for any information
Ryan |
If I know the value of several hashes is it possible to work out the algorithm used? |
Is it a weakness to use a single shared secret for protecting messages using a Encrypt-then-MAC scheme?
Assuming a system is using AES-256-CBC and a SHA1-HMAC and the same secret key for both operations. Upon intercepting one of these messages and attacker could brute force this secret key by trying to solve the ... |
I came across a marketing video [here][1]. They claim to perform AES encryption and tokenization of sensitive data, at the corporate gateway, before it leaves the company firewall destined for the public cloud. So keys and *token<=>plain text* mapping tables remain at gateway and cipher text/tokens live in the public c... |
They are not using any exotic encryption. In fact, based on data, it appears it's just 1:1 mapping (tokenization) after lowering the case on plain text data. I don't know about others but to me this pattern just stood out when I had a look at the demo video. To see it yourself, check their [publicly visible demo video]... |
Has anyone checked if using haveged, a Linux daemon which uses the HAVEGE algorithm, changes the non-deterministic properties of the random data from `/dev/random` in any negative ways? |
Background:
As a follow up to: Is It Possible To Reconstruct a Cryptographic Hash's Key
Situation:
-I am using a SHA256 HMAC function on a single word input: sha256hmac(privatekey,word) = output -Private key is 128 bit length, non-changing -The "word" is literally a short one word
Questions:
Assuming a... |
I am designing a simple and secure stream communication protocol. My idea was to build each message sent to the wire as:
(message size || clear text || UHASH(message size || clear text)) $\oplus$ unique stream cipher output
where UHASH is the main function from UMAC (see question http://crypto.stackexchange.com/q... |
Using the output of a stream cipher, how to guarantee the integrity of 4 bytes of data? |
It's more a theoretical question of how would you approach it. All you know about the ciphertext it's was generated with a historical cipher.The ciphertext appears to be random, BUT it's divided into sets of six letters. By historical ciphers I mean: mono ( Ceasar ), polyalphabetic (Vigenere ), homophonic or polygraphi... |
For a cryptographic hash function and input values of shorter length than the hash function output, it's pretty obvious that there should be as few collisions as possible. But are there guaranteed to be none?
In other words, for a cryptographic hash function $H: x\to y, x \in \mathbb{N}, y \in [0,y_{max}]$, are ther... |
Are cryptographic hash functions perfect hash functions? |
For a cryptographic hash function and input values of shorter length than the hash function output, it's pretty obvious that there should be as few collisions as possible. But are there guaranteed to be none?
In other words, for a cryptographic hash function $H: x\to y, x \in \mathbb{N}, y \in [0,y_{max}]$, are ther... |
Assume there is a crypto algorithm that deals with matrices to encrypt and decrypt. Regardless of the specification of such algorithm, what if the algorithm assumes that two parties can securely agree on a matrix and use it along with its inverse to encrypt and decrypt? What I am trying to understand, is that, such thi... |
I wouldn't even go so far as to say that a good hash function must have "as few collisions as possible" as you state in your question. The identity function has no collisions if we restrict the domain to be the inputs having the same size as the digest. But it's clearly a lousy hash function.
To be "good" as a has... |
The problem you are solving is "how can I make sure some who can modify data doesn't confuse the message parsing logic, at least, to the extent that I don't recognize that something's wrong for quite a while".
First of all, how do you expect to handle the case where something is modified in the message? Do you imme... |
**Problem Overview**
I want to securely store log files so they can't be modified without detection.
The files will be encrypted using authenticated encryption (AES in GCM mode), with a random IV and symmetric key for each file. The symmetric key will be encrypted using the public part of an RSA key pair. Both th... |
**Problem Overview**
I want to securely store log files so the contents are secret, and they can't be modified without detection.
The files will be encrypted using authenticated encryption (AES in GCM mode), with a random IV and symmetric key for each file. The symmetric key will be encrypted using the public par... |
I am designing a simple and secure stream communication protocol. My idea was to build each message sent to the wire as:
(message size || clear text || UHASH(message size || clear text)) $\oplus$ unique stream cipher output
where UHASH is the main function from UMAC (see question http://crypto.stackexchange.com/q... |
Is it possible to find out which public key was used to generate the message?
Scenario is like this :
I got data which is encrypted with a public key. Now a "bad guy" hast the encrypted data, and knows the decrypted content and wants to know who was the receiver of the data. The "bad guy" has all possible public ... |
'Hybrid' encryotion, where we combine symmetric encryption with public-key cryptography, is pretty 'tried and tested'.
To summarise, we generate a symmetric key and encrypt it using RSA. We would encrypt our data using the symmetric, and prefix it with the IV and encrypted key. You therefore need the private key fro... |
'Hybrid' encryption, where we combine symmetric encryption with public-key cryptography, is pretty 'tried and tested'.
To summarise, we generate a symmetric key and encrypt it using RSA. We would encrypt our data using the symmetric, and prefix it with the IV and encrypted key. You therefore need the private key fro... |
For example, in my situation I know `hash(20) = 486e9638177faf1f34e49910491b77af`.
I also know the hashes for all values from 0 to 20.
Is it possible to work out the algorithm used to hash these values? |
Is it possible to work out the hash algorithm from a list of known message-hash pairs? |
I was wondering what "securely realizes mean" , I see this in some cryptography but i don't know what it means for a protocol to "securely realize" a function F,
Is it just a fancy way of saying uses or does it mean something else? |
What does securely realize mean? |
In addition to the special case analytical attacks for small public exponents, I wouldn't use a low value of e due to Partial Key Exposure. See "[Exposing an RSA Private Key Given a Small Fraction of its Bits][1]."
[1]: http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.40.1461&rep=rep1&type=pdf |
I have thought up a method for generating random numbers between a client and a server which I hope is fair:
- The client and server decide on a range in advance 0 through `n`.
- The server generates a 256bit random number `m` (of the range 0 - floor(2^256 / n) * n) and and sha256 hashes it to give `m'`, `m... |
I was wondering what "securely realizes" means. I see this in some cryptographic papers but I don't know what it means for a protocol to "securely realize" a function $F$. Is it just a fancy way of saying "uses" or does it mean something else? |
What does "securely realize" mean? |
I read that to break repeating-key xor you can do the following: try a keysize $n$ and compute the hamming distance between the first $n$ bits of the encrypted string and the bits $n+1$ to $2n$ of the encrypted string and normalize by keysize.
The true keysize probably minimizes this. Why?
It also suggests to ave... |
Yes, you are remembering correctly. Yes, this is a reasonable method to find the key length.
The reason why this works is because, typically, the plaintext is not uniformly random. For instance, rather than a random bit-string, the plaintext might be some English text, encoded in ASCII. If $X,Y$ represent two ran... |
In addition to the special case analytical attacks for small public exponents, I wouldn't use a low value of e due to Partial Key Exposure. See "[Exposing an RSA Private Key Given a Small Fraction of its Bits][1].":
> Our results show that RSA, and particularly low public exponent RSA,
> are vulnerable to partial ... |
we are currently developing a little AES implementation in a crypto-course at university.
As far as I know, AES uses 128 bit blocklength, so all data that will be encrypted will get split up into blocks with 128 bit (16 byte) into an 2d-array (or 1d in implementation) with 4x4 fields.
I was wondering and didn't ... |
AES - plaintext is smaller 128 bit - how to expaned? |
Yes, you are remembering correctly. Yes, this is a reasonable method to find the key length.
The reason why this works is because, typically, the plaintext is not uniformly random. For instance, rather than a random bit-string, the plaintext might be some English text, encoded in ASCII. If $X,Y$ represent two ran... |
The protocol you are trying to reinvent is called [SRP](http://srp.stanford.edu).
Unless you have a compelling reason to believe that your protocol is secure, it should by default be assumed completely broken. Given that your protocol has seemingly no benefits over SRP, you should seriously consider going with somet... |
The protocol you are trying to reinvent is called [SRP](http://srp.stanford.edu).
Unless you have a compelling reason to believe that your protocol is secure, it should by default be assumed completely broken. Given that your protocol has seemingly no benefits over SRP, you should seriously consider going with somet... |
So you have a small integer, and you want to transmit it in such a way that (a) you don't particularly care if the attacker finds out what that integer is, but (b) no matter what the attacker changes or substitutes, you don't want the receiver to be tricked into thinking you sent some other number (in particular, som... |
The protocol you are trying to reinvent is called [SRP](http://srp.stanford.edu).
Unless you have a compelling reason to believe that your protocol is secure, it should by default be assumed completely broken. Given that your protocol has seemingly no benefits over SRP, you should seriously consider going with somet... |
I have thought up a method for generating random numbers between a client and a server which I hope is fair:
- The client and server decide on a range in advance, $0$ trough $n-1$.
- The server generates a $256$ bit random number $m$ (in the range $0$ to $\operatorname{floor}(\frac{2^{256} }{ n}) · n$) and h... |
Is this scheme a provably fair random number generation? |
Assume RSA with a public modulus $N$ of $n$ bits, a small odd public exponent $e$, plaintext $M$ a random non-negative integer less than $2^m$ for some integer parameter $m$, with $M\mapsto C=M^e\bmod N$ (textbook RSA) used for encryption. Inasmuch as it matters, assume there are $2^r$ ciphertexts available to the atta... |
If I correctly understand the concept of a "brain wallet" in BitCoin, you start with a passphrase, generate the hash of the passphrase, then somehow derive a public / private key from that to use as your BitCoin identifier.
This conflicts with what I understand about key pairs... namely that they are special... not ... |
How can a key pair be derived from an arbitrary hash? |
How do cryptography in SSH(2) work (secure channel establishment, authentication)?
Does key authentication in SSH(2) protect from MitM by providing authentication and integrity and why?
|
Bitcoin doesn't use RSA, it uses ECDSA. Every 256-bit value is a valid private key. (Though a very small fraction of them have to be folded.)
But even if the numbers had to be special, it still wouldn't matter. You could use every 256-bit value as a seed to a pseudo-random number generator which you could use to det... |
Let's say I want to create private archives for the long term (e.g. more than 30 ). The archives' sizes could be anywhere from 1 GB to 30 GB. As far as I understand I could go down two ways:
The first would be for example using plain AES-256 encryption in CTR mode with a random key stored on paper.
The second, m... |
Given nothing more than some integer $m =$ OAEP($M$), is it possible to recover the original plaintext $M$? In other words, without being given the hash functions or the random string used for encoding, or even the length of it. |
Is OAEP reversible? |
I understand that when you want to encrypt and sign data with RSA the generally recommended approach is sign-then-encrypt.
However, I have encrypted data that I need to sign, to prove the author of the encrypted data.
1. Encrypt wth recipient's public key
2. Sign with author's private key
3. Concatenate ciph... |
Given nothing more than some integer $m =$ OAEP($M$), is it possible to recover the original plaintext $M$? In other words, without being given the hash functions or the random string used for encoding, or even the length of it.
EDIT: This is being used in tandem with RSA, but I don't know the hash functions that OA... |
If an adversary knows my public key and guesses what was my plaintext, can he test for it somehow?
The most obvious way is encrypting the guessed plaintext with my public key and the same parameters that he can probably discover from the ciphertext to see if the result is the same.
|
If an adversary knows my public key and guesses what was my plaintext, can he test for it somehow?
The most obvious way is encrypting the guessed plaintext with my public key and the same parameters that he can probably discover from the ciphertext, to see if the result is the same.
|
RSA - Ecrypting the same data with the same public key = same ciphertext? |
I understand that when you want to encrypt and sign data with RSA the generally recommended approach is sign-then-encrypt.
However, I have encrypted data that I need to sign, to prove the author of the encrypted data.
1. Encrypt wth recipient's public key
2. Sign with author's private key
3. Concatenate ciph... |
I am just reading the "soundness"-definition for proofs of knowledge by Bellare / Goldreich. A proof of knowledge is a proof between a prover $P$ and a verifier $V$. $P$ convinces $V$ to know a secret value. The idea is to define a knowledge extractor $K$, which can calculate the secret. They write
> There exists a ... |
Question about proof of knowledge defintion? |
Please tell me how i can to derive formulas for adding and multiplication of 2 points in jacobian coordinates ((x,y)=(XZ2,YZ3)) over elliptic curve? Thanks a lot beforehand. |
Is there some standard protocol for mutual authentication of two parties when there is possibility to use public key cryptography? The problem is that two parties can use public key cryptography but public keys are not embedded within any kind of certificates. Is there a way to avoid MITM attacks? Simple use of public ... |
Given we are using AES counter mode, suppose we randomly generate several keys, all of them are using same IV (say, zeros). Does this lead to any security issue?
I know that in CTR mode, same key-iv pairs would lead to two-time-pad. But the above construction will not have the same keys.
In application:
Let's ... |
Given we are using AES counter mode, suppose we randomly generate several keys, all of them are using same IV (say, zeros). Does this lead to any security issue?
I know that in CTR mode, same key-iv pairs would lead to two-time-pad. But the above construction will not have the same keys.
In application:
Let's ... |
As I describe in my [previous question][1] I am trying to decide if it's worth it for me to use the [Offline Private Key Protocol][2] in creating some long term private archives, instead of just going with a simple symmetric encryption like AES-256. The answer to that question pointed out that using RSA to encrypt the ... |
For primes p and q used to create a keypair, I understand that the following operation is used to create a signature :-
M ^ d (mod N)
where d and N have their usual meanings and M is the message. In this case, however you need to possess the public key in order to verify the signature S as follows :-
S ^ e (mo... |
For primes p and q used to create a keypair, I understand that the following operation is used to create a signature :-
M ^ d (mod N)
where d and N have their usual meanings and M is the message. In this case, however you need to possess the public key in order to verify the signature S as follows :-
S ^ e (mo... |
After reading [these][1] [two][2] resources I am wondering am I getting all the differences between Scrypt and PBKDF2 or am I missing something?
As far as I understood, the similarity is:
- both are using password-based KDF
The difference is:
- Scrypt is more resource demandful
[1]: http://www.tar... |
Is there a construction of an order preserving hash function that keeps the preimage property of a crypto hash function? By order preserving hash function (OPHF) i mean for $x<y$ then $OPHF(x) < OPHF(y)$ |
>When we say "RSA is broken" do we mean that a practical attack is discovered to retrieve the private key from the public, or do we mean that given a ciphertext and no knowledge of either the private or the public key the attacker can decrypt the data?
First off, we always assume the attacker has the public key. Som... |
I'm trying to prove something and if I can show that there is a simple way to calculate $(g^a \bmod p)^k$ if I know both $g^k \bmod p$ and $g^a \bmod p$, then (I think) it will help me prove it, but I'm not able to see an obvious way to use the two expressions to calculate the other. Is there a property in modular arit... |
I will be making (in the near future) an app that will contain some pretty heavy crypto. As it is possible that my app will be ported to different devices (initially it will be iOs only, but MAC, Android & maybe even Windows ports will eventually exist) . The question is how to make the crypto library as portable as po... |
I have been working on a project implementing [LT codes](http://en.wikipedia.org/wiki/Luby_transform_code) with Homomorphic hashing (inspired from http://blog.notdot.net/2012/08/Damn-Cool-Algorithms-Homomorphic-Hashing and http://blog.notdot.net/2012/01/Damn-Cool-Algorithms-Fountain-Codes).
Here's what I have unders... |
How can I derive formulas for adding and multiplication of 2 points in Jacobian coordinates $(x,y) = (XZ^2,YZ^3)$ over an elliptic curve? |
Has anyone checked if using [`haveged`](http://www.issihosts.com/haveged/), a Linux daemon which uses the [HAVEGE](http://www.irisa.fr/caps/projects/hipsor/) algorithm, changes the non-deterministic properties of the random data from `/dev/random` in any negative ways? |
I'm looking for a toy hash function, where the idea is to have high school students break (i.e. find a collision) a hash function by hand, in order to teach them how one way functions and hashing works.
Do you happen to know some function like that? |
I will be making (in the near future) an app that will contain some pretty heavy crypto. As it is possible that my app will be ported to different devices (initially it will be iOs only, but MAC, Android & maybe even Windows ports will eventually exist) . The question is how to make the crypto library as portable as po... |
I will be making (in the near future) an app that will contain some pretty heavy crypto. As it is possible that my app will be ported to different devices (initially it will be iOs only, but MAC, Android & maybe even Windows ports will eventually exist) . The question is how to make the crypto library as portable as po... |
The problem with a hash function like you ask for is that, if you hash an $n$-bit string and give the hash to someone else, they can recover the string using $n$ hash calculations with a binary search.
For a simple example, let's say the $n=8$, your string is $01011001$ in binary, and its hash is $Y = H(01011001)$.
... |
I am read the Lemma 2 (pp13) in this paper. Here a make a question Why "for any $Hash_z$ and any $Gen$"? The author of paper reply
The reason why "for any $Hash_z$ and any $Gen$" is that if the sentence is
not included the cryptosystem may be broken due to weak $Hash_z$ or $Gen$.
I know the hash str... |
How can I derive formulas for adding and multiplication of 2 points in Jacobian coordinates $(x,y) = (\frac{X}{Z^2},\frac{Y}{Z^3})$ over an elliptic curve? |
In my lecture say:
Let be $K$ a the key generation algorithm. Given a security parameter repre-
sented in unary, $1^k$, $K(1^k)$ will output a keypair $(pk; sk)$, known as the public key and the private (or secret) key, respectively.
My question is: In the McEliece Cryptosystem How I will be able to represent ... |
I am read this paragraph and I have a doubt.
An adversary to PKC $\Pi$ is given by two probabilistic polynomial time algorithms, $A = (A1; A2)$. In the first stage, the "find" stage, the adversary analyzes the public key and tries to determine which plaintexts, when encrypted, are vulnerable to attack. This is the j... |
In my lecture say:
Let be $K$ a the key generation algorithm. Given a security parameter repre-
sented in unary, $1^k$, $K(1^k)$ will output a keypair $(pk; sk)$, known as the public key and the private (or secret) key, respectively.
My question is: In the McEliece Cryptosystem How I will be able to represent ... |
I'm referring to page 383 of J. Katz and Y. Lindell's Introduction to Modern Cryptography. The book presents a padded RSA:
- ${\bf Key Generation:}$ same as Textbook RSA (given security parameter $1^n$, generate public key ($N,e$), secret key ($N,d$), such that $N = pq, ed \equiv 1 \mod{(p-1)(q-1)}$)
- ${\bf En... |
I am read this paragraph and I have a doubt.
> "An adversary to PKC $\Pi$ is given by two probabilistic polynomial
> time algorithms, $A = (A1; A2)$. In the first stage, the "find"
> stage, the adversary analyzes the public key and tries to determine
> which plaintexts, when encrypted, are vulnerable to attack. T... |
In <a href="http://crypto.stackexchange.com/a/8168/5021">an answer to a previous question</a> it was suggested that one way to protect your asymmetrically encrypted AES-256 keys, from say a solution to prime factorization, would be to chain asymmetric algorithms. Having read about the meet-in-the-middle attacks here an... |
what should I do if my original message is greater than 64 bits? what is the process of padding in MD5?
![enter image description here][1]
[1]: https://i.stack.imgur.com/fvOoZ.jpg
I am reading this, but I cannot understand it |
You could protect the ECIES ciphertext with a superencipherment of DLIES, and you would not be weakening your security unless you slipped up and reused keys or used related keys. That means each step should be done carefully and thoughtfully as if it was the only protection step you would be taking. For example, when... |
Ok, I hope this question makes some sense because I am not so sure how to word it any differently… Imagine the following situation:
- There are 10 defined colors (blue, orange, yellow etc.)
- There are 2 Persons and each of them has 1 favorite, secrete color
- The 2 persons don't know each other's favorite col... |
How to compare two datasets „anonymously”? |
I'm building a basic HSM out of an Arduino, and am using the following scheme to store data:
- Master symmetric key stored in firmware (secure bit set to prevent trivial extraction).
- Secondary symmetric keys stored as plaintext in web application database, one per user.
- HSM record key generated by xor'ing t... |
Is it worth applying a MAC on data in a HSM? |
what should I do if my original message is greater than 64 bits? what is the process of padding in MD5?
As described in *Internet Security: Cryptographic Principles, Algorithms and Protocols*, [page 138][1], the second step in MD5 is to append the length of the message:
![enter image description here][2]
Can... |
I am read the Lemma 2 (pp13) in the paper [1]. Here a make a question Why "for any $Hash_z$ and any $Gen$"? The author of paper reply
> The reason why "for any $Hash_z$ and any $Gen$" is that if the sentence is
not included the cryptosystem may be broken due to weak $Hash_z$ or $Gen$.
I know the hash stro... |
I'm building a basic HSM out of an Arduino, and am using the following scheme to store data:
- Master symmetric key $k_m$ stored in firmware (secure bit set to prevent trivial extraction).
- Secondary symmetric keys $k_s$ stored as plaintext in web application database, one per user.
- HSM record key $k_r$ gene... |
Designing an HSM or other secure device is relatively easy; making it reliable even in the absence of adversary requires careful engineering; making it safe against adversaries with some level of physical access is hard; demonstrating that it is safe (for some definition of that) is even harder.
One thing to worry a... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.