# All Questions

161 views

### Is it possible to add OpenSSL engine for a block algorithm with different input and output block size?

I need to add a new symmetric cryptography algorithm to OpenSSL, and I thought that the best way to do it is via its engine API. This algorithm will later be used by an application via the OpenSSL ...
84 views

8k views

### How does one calculate a primitive root for Diffie-Hellman?

In the Diffie-Hellman key exchange, one of the steps involves calculating a primitive root of a prime number $p$. How would one go about doing so, considering that $p$ could be very large? Is there ...
3k views

### Is a die implemented in a physics engine truly random?

So, a fair die throw is really random, not pseudo. So, would a RNG implemented as the result of a die throw in a physics engine (say, Newton, Havok, Nvidia's PhysX) be regarded as both ...
240 views

### Brute Force AES Calculations

I have an encryption service in which the user decides the length and the type of key, so I would like to build a tool that educates the user on the brute force times for the key they created if using ...
98 views

### NIST implementation of the Lucas primality test

The NIST standard FIPS 186-4 describes an implementation of the Lucas primality test in section C.3.3. I can follow the algorithm but I am puzzled by step 6.2: ...
68 views

### Key escrow on indistinguishability games

Does it mean that when PPT attacker is breaking an indistinguishable based (equivalent with semantic security) game with non negligible probability that he is able to infer the secret keys either on ...
3k views

### Why is OCB-AES mode not becoming a standard for authenticated encryption?

The OCB mode of authenticated encryption (used for example with AES) is the fastest way to provide authenticity and confidentiality without having to strive into questions like: Encrypt then MAC, MAC ...
118 views

### In RSA, why does Alice's $N$ need to be relatively prime to Bob's $N$?

I was asked this by my professor and I didn't understand the reasoning behind it. If Alice has a the key pair $(p_a, n_a)$ and Bob has the key pair $(p_b, n_b)$, why do $n_a$ and $n_b$ have to be ...
75 views

### Understanding Cryptography practically [closed]

I have just undergone a one semester course in cryptography. I was introduced to multiple theoretical aspects, the way several algorithms work, the methods and their stability and so on. Due to time ...
185 views

### AES mix column stage

In a PDF related to AES algorithm for mix column stage is written: The multiplication mentioned above is performed over a Galois Field. The mathematics behind this is beyond the scope of this ...
605 views

### For a one-time pad, which MAC method is information-theoretically secure?

In the the main post about MAC methods it mentions a few methods: Authenticate And Encrypt: The sender computes a MAC of the plaintext, encrypts the plaintext, and then appends the MAC to the ...
326 views

### Square roots, prime factorization

I´m stuck in my homework and since its homework, I would rather get some hints than full solution. The problem goes: factorize n = 88416763 in case that you know that the square roots of 51733469 ...
472 views

### Why to try get key out of white box crypto? How can one protect WBC itself?

Help me understand the following. With WBC the question is mainly being stated as can one try to break WBC to identify the key. My question is: Why would one ever want to do that anyways? If one can ...
252 views

### Can DH_anon really be exploited by an attacker?

General consensus is that DH_anon (and ECDH_anon) ciphersuites should be disabled since they offer no way to verify if the server is the one you intend to communicate with. However, I have never run ...
115 views

### Timing Attack on OpenSSL by Brumley

I am referring to this paper by David Brumley and Dan Boneh: Remote Timing Attacks are Practical (In proceedings of the 12th Usenix Security Symposium, 2003). In this paper on page 4, Brumley ...
212 views

### What, cryptographically speaking, is a “long message”?

I have read about long message attacks on some cryptographic hash functions. However, I don't quite understand what is being referred to as a "long message". Also, do long message attacks only apply ...
80 views

### The use of the term “sound” in cryptography [closed]

We often see the term "sound" in cryptography. What is the sense of this word ? Thank you.
120 views

### Is SEAL 3.0 broken?

I'll like to know if SEAL 3.0 (cf http://web.cs.ucdavis.edu/~rogaway/papers/seal.pdf) is broken. I stumbled on Bernstein's website that claimed that SEAL 3.0 has been broken. (cf ...
97 views

### Is $(f(X), G(X))$ pseudorandom?

If $f:\{0,1\}^n \to \{0, 1\}^n$ is a one-way function, $G:\{0, 1\}^n \to \{0, 1\}^m$ is a pseudorandom generator, and $U_m$ is the uniform distribution over $m$-bit strings. Is the joint distribution ...
209 views

### Security of RSA with $\gcd(pq, (p-1)(q-1))\ne 1$

The Congress of ThéOùÇa enacted that civilian use of any public-key encryption system is authorized on the territory of ThéOùÇa, subject to meeting certain security requirements published by the ...
190 views

### Serpent 256bit Non bit sliced version (Table Sbox/IP/FP/LT/ILT) (Non-bitslice notation rules)

Good afternoon! I got some mismatches while counting Round Keys at non bitsliced version of Serpent. I have used official AES submission outputs (file ecb_iv.txt). AES submission package test vector: ...
96 views

### what is contained in a public key certificate

Public key certificate is a digitally signed document which verifies the sender is indeed the person. May I know how can the receiver tell the sender is indeed the person solely based on information ...
307 views

### RC4 encryption/ decryption with hashing

I am working on RC4 encryption/ decryption algorithm based on the following: A wants to send M to B, for that A did: H = Hash (K||M) C = Ek (M||H) A sent ...
244 views

### How do I safely anonymize/hash a unique identifier to protect privacy?

I am building a system to collect a unique identifier (MAC addresses from 802.11 probe requests). The system will have several collection points over a large area, submitting to a central database. I ...
145 views

### Multi-round Transposition/Playfair as a secure hand cipher in the computer age

Given that computers can be easily compromised, there is a need for a hand cipher that can withstand computer attack. Clearly the traditional hand ciphers fail. One time pads work. They also have ...
93 views

### Showing that $2^{N-1}\equiv1\pmod N$ when $N=2^p-1$ for prime $p$

I got this question on a previous exam and I got it wrong. I've gone back through it several times since then, but I can't seem to get it. I would really like to know how to do it, so if someone could ...
413 views

### Is splitting AES ecrypted data safe?

Say I have a key, an iv and an AES/GCM/NoPadding encoded string and I want to split this information between three people such that only jointly can they reveal the ...
107 views

### Is XCBC where k2 and k3 might be the identical, secure?

XCBC paper says all three keys should be independent. It doesn't say they must always be different. However it seems this is necessary to differentiate padded message and message without padding. ...
113 views

### Using same key for encryption and ECBC-MAC k2

ECBC-MAC: $E_{k_2}(CBC-MAC_{k_1}(m))$ If we use same key for encryption (CTR or CFB) and k2 (end tag encryption) in ECBC-MAC in encrypt-than-MAC sheme, is it secure?
65 views

### How good is middle cube method with jumbled digits?

I had to make my own prng for a stream cipher for an inter school science project (I am mentioning that a lot). So I thought of cubing the seed instead of squaring it (like in the middle square ...
404 views

### File format of an $2048$ bits RSA public key

From here, there are $14$ bytes specifying the file format of the key. I am still quite confused about the format bytes. For example, the following public key 30 82 01 0a 02 82 01 01 00 8e a3 d1 c7 ...
86 views

### Is a RSA 2048 bits public key secure [duplicate]

I realize servers such as Google, Yahoo, which use RSA has 2048 bits public key. After comparing those keys, I realize that the public keys share a common property, that is first 9 bytes and last 5 ...
86 views

I've got an API spec that specifies NRPAD and FPAD as possible padding schemes. I see these being used together with the Korean SEED algorithm. The SEED specification however is void of any padding ...
176 views

### Show that the equal difference property exits for a modified DES encryption system

My cryptology professor gave us this problem on a past homework assignment and I only managed to get one of the 3 parts correct. Needless to say, I want to know how to do the other two parts as well. ...
92 views

### How can a good encryptor be made?

I am making an encryptor software for a stream cipher with my own PRNG as a project for an inter school science competition. How can I make one so that after it generates the pseudo random nos. it can ...
938 views

### Openssl & RSA : how many public exponents are possible?

I would like to know if it is possible to set the public exponent we want with "OpenSSL RSA" or if it is really limited to 2 possible exponents: 3 65537 If yes, why ?
213 views

### AES: Changing plaintext to state

Can someone explain this to me? For example how M chanes to 0c? Changing plaintext to state:
85 views

### Why do we need password in a server which uses TLS?

Suppose a server uses TLS to protect communication between us and the server. I observe that in the TLS handshake protocol, password is not mentioned anywhere. Then why do we need to have a ...
331 views

### Cryptographic system with double keys with reversible order

While reading Shamir, Rivest and Adleman's paper on "Mental Poker", I've met a mention of system such that $E_a(E_b(x)) = E_b(E_a(x))$, without however disclosing details on it, with $E_a(x)$ being ...
350 views

### AES— Brute force attack versus Known plain text attack

I am taking a codes and cryptology course and the following is a questions on a past exam that I could not and still can't solve: ...
210 views

### How can a good pseudo-random number generator be made?

I am trying to make a pseudo-random number generator so that I can use it in a synchronous stream cipher for encrypting plain text. I want it to generate numbers which are as random as possible. What ...
333 views

### CRC32 vs. low 32 bits of cryptographic hash

I was having a discussion with a colleague yesterday whose education and experience exceeded mine. He said something yesterday that sounded incorrect to me intuitively, but I don't have the knowledge ...
421 views

### RSA Decryption given n, e, and phi(n)

my cryptography professor gave us this problem for extra credit a while back and I attempted it but I didn't get it correct. I have gone back to it, but I'm even more lost now than I was the first ...
58 views

### When homomorphic encryption goes wrong?

Consider I have two ciphertext $c_1$ and $c_2$ encrypted using RSA encryption. By definition if I multiply them I'd get $c_1.c_2 \ modN$. My question is what would happen if $c_1.c_2 >N$. Can we ...
448 views

### Simplest code for 64-bit block RSA-like encryption/decryption and key generation

Looking for the simplest code in C. Need a set of functions that will first generate a public/private 64-bit key pair, and then the function to code/decode a given 64-bit block, no built-in checksum ...
260 views

### Is it feasible to use combination of ABE schemes for encrypting the data?

I have a peculiar requirement for preserving the shared log files. For example I have 1000 records which belong to different organizations as listed below and all the logs are present in a single CSV ...
I've thought up a way to represent the transformation of S-Box in DES by ANF. Let $x_i\;(1\le i\le 6)$ be the input of an S-Box, $y_i\;(1\le i\le 4)$ be the output, for example, then y_1= 1\oplus ...