# All Questions

238 views

### Can we decrypt in this order when the message is encrypted twice?

If we encrypt a message twice with symmetric key $k_1$ first and then $k_2$ like $E_{k2}\{E_{k1}\{m\}\}$ , ideally we should decrypt with $k_2$ first and then $k_1$ but is it possible to decrypt with ...
636 views

### additive ElGamal encryption algorithm

I'm performing ElGamal encryption algorithm and using the additive homomorphic property so the product of two ciphertexts is the encryption of the sum of the plaintexts. The problem is that I need to ...
247 views

### How large should a Diffie-Hellman p be if the messages are encrypted?

How large should the prime $p$ and generator $g$ values be in a Diffie-Hellman handshake if the messages are encrypted. If the key that encrypted the Diffie-Hellman messages becomes compromised, ...
357 views

### Nonce role on stream ciphers

Modern stream ciphers usually predicts the usage of a nonce (also termed as IV) in the cryptosystem. The cost of initializing the cipher with the nonce varies from algorithm to algorithm (for ...
194 views

### Discrete logs on elliptic curve with embedding degree 3 with the 'MOV' attack

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 ...
467 views

### using Post-quantum asymmetric ciphers instead of RSA

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 ...
2k views

### Is it safer to encrypt twice with RSA?

I wonder if it's safer to encrypt a plain text with RSA twice than it is to encrypt it just once. It should make a big difference if you assume that the two private keys are different, and that the ...
368 views

### Why is a non fixed-length encryption scheme worse than a fixed-length one?

I have the following definition (highlights by me): An (efficient secret-key) encryption scheme $(Gen,Enc,Dec)$, where $Gen$ and $Enc$ are PPT algorithms and $Dec$ is a Deterministic Polytime ...
4k views

### What exactly is addition modulo $2^{32}$ in cryptography?

EDIT: I've been confusing this the whole time. What I've been wanting to say this whole time is addition modulo $2^{32}$ not addition modulo 32 as the question originally said. Thanks for pointing ...
1k views

### Shortcuts / practicality of brute forcing block cipher (AES) + ECB with known plaintext

I know the plaintext (26 bytes long) and cryptotext of block cipher (suspected to be AES) in ECB mode. I can generate hundreds or thousands of such samples, but the samples are not arbitrary. What are ...
479 views

### Entropy of system data - use all and hash, or trim least significant bits?

I'm working on a background entropy collector for key generation that monitors hardware and produces an entropy pool. Here's my list of sources: Mouse position Keyboard timings (i.e. time between ...
2k views

### How to get the keyword from a keyword cipher?

I was given a ciphertext and now I am trying to break it via looking for the keyword. This is a keyword cipher. So: PlainEnglish: ABCDEFGHIJKLMNOPQRSTUVWXYZ If ...
221 views

### Shannon entropy calculation: is $H(A|R·A) = H(A)$?

Suppose I generate a random $m×m$ matrix $R$, where each of its elements belongs to $\mathbb Z_n$. I ensure that $R$ is invertible in $\mathbb Z_n^{m×m}$. Now I take a non-random $m×m$ ...
703 views

### Salts, how does the script know what the salt is?

I am new to PHP programming and trying to grasp the idea of hashing and encryption for protecting passwords, credit card details and such. I've done a lot of reading about MD5 which I think I ...
505 views

### A mathematical explanation of the DES encryption system

I need a mathematical explanation of what does the DES encryption system really do. This means I need more explanation than the one that offers FIPS, which is more an explanation for computer ...
152 views

### Building a combined encryption scheme from two encryption schemes that's secure if at least on of them is secure

Any thoughts on how this can be done? Let $\Pi_1 = (\mathrm{Gen}_1, \mathrm{Enc}_1, \mathrm{Dec}_1)$ and $\Pi_2 = (\mathrm{Gen}_2, \mathrm{Enc}_2, \mathrm{Dec}_2)$ be two encryption schemes for ...
112 views

### NTRU Encryption

It's using Euclidian inverse. Can you show it step by step? $$N=7, q=11, a = 3+2X^2 -3X^4 +X^6$$ the inverse of $a \pmod {11}$ is $$A=-2+4X+2X^2 +4X^3 -4X^4 +2X^5 -2X^6$$ How do we compute $A$?
203 views

### Sharing an encrypted file between a group of people

Is there any way to share an encrypted file with a group? In the other words, can I encrypt a file with a public key so that each person in a group decrypt it with his/her private key? Is there any ...
94 views

### DES-X , computation load and storage

The passage said that the computational load to attack DES-X can be reduced to approximately $2^{(56+64)}=2^{120}$ steps,and the storage of data sets should be $2^{64}$. But I can't figure why ...
56 views

### Smart card Strong authentication / Verification ( fingerprints)

I'm trying to make a strong authentication software and embedded software in a java card. I have found many papers and publications about the subject… too much information to process and I'm working ...
358 views

### why inverse in diffie-hellman protocol will not give same value?

Security of diffie hellman protocol is $K=g^{ab}$.if sender want to calculate value of $b$(given $a$) he can do $g^{{{ab}^b}^{-1}}$(where K=$g^{ab}$) which will give $g^{a}$ as we are cancelling value ...
87 views

### Addition-only PHE in F#

Using homomorphic encryption, I would like to be able to take an encrypted integer and either add 1 or -1 for a new encrypted value. I do not want the encrypted value to be recoverable - just the ...
327 views

### How can we get CA's public key?

To get a public key of some organization or someone we want to send an encrypted message to, we need to make a request to CA asking that organization's public key. CA then returns X509 certificate. It ...
80 views

### Hash of multiset of values, which lets me compute the hash of the union

Cryptographic hash functions normally take as input a bitstring. I am looking for a hash function that takes as input a finite multiset of values. In other words, given $S \subset \{0,1\}^*$, I want ...
246 views

### ECKS-PS algorithm: searching in encrypted data; bilinear maps

I have found an encryption algorithm named ECKS-PS (published in the paper Efficient conjunctive keyword search on encrypted data storage system) that allows an user to search in encrypted data. All ...
1k views

### AES key/ciphertext space sizes

This is giving me a brain ache now... If I have AES-128, block is 128 bit, then every plaintext (128-bit) can be encrypted to some ciphertext that is also 128-bit. This is the block size. But: 128-bit ...
816 views

### Kryptos : K2. What is the origin of the “abscissa” keyword?

I'm studying the Kryptos sculpture with its cryptographic puzzles K1 to K4. Similar to the "palimsest" keyword for K1, the keyword "abscissa" for K2 was determined by brute-force. To better ...
291 views

### Can Add and Multiply On Cipher Text achieve all operations?

A Fully homomorphic encryption scheme needs to support an evaluate function that can do add and multiply operations on cipher text. Can we do all kinds of complex operations on cipher text like ...
1k views

### How can the Diffie-Hellman key exchange be extended to three parties? [duplicate]

Possible Duplicate: Can one generalize the Diffie-Hellman key exchange to three or more parties? How can Alice, Bob, and Charlie share a common secret key using an extended version of the ...
599 views

### Cryptanalysing Affine cipher

I am trying to cryptanalyse a cipher–text encrypted by Affine cipher. The encryption formula is: $c = f(x) = (ax+b)\bmod m$, where $a$ and $b$ are unknown constants; $x$ is a plain-text symbol, and ...
122 views

### Rijndael S-boxes: Where do the $\mu$ and $\nu$ polynomial ring elements come from?

I've asked some other questions before about Rijndael's S-boxes, and step by step I'm coming to an understanding; but those steps often guide me to new questions. I did some lines of code to ...
63 views

### Does SHA-1 hash have quasi commutative property? [closed]

Although I have tested with a program and found negative answer, I want to be sure.
217 views

### Cracking secret key of a MD5 hash?

I have a MD5 hash which is obtained by hashing certain strings appended by a pipe character ( | ). (I know the values of these) A secret key is added as a suffix to this (I don't know the secret key). ...
78 views

### How to calculate kinv from the given k value

I am implementing an ECDSA NIST test vectors verification application. The test vectors are taken from http://csrc.nist.gov/groups/STM/cavp/#09. One of the test vectors is given below: ...
225 views

### Homomorphic Encryption: how does the equality test on ciphertexts work?

Let's suppose we have a asymmetric crypto-system $H$ which is homomorphic with respect to some function $F$. Alice encrypts a message $m$ with her private key $e$ in the crypto-system $H$ and ...
133 views

### Homomorphic Encryption Notation Question

What does the following notation mean in a homomorphic encryption scheme? ENC(x;r) What does x and ...
122 views

### No Birthday Attack to TCR

I'm reading the paper “Collision-Resistant Hashing? Towards Making UOWHFs Practical” , which compared TCR (Target Collision Resistant) and ACR (Any collision Resistant). It says we wish to stress ...
292 views

### How to secure a mental poker protocol? [closed]

I would like to implement a mental poker protocol in a secure fashion. How should I go about that without (preferably) infringing on the Mental Poker Framework patent?
271 views

### RSA given q, p and e?

I am given the q, p, and e values for an RSA key, along with an encrypted message. Here are ...
174 views

### Hash Based Encryption (fast & simple), how well would this compare to AES? [duplicate]

First of all, I know it's a very bad idea to invent your own encryption algorithm. It's better to use existing known, trusted, extensively tested and studied algorithms with a proven track record. The ...
1k views

### How to Mathematically Prove the Bilinear Pairing Properties [closed]

I am currently working on Bilinear Pairing.To start my work i need to find the mathematically prove of three properties of bilinear pairing. Let $G_{1}$ and $G_{T}$be a cyclic multiplicative ...
82 views

### OTP - Reuse key BUT add IV, is it secure enough?

EDIT: REUSING KEY IS SECURE! OTP - Reusing key IS SECURE! PROVED! I have already asked a similar question and now I can continue to this question about adding a "extra key" = IV. My last question ...
134 views

### OTP - Reusing key IS SECURE! PROVED! [duplicate]

EDIT: This is not a duplicate, in this I have explained WHY this should be secure and not if it is secure, so please stop down-vote if you haven't read everything. I have questioned before about my ...
13k views

### What are the differences between a digital signature, a MAC and a hash?

A message may be accompanied with a digital signature, a MAC or a message hash, as a proof of some kind. Which assurances does each primitive provide to the recipient? What kind of keys are needed?
26k views

### How can I use SSL/TLS with Perfect Forward Secrecy?

I'm new to the field of cryptography, but I want to make the web a better web by setting up the sites that I host with Perfect Forward Secrecy. I have a list of questions regarding the setup of ...
26k views

### Explaining weakness of Dual EC DRBG to wider audience?

I have an audience of senior (non-technical) executives and senior technical people who are taking the backdoor in Dual_EC_DRBG and considering it as a weakness of Elliptic curves in general. I can ...
6k views

### Is modern encryption needlessly complicated?

RSA, DES, AES, etc. all use (relatively) complicated mathematics to encrypt some message with some key. For each of these methods, there have been several documented vulnerabilities found over the ...
1k views

### How is the MD2 hash function S-table constructed from Pi?

For fun, I'm learning more about cryptography and hashing. I'm implementing the MD2 hash function following RFC 1319 (http://tools.ietf.org/html/rfc1319). I'll preface by saying I know there are ...