# All Questions

539 views

### What are the key differences between the draft SHA-3 standard and the Keccak submission?

I just noticed that on the NIST website there is a PDF with a draft of the SHA-3 standard (i.e. FIPS 202) (marked as "new", and seemingly the page was last changed on April 7, 2014). Previously it ...
198 views

### “Fine grain Cross-VM Attacks on Xen and VMware are possible” and OpenSSL 0.9.7

Here's a paper that just made its way into Cryptology ePrint Archive: Fine grain Cross-VM Attacks on Xen and VMware are possible!. Its a good survey of past attacks and presents a couple of new ...
3k views

### Use cases for CMAC vs. HMAC?

Both can be used to verify the integrity of a message. Assuming you have the needed primitives available to you (i.e. the code space of needing both a cipher and a hash function isn't prohibitive), is ...
102 views

### Why does computing g^a * g^{-a} with the PBC library result in zero?

My example code is as follows: /* * Example 1 * 1) Calculate g^a * 2) calculate g^{-a} * 3) multiply g^a * g^{-a} * */ Note: here ...
100 views

### Definition of one-way functions: randomly-chosen point vs every point

Notation: $\Sigma^k$ is the set of $k$-strings on the alphabet $\Sigma$; $\Sigma^\ast$ is the set of all finite dimensional strings on the alphabet $\Sigma$. In the context of computer-science a ...
3k views

### How to calculate Modulo using a standard calculator for a one time pad encryption

I wrote a simple python script to preform one time pad encryption I would like to be able to decrypt the ciphertext by hand. In my script I use mod 26. This is how I was shown to calculate a mod ...
1k views

### Leaving authentication data blank less secure for AES GCM?

The AES GCM example for Ruby / OpenSSL shown at: http://ruby-doc.org/stdlib-2.0/libdoc/openssl/rdoc/OpenSSL/Cipher.html has a GCM example of the following: ...
3k views

### Which algorithms are used to factorize large integers?

Even if RSA decided to cancel the Factoring Challenge, it seems that some teams keep working on it. According to Wikipedia, RSA-768 has been factored in late 2009. What are the current large integer ...
2k views

I'm conducting an experiment dealing with differences in padding across different aes operations for my Intro to Crypto class, and the question says OpenSSL uses PKCS5 padding, and that I need to ...
1k views

### Security of N bit HMAC

Lets say that I am using 128 bit HMAC. How many operations are needed to find a "non secure" message. Is a birthday attack possible?
164 views

### Why do we need extra hashing if we could use simpler scheme?

Lets say that we use init vector IV, key K and HMAC key H. Message is M. Mode of operation is CBC !!! We usually encrypt this way: ...
93 views

### Is a tweakable block cipher still considered deterministic in nature?

"a block cipher is a deterministic algorithm operating on fixed-length groups of bits, called blocks, with an unvarying transformation that is specified by a symmetric key. - Wikipedia " But with a ...
118 views

### Cryptography Implementation in software

I am trying to implement a password manager in C and I had a question about the proper steps in implementing the crypto. I looked at some implementations, google talks on crypto and what the standards ...
79 views

### MAC security and adversaries with memory

The usual definition of MAC security is (roughly) that there is no "efficient" adversary that has non-negligible advantage in the "MAC game" where the MAC game is as follows: the challenger chooses a ...
175 views

### Is there a reason that the N value in scrypt is limited to powers of two?

I have been looking at the scrypt hashing algorithm and am confused as to why the N value, which determines the overall cost, is limited to powers of two. There are ...
408 views

### Relation between key size and PRNG state size

Some (supposedly) cryptographically secure PRNGs have an internal state of only 160 bits or less. When the algorithm is otherwise properly designed, that seems like enough to generate a 128 bit key ...
209 views

### Is it necessary to use single hash function for signature generation and HMAC?

I am trying to figure out if we need to use single hash function across all the places in a ssh session. i.e – signature generation/verification and HMAC calculation/validation. Is it possible to use ...
102 views

### Cryptographic library quality [closed]

I've been working on a project that will require secure communication over the internet, so I've been thinking of TLS 1.2. After looking around I chose Botan but then I thought about using a more ...
330 views

### What does it mean when two encrypted files, encrypted with the same method but with different keys, when xor'd together, produce a repeating pattern?

Let's say I have fileA and fileB, both encrypted somehow, but in the same method with different keys. If I xor them together, they will make a repeating pattern of 32 bytes length. What does that ...
400 views

### One time pad: why is it useless in practice?

The symmetric cryptosystem One time pad (OTP) seems to be very beautiful since it is perfectly secret according to Shannon. Many books, however, point out that the main drawback is that one must ...
135 views

### Is ElGamal still unforgable if the adversary knows r

Is ElGamal still unforgable if the adversary knows the value of $r$ that was calculated by $g^k$? When we do sign the message $msg$, we calculate $r = g^k$. As we know the regular ElGamal ...
228 views

### Using Stream Cipher as CSPRNG

Are there any guidelines or justification for converting a stream cipher algorithm for use as a CSPRNG? For instance, lets say I wanted to convert one of the eStream portfolio Profile 1 (software) ...
114 views

### Is there a method to combine encryption and ring signing?

There's the well-known question on whether to sign or encrypt first. However, if instead a message is to be ring-signed such that either recipient could be the actual signer, is there any scheme that ...
88 views

### Do Chosen-Chiphertext attacks only apply to public-key cryptosystems?

Do Chosen-Chiphertext attacks (CCA-1/2) only apply to public-key Cryptosystem?
236 views

2k views

### Turning a cipher into a hashing function

This is theoretical question. I'd like to know if it's possible (and what are eventually the consequences), not that I'm going to do it in one of my projects. ;) The first hashing functions created ...
98 views

### Existence of a map $\phi:\mathbb{Z}_{N^2}^* \mapsto \mathbb{F}$

Is there a map between the group of $\mathbb{Z}_{N^2}^*$ where $N$ is a composite number , a product of two equal size secure prime numbers $p$ and $q$ and a finite field $\mathbb{F}$, such that for ...
82 views

### Composing hashes and/or MACs

Suppose I have n hash/MAC functions, of which n-1 are extremely insecure, leaving only one that is in fact cryptographically secure. If I use all of them on a message and the XOR them together the ...
50 views

### Is anyone aware of Du atallah multiplicative secret sharing scheme for dot products for > 2 party scenario?

I am working on Du Atallah's multiplicative secret sharing scheme for more than 2 party scenario. Is anyone aware of its multiparty version (more than 2 parties). The paper for 2 party can be found ...
1k views

### Are AES-256's related-key weaknesses exploitable if it is used to build a hash?

Assume it is made a hash based on AES-256 encryption (perhaps because this is hardware-accelerated, but no standard hash is); and it is used the Merkle–Damgård structure, that is padding of the ...
1k views

### Are there any elliptic curve asymmetric encryption algorithms?

RSA offers the functionality of encrypting (short messages, or symmetric keys) with a public key, and decrypting with a private key. However, RSA key generation is extremely expensive, especially for ...
436 views

### Block cipher and parity of permutation

Can anyone explain the following text passage to me? Most real-world block ciphers build even permutations, because it's hard to build odd ones using small operations (32 bit) on larger (128 ...
704 views

### Does AES-128 have the same strength as AES-256 with a padded key?

When I use the same 128-bit key for AES-128 and AES-256 with a known/public padding for the latter, is there some weakness in AES-256 that is not present in AES-128 with essentially the same key? ...
241 views

### Is there a simple zero knowledge proof of $x$ for $b=x^x\pmod p$?

We have a multiplicative cyclic group $G$ which is a subgroup of $(\mathbb{Z}/n\mathbb{Z})∗$. There are two parties, Alice and Bob: If: Alice knows: $b$ and $x$ such that $x^x = b$; Bob knows: $b$. ...
72 views

### Positioning of keys in encrypted text

I'm just looking at very simple encryption. I've noticed that the key is typically either at the front or at the back of the encrypted text. This is quite easy to break if you know the key. It can ...
1k views

### Why does HMAC need a fixed length padding?

As everybody knows in order to calculate HMAC we have to concatenate padding to the message. I am just curious why the padding needs to be fixed-length. Why do we need the blocksize parameter here? ...
852 views

### What is a 'secret key factory'? What precisely is it doing? [closed]

I have found a Java implementation of AES CBC mode that runs in Netbeans. The lines below appear to create the key from password and salt: ...
884 views

### Attack of an RSA signature scheme using PKCS#1 v1.5 encryption padding

My best interpretation of this question is that Java's crypto API has been subverted to perform RSA signature using PKCS#1 v1.5 encryption padding. Assume the signature $S$ of a message $M$ is ...
89 views

### Exchanging Keyspace and Message space in PRF

Suppose there is a secure PRF $F: K \times X \to Y$. Then is $F': X \times K \to Y$, defined by $F'(x,k):=F(k,x)$, a secure PRF? In my opinion it should be because exchanging the keyspace with ...
492 views

### Does ElGamal Encryption create a different key for each block sent?

I ask about ElGamal algorithm. Is ElGamal algorithm used new key for each encryption process. in other word it should we use new key for each chunk? For example, if we have message that has four block ...
751 views

### How to select $g$ in Paillier Cryptosystem

For my cryptography class project in university I have selected Paillier Cryptosystem as a course project ...
259 views

### does re-encrypting the same value with multiple keys reduce security

I found myself wondering today, how much security is lost if you take a plaintext - assume that its content, including any metadata is unknown to an attacker, for example it may be random data - and ...
259 views

### Homomorphic Encryption and Semantic Security using Lattices?

I've been reading Brakerski and Vaikuntanathan's "Efficient Fully Homomorphic Encryption from (Standard) LWE" and I'm still digesting pieces at a time. Under section 1.1, "Re-Linearization: Somewhat ...
59 views

### How to make sure the pre-agreed information safe for DH-Key Exchange

The definition of DH key exchange was given as the method let two authenticate each other & exchange the crypto key over an insecure channel. DH-key-exchange was innovated to defence ...
183 views

### implementing a cryptographic hash with a block cipher [duplicate]

How can a cryptographic hash function be implemented/created using the block cipher? I was wondering if we can use AES in cipher block chaining mode to implement it.
271 views

### PRP, PRF and modular arithmetic

Are there any arithmetic or mathematical functions that can be used as PRPs or PRFs ? Since, Conventional block ciphers like AES are that are proven to be good PRPs are not based on mathematics but ...
Can the knapsack be used in cryptography in a secure sense (described below)? Knapsack problem: Given some number $X$ and a set $W$ of weights $w_1, w_2, ... w_n$, find a subset $S$ of $W$ (if it ...