Questions tagged [algorithm-design]

Design of cryptographic primitives (algorithms), like block ciphers, stream ciphers, random-number generators, hash functions, MACs, key exchanges, public-key encryption or signature schemes. Also tag with the relevant type of primitive. If you ask about a known existing algorithm, also tag with its name.

Filter by
Sorted by
Tagged with
0
votes
2answers
158 views

Is there an efficient algorithm that allows to construct a cryptographically secure $n$-bit hash function based on two unkeyed $n$-bit permutations?

Let $f(x)$ and $g(x)$ denote two independent, “ideal”, unkeyed, public $n$-bit permutations (two publicly known bijective functions that produce $n$-bit outputs from $n$-bit inputs), where $n$ is an ...
1
vote
1answer
63 views

Are there any algorithms for which generating any zero-knowledge proofs is not practical?

It is related to my earlier question: Can zkSNARK or other zero-knowledge proofs be used to proof message authenticity without revealing private key? Are there any algorithms for which generating ...
1
vote
1answer
81 views

Can zkSNARK or other zero-knowledge proofs be used to proof message authenticity without revealing private key?

The situation: Alice and Bob are exchanging messages encrypted by some known asymmetric encryption protocol. All their encrypted messages, as well as public keys are intercepted by Charlie. Can ...
5
votes
2answers
228 views

Is the ChaCha20 block function reversible using known plaintext?

I've been recently implementing the chacha20 stream cipher with Poly1305. As the core operations which make up the Quarter Round of chacha20 (ARX - Addition Rotation Xor) are indeed reversible, does ...
1
vote
1answer
56 views

How to find a small generator with small inverse? Does it have negative impact to security? (for Schnorr subgroup of $\mathbb{Z}/P\mathbb{Z}$)

Given a prime $P$ with $$P= r \cdot q+1$$ with $q$ prime as well. I'm looking for a generator $g$ of the Schnorr subgroup with order $q$ which is small by value and has a inverse (to $\bmod P$) which ...
0
votes
1answer
79 views

Is there an efficient algorithm that allows to obtain a uniform distribution of all possible $4$-bit permutations from a single keyless $4$-bit S-Box?

Let $S$ denote a keyless permutation that operates on $4$-bit inputs and returns $4$-bit outputs (that is, $S$ is a $4$-bit S-Box). In this question, $x_0$ denotes an arbitrary bitstring that ends ...
0
votes
3answers
137 views

Why didn't people redesign the key scheduling algorithm of DES to use longer keys instead of using 3-DES?

To overcome short key length of DES, Triple DES was devised. What would go wrong or why didn't people redesign the key scheduling algorithm to use longer keys?
1
vote
0answers
30 views

Asymmetric non-interactive proof of work scheme

I'm looking for a non-interactive proof of work scheme. I want for it to (1) be faster to find solutions to if you're in the possession of an arbitrary secret, like a private key, and (2) for the ...
1
vote
1answer
178 views

Scrypt KDF cipher (scrypt CLI) - known vulnerabilities and cryptanalysis?

There is a scrypt cipher that is used for example by some cryptos like LItecoin for their mining algorithm. I never heard of scrypt. I know eg SHA-256 which is well analyzed and considered as secure ...
0
votes
1answer
80 views

Division of Point in Elliptic Curve: Getting Back Point

Let $P=(x_p,y_p)$ be a point on elliptic curve $E (a, b) := y^2=x^3+ax+b$, for an integer $n$, there exists a point $Q=(x_q,y_q)=nP$ on $E (a, b)$. If $(x_q,y_q)$ and $n$ are given, what is the ...
2
votes
1answer
69 views

How to store encrypted solutions of a find location game?

I'm coding a bot on Telegram to sustain a quiz game. A group of people (authors) can upload photos of streets or particular landscapes that they have found on internet, without any description, and ...
1
vote
1answer
59 views

Are there low-bit hashing or encryption functions for teaching cryptographical concepts?

I understand how hashing and encryption/decryption work at a very high level, where the functions work as a black box. Hashing scrambles the input in a non-uniquely reversible way, whereas encryption ...
5
votes
2answers
231 views

“One-Wayness” of SHA 1

I recently started learning about Hash Functions for my first time, and I've gone through and have tried to understand the SHA1 process. Brilliant does an excellent job of explaining it step by step. ...
0
votes
1answer
184 views

Is there a method to encrypt relations in between values of a cyclic value set and generate values out of this set with pseudo RNG? (all at user PC)

Is there a pseudo RNG and function $f$ with 1.) The RNG produces a value $v_0$ out of $N$ different values (set $S$). 2.) Independent of the RNG the function $f$ generates $v_{i+1}=f(v_i)$ ...
-2
votes
1answer
464 views

What is AES subkey? [closed]

I saw the AES algorithm that at the end of algorithm the buffer that stored in the beginning of algorithm the encrypt/decrypt key. now is store the last subkey. What is the last subkey? Why do I ...
0
votes
1answer
68 views

What does it mean for a number to be “in the order of” a prime number?

In some papers I'm looking at there is some language that says things like "Choose a random number in the order of prime q" and I see some syntax that it is referring to that looks s = Zq (where q is ...
30
votes
2answers
7k views

Theoretically, what if I were to change some magic numbers in, say, AES?

Purely theoretically. I know it's a bad idea to try to invent your own encryption and that's not the intention here. Just a thought experiment. Say, I change some or all of the magic numbers used in, ...
2
votes
1answer
43 views

Signature over MAC value for a random key

Would it be possible to create a signature scheme like this: $ \DeclareMathOperator{Gen}{Gen_{\Mac}} \DeclareMathOperator{Mac}{Mac} \DeclareMathOperator{Sign}{Sign} \DeclareMathOperator{F}{F} \...
0
votes
1answer
44 views

Question about algorithm

https://www.shoup.net/ntb/ntb-v2.pdf, page 523, algortithm IPT I don't get the for loop, since "k" isn't used anywhere inside the loop. What am i missing?
0
votes
1answer
82 views

Is this the right way to implement ElGamal scheme over Elliptic Curves over prime field? [duplicate]

I'm fairly new to Cryptography, especially elliptic curves in general. I learned to do Point Multiplication, Scalar Multiplication and also programmatically implemented them. But I was trying to do ...
5
votes
2answers
210 views

Does homomorphic encryption hide the algorithm itself?

The question is rather simple, but finding resources and answers quite tricky. Homomorphic encryption should enable us to compute over encrypted data. What if the algorithm for computing should be ...
1
vote
1answer
90 views

Why does solving the underlying polynomial system “break” the multivariate cryptosystem

I was wondering why exactly does solving a polynomial system (directly or indirectly) "break" a multivariate cryptosystem as a digital signature. I realize that the exact reason differs from system ...
1
vote
2answers
156 views

How does this formula work $(aG + bG) = (a + b) G$ in ECDSA?

Please explain how does this formula $(aG + bG) = (a + b) G$ work in ECDSA? According to the source: $a$ and $b$ are different private keys Suppose $a = 3$ $b = 4$ then the public key is $Q = aG$...
1
vote
0answers
81 views

When Frankensteining ciphers together, why does order matter? [duplicate]

In a comment on this answer, Cort Ammon states I have heard interesting solutions to these issues involving encrypting something with a proper tested algorithm first (not second), and then ...
17
votes
4answers
9k views

Creating cryptographic algorithms at runtime

Would it be possible to create a program with which to create a cryptographic algorithm (i.e. encryption or hash) using well-known elements of other algorithms in the same way that algorithms "reuse" ...
0
votes
0answers
35 views

Is it possible to decrypt a message if a hash of the message was used as a key to encryption [duplicate]

I encountered a scheme where a hash of a message was used to encrypt the same message: result = Encrypt(message=m, key=hash(m)) Specifically: ...
1
vote
1answer
63 views

Is there such a thing as shortcutable key stretching?

I'm curious if there's a cryptographic (or mathematical) technique for key stretching that allows someone with a secret to quickly derive the final key, requires a deterministic number of rounds for ...
1
vote
0answers
82 views

Generating a MAC on a Polynomial

In the following, all the operations and polynomials are defined over a finite field of prime order, $\mathbb{F}_p$, where $p$ is a sufficiently large prime number. All polynomials and values below ...
1
vote
1answer
59 views

Algorithm/encryption technique which outputs a set number of numerical digits e.g. 20 digits from a given input

What the name of the algorithm/encryption technique which outputs a set number of numerical digits e.g. 20 digits based on some input. You can input some data e.g. text or numbers but the output is ...
1
vote
1answer
93 views

What is the most secure encryption algorithm that keeps the entropy the same or even lowers it? [closed]

On top of my mind comes caesar cipher, but that is not really secure so what is the most secure encryption algorithm that doesn't affect entropy or even lowers it? I know this might not be as ...
1
vote
1answer
51 views

Is there an algorithm that allows to distribute elements securely between parties?

Let's say we have a set of numbers $n = \{ 1, 2, 3, 4, 5, \ldots \}$ and $m$ players ($m < \operatorname{sizeof}(n)$, of course). I want to know if there's a way for all $m$'s to pick different ...
1
vote
2answers
146 views

Is obfuscation considered a cryptographic primitive?

The general definition of obfuscation is the process of obscuring a message (not necessarily source code). There is a "rigorous" method for obfuscation (indistinguishability obfuscation, ...
0
votes
0answers
43 views

Is there a name for encryption which relies on repetitive calculation (=time) instead of a key-value? (e.g. block chain, hash value, block cipher)

Many encryption problems are fast to solve if a key, factor, exponent or something similar is known. Other encryption methods don't have such keys. E.g. a hash value of another value. It's used ...
0
votes
0answers
43 views

GCD in Montgomery arithmetic

Wikipedia article on Montgomery modular multiplication contains the following statement: Many operations of interest modulo $N$ can be expressed equally well in Montgomery form. Addition, ...
8
votes
7answers
730 views

In search of a pedagogically simple example of asymmetric encryption routine?

(I am not a cryptography expert; I do write software) I am working with some youth (ages 11-13) and wanted to explore for an hour or so some basic cryptography. Doing symmetric ciphers is pretty ...
7
votes
3answers
1k views

Why is ECB+CTR not a thing?

AES-CTR is nice for its parallelizability and simplicity but if you duplicate an IV you reveal plaintext. Chaining modes like CFB and CBC don't have that problem per se but they are not ...
1
vote
0answers
32 views

Does a digital signature algorithm exist which has a normal, a blind, an elliptic curve and an elliptic curve blind version?

Q: Does a digital signature algorithm exist which has a normal, a blind, an elliptic curve and an elliptic curve blind version? I am searching for an algorithm where you can see what happens if you ...
0
votes
2answers
76 views

Is there a way to easily encode a message without a computer on either end?

I enjoy making notes and passing them to my friends, and I also like making them encrypted for no reason. My friends enjoy it too, but it's a bit annoying to use the Caesar cipher for everything ...
0
votes
0answers
41 views

Do any block cipher encryption functions (or similar functions) exist which are associative to each other and cyclic?

Most block ciphers encrypt a plaintext deterministically into a ciphertext which allows decryption in the opposite direction. Now, instead of encrypting just one plaintext, I'm looking for a cyclic '...
0
votes
0answers
69 views

Do there exist cryptographic algorithms where the “core” function is 96-to-32-bit?

There exists a FOX family of block ciphers (Wikipedia article: IDEA NXT). This cipher uses a function called "f32" which operates on three 32-bit words and outputs one 32-bit word. This function ...
4
votes
1answer
306 views

Why doesn't GMAC/GCM encrypt its authentication tag?

As most know, a duplicate nonce with GMAC/GCM allows key recovery attacks against GMAC itself and thus the ability to forge messages. This is because GMAC computes GHASH and then just XORs this with ...
2
votes
1answer
105 views

Are there any LFSR-based ciphers with variable feedback polynomials?

All LFSR-based stream ciphers that I know of use a fixed feedback polynomial (i.e. the taps are always in the same position). I know that, at least for non-trivial output lengths, it is necessary to ...
4
votes
0answers
80 views

Can zero-knowledge proof be used to determine if another person knows a certain movie with a twist ending?

Suppose I want to talk with a co-worker about a movie called "The Twist Movie". I know the movie contains an interesting twist, and bringing up the movie in a discussion about twists in movies might ...
2
votes
2answers
168 views

Efficient way of generating a random number of N (less than 64) bits with exactly M bits equal to one [closed]

Would there be an efficient way to implement a function with the following signature: unsigned long long int random_word(size_t n, size_t m) that would generate ...
5
votes
3answers
593 views

Nonce-misuse-resistance scheme applied after the fact to AES-GCM for defense in depth?

This is a follow-up to a previous question about encrypting IV/MAC results from AEAD ciphers. I have a system I'm working on that needs to use standard (NIST/FIPS) cryptography, at least for its ...
3
votes
0answers
162 views

Are there any cryptographic methods which use multiple cyclic groups?

For some cryptographic methods you can construct them. e.g. elliptic curves (product of two cyclic groups) or Diffie–Hellman (can be product of n-cyclic groups). But they have no usage because at a ...
1
vote
1answer
147 views

Risks of publishing multiple signatures

Is there a risk when publishing multiple signatures for the same message? For instance, an ECDSA key (using an EC key) and a RSA-PSS signature (using a RSA key). The context of my question is the use ...
0
votes
1answer
131 views

Is Permutation conjugate problem hard?

Let $x$,$y$,$z$ be permutations. Then public key is $z=xyx^{−1}$ and $y$. Is permutation conjugate search problem easy? if yes, how to find $x$ from $z$ and $y$? Let be a is Alice's secret key as ...
3
votes
1answer
327 views

Are “non-mathematical” encryption algorithms comparably secure against brute force key recovery?

I recently learned about a desktop encryption application called ALKEMI, which does not use mathematical encryption according to the website, which I understand to be a misnomer, at best: The ...
4
votes
1answer
173 views

How to construct a “toy” version of Gimli permutation for three (instead of twelve) 32-bit words?

I am interested to see a "toy" version of the Gimli permutation for three (instead of twelve) 32-bit words. I see that the "core" sub-permutation of Gimli operates on three 32-bit words, but I don't ...

1
2
3 4 5
16