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
1
vote
2answers
32 views

RC6 Integer operations in modulo 32 between two 32-bit blocks

I am new to cryptography and I am trying to code the RC6 (Rivest cipher 6) algorithm. The algorithm requires addition, subtraction and multiplication in modulo 232. If I am performing these operations ...
0
votes
1answer
17 views

Is there any link between group signature and multi-signature

Are both of these concepts related in someway. Can a group signature scheme be transformed into a multi-signature scheme?
0
votes
1answer
37 views

Understanding non-linearity in Salsa20 over various rings

In his design of Salsa20, Bernstein writes to ensure non-linearity he chose 32-bit addition (breaking linearity over $Z/2$), 32-bit xor (breaking linearity over $Z/2^32), and constant-distance 32-bit ...
3
votes
2answers
39 views

How are the instantiations of RSAES-OAEP and SHA*WithRSAEncryption different in practice?

For the spare-time project I had been working on, I'm evaluating the PKCS#1 padded RSA schemes for implementation. For PKCS#1 v1.5, encryption doesn't seem to require a hash function, and the ...
1
vote
0answers
68 views

Encryption of data with multiple possible decryption keys

I'm new to the Cryptography Stack Exchange, so my question might be very naive. What encryption algorithms are out there that will allow different decryption keys to decrypt the same piece of ...
1
vote
1answer
75 views

Extracting genome from a Ciphertext [closed]

Is it Probable to extract the ciphertext's genome and Visualizing it ? Converting this: ...
16
votes
3answers
10k views

How Unique is a "NeuralHash"?

I was doing some reading today about a major tech company planning to implement a new system for automatically detecting and reporting CSAM in users' photos. Overall, the system as described in their ...
3
votes
2answers
340 views

Recognize whether two random values are raised to the same power

Alice selects two random numbers from a finite field $Z_p$ : $a$ and $b$. Bob does one of the two following steps randomly (sometimes he does step 1; sometimes step 2): He chooses a random number $r$ ...
1
vote
1answer
51 views

How do we say that one cryptographic primitive is stronger than another?

Can anyone help me understand this: How do we say that one cryptographic primitive is stronger than another?
1
vote
0answers
82 views

What motivated CCM's monstrous design?

The formatting function in Appendix A of NIST-SP-800-38C is a monster enabling CCM to support variable-length nonce from 7-13 bytes, variable-length encoding of the length of the payload. Also, the ...
0
votes
0answers
42 views

Are there any block ciphers (like AES) which are (or can be) commutative under composition for different keys?

Let $BC$ be a block cipher with similar security as AES (in ECB mode). This $BC$ is applied to a message $m$ of same bit size. The result is a cipher $c$. e.g.; $$BC(key_A,m) = c_A$$ $$BC(key_B,m) = ...
-1
votes
1answer
49 views

Padding and the MD5 algorithm

In MD5, if M=100, how can we perform padding on it and how many blocks are needed in each round? These are general questions for understanding padding and rounds.
3
votes
3answers
133 views

Can you create an encryption algorithm from a signing algorithm, or vice versa?

I remember reading, a few years ago, that you couldn't prohibit encryption without prohibiting signing, as you can always make a public key encryption algorithm from a signing algorithm. (It might be ...
1
vote
1answer
20 views

crypt algorithm by a vectored key and the error is Proportional to the difference between input key and real key

I want to find an crypt algorithm which provides the functionality described below. Given a key (a vector Vkey) and a data (an image), use this key to encry the image; the encrypted image can not be ...
1
vote
0answers
43 views

Key stream instead of key schedule

Let's consider a block cipher in CTR mode. And let's consider a keyed PRNG or just a good PRNG with a seed as the key. The PRNG has to be very fast. Is it a good idea to put away the key schedule and ...
0
votes
0answers
32 views

Test vectors for SIT -encryption algorithm?

Test vectors for SIT -encryption algorithm? I'm looking for Tests Vectors to test my implementation of SIT. Thanks a lot.
0
votes
0answers
29 views

Advantages of round function as a good PRNG

If round function in block cipher is a good PRNG, does it have any advantages? Can we expect better faster diffusion or confusion? Does it make sense to design algorithms in such a way that the round ...
1
vote
4answers
172 views

Are there any cryptographic algorithms, which lets the user apply some modifications on the encoded data, without decoding it?

I would like to encode some data with a key, and send it to a third party. They don't know the key to decode it, but I would like to make it possible for them to apply some modifications on it. Then ...
0
votes
2answers
199 views

What is the name of this public key encryption cryptosystem?

I have been trying to find the name of a public key encryption cryptosystem that I learnt as an introduction to cryptography some years ago but the only scheme I could find was something similar but ...
0
votes
0answers
19 views

Few questions about setting up SuperCop primitives

Have a couple of questions about the supercop library. I've refrained from asking this question for a considerable amount of time because every time I thought about asking it, it sounded stupid in my ...
2
votes
1answer
87 views

How to produce a ternary value (3-face "dice roll") digest from a message?

Apologies in advance if the terminology I am using in the title of this question, is flawed. I want an algorithm that will produce a ternary value (meaning from a set of three, as opposed to from a ...
-2
votes
1answer
86 views

Writing an original encryption algorithm [closed]

Firstly, I'd just like to clarify, I am less than a beginner when it comes to cryptography. Please bear with me. I'm sure its flawed I just don't know how. I was bored one day, and decided to come up ...
2
votes
1answer
141 views

Does a bigger key mean more security - if we do not change the structure of the algorithm?

Let's say I have 128-bit cipher in which each round needs to get 768 key bits. Let's consider 10 rounds. It can be easily 128-bit key cipher. I can do key schedule and produce 7680 bits of keys (let's ...
0
votes
2answers
122 views

Encrypting cryptocurrency seeds for cold storage

I’d like some feedback on an encrypting algorithm. I’m not rolling my own, but even putting together well-proved pieces may create many pitfalls. (I don’t know if I'm stretching questioning in this ...
0
votes
2answers
104 views

How can a recipient recognize which encrypted messages are intended for them?

Let's say there's a decentralized email service where parties' public keys are known. A sender sends a message to a recipient by encrypting via RSA with the recipient's public key and posting the ...
3
votes
2answers
89 views

Using $key^{th}$ multiple of $\pi$ as a one-time pad

With a key $k$ of sufficient length, say 128 bits, is it possible to use $k^{th}$ multiple of $\pi$ as a one-time pad? Please enlighten on the security as well as practical aspects (only if secure of ...
0
votes
1answer
77 views

Why computation of $u*v^3*(u*v^7)^{(p-5)/8}$ is suggested instead of $(u/v)^{(p+3)/8}$

Working with Curve25519 I've faced with suggested form of computation square root candidate as: $uv^3(uv^7)^{\frac{p-5}{8}}$ instead of $\left(\frac{u}{v}\right)^{\frac{p+3}{8}}$. Why it is so? Or why ...
2
votes
0answers
60 views

Is there any way to encrypt the path in between a small number of 3D positions?

Or more general: given two valid random cipher $c_0, c_1$ a function $D$ with $$D(c_0,c_1) = (a,b,c)$$ should exist but hard to compute (for most cases). The result $(a,b,c)$ represents the path from $...
2
votes
1answer
70 views

Is there any block-cipher, format-preserving or similar encryption method with known cycle size? (without short-cut, with known source/runtime vars)

E.g. given a $n$-bit message $m_0$ and an encryption function $f$ After applying the function $c$ times it will result in $m_0$ again. $f^1(m_0) = f(m_0) = m_1$ $f^2(m_0) = f(f(m_0)) = f(m_1) = m_2$ .....
2
votes
0answers
68 views

Is this "AND" implementation safe against side channel attacks?

I found out that the following is a working implementation of calculating an AND function between XOR masked shares, implementation at Github. It works by calculating parities, whose terms cancel each ...
0
votes
1answer
53 views

Can Hash Functions take fixed-size input?

I‘ve argued for quite some time with a friend about wether or not this C# method can be qualified as a Hash Function. ...
5
votes
2answers
316 views

Recommendation of lightweight RNG for Miller-Rabin primality test

Miller-Rabin tests the compositeness of candidate numbers (hence, input $x$) that's often used as a primality test. The M-R test requires different random numbers for accuracy and confidence in the ...
2
votes
1answer
71 views

Building a 4-bit S-box with a 4-uniform DDT

I am looking for a 4-bit S-box which has only 4s in its difference distribution table (except the top left corner) but I was not able to find one in the literature. Has such an S-box been already ...
1
vote
2answers
138 views

Question about SSH host key algorithms

I'm currently writing a report for my Master's degree on the SSH protocol. Quite interesting! However I'm having trouble getting into the inner workings of the host key algorithms. For example, ...
6
votes
3answers
335 views

Nothing-up-my-sleeve numbers standard

Premise Several cryptographic primitives employ randomized numerical constants. To avoid suspicious that the designer selected such constants in order to plant a backdoor, "nothing-up-my-sleeve ...
1
vote
3answers
128 views

Does this algorithm have a name? (Distance between letters)

This came to mind the other day and I'm wanting to know if there is a name for the following algorithm (I'm not sure if "cipher" is the right word for it): Take two consecutive letters at a ...
6
votes
1answer
252 views

Fast irreversible transformation/compression of short messages using a secret

I'm looking for a very fast function $f(m, k) $ that takes a 64-bit integer $m$ and a fixed secret key $k$ of virtually any size (generated by a CSPRNG) and turns them into a 64- or 32-bit integer $ r ...
1
vote
1answer
82 views

Long or short encryptions?

Is it generally considered desirable - or not? - to use an algorithm which encrypts a single byte into a byte array of length around 5 or 10? Greater length allows me to add additional layers of ...
0
votes
1answer
52 views

Name for crypto algorithm that preserves visual pattern

Given some input plaintext and output ciphertext, is there a group of crypto algorithms that mean that a change in the ending x bytes of the input plaintext makes some y change at the end of the ...
2
votes
3answers
115 views

Reason for squaring and not arbitrary exponentiation in Wesolowski and Pietrzak verifiable delay functions (VDFs)

I'm working at understanding the Wesolowski and Pietrzak RSA group based VDFs (verifiable delay functions). These basically work by requiring the prover to do a bunch of repeated squaring within a ...
1
vote
1answer
84 views

Hashes or ciphers with all rounds executed in parallel?

Pretty much every cipher or hash I've seen has multiple rounds the are designed to be run serially one after the other. Has anyone ever designed a fully parallel cipher or hash? This would be one ...
0
votes
0answers
37 views

Brute force attack on a block cipher with length n [duplicate]

Consider a block cipher whose block length is 𝑛. 𝑁 = 2𝑛 is number of possibilities. Imagine we have 𝑡 plain text-cipher text pairs { 𝑃𝑖, 𝐶𝑖 = 𝐸𝐾(𝑃𝑖) } , where the key 𝐾 selects one of ...
2
votes
1answer
110 views

Unbalanced numeric Feistel network implementation

After reading a comprehensive paper [1] covering various kinds of generalized Feistel networks, I've tried to implement the Unbalanced Numeric Feistel variant, which relies on modular arithmetic for ...
-1
votes
1answer
95 views

Alternatives to XTEA as encryption algorithms for stenography

I recently implemented an algorithm written in Python that was using the XTEA encryption method. Are there any more reliable algorithms than the XTEA , regarding to memory usage and PSNR ratio ,other ...
10
votes
2answers
2k views

Why is this not a viable key exchange algorithm? [duplicate]

I was just wondering why this kind of algorithm can't be used instead of, say, Diffie-Hellman to exchange keys: Alice decides on a key she wishes to share with Bob. Alice generates a stream of bytes ...
0
votes
0answers
92 views

Most popular block ciphers

Which block (cipher) algorithms are the most popular and most used today? What parameter values (block length, key length) are now considered standard (safe).
0
votes
0answers
54 views

Is this really a universal one-way function?

This PDF supposedly gives a construction of a universal one-way function, i.e. a function which is one-way as long as there exists a one-way function: Recall that there are only countably many Turing ...
1
vote
0answers
54 views

Hashing of variable-length chunked data leading to leakage of secret key from side channel?

Hypothetically, secret data could be hashed in some schemes in one way or another. Could chunking of the data lead to exposure of secret component through side channel? Say converting a randomized ...
0
votes
0answers
36 views

Generating traceable passwords

I'm new to cryptography, so please bear with me as I try to explain what's going in my head. I have an idea to write a program to generate one-time passwords for online conferences that are although ...
3
votes
1answer
76 views

Multilinear Extension Polynomial: Compute the coefficients of the expanded polynomial

Let $\textbf{a}=\left[10, 32, 57, 81\right]$ and $x=\{0, 1, 2, 3\}$. Then multilinear extension of vector $\textbf{a}$ is the polynomial, $f_\textbf{a}(x_2, x_1) = 10(1-x_2)(1-x_1) + 32(1-x_2)x_1 + ...

1
2 3 4 5
16