3
votes
1answer
1k views

Implementing AES encryption for firmware distribution system

I need to implement an AES encryption for firmware distribution system. I have a bootloader that can decrypt various AES variants (ECB,CBC,CTR). When I approached this I found few issues that aren't ...
3
votes
3answers
271 views

Existing works on pre-computing ElGamal ephermal keys

I was playing around with a problem in e-voting schemes that use additive homomorphic encryption to tally votes, namely that at the end of the day somebody (or somebodies, if the secret material has ...
3
votes
1answer
343 views

Is truncating a hashed private key with SHA-1 safe to use as the symmetric key for AES for data at rest?

I realize this is mixing the purposes between asymmetric and symmetric crypto, but I was wondering if it is safe to use a hashed, truncated private key (asymmetric) as the symmetric key for encrypting ...
3
votes
1answer
346 views

RSA algorithm's license free or paid?

I checked RSA's patent application, which was registered in 1983. As patents don't last more than 20 years, it seems to me it should be free. But my friend said to use RSA I have to buy a license from ...
3
votes
1answer
199 views

Stream ciphers based on discrete logs

Blum Blum Shub is a stream cipher that is provably reducible to the difficulty of factoring integers. I'm wondering whether there is a similar construction for discrete logs? For example, I could ...
3
votes
1answer
220 views

Where can i find relative software for differential cryptanalysis?

Is there any publicly known software for differential cryptanalysis over some cryptographic building blocks as blocks ciphers or cryptographic hash functions
3
votes
2answers
122 views

When to prefer exchanging cryptographic certificates over exchanging only public keys?

Let's think of the following case: A group of peers want to exchange messages with each other. They use public-key cryptography to sign and encrypt messages. Anyone with any name can join the ...
3
votes
1answer
518 views

How do I generate a session key using the Diffie Hellman algorithm?

How to generate a session key between two nodes in two different subnets when the nodes don't know each other directly, using diffie hellman algorithm?
3
votes
1answer
427 views

Is XOR in a CBC-like mode secure?

Assuming that $K_{n}$, $P_{n}$, and $C_{n}$ are individual bytes of the key, plaintext, and ciphertext respectively. The first byte of ciphertext is computed like this: $C_{1} = K_{1} \oplus P_{1}$ ...
3
votes
1answer
156 views

DIfferent inner and outer hash functions for NIST Recommended HMAC?

The NIST recommended HMAC uses $$\operatorname{HMAC}_k(text) = H_\mathrm{out}( (k \oplus \mathrm{opad}) \operatorname\| H_\mathrm{in}((k \oplus \mathrm{ipad}) \operatorname\| text) )$$ Is it ...
3
votes
1answer
218 views

Is there a known vulnerability when using identical key and salt with PBKDF2?

For optimum security, a random salt should be chosen for PBKDF2. I came across a scenario where I produce a hash of a random file that serves as the "password". Due to the nature of files, this has ...
3
votes
1answer
313 views

What type of hash functions provides non-malleability of hash digests?

I want to use a hash function for commitments. I don't want an attacker to construct a commitment related to a previously published (but still unopened) commitment. A simple deterministic commitment ...
3
votes
1answer
245 views

OCB - brute force against unknown IV

I read that brute force attacks against a plaintext encrypted in OCB with unkown key and IV has approximately the same complexity as an attack where only the key is unknown. Why is that ? Is there a ...
3
votes
2answers
498 views

Inverses in Truncated Polynomial Rings

I've been trying a long time to understand a thing which is obviously extremely simple, but I just can't get it. Read this, please: The NTRUEncrypt PKCS uses the ring of truncated polynomials $R$ ...
3
votes
1answer
527 views

KeeLoq showing that decryption is indeed the inverse of encryption

In some text I am reading, there is an exercise asking to show that KeeLoq decryption function is the inverse of the encryption function. Details about KeeLoq are given in the Wikipedia article. As I ...
3
votes
1answer
85 views

How can I know when a file was signed?

I have been thinking about digitally signed documents (Word files and PDF files) and can not get over the fact about - how can I securely know when the file was signed? Scenario: If the date of the ...
3
votes
1answer
64 views

What are options to compute DES retail MAC (aka ISO 9797-1 mode 3) under PKCS#11?

The DES retail MAC, also known as ISO 9797-1 mode 3 with DES, computes the MAC of a block of data using a 16-byte (112 bit) key. It can be seen as CBC-MAC using simple DES with the first half of the ...
3
votes
1answer
69 views

Entropy Loss of KDFs

Am I losing any entropy when using KDFs, such as the ones in NIST Special Publication 800-108? For example, can I derive 128-bit session keys from a (uniformly random) 128-bit master key?
3
votes
1answer
89 views

Multi-key decryption

Let's assume I want to send a secret message to $N$ recipients in an asymmetric way. My message could be encrypted with $N$ different public keys $p_i$ one after another and send to each user ...
3
votes
1answer
115 views

Luby-Rackoff theorem confusion

The Luby-Rackoff theorem states that if a round function is a secure pseudorandom function (PRF) then 3 rounds are sufficient to make the block cipher a pseudorandom permutation (PRP). PRPs are ...
3
votes
1answer
99 views

Using GMAC for Authentication without encrypting the message

I am pretty new to cryptography and have a sample of GCM mode of operation for AES. PFB the code ...
3
votes
1answer
78 views

Decrypting an encrypted text out of order

Does there exist a cipher that can be encrypted twice with two different keys and then decrypted twice using either key first? For example: ...
3
votes
1answer
73 views

Galois field step in XEX mode

I'm reading through the XEX mode spec, and I want to make sure I've understood the $\alpha^j$ step correctly: $X = E_K(I) \oplus \alpha^j$ $C = E_K(M \oplus X) \oplus X$ where: $M$ is the ...
3
votes
1answer
91 views

Is there a practical upper limit for password rehashing?

When using PBKDF2, is there a practical upper limit to the iteration count above which we lose security? Note: If you answer “No”, that's fine. But if you answer: “There can't be an upper limit“, ...
3
votes
1answer
118 views

Does adding a salt to the message before HMAC processing add any security?

An HMAC function is designed to verify message integrity, i.e., that the message has not been tampered with. It is generally (always?) implemented by using a hashing function ...
3
votes
1answer
110 views

Pseudorandom permutations on domains of arbitrary (i.e. not a power of 2) size

The Feistel cipher algorithm produces a pseudorandom permutation with domain size equal to $2^{2m}$ (for some $m \in \mathbb{Z}^+$). That is, a one-to-one function $\pi$ of the set $\{0, 1, 2, \dots, ...
3
votes
1answer
112 views

Math to replace s-boxes - Good or bad idea?

The following was going through my brain for the past week. If my thoughts are generally known to the cryptographic community would someone provide a link or two. Even if I’m making a classic newbie ...
3
votes
1answer
123 views

Attacks on AES-128 (ECB) based on some knowledge of plaintext

I'm working with a third party protocol which employs AES-128 in ECB mode of operation to encrypt a packet composed of 16-byte blocks (it encrypts each block independently). I'm trying to determine if ...
3
votes
1answer
128 views

Is it a good idea to use Lagrange/Newtonian interpolation for encryption?

I see that Lagrange interpolation is commonly used for secret sharing, but could it be used for encryption? The goal is to reduce database I/O and compute new values on the fly. Suppose the use case ...
3
votes
1answer
86 views

Is email an example of public-key cryptography?

It seems like email is at least analogous to public-key cryptography, the public portion of the key being your email address, and the private portion of the key being the password to the email ...
3
votes
1answer
148 views

Description of signatures with message recovery (as in ISO/IEC 9796-2 and EMV Signatures)

I'd like to get an overview of how the signatures with message recovery work, especially in case EMV and other smart card systems. Is there a nice overview available without being required to read the ...
3
votes
1answer
163 views

How to calculate inverse affine transform in AES from forward affine transform?

In AES the forward affine tranformation matrix is defined as: $$ \begin{bmatrix} 1& 0& 0& 0& 1& 1& 1& 1 \\ 1& 1& 0& 0& 0& 1& 1& 1 \\ 1& ...
3
votes
2answers
134 views

What are good combinations of public key algorithms or primitives for long term security?

There has been talk in literature about doing multiple encryption with different block ciphers or stream ciphers several times before, and the benefits and risks of such efforts. There may be hidden ...
3
votes
2answers
171 views

Creating a license system based on asymmetric encryption (RSA or ECDSA)

I’ve spent a couple of days researching the topic of creating a license system for my desktop software. While I fully understand that there’s no perfect copy protection, this approach seems to have ...
3
votes
1answer
132 views

Security benefits of Ed25519 generating signatures deterministically

I am reading on the Ed25519 curve, and I am trying to understand a claim. Here is the claim: Foolproof session keys. Signatures are generated deterministically; key generation consumes new ...
3
votes
1answer
205 views

ECC public key encryption and authentication - ECIES with ECDSA vs ECDH with AES

I'm currently working on a project where I want to establish a secure and authenticated communication channel between to entities, using Elliptic Curve Cryptography. Now I'm not really sure how to ...
3
votes
1answer
167 views

Is pairing based cryptography ready for productive use?

I'm currently testing one among those many interesting cryptographic protocols based on bilinear maps. It's quite hard to understand the underlying fundamentals, especially since there are several ...
3
votes
1answer
112 views

FHE over the Integers - reduction to approximate gcd problem

I have three quick questions concerning the reduction of the scheme to the approximate gcd problem: What exactly do the authors mean by $q_p(z_1')$ being the odd part of the gcd? (last line of step ...
3
votes
2answers
225 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 ...
3
votes
2answers
118 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 ...
3
votes
1answer
110 views

XOR with constant key in CBC mode

I have a hypothetical encryption scheme where somebody uses the one-time pad in CBC mode. That is, the block cipher is $E(k, m) :=k⊕m$, and that block cipher is used in CBC mode. Now, I am assuming ...
3
votes
1answer
67 views

Compression step of PGP

We do compression in PGP. Does this step increase/decrease or either have any effect regarding the authentication of a message?
3
votes
2answers
141 views

Is that possible to use encryption higher than 256-bit?

When browsing websites with Chrome sometimes I can see a green lock and encryption info inside. It says the connection with this website is 128-bit or 256-bit encrypted with TLS1.2. So I'm wondering ...
3
votes
1answer
98 views

Homomorphic Encryption - Smart Vercauteren Batching

I'm going through Smart and Vercauteren's paper "Fully Homomorphic SIMD operations" and had a question about some notation used in the paper. In section 2 of the above it is stated that for each ...
3
votes
1answer
169 views

Compare RFC 5246 SessionID re-use versus RFC 5077 Session Resumption?

Can you help me understand the differences, both algorithmic and practical, between RFC 5246 SessionID re-use and RFC 5077 Session Resumption? Both appear to be ways to nail up a second TLS session ...
3
votes
1answer
95 views

Quadratic Sieve: what's the next step after it fails?

Factoring some 20-45 digit values n with a (simple) quadratic sieve, the quadratic sieve may end up with pairs of x and y s.t. $x^2 \equiv y^2 \pmod n$, but neither x+y nor x-y has a nontrivial gcd ...
3
votes
1answer
77 views

What is the importance of the $r$ and $c$ values for the Sponge Construction?

What is the importance of the $r$ and $c$ values? Keccak[r=1600,c=0] is stated on a calculator on the Keccak website to be a checksum. But I figured if c=0, then there's only one possible output? ...
3
votes
1answer
133 views

Unpredictability vs randomness

I'm experimenting with creating an entropy source for an environment where I have no hardware available and the language is very high level (executed in a virtual machine). I know it's not a good idea ...
3
votes
1answer
243 views

Any use for now-defunct Mt Gox Yubikey?

As everyone is now aware, Mt Gox has declared bankruptcy. As what appears to be the very last thing they did, Mt Gox accepted my $35 and fulfilled my special Mt Gox Yubikey. Having just arrived in the ...
3
votes
2answers
220 views

GCM encryption for 256-bit and 512-bit block ciphers

The Galois/Counter Mode of Operation (GCM) This paper describe using GCM mode with 128-bit and 64-bit block cipher. Can we use this mode for 256-bit and 512-bit block cipher?

15 30 50 per page