# All Questions

374 views

### How to verify a shared secret using only AES?

I have two devices that need to verify that they both are in possesion of the same secret key. One of the devices is a very limited embedded device that only has AES128 available, no SHA or other hash ...
224 views

### Are well designed crypographic codes unbreakable? (NOT ciphers)

Codes are not to be confused with ciphers. It is known that all known ciphers are theoretically breakable except the one-time pad and this isn't what the question is about. Some cryptographic codes ...
598 views

### PGP digital signature vs SHA256 HMAC Comparison

First let me admit that I am not a mathematician or a cryptographer. I am responsible for assisting in making a recommendation on a project that is consolidating payment processes within a company's ...
42 views

### trying to get calculator and RSA calculatin does not make sense [duplicate]

got two question, I am novice in the area of crypto and currently in big learning curve. From crypto book I am going over with, I see the RSA algorithm example as follows: it chose two rand #-s: ...
21 views

### RFC 5297 implementation [duplicate]

I am looking for an implementation of RFC 5297 algorithm using javascript. I would like to see how to wrap a key on client side web browser, like Mozilla's fxa-auth-client (That uses a xor to wrap) ...
130 views

### Format preserving encryption FFX

In FFX mode the format of the ciphertext is same as plaintext. How does it ensure data integrity and authentication? Is there any bit flip attack in FFX mode? Is it malleable?
246 views

### AES as Integer Program

I read that AES can be broken by solving a Linear Integer Program (IP). From a given encrypted text, how can one construct this IP? How big is the system?
464 views

### The difference between MAC algorithms and what to use

I've been looking into message authentication codes and found several ways to create integrity for a message. I know of the following algorithms: HMAC, this can use any cryptograhpic hash function ...
128 views

### Simplicity and precision in cryptography papers [closed]

I know a PhD student who recently had his paper on applied cryptography rejected because one the reviewers claimed that it was "the solution was too simple and the notation used was more than ...
65 views

### Energy necessary for brute-forcing or decryption

I am trying to understand how the physical limits of computation apply to crytography, and came up with the scenario below as a sort of gedanken. I would be grateful to see how others answer it. ...
189 views

### Clefia Vs AES 128 bit

I am running a comparison between Clefia (Lightweight cipher from Sony Corporation which is a standard now http://www.sony.net/Products/cryptography/clefia/standard/index.html) and AES 128 bit. The ...
48 views

### Decypting a Stream Cipher

I am trying to decrypt a stream cipher. I know what the first word of the message is when decrypted but I am unsure how to decrpyt the rest of the message. I know what the first word is because I ...
77 views

### Is it a bad idea to use PGP encryption for structured/predictable data?

I'm working on an app and need to encrypt some structured data. The data will be turned into a string form (JSON) before getting encrypted. The data format I'm using will always start with a ...
2k views

### If you hashed a hash an infinite number of times would you end up with a unique hash?

If you took a hashing algorithm for example MD5 and repeatedly passed the output hash back into the algorithm an arbitrarily large number of times would you eventually end up with one unique hash? My ...
171 views

### Can I use the output from a DRBG directly as K for AES, or do I need to use a key generator algorithm?

NIST has 3 validated "Recommendation for Random Number Generation Using Deterministic Random Bit Generators" (DRBG's) that are based on NIST SP 800-90A: Hash_DRBG (based on hash functions) ...
80 views

### How to select a 'tweak' used in FE1 mode format preserving encryption?

I'm experimenting with this library Botan which includes a module for format preserving encryption based on FE1 mode. The parameters for the Encrypt method are as follows ...
332 views

### Block cipher does not provide security by itself

What is this statement all about? When I look at a block cipher it seems pretty hard to break it and the mathematics behind insure a good complexity. It may refer to key generation, initialization ...
376 views

### Key space vs Cardinality of 1024-bit RSA

I have been trying to figure out the encryption key space, and cardinality of 1024-bit RSA. From my understanding, the key generated from 1024-bit will be primes greater than $2^{1023}$ but less than ...
143 views

### SHA-512 partial preimage

I was looking at how SHA-512 works, and I have a question. Imagine I want an input $N$ of 512 bits whose hash in hexadecimal starts with the digits 12345678. How ...
135 views

### Is it safe to derive two different keys with the same password and key derivation function using two different salts?

I would like to know if the following process would harm the security of a fictional system if the persisted data would be stolen: in this system a user has a single password. The password will be ...
68 views

### If a DES key correctly decrypts one message, what's the probability it's the real key?

Suppose an adversary gets a message-ciphertext pair $(M,C)$, where $C=DES_K(M)$. They do an exhaustive key reach to locate the lexicographically first key $T$ for which $C=DES_T(M)$. What's the ...
7k views

### Is it fair to assume that SHA1 collisions won't occur on a set of <100k strings

I'm building a system that has to take file paths, and generate a unique name for each one. I'm planning on using SHA1 as the hash function. My question is: do I have to deal with possible collisions ...
114 views

### Reducing the keyspace for a brute force attack on a chained 64-bit xor

I have a block of data which I know is encrypted using a chained 64-bit xor (sorry if that makes no sense, I'm not familiar with crypto lingo). I know a little bit about what the plaintext should look ...
469 views

### What do $0^n$ and $1^n$ mean in cryptography?

Let $f$ = $\{f_k\}$ be a pseudorandom function family. Let $G(x)$ be a pseudo-random generator such that: $G(x) = f_x(0^k)f_x(1^k)$ where $k=|x|$. I don't understand the meaning of $1^n$ ...
45 views

### What crypto scheme should I use on embedded m2m system with assymetric uplink/downlink bandwidth?

I am working on implementing info security into custom m2m radiolink communication system, which has some restrictions: MCU based endpoint can transmit to gateway with packets max 16 bytes long, and ...
64 views

### Decrypting DES - limited information

I have a list of DES encrypted strings/data, they come in two lengths, 32 chars hex (16 bytes) or - I believe - 64 chars. I know the key, which is 8 ascii chars (I might add that I am the rightful ...
71 views

### FIPS 113 Computer Data Authentication

on the NIST website for Message authentication There is a mention of 2 approved algorithms, i am curious about the first one. the link to FIPS 113, Computer Data Authentication appears to be dead ...
507 views

### What are words in a HASH algorithms

From wikipedia: "They differ in the word size; SHA-256 uses 32-bit words where SHA-512 uses 64-bit words." In this context what do they mean with words? is it the same as a 32 bit (or 64 bit) block ...
38 views

I read about zero knowledge proofs. Let's say you want to create an account at a website. You choose a password $p$ and from $p$ you derive deterministically a public & private key pair $(e,d)$ ...
153 views

### What can cause similar MD5 hashes

I have a set of MD5 hashes with huge similarities in the second half of the hash, (made up) examples: ...
78 views

### Why does the ElGamal signature have the specific form that it does?

In the original paper, ElGamal(1985) starts his discussion of signatures by saying: "The signature ..... is chosen such that the equation: $\alpha^m = y^r r^s \text{mod p}$ (equation 3 from the ...
79 views

### arithmetic calculation problem to quadratic arithmetic program

I am reading the Pinocchio paper (verifiable computation): http://research.microsoft.com/pubs/180286/pinocchio.pdf The paper is rather hard for me. I am considering this calculation problem: ...
183 views

### Zero knowledge / proof of knowledge sudoku solution

I recently started a coursera course "cryptography 1" provided by Stanford university. In one point when explaining zero proof knowledge the instructor mentions the following: Almost any puzzle ...
602 views

### Is it possible to create a “proof-of-upload” system for BitTorrent ratio tracking?

One issue that private BitTorrent trackers that track users' share ratios often run into is how to keep track of people who are screwing with their upload statistics, something known as ...
120 views

### How to attack the Two Time Pad?

I encrypt 2 random keys with the same 'one' time pad. You can get both encrypted keys. You don't know anything besides the size. Is there a way to attack the two time pad in this scenario? And what ...
93 views

### Looking for encryption algorithm not subject to known-plaintext attack with IV reuse

I've encountered an interesting problem where we can basically say the following: We need to encrypt messages, but we have no room to store IVs. We can synthesize IVs; however an attacker would be ...
70 views

### Adding a Random component to CBC MAC in order to enlarge the tag space

CBC MAC that is using AES as the underlying block cipher, has tag space of 2^128. If we add a random single block, concatenating it with the tag, and encrypt it again in AES CBC mode, with additional ...
94 views

### Why Might XOR's Lead to Hash Functions Lacking 2nd Pre-image Resistance?

My hash function is as follows: Cut the string in half (assume even length of 2m) XOR's the two halves together Take the result of the XOR and pass it to a function (a one-to-one and "onto" ...
203 views

### Encryption of plain text using stream cipher algorithm

We know that in stream cipher algorithms plain text and generated key are Xored byte by byte. Generated key depends on how much plain text there is and on that basis key will generate and plain text ...
71 views

### Matsui's Linear attack on DES P box

I'm trying to understand Matsui's linear attack on DES and I have something I don't understand in his paper. In his paper he say that: $NS_{5}(16,15)=12$ (which is OK) and from that he say that: ...
152 views

### Permuted vectors

Consider we have two vectors $v_1, v_2$ of size $n$, and each vector contains $n$ elements. We permute the vectors as: $\pi (k_1,v_1), \pi (k_2,v_2)$. Where $\pi (k_i,v)$ denotes a permutation of a ...
85 views

### Is a padding oracle attack possible if data is only encrypted internally on a server (e.g. for storage)?

I read something about the padding oracle attack when analysing the use of an AES-encryption of data in a database and was "scared" it could be a serious issue. But after investigating a bit further, ...
96 views

### How do revocation certificates work in PGP?

I've already read how to build and upload them, but I'm wondering how revocation certificates work, what informations they hold and so on. Suppose my private key is compromised, but I have a ...
78 views

127 views

### Is the Salsa20/ChaCha20 keystream generation one-way?

Is it possible to recompute the Salsa20 or ChaCha20 key in a realistic time if the keystream and the nonce are given to an attacker? Or is the keystream generation one-way, like a cryptographic has ...
57 views

I have a question about decryption. Let's say I have a bunch of files that are encrypted. Someone gains access to those files, and finds out that he already has one of them, unencrypted. My question ...
66 views

### Are more S boxes more secure in a SP-Network?

The classic DES uses 8 different fixed S boxes. If computer memory was not an issue, would say 800 different S boxes be more secure? I'm thinking of a SP-network that would only run on a server like ...